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

Andrew Ng via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Mar 10 10:01:55 PST 2017


andrewng created this revision.

This patch fixes an issue in the Optimize LEAs pass where redundant LEAs were not removed because they were being used by debug values. This issue was discovered when comparing the output of optimized code with and without debug info.

The debug value instructions are now ignored when determining whether LEAs are redundant. The debug values for the redundant LEAs are also updated accordingly.

Please let me know if this is OK to commit. Thank you.


https://reviews.llvm.org/D30835

Files:
  lib/Target/X86/X86OptimizeLEAs.cpp
  test/CodeGen/X86/lea-opt-with-debug.mir

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D30835.91366.patch
Type: text/x-patch
Size: 10376 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20170310/2ebec963/attachment.bin>


More information about the llvm-commits mailing list