Chromium Code Reviews| Index: src/IceTargetLowering.cpp |
| diff --git a/src/IceTargetLowering.cpp b/src/IceTargetLowering.cpp |
| index 0ee0afa2301929fa5e2596a709f0db2bd03e3886..5679b107591ac88224392069be6e275ce34280b4 100644 |
| --- a/src/IceTargetLowering.cpp |
| +++ b/src/IceTargetLowering.cpp |
| @@ -363,7 +363,9 @@ void TargetLowering::getVarStackSlotParams( |
| VarList SpilledVariables; |
| for (Variable *Var : Variables) { |
| if (Var->hasReg()) { |
| - RegsUsed[Var->getRegNum()] = true; |
| + // Rematerializable uses of esp/ebp do not count as uses for spilling. |
|
John
2015/11/16 14:00:02
I would rather say
... uses of stack/frame pointe
Jim Stichnoth
2015/11/16 14:47:57
I don't understand what this change does.
The pur
sehr
2015/11/16 18:42:24
Well, it doesn't work to remove it, as I discovere
sehr
2015/11/16 18:42:24
Done.
Jim Stichnoth
2015/11/16 22:47:18
I spent some quality time with the code to underst
|
| + if( !Var->isRematerializable()) |
|
Jim Stichnoth
2015/11/16 14:47:57
Please run clang-format...
sehr
2015/11/16 18:42:24
Done.
|
| + RegsUsed[Var->getRegNum()] = true; |
| continue; |
| } |
| // An argument either does not need a stack slot (if passed in a register) |