[PATCH] D59106: [CodeGen] Add MMOs to statepoint nodes during SelectionDAG

Philip Reames via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Mar 7 12:52:31 PST 2019


reames created this revision.
reames added reviewers: skatkov, fedor.sergeev.
Herald added subscribers: bollu, mcrosier.
Herald added a project: LLVM.

The existing statepoint lowering code does something odd; it adds machine memory operands post instruction selection.  This was copied from the stackmap/patchpoint implementation, but appears to be non-idiomatic.

This change is largely NFC.  It moves the MMO creation logic into SelectionDAG building.  It ends up not quite being NFC because the size of the stack slot is reflected in the MMO.  The old code blindly used pointer size for the MMO size, which appears to have always been incorrect for larger values.  It just happened nothing actually relied on the MMOs, so it worked out okay.

For context, I'm planning on removing the MOVolatile flag from these in a future commit, and then removing the MOStore flag from deopt spill slots in a separate one.  Doing so is motivated by a small test case where we should be able to better schedule spill slots, but don't do so due to a memory use/def implied by the statepoint.


Repository:
  rL LLVM

https://reviews.llvm.org/D59106

Files:
  lib/CodeGen/SelectionDAG/StatepointLowering.cpp
  lib/CodeGen/TargetLoweringBase.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D59106.189769.patch
Type: text/x-patch
Size: 8194 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20190307/ab172cba/attachment.bin>


More information about the llvm-commits mailing list