-
-
Notifications
You must be signed in to change notification settings - Fork 1.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
Add support for LLVM 12 #10873
Add support for LLVM 12 #10873
Conversation
Hah was hoping to get back to this at some point but distracted myself with the shiny arm64 stuff. I think I got hung up on something in codegen that was breaking with struct returns, so unless something has changed elsewhere, that will probably still need to be addressed? |
@maxfierke Haha no problem :) I've been using this patch locally as llvm on arch has updated to 12 and can't say I've encountered any problems. I guess we'll let CI be the judge of it. |
So compiler specs actually do fail when compiled with LLVM 12 :/
EDIT: Tracked down this failure to However, probably doesn't block merging as it's limited to this one specific use case? |
I think struct returns are fairly important for some C lib bindings EDIT: ahh wait, this is only with procs that return C structs? starting to remember where I got hung up on this... deep in LLVM land. was trying to figure out why ValueEnumerator was ending up with a null pointer... somewhere. I think it had something to do with not specifying the size of the |
More so meant it could be fixed in another pr. Of course that should be done before saying llvm 12 is officially supported. |
byval supports types back to LLVM 9, so enabled that piece too.
Updated w/ the struct return stuff ironed out in 31a8aa2, passes the whole compiler suite now |
Despite the LLVM docs specifying byval having an optional type back to 9.0, it seems it didn't validate on LLVM 10, so playing safe and leaving for LLVM 12+ only.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Passes all specs on my machine with LLVM12
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to go 👍 Thanks @maxfierke @Blacksmoke16 🙏
Co-authored-by: Sijawusz Pur Rahnama <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Checking for type
will short-circuit the more expensive LLVM::Attribute.requires_type?
call.
…irst Co-authored-by: Sijawusz Pur Rahnama <[email protected]>
Fixes #10434
All credit to @maxfierke