rust/compiler/rustc_codegen_llvm/src
bors d19980e1ce Auto merge of #117500 - RalfJung:aggregate-abi, r=davidtwco
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-19 18:42:20 +00:00
..
back Remove asmjs from compiler 2023-10-28 23:24:25 -07:00
coverageinfo coverage: Consistently remove unused counter IDs from expressions/mappings 2023-10-28 09:33:48 +11:00
debuginfo use visibility to check unused imports and delete some stmts 2023-10-22 21:27:46 +08:00
llvm consts: remove dead code around i1 constant values 2023-11-03 15:40:17 -04:00
abi.rs move ABI sanity check from LLVM codegen backend to ABI computation logic 2023-11-03 07:14:27 +01:00
allocator.rs Auto merge of #113722 - bjorn3:allocator_shim_refactor, r=jackh726 2023-08-13 16:49:49 +00:00
asm.rs Auto merge of #114467 - Amanieu:asm-unstable-features, r=davidtwco 2023-08-15 11:59:02 +00:00
attributes.rs Auto merge of #113814 - ChoKyuWon:master, r=davidtwco 2023-08-18 13:20:37 +00:00
base.rs cg_llvm: remove pointee types and pointercast/bitcast-of-ptr 2023-07-29 13:18:17 -04:00
builder.rs Format all the let chains in compiler 2023-10-13 08:59:36 +00:00
callee.rs Fix some typos 2023-11-14 23:06:50 +08:00
common.rs Ensure strings created with const_str get the unnamed_addr attribute 2023-11-15 07:56:40 +00:00
consts.rs consts: remove dead code around i1 constant values 2023-11-03 15:40:17 -04:00
context.rs Add -Z llvm_module_flag 2023-11-11 19:48:47 -08:00
declare.rs CFI: Fix SIGILL reached via trait objects 2023-05-09 20:04:19 +00:00
errors.rs warn when using an unstable feature with -Ctarget-feature 2023-11-06 09:44:00 +01:00
intrinsic.rs Merge simd size and type extraction into checking whether a type is simd, as these always go together. 2023-10-31 11:23:39 +00:00
lib.rs Bump cfg(bootstrap)s 2023-11-15 19:41:28 -05:00
llvm_util.rs target_feature: make it more clear what that 'Option' means 2023-11-12 12:46:05 +01:00
mono_item.rs use visibility to check unused imports and delete some stmts 2023-10-22 21:27:46 +08:00
type_.rs Fix misuses of a vs an 2023-10-04 08:01:11 +08:00
type_of.rs s/Generator/Coroutine/ 2023-10-20 21:10:38 +00:00
va_arg.rs cg_llvm: remove pointee types and pointercast/bitcast-of-ptr 2023-07-29 13:18:17 -04:00
value.rs mv compiler to compiler/ 2020-08-30 18:45:07 +03:00