This patch makes sure that a debug value that is after the bitcast in dupRetToEnableTailCallOpts() is also skipped.
The reduced test case is from SPEC-2006 on SystemZ.
Differential D57050
[CodeGenPrepare] Handle all debug calls in dupRetToEnableTailCallOpts() jonpa on Jan 22 2019, 5:54 AM. Authored by
Details
Diff Detail Event TimelineComment Actions Thanks for the patch. Could you please reduce the test case a bit further? There are kilobytes of debug info metadata here which don't appear necessary for reproducing the problem. To start, I suggest running opt -strip -metarenamer -debugify on the IR input. That should still reproduce the issue. Comment Actions
Comment Actions
Ah, that's how you do it! :-) Test case reduced.
Comment Actions The test case looks much better now, thanks. Usually we include a short set of instructions in the test case on how to produce the IR, including the source code, in case the IR needs to be re-generated in response to a format change etc. Other than that, LGTM. Comment Actions I was not aware of that... The Debug info is just all "dummy" which has just been copied-and-pasted into the test case. I'm afraid I think my .ll test case is gone at the moment. Do you really need me to regenerate it, or could it be accepted given its small size? (I don't think reducing the source input is meaningful given that the debug-info is not "real", right?) Comment Actions If that's the case a brief excerpt of the original source construct (C, C++ or otherwise) that was used to produce the IR along with a couple of command lines to produce the MIR file should be sufficient. It doesn't have to be exact, but just so that the poor soul who has to regenerate the IR at some point in the future has something to go on. Check out llvm/test/CodeGen/MIR/X86/branch-folder-with-label.mir for an example. Comment Actions I made a new reduced MIR test case from the original source file and this time included the IR as a comment. Hope that works. Comment Actions I see a minor issue in the test, but the patch looks great to me otherwise. Thanks!
|
Something might have went wrong during the test update -- I think Wolfgang's comment about the missing bitcast applies again?