about summary refs log tree commit diff
path: root/tests/ui/abi/compatibility.rs
AgeCommit message (Collapse)AuthorLines
2023-12-11Auto merge of #118032 - RalfJung:char-u32, r=Mark-Simulacrumbors-0/+7
guarantee that char and u32 are ABI-compatible In https://github.com/rust-lang/rust/pull/116894 we added a guarantee that `char` has the same alignment as `u32`, but there is still one axis where these types could differ: function call ABI. So let's nail that down as well: in a function signature, `char` and `u32` are completely equivalent. This is a new stable guarantee, so it will need t-lang approval.
2023-11-19Auto merge of #117500 - RalfJung:aggregate-abi, r=davidtwcobors-3/+27
Ensure sanity of all computed ABIs This moves the ABI sanity assertions from the codegen backend to the ABI computation logic. Sadly, due to past mistakes, we [have to](https://github.com/rust-lang/rust/pull/117351#issuecomment-1788495503) be able to compute a sane ABI for nonsensical function types like `extern "C" fn(str) -> str`. So to make the sanity check pass we first need to make all ABI adjustment deal with unsized types... and we have no shared infrastructure for those adjustments, so that's a bunch of copy-paste. At least we have assertions failing loudly when one accidentally sets a different mode for an unsized argument. To achieve this, this re-lands the parts of https://github.com/rust-lang/rust/pull/80594 that got reverted in https://github.com/rust-lang/rust/pull/81388. To avoid breaking wasm ABI again, that ABI now explicitly opts-in to the (wrong, broken) ABI that we currently keep for backwards compatibility. That's still better than having *every* ABI use the wrong broken default! Cc `@bjorn3` Fixes https://github.com/rust-lang/rust/issues/115845
2023-11-19disable csky test on CIRalf Jung-3/+5
2023-11-18guarantee that char and u32 are ABI-compatibleRalf Jung-0/+7
2023-11-07test and fix some more targetsRalf Jung-0/+9
2023-11-04document ABI compatibilityRalf Jung-4/+4
2023-11-03default Aggregate ABI to Indirect, and make sure it's never used for unsizedRalf Jung-0/+11
2023-11-03move ABI sanity check from LLVM codegen backend to ABI computation logicRalf Jung-3/+5
2023-10-24tests/ui/abi/compatibility: Set min-llvm-version to 17 for LoongArch64WANG Rui-0/+1
2023-09-22run abi/compatibility test against a whole bunch of targetsRalf Jung-10/+173
2023-09-20tests/ui/abi: Enable repr(transparent) union ABI tests on LoongArch64WANG Rui-2/+0
2023-09-19tests/ui/abi: Enable repr(transparent) union ABI tests on RISC-Vmsizanoen-2/+1
2023-09-12add some DispatchFromDyn ABI compatibility testsRalf Jung-0/+5
2023-09-12add enough cfg to make the test pass on problematic targetsRalf Jung-14/+39
2023-09-12also test ABI-compatibility for some unsized typesRalf Jung-2/+19
2023-09-12make sure the types in the ABI compat test actually type-checkRalf Jung-2/+5
2023-09-11Rollup merge of #115708 - RalfJung:homogeneous, r=davidtwcoMatthias Krüger-8/+2
fix homogeneous_aggregate not ignoring some ZST This is an ABI-breaking change, because it fixes bugs in our ABI code. I'm not sure what that means for this PR, we don't really have a process for such changes, do we? I can only hope nobody relied on the old buggy behavior. Fixes https://github.com/rust-lang/rust/issues/115664
2023-09-10fix homogeneous_aggregate not ignoring some 1-ZSTRalf Jung-8/+2
2023-09-09rustc_layout, rustc_abi: make sure the types are well-formedRalf Jung-4/+5
2023-09-08need to disable part of this test on armRalf Jung-1/+8
2023-09-08add a testcase for another MIPS64 bugRalf Jung-0/+1
2023-09-08merge transparent-abi test into general abi compatibility test, and test ↵Ralf Jung-2/+42
repr(transparent) unions
2023-09-08add tests for RFC 3391Ralf Jung-0/+25
2023-09-08accept some differences for rustc_abi(assert_eq), so that we can test more ↵Ralf Jung-0/+76
things to be compatible