In the previous commit, the register was saved, but space was not allocated.
This resulted in the parameter save area potentially clobbering r30, leading to
nasty results.
Details
- Reviewers
hfinkel - Commits
- rG654346e6f9a8: Fully fix Bug #22115.
rL225573: Fully fix Bug #22115.
Diff Detail
- Repository
- rL LLVM
Event Timeline
lib/Target/PowerPC/PPCFrameLowering.cpp | ||
---|---|---|
1163 ↗ | (On Diff #17951) | This variable is only used inside the if statement. Why are you creating it out here? |
lib/Target/PowerPC/PPCMachineFunctionInfo.h | ||
123 ↗ | (On Diff #17951) | We don't initialize all of the member variables here, but I'd rather we did. Can you please initialize PICBasePointerSaveIndex here. |
lib/Target/PowerPC/PPCFrameLowering.cpp | ||
---|---|---|
1163 ↗ | (On Diff #17951) | It's how the others do it (BPSI is identical, which is where I copied it from). I'll fix this one though. |
1163 ↗ | (On Diff #17951) | D'oh, bad reading on my part. Ignore this. BPSI is used in the condition. |
lib/Target/PowerPC/PPCMachineFunctionInfo.h | ||
123 ↗ | (On Diff #17951) | Sure thing. |
Thanks. With those changes, LGTM.
-Hal
- Original Message -----
From: "Justin Hibbits" <jrh29@alumni.cwru.edu>
To: jrh29@alumni.cwru.edu, hfinkel@anl.gov
Cc: llvm-commits@cs.uiuc.edu
Sent: Friday, January 9, 2015 5:26:23 PM
Subject: Re: [PATCH] Fully fix Bug #22115.Comment at: lib/Target/PowerPC/PPCFrameLowering.cpp:1163
@@ +1162,3 @@
+ // Only used in SVR4 32-bit.
+ int PBPSI = FI->getPICBasePointerSaveIndex();+ if (FI->usesPICBase()) {
hfinkel wrote:
This variable is only used inside the if statement. Why are you
creating it out here?It's how the others do it (BPSI is identical, which is where I copied
it from). I'll fix this one though.Comment at: lib/Target/PowerPC/PPCMachineFunctionInfo.h:123
@@ -119,3 +122,3 @@MF(MF), UsesPICBase(0) {}
hfinkel wrote:
We don't initialize all of the member variables here, but I'd
rather we did. Can you please initialize PICBasePointerSaveIndex
here.Sure thing.
EMAIL PREFERENCES
http://reviews.llvm.org/settings/panel/emailpreferences/