When @llvm.returnaddress is called with a value higher than 0 it needs to read from the call stack to get the return address. This means that the register windows needs to be flushed to the stack to guarantee that the data read is valid. For values higher than 1 this is done indirectly by the call to getFRAMEADDR(), but not for the value 1.
Details
Details
Diff Detail
Diff Detail
- Repository
- rL LLVM
Event Timeline
lib/Target/Sparc/SparcISelLowering.cpp | ||
---|---|---|
2733 ↗ | (On Diff #153051) | Maybe pull FLUSHW out of getFRAMEADDR, into LowerFRAMEADDR, so it doesn't get emitted twice here for returnaddress(>= 2) calls? |
Comment Actions
Added optional argument to getFRAMEADDR to always flush register windows regardless of depth. Also simplified the code a bit.