diff options
| author | Richard Osborne <richard@xmos.com> | 2011-08-24 13:32:43 +0000 |
|---|---|---|
| committer | Richard Osborne <richard@xmos.com> | 2011-08-24 13:32:43 +0000 |
| commit | 6e3c83eb1c0b2f0f7a1a81f8cbda0540f7b1a59c (patch) | |
| tree | e01315b2c8a9fa36345054777eba3e6bd377d13d /llvm/lib | |
| parent | 95589f13ff24ccecb82e7c30e1fb444c846b26f8 (diff) | |
| download | bcm5719-llvm-6e3c83eb1c0b2f0f7a1a81f8cbda0540f7b1a59c.tar.gz bcm5719-llvm-6e3c83eb1c0b2f0f7a1a81f8cbda0540f7b1a59c.zip | |
Add Uses=[SP] to call instructions. This fixes a miscompilation with a
variable sized alloca.
llvm-svn: 138433
Diffstat (limited to 'llvm/lib')
| -rw-r--r-- | llvm/lib/Target/XCore/XCoreInstrInfo.td | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/llvm/lib/Target/XCore/XCoreInstrInfo.td b/llvm/lib/Target/XCore/XCoreInstrInfo.td index a1ec8aad87b..a9604692466 100644 --- a/llvm/lib/Target/XCore/XCoreInstrInfo.td +++ b/llvm/lib/Target/XCore/XCoreInstrInfo.td @@ -739,7 +739,7 @@ def LDAP_lu10_ba : _FLU10<(outs), let isCall=1, // All calls clobber the link register and the non-callee-saved registers: -Defs = [R0, R1, R2, R3, R11, LR] in { +Defs = [R0, R1, R2, R3, R11, LR], Uses = [SP] in { def BL_u10 : _FU10< (outs), (ins calltarget:$target, variable_ops), @@ -981,7 +981,7 @@ def ECALLF_1r : _F1R<(outs), (ins GRRegs:$src), let isCall=1, // All calls clobber the link register and the non-callee-saved registers: -Defs = [R0, R1, R2, R3, R11, LR] in { +Defs = [R0, R1, R2, R3, R11, LR], Uses = [SP] in { def BLA_1r : _F1R<(outs), (ins GRRegs:$addr, variable_ops), "bla $addr", [(XCoreBranchLink GRRegs:$addr)]>; |

