-
Notifications
You must be signed in to change notification settings - Fork 184
gccrs: 128bit integer support is limited on 32 bit platforms #4007
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
base: master
Are you sure you want to change the base?
Conversation
This is a wider gcc issue we will need to address at some point but this test runs fine under 32 bit more without the 128bit lang item for rotate here. gcc/testsuite/ChangeLog: * rust/execute/torture/sip-hasher.rs: remove 128bit lang item Signed-off-by: Philip Herron <[email protected]>
@@ -1,4 +1,3 @@ | |||
// { dg-skip-if "" { *-*-* } { "-m32" } { "" } } |
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.
Maybe as @tschwinge suggested it'd be better to dg-ice for 32-bit?
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.
Should link to #4003 in the commit message anyway
yeah i was testing quite a bit here and normal things like the arithmetic operators like +, - etc wok on 128 bit integers but rotate doesnt the C front-end explicitly says 128bit doesnt work on 32 bit. From testing it seems as though rotates and shifts dont work. The RTL passes do try to expand the rotate into two parts like two u64's as far as i can tell in gdb but this a bit beyond my ability right now its hitting stuff in the code relating to the target option support so i think its a wider thing to ask GCC folks about at this point. |
@tschwinge @dkm @CohenArthur what do you think i should do? I think i can tweak this test case to pass for this alpine 32 bit CI but not sure who to poke in GCC about this maybe i should just ask on the gcc mailing list i guess? |
As far as I know, GCC supports 128-bit integers only for certain (64-bit?) targets, but not for 32-bit targets. As far as I remember, the new GCC/Cobol support is also running into that (because they need 128-bit integers) -- so maybe that'll get resolved sooner or later. I see C, C++ test cases conditionalize |
A follow-on question then is whether Rust mandates |
By the way, I see |
https://blog.rust-lang.org/2024/03/30/i128-layout-update/ Looks like rustc didn't have a stable ABI for |
if you don't feel like sending a mail, IRC is also an option. |
This is a wider gcc issue we will need to address at some point but this test runs fine under 32 bit more without the 128bit lang item for rotate here.
gcc/testsuite/ChangeLog: