Commit 60d9010
committed
AMDGPU: Fix issue in shl(or) combine
The code is doing the optimization: `((a | c1) << c2)` ==> `(a << c2) + (c1 << c2)` But this is only valid if `a` and `c1` have no common bits being set. Differential Revision: https://reviews.llvm.org/D1502461 parent 5130e04 commit 60d9010
File tree
2 files changed
+22
-19
lines changed- llvm
- lib/Target/AMDGPU
- test/CodeGen/AMDGPU
2 files changed
+22
-19
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
9550 | 9550 | | |
9551 | 9551 | | |
9552 | 9552 | | |
| 9553 | + | |
| 9554 | + | |
9553 | 9555 | | |
9554 | 9556 | | |
9555 | 9557 | | |
| |||
9584 | 9586 | | |
9585 | 9587 | | |
9586 | 9588 | | |
9587 | | - | |
9588 | | - | |
| 9589 | + | |
| 9590 | + | |
| 9591 | + | |
| 9592 | + | |
| 9593 | + | |
| 9594 | + | |
| 9595 | + | |
| 9596 | + | |
9589 | 9597 | | |
9590 | 9598 | | |
9591 | 9599 | | |
| |||
9595 | 9603 | | |
9596 | 9604 | | |
9597 | 9605 | | |
9598 | | - | |
9599 | 9606 | | |
9600 | 9607 | | |
9601 | 9608 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
410 | 410 | | |
411 | 411 | | |
412 | 412 | | |
413 | | - | |
414 | 413 | | |
415 | | - | |
416 | | - | |
417 | | - | |
418 | | - | |
419 | | - | |
| 414 | + | |
| 415 | + | |
420 | 416 | | |
421 | | - | |
| 417 | + | |
| 418 | + | |
422 | 419 | | |
423 | 420 | | |
424 | 421 | | |
| |||
427 | 424 | | |
428 | 425 | | |
429 | 426 | | |
430 | | - | |
431 | | - | |
432 | | - | |
433 | | - | |
434 | | - | |
435 | | - | |
436 | | - | |
437 | | - | |
438 | | - | |
| 427 | + | |
| 428 | + | |
| 429 | + | |
| 430 | + | |
| 431 | + | |
| 432 | + | |
| 433 | + | |
| 434 | + | |
439 | 435 | | |
440 | 436 | | |
441 | 437 | | |
| |||
0 commit comments