[PATCH] D30835: [DebugInfo][X86] Teach Optimize LEAs pass to handle debug values

David Blaikie via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Mar 10 10:22:03 PST 2017


dblaikie added a comment.

Looks like this change does two things - fixes the "debug info affects optimization" and also does some work to improve optimized debug info quality? Might be worth separating this into two changes to make sure there's good test coverage/easier to review/etc?



================
Comment at: lib/Target/X86/X86OptimizeLEAs.cpp:599
         // isReplaceable function.
+        const unsigned FirstVReg = First.getOperand(0).getReg();
         for (auto UI = MRI->use_begin(Last.getOperand(0).getReg()),
----------------
LLVM doesn't have much top level const like this - I'd probably leave it off.


https://reviews.llvm.org/D30835





More information about the llvm-commits mailing list