[PATCH] [StatepointLowering] Reuse stack slots across basic blocks

Igor Laevsky igor at azulsystems.com
Thu Jun 4 11:39:23 PDT 2015


Hi reames, sanjoy,

During statepoint lowering we can sometimes avoid spilling of the value if we know that it was already spilled for previous statepoint.
We were doing this by checking if incoming statepoint value was lowered into load from stack slot. This was working only in boundaries of one basic block.

But instead of looking at the lowered node we can look directly at the llvm-ir value and if it was gc.relocate (or some simple modification of it) look up stack slot for it's derived pointer and reuse stack slot from it. This allows us to look across basic block boundaries.

REPOSITORY
  rL LLVM

http://reviews.llvm.org/D10251

Files:
  lib/CodeGen/SelectionDAG/StatepointLowering.cpp
  test/CodeGen/X86/statepoint-stack-usage.ll

EMAIL PREFERENCES
  http://reviews.llvm.org/settings/panel/emailpreferences/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D10251.27137.patch
Type: text/x-patch
Size: 12747 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20150604/b028801f/attachment.bin>


More information about the llvm-commits mailing list