about summary refs log tree commit diff
path: root/compiler/rustc_target/src/abi
AgeCommit message (Collapse)AuthorLines
2022-02-21formatting fixesPetr Sumbera-8/+2
2022-02-21more complete sparc64 ABI fix for aggregates with floating point membersPetr Sumbera-101/+183
Previous fix didn't handle nested structures at all.
2022-02-19Adopt let else in more placesest31-6/+3
2022-02-13Auto merge of #93670 - erikdesjardins:noundef, r=nikicbors-1/+6
Apply noundef attribute to &T, &mut T, Box<T>, bool This doesn't handle `char` because it's a bit awkward to distinguish it from `u32` at this point in codegen. Note that this _does not_ change whether or not it is UB for `&`, `&mut`, or `Box` to point to undef. It only applies to the pointer itself, not the pointed-to memory. Fixes (partially) #74378. r? `@nikic` cc `@RalfJung`
2022-02-09Make FnAbiError Copy.Camille GILLOT-3/+7
2022-02-08Auto merge of #93561 - Amanieu:more-unwind-abi, r=nagisabors-9/+11
Add more *-unwind ABI variants The following *-unwind ABIs are now supported: - "C-unwind" - "cdecl-unwind" - "stdcall-unwind" - "fastcall-unwind" - "vectorcall-unwind" - "thiscall-unwind" - "aapcs-unwind" - "win64-unwind" - "sysv64-unwind" - "system-unwind" cc `@rust-lang/wg-ffi-unwind`
2022-02-05Apply noundef attribute to &T, &mut T, Box<T>, boolErik Desjardins-1/+6
This doesn't handle `char` because it's a bit awkward to distinguish it from u32 at this point in codegen. Note that for some types (like `&Struct` and `&mut Struct`), we already apply `dereferenceable`, which implies `noundef`, so the IR does not change.
2022-02-02Add more *-unwind ABI variantsAmanieu d'Antras-9/+11
The following *-unwind ABIs are now supported: - "C-unwind" - "cdecl-unwind" - "stdcall-unwind" - "fastcall-unwind" - "vectorcall-unwind" - "thiscall-unwind" - "aapcs-unwind" - "win64-unwind" - "sysv64-unwind" - "system-unwind"
2021-12-17Eliminate duplicate codes of is_single_fp_elementlzh-40/+22
2021-12-01fix sparc64 ABI for aggregates with floating point membersPetr Sumbera-47/+133
2021-11-05Update LLVM comments around NoAliasMutRefJosh Stone-2/+4
2021-10-19Fix issue 90038Gary Guo-1/+1
2021-09-20Auto merge of #88321 - glaubitz:m68k-linux, r=wesleywiserbors-0/+32
Add initial support for m68k This patch series adds initial support for m68k making use of the new M68k backend introduced with LLVM-13. Additional changes will be needed to be able to actually use the backend for this target.
2021-09-18Querify `fn_abi_of_{fn_ptr,instance}`.Eduard-Mihai Burtescu-0/+1
2021-09-18ty::layout: intern `FnAbi`s as `&'tcx`.Eduard-Mihai Burtescu-11/+11
2021-09-18ty::layout: propagate errors up to (but not out of) `FnAbi::of_*`.Eduard-Mihai Burtescu-2/+25
2021-09-18rustc_target: `adjust_for_cabi` -> `adjust_for_foreign_abi`.Eduard-Mihai Burtescu-1/+1
2021-09-17compiler/rustc_target: Add support for m68k-linux-gnuJohn Paul Adrian Glaubitz-0/+32
2021-09-13enum niche allocation grows toward zero if possibleAndreas Liljeqvist-9/+43
2021-09-09bugfixAndreas Liljeqvist-1/+1
2021-09-09WrapAndreas Liljeqvist-1/+1
2021-09-09rename `is_valid_for` to `is_valid`Andreas Liljeqvist-2/+2
2021-09-09Rename `(un)signed` to `(un)signed_int`Andreas Liljeqvist-6/+6
2021-09-09Move `unsigned_max` etc into `Size` againAndreas Liljeqvist-7/+22
2021-09-09Make `abi::Abi` `Copy` and remove a *lot* of refsAndreas Liljeqvist-19/+19
fix fix Remove more refs and clones fix more fix
2021-09-09Fix docstringAndreas Liljeqvist-2/+1
2021-09-09Use special `Debug` format when `start` > `end`Andreas Liljeqvist-1/+5
2021-09-09Remove `contains_zero`, respect the compilerAndreas Liljeqvist-8/+1
2021-09-09derive Copy for WrappingRange and ScalarAndreas Liljeqvist-5/+5
2021-09-09fix matchAndreas Liljeqvist-2/+4
2021-09-09Add methods for checking for full ranges to `Scalar` and `WrappingRange`Andreas Liljeqvist-21/+15
Move *_max methods back to util change to inline instead of inline(always) Remove valid_range_exclusive from scalar Use WrappingRange instead implement always_valid_for in a safer way Fix accidental edit
2021-09-02rustc_target: move `LayoutOf` to `ty::layout`.Eduard-Mihai Burtescu-41/+0
2021-08-30rustc_target: remove `LayoutOf` bound from `TyAbiInterface`.Eduard-Mihai Burtescu-61/+51
2021-08-30rustc_target: `TyAndLayout::field` should never error.Eduard-Mihai Burtescu-9/+8
2021-08-27rustc_target: require `TyAbiInterface` in `LayoutOf`.Eduard-Mihai Burtescu-2/+2
2021-08-27rustc_target: rename `TyAndLayoutMethods` to `TyAbiInterface`.Eduard-Mihai Burtescu-65/+71
2021-08-27rustc_target: add lifetime parameter to `LayoutOf`.Eduard-Mihai Burtescu-79/+64
2021-08-26`#[inline]` non-generic `pub fn`s in `rustc_target::abi` and `ty::layout`.Eduard-Mihai Burtescu-0/+21
2021-08-26Auto merge of #88308 - eddyb:cooked-layouts, r=nagisabors-1/+1
Morph `layout_raw` query into `layout_of`. Before this PR, `LayoutCx::layout_of` wrapped the `layout_raw` query, to: * normalize the type, before attempting to compute the layout * pass the layout to `record_layout_for_printing`, for `-Zprint-type-sizes` Moving those two responsibilities into the query may reduce overhead (due to cached calls skipping those steps), but I want to do a perf run to know. One of the changes I had to make was changing the return type of the query, to be able to both get out the type produced by normalizing inside the query *and* to match the signature of the old `TyCtxt::layout_of`. This change may be worse, perf-wise, so that's another reason I want to check. r? `@nagisa` cc `@oli-obk`
2021-08-25use undef for uninitialized bytes in constantsErik Desjardins-0/+38
2021-08-24Morph `layout_raw` query into `layout_of`.Eduard-Mihai Burtescu-1/+1
2021-08-24use convention for with_* methodsAndreas Liljeqvist-7/+9
2021-08-24Force inline: small functions and single call-siteAndreas Liljeqvist-2/+4
2021-08-23Simplify zero checkAndreas Liljeqvist-1/+1
2021-08-23add `with_start` and `with_end`Andreas Liljeqvist-1/+11
2021-08-23implement debug in similar way to RangeInclusiveAndreas Liljeqvist-1/+8
2021-08-23Rename to WrappingRangeAndreas Liljeqvist-5/+5
2021-08-23implement contains_zero methodAndreas Liljeqvist-3/+9
2021-08-23Use refAndreas Liljeqvist-2/+2
2021-08-23Removed fixed fixmeAndreas Liljeqvist-3/+0