-
Notifications
You must be signed in to change notification settings - Fork 13.5k
SimplifyCFG removes needed path of computed goto #117724
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Do you see this on current main? This looks like the issue 3c9022c fixed. |
I am still seeing the problem and have confirmed commit 3c9022c is present and correct in my build. I am also seeing the problem on Compiler Explorer trunk build '''clang version 20.0.0git (https://github.com/llvm/llvm-project.git 4527894)''' which appears to be up to date as of 26th November 2024, so do not think this is a local build problem. |
Can you share the compiler explorer link? In https://clang.godbolt.org/z/z58j37661 I see the constant 3735928559. |
Argh, apologies I had the wrong explorer page open and was looking at the LLVM 19 results (in which it is broken). I can now see that compiler explorer trunk build does work ok. I need to dig and find why my local build of main still exhibits the problem. |
There was a followup fix yesterday in 39601a6, so maybe your local build doesn't have that one? |
For the record, #117869 is the backport PR. |
Ah, thank you I did not have yesterday's follow-up fix. Rebuilding now to confirm my local build works. |
I have confirmed the fix 39601a6 from yesterday does fix my local build. Again apologies for wasting your time; just my luck to report a bug the day its fixed. regards Phil |
Heh, no luck involved -- the original fix only got a second look because of this report :) |
We have determined a case where required code in a computed goto flow is removed incorrectly. The included source has been cut-down from a more complex example and appears to be the simplest we can create to reproduce the fault. In the code the [0]th part of the computed goto is removed and replaced by the [2]nd path of the goto (can be determined by the the constant -0XDEADBEEF being absent from the assembly output).
It appears the commit
@
introduced this regression.
Small.CPP: '-S -O2' will reproduce.
The text was updated successfully, but these errors were encountered: