Rohit Aggarwal via llvm-dev
2021-Aug-18 20:21 UTC
[llvm-dev] After InstCombine pass, expected output got changed
Hi All, I am running the instcombine pass on the given lR and executing the binary. *./build_release13x/bin/opt -enable-new-pm=false -instcombine sample.ll -S -o sample_instcombined_llvm.ll && ./build_release13x/bin/clang sample_instcombined_llvm.ll && ./a.out* But before passing to instcombine, the output is *CE6DB4AC* and after passing to instcombine value changes to *3B83FBC*. I tried to debug the issue and found that due to the occurence of poison value, some instructions(or, store,..) are getting deleted/erased. I also observed that there are active changes happening related to poison values in the community. Is this behaviour expected one? Or Could it be a side effect of those changes? Thanks and Regards, Rohit Aggarwal Compiler Engineer - AMD -- Disclaimer:- This footer text is to convey that this email is sent by one of the users of IITH. So, do not mark it as SPAM. -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20210819/4f5ea5e5/attachment-0001.html> -------------- next part -------------- A non-text attachment was scrubbed... Name: sample.ll.tar.gz Type: application/gzip Size: 49311 bytes Desc: not available URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20210819/4f5ea5e5/attachment-0001.bin>
Florian Hahn via llvm-dev
2021-Aug-19 08:49 UTC
[llvm-dev] After InstCombine pass, expected output got changed
Hi,> On Aug 18, 2021, at 21:21, Rohit Aggarwal via llvm-dev <llvm-dev at lists.llvm.org> wrote: > > > Hi All, > > I am running the instcombine pass on the given lR and executing the binary. > > ./build_release13x/bin/opt -enable-new-pm=false -instcombine sample.ll -S -o sample_instcombined_llvm.ll && ./build_release13x/bin/clang sample_instcombined_llvm.ll && ./a.out > > But before passing to instcombine, the output is CE6DB4AC and after passing to instcombine value changes to 3B83FBC. > > I tried to debug the issue and found that due to the occurence of poison value, some instructions(or, store,..) are getting deleted/erased. > > I also observed that there are active changes happening related to poison values in the community. Is this behaviour expected one? Or Could it be a side effect of those changesThere are 2 potential causes for the difference: 1) your input has undefined behavior and/or the result depends on a poison value or 2) a bug in instcombine. Without narrowing things down to the problematic pattern, it is very hard to say which one it is. I’d suggest you try to isolate the change in behavior to the problematic instcombine pattern and minimize the input IR to trigger the problematic pattern. Cheers, Florian -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20210819/07132b99/attachment.html>