Commit a8b5601
Automerge: [slp][profcheck] Mark
There are 2 cases:
- either the `select` condition is a vector of bools, case in which we don't currently have a way to represent the per-element branch probabilities anyway;
- or the select condition is a scalar, for example from a `llvm.vector.reduce`. We could potentially try and do more here - if the reduced vector contained conditions from other selects, for instance
In either case, IIUC, chances are the `select` doesn't get lowered to a branch, at least I'm not seeing any evidence of that in an internal complex application (CSFDO + ThinLTO). Seems sufficient to mark the selects are unknown (for profiled functions); since that metadata carries with it the pass name (`DEBUG_TYPE`) that marked it as such, we can revisit this if we detect later lowerings of these selects that would have required an actual profile.
Issue #147390selects as having unknown profile (#162960)File tree
4 files changed
+27
-82
lines changed- llvm
- include/llvm/IR
- lib
- IR
- Transforms/Vectorize
- utils
4 files changed
+27
-82
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2548 | 2548 | | |
2549 | 2549 | | |
2550 | 2550 | | |
| 2551 | + | |
| 2552 | + | |
| 2553 | + | |
| 2554 | + | |
| 2555 | + | |
2551 | 2556 | | |
2552 | 2557 | | |
2553 | 2558 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
25 | 25 | | |
26 | 26 | | |
27 | 27 | | |
| 28 | + | |
28 | 29 | | |
29 | 30 | | |
30 | 31 | | |
| |||
1002 | 1003 | | |
1003 | 1004 | | |
1004 | 1005 | | |
| 1006 | + | |
| 1007 | + | |
| 1008 | + | |
| 1009 | + | |
| 1010 | + | |
| 1011 | + | |
| 1012 | + | |
| 1013 | + | |
| 1014 | + | |
| 1015 | + | |
| 1016 | + | |
| 1017 | + | |
1005 | 1018 | | |
1006 | 1019 | | |
1007 | 1020 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
19460 | 19460 | | |
19461 | 19461 | | |
19462 | 19462 | | |
19463 | | - | |
| 19463 | + | |
| 19464 | + | |
19464 | 19465 | | |
19465 | 19466 | | |
19466 | 19467 | | |
| |||
23580 | 23581 | | |
23581 | 23582 | | |
23582 | 23583 | | |
23583 | | - | |
| 23584 | + | |
23584 | 23585 | | |
23585 | | - | |
| 23586 | + | |
23586 | 23587 | | |
23587 | 23588 | | |
23588 | 23589 | | |
23589 | 23590 | | |
23590 | 23591 | | |
23591 | 23592 | | |
23592 | | - | |
| 23593 | + | |
23593 | 23594 | | |
23594 | | - | |
| 23595 | + | |
| 23596 | + | |
23595 | 23597 | | |
23596 | 23598 | | |
23597 | 23599 | | |
| |||
23612 | 23614 | | |
23613 | 23615 | | |
23614 | 23616 | | |
23615 | | - | |
| 23617 | + | |
| 23618 | + | |
23616 | 23619 | | |
23617 | 23620 | | |
23618 | 23621 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1312 | 1312 | | |
1313 | 1313 | | |
1314 | 1314 | | |
1315 | | - | |
1316 | | - | |
1317 | | - | |
1318 | | - | |
1319 | | - | |
1320 | | - | |
1321 | | - | |
1322 | | - | |
1323 | | - | |
1324 | | - | |
1325 | | - | |
1326 | | - | |
1327 | | - | |
1328 | | - | |
1329 | | - | |
1330 | | - | |
1331 | | - | |
1332 | | - | |
1333 | | - | |
1334 | | - | |
1335 | | - | |
1336 | | - | |
1337 | | - | |
1338 | | - | |
1339 | | - | |
1340 | | - | |
1341 | | - | |
1342 | | - | |
1343 | | - | |
1344 | | - | |
1345 | | - | |
1346 | | - | |
1347 | | - | |
1348 | | - | |
1349 | | - | |
1350 | | - | |
1351 | | - | |
1352 | | - | |
1353 | | - | |
1354 | | - | |
1355 | | - | |
1356 | | - | |
1357 | | - | |
1358 | | - | |
1359 | | - | |
1360 | | - | |
1361 | | - | |
1362 | | - | |
1363 | | - | |
1364 | | - | |
1365 | | - | |
1366 | | - | |
1367 | | - | |
1368 | | - | |
1369 | | - | |
1370 | | - | |
1371 | | - | |
1372 | | - | |
1373 | | - | |
1374 | | - | |
1375 | | - | |
1376 | | - | |
1377 | | - | |
1378 | | - | |
1379 | | - | |
1380 | | - | |
1381 | | - | |
1382 | | - | |
1383 | | - | |
1384 | | - | |
1385 | | - | |
1386 | | - | |
1387 | | - | |
1388 | | - | |
1389 | | - | |
1390 | | - | |
1391 | 1315 | | |
1392 | 1316 | | |
1393 | 1317 | | |
| |||
0 commit comments