Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.
Sign up1.18.0 armv7 regression: extern-fn-struct-passing-abi assertion failed, passed in 1.17.0 #43329
Comments
This comment has been minimized.
This comment has been minimized.
|
Can you try with |
sanxiyn
added
the
O-ARM
label
Jul 20, 2017
This comment has been minimized.
This comment has been minimized.
|
I added this flag to I didn't recompile rustc itself with the flag that you mentioned, however. Did you want me to try that too? |
This comment has been minimized.
This comment has been minimized.
|
Hm, no. I think you just proved this is not due to field reordering. |
This comment has been minimized.
This comment has been minimized.
|
Those tests look like they are only for x86, so I wonder why they are being run now on arm. |
This comment has been minimized.
This comment has been minimized.
|
Oh actually, looking more closely they are just commented for x86 but should always be valid. |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This Anyway, it seems this is not strictly a regression, but rather something that never worked, just wasn't tested until @eddyb, since you added that, any idea what could be missing on ARM? |
This comment has been minimized.
This comment has been minimized.
|
The only way to really know is to read the clang source. |
This comment has been minimized.
This comment has been minimized.
|
Looking at disassembly, the C side is expecting the The ARM Procedure Call Standard 6.1.2.1 describes the homogeneous aggregate conditions for using VFP, and I found where clang checks for that. We're also already doing this for AArch64 per #24181. I'll work on adding this for ARM hf targets. |
This comment has been minimized.
This comment has been minimized.
|
Ah, missing homogenous aggregates would explain it, and adding support for it is fine as long as there is no old version it would break for. |
This comment has been minimized.
This comment has been minimized.
|
What's the right way for |
This comment has been minimized.
This comment has been minimized.
|
cc @alexcrichton @michaelwoerister for #43329 (comment) - I don't think we have a way to tell, other than by matching on the target triple or something. Maybe there's a target feature? |
This comment has been minimized.
This comment has been minimized.
|
AFAIK it's related to the target today, but I'll admit that my knowledge of VFP and ARM things is tenuous at best. My understand though is that:
In that, I think "hf" at the end of the target indicates VFP which I'm taking as transitively implying "hard float" |
This comment has been minimized.
This comment has been minimized.
|
Shouldn't it be on a per-function basis? What if someone used LLVM has three ARM-specific /// ARM_APCS - ARM Procedure Calling Standard calling convention (obsolete,
/// but still used on some targets).
ARM_APCS = 66,
/// ARM_AAPCS - ARM Architecture Procedure Calling Standard calling
/// convention (aka EABI). Soft float variant.
ARM_AAPCS = 67,
/// ARM_AAPCS_VFP - Same as ARM_AAPCS, but uses hard floating point ABI.
ARM_AAPCS_VFP = 68,AFAICS Rust only explicitly sets cc @TimNN and @japaric, as I know you two have dealt with ARM ABIs in the past... |
This comment has been minimized.
This comment has been minimized.
|
@alexcrichton @cuviper Yeah that's right, if it's |
This comment has been minimized.
This comment has been minimized.
|
OK, so for now it's roughly |
infinity0 commentedJul 19, 2017
Same errors on both Debian and Fedora:
The corresponding test succeeded in 1.17 on Debian, though it appears Fedora did not run this test (and ran fewer tests overall) for 1.17 and earlier.
cc @cuviper