Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1011)

Unified Diff: src/IceTargetLoweringMIPS32.cpp

Issue 2455933002: Subzero, MIPS32: Stacksave/Stackrestore implementation (Closed)
Patch Set: Enabled tests in nacl-other-intrinsics.ll Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/IceTargetLoweringMIPS32.h ('k') | tests_lit/llvm2ice_tests/nacl-other-intrinsics.ll » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/IceTargetLoweringMIPS32.cpp
diff --git a/src/IceTargetLoweringMIPS32.cpp b/src/IceTargetLoweringMIPS32.cpp
index cca3962750704964c7742990968db0570a809dbf..a15241f76d31c649eb8113605d148325d177f279 100644
--- a/src/IceTargetLoweringMIPS32.cpp
+++ b/src/IceTargetLoweringMIPS32.cpp
@@ -4428,11 +4428,18 @@ void TargetMIPS32::lowerIntrinsicCall(const InstIntrinsicCall *Instr) {
return;
}
case Intrinsics::Stacksave: {
- UnimplementedLoweringError(this, Instr);
+ Variable *SP = getPhysicalRegister(RegMIPS32::Reg_SP);
+ _mov(Dest, SP);
return;
}
case Intrinsics::Stackrestore: {
- UnimplementedLoweringError(this, Instr);
+ if (getFlags().getUseSandboxing()) {
+ UnimplementedLoweringError(this, Instr);
+ return;
+ }
+ Variable *Val = legalizeToReg(Instr->getArg(0));
+ Variable *SP = getPhysicalRegister(RegMIPS32::Reg_SP);
+ _mov_redefined(SP, Val);
return;
}
case Intrinsics::Trap: {
« no previous file with comments | « src/IceTargetLoweringMIPS32.h ('k') | tests_lit/llvm2ice_tests/nacl-other-intrinsics.ll » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698