-
Notifications
You must be signed in to change notification settings - Fork 12.6k
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
ML inliner and coroutine code crash #62616
Comments
@llvm/issue-subscribers-backend-x86 |
"parser at end of file" doesn't mean anything, the lines above it are what matter
is because godbolt's clang isn't compiled with ML inlining support. although I'm surprised it kept going after that.
looks like the real issue. can you get a repro without the inliner flag? |
I can't repro on Win locally without that flag, and with that flag I always get the "error in backend" error. If you tell me how to build with ML inliner support on Windows (if such a thing exists), I can try to rebuild my LLVM checkout that way. The original error on the Android bot is here, but uninformative: https://logs.chromium.org/logs/chromium/buildbucket/cr-buildbucket/8774566019004443201/+/u/compile__with_patch_/stdout |
I don't believe it's supported on windows. This is something you'll probably need to repro on Linux. If there's a Chrome change I can try to repro the crash with I can try taking a look. |
When I tried just now on my Linux checkout with the Chromium clang and the testcase at the top of this bug, I got:
Is that sufficient? |
ah yes thanks @mtrofin this looks like an ML inliner advisor issue
probably something about coroutine lowering passes introducing functions that the ML inline advisor isn't expecting |
Ack, I'll take a look. Thanks for the repro! |
@mtrofin, did you had a chance to look at this? |
Not yet. Talked to @kazutakahirata to take a look, but didn't update the assignees (sorry). |
Ack. |
@zmodem to double-check, this is using the model that's part of the chromium's build of llvm, correct? |
Yes. (I didn't check, but I assume so; this came from https://crbug.com/1467960). |
might be wrong, but I doubt the exact model will matter since these functions are so small and will probably get inlined given a reasonable model |
The coroutine handle methods needed to be added to the `FunctionLevels`. We already had logic for their appearing between calls into the `Inliner` pass.
PR #68263 should resolve this. |
The following code causes a fatal error when run with
-std=c++20 -O -mllvm -enable-ml-inliner=release
. See repro at https://godbolt.org/z/zze1o6d4a.The output is:
The text was updated successfully, but these errors were encountered: