-
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
Bitcode reader asserts in lazyLoadOneMetadata #56194
Comments
@scott-linder I'm starting to suspect this is somehow involved with the "DIOpArg" in the test case. This seems to be in the heterogenous debug info patches and triggers the assert in upstream |
Further reduced with llvm-reduce |
ping, running into this again |
TLDR: I don't know that I can resolve the issue fundamentally until we upstream. The new More details: The assertion is most immediately due to the lack of a However even with lazy-loading disabled (this can be forced with the hidden We also used sequential IDs for the new metadata downstream, which means we have actually already changed the values used between releases as we have merged in upstream (i.e. when the new |
Independent of the debugging support, the bitcode reader seems really fragile and should be more capable of dropping this
Is this a real problem given that you're supposed to be able to just drop metadata? |
Certainly I agree there is a bug here (in fact several) but it amounts to "fix the whole of the metadata reader", which I can't promise I have the cycles for. The issue with the overlapping IDs is that technically there is nothing which prevents different kinds of metadata from having overlapping encoding spaces. I.e. an amd-stg-open compiler might generate some METADATA_EXPR metadata in such a way that the overlapping metadata with the same ID from upstream could actually parse it. Maybe such a case is outlandish, but it seems like there could be miscompiles (potentially even silently) if something meaningful to codegen were parsed in this way. Much more likely this would just uncover other bugs in the compiler around corrupt metadata, though. |
While trying to load some bitcode from an older build from a few months ago, I ran into this assertion in the bitcode reader. Attached is patch adding reduced lit test
0001-Bitcode-Add-asserting-bitcode-testcase.zip
The text was updated successfully, but these errors were encountered: