[llvm-dev] DBG_VALUE insertion for spills breaks bundles

Verma, Saurabh via llvm-dev llvm-dev at lists.llvm.org
Tue Dec 19 08:13:45 PST 2017


Hi,

The insertion of DBG_VALUE instructions for spills does not seem to be handling insert locations inside bundles well. If the spill instruction is part of a bundle, the new DBG_VALUE is inserted after it, but does not have the bundling flags set. This essentially means that if we start with a set of bundled instructions:

MI1 [BundledSucc=true,  BundledPred=false]
MI2 [BundledSucc=false, BundledPred=true]

Where MI1 is a spill, and MI2 is a different instruction, after ExtendRanges we end up with

MI1 [BundledSucc=true,  BundledPred=false]
DBG_VALUE MI [BundledSucc=false,  BundledPred=false]
MI2 [BundledSucc=false, BundledPred=true]

Since this happens after the final instruction scheduling, it results in broken schedules. I believe setting the bundling flags before invoking MBB->insertAfter in ExtendRanges should fix this.

Best regards
Saurabh Verma
--------------------------------------------------------------
Intel Research and Development Ireland Limited
Registered in Ireland
Registered Office: Collinstown Industrial Park, Leixlip, County Kildare
Registered Number: 308263


This e-mail and any attachments may contain confidential material for the sole
use of the intended recipient(s). Any review or distribution by others is
strictly prohibited. If you are not the intended recipient, please contact the
sender and delete all copies.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20171219/70314b80/attachment.html>


More information about the llvm-dev mailing list