[PATCH] D45878: [DEBUG INFO] Fixing cases where debug info (-g) causes changes in the program.

Jonas Paulsson via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri May 4 02:52:33 PDT 2018


jonpa added inline comments.


================
Comment at: lib/Target/SystemZ/SystemZElimCompare.cpp:195
+  DbgValues.clear();
+  if (!MI.getOperand(0).isReg())
+    return;
----------------
bjope wrote:
> Shouldn't we iterate over all MI defs (both explicit and implicit)?
> If there is a reason for limiting this to check some operands, then perhaps this check should be on the caller side (and then the register could be passed as an argument).
This was the behaviour I found in MachineSink.cpp, which I guess kind of works generally.

I agree with you that it seems right to do a best-effort check since it will not be done (cause compile time regression) without -g.






https://reviews.llvm.org/D45878





More information about the llvm-commits mailing list