diff options
| author | Roman Lebedev <lebedev.ri@gmail.com> | 2019-05-28 17:53:54 +0000 |
|---|---|---|
| committer | Roman Lebedev <lebedev.ri@gmail.com> | 2019-05-28 17:53:54 +0000 |
| commit | 1499f65ac1702d0858c1f7a5406929040a2e6e1e (patch) | |
| tree | 8b0db7d2ce6855737f1557042df28c740fc36401 /llvm/test/CodeGen/SPARC | |
| parent | 19f51ec04ac1edd0b278e23b8b5cb3ff49c2dd08 (diff) | |
| download | bcm5719-llvm-1499f65ac1702d0858c1f7a5406929040a2e6e1e.tar.gz bcm5719-llvm-1499f65ac1702d0858c1f7a5406929040a2e6e1e.zip | |
[DAGCombiner][X86][AArch64][SPARC][SystemZ] y - (x + C) -> (y - x) - C fold
Summary:
Direct sibling of D62223 patch.
While i don't have a direct motivational pattern for this,
it would seem to make sense to handle both patterns (or none),
for symmetry?
The aarch64 changes look neutral;
sparc and systemz look like improvement (one less instruction each);
x86 changes - 32bit case improves, 64bit case shows that LEA no longer
gets constructed, which may be because that whole test is `-mattr=+slow-lea,+slow-3ops-lea`
https://rise4fun.com/Alive/ffh
Reviewers: RKSimon, craig.topper, spatel, t.p.northover
Reviewed By: t.p.northover
Subscribers: t.p.northover, jyknight, javed.absar, kristof.beyls, fedor.sergeev, jrtc27, llvm-commits
Tags: #llvm
Differential Revision: https://reviews.llvm.org/D62252
llvm-svn: 361853
Diffstat (limited to 'llvm/test/CodeGen/SPARC')
| -rw-r--r-- | llvm/test/CodeGen/SPARC/2013-05-17-CallFrame.ll | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/llvm/test/CodeGen/SPARC/2013-05-17-CallFrame.ll b/llvm/test/CodeGen/SPARC/2013-05-17-CallFrame.ll index 1a97e4e317e..274e99b114c 100644 --- a/llvm/test/CodeGen/SPARC/2013-05-17-CallFrame.ll +++ b/llvm/test/CodeGen/SPARC/2013-05-17-CallFrame.ll @@ -15,10 +15,9 @@ define void @variable_alloca_with_adj_call_stack(i32 %num) { ; V8-NEXT: .cfi_register 15, 31 ; V8-NEXT: add %i0, 7, %i0 ; V8-NEXT: and %i0, -8, %i0 -; V8-NEXT: add %i0, 8, %i0 ; V8-NEXT: sub %sp, %i0, %i0 -; V8-NEXT: add %i0, 96, %o0 -; V8-NEXT: mov %i0, %sp +; V8-NEXT: add %i0, -8, %sp +; V8-NEXT: add %i0, 88, %o0 ; V8-NEXT: add %sp, -16, %sp ; V8-NEXT: st %o0, [%sp+104] ; V8-NEXT: st %o0, [%sp+100] |

