about summary refs log tree commit diff
path: root/tests/codegen/cffi
AgeCommit message (Collapse)AuthorLines
2024-04-24Auto merge of #122053 - erikdesjardins:alloca, r=nikicbors-1/+1
Stop using LLVM struct types for alloca The alloca type has no semantic meaning, only the size (and alignment, but we specify it explicitly) matter. Using `[N x i8]` is a more direct way to specify that we want `N` bytes, and avoids relying on LLVM's struct layout. It is likely that a future LLVM version will change to an untyped alloca representation. Split out from #121577. r? `@ghost`
2024-04-12Rollup merge of #123249 - goolmoos:naked_variadics, r=pnkfelixMatthias Krüger-0/+19
do not add prolog for variadic naked functions fixes #99858
2024-04-12do not add prolog for variadic naked functionsGuy Shefy-0/+19
fixes #99858
2024-04-11use [N x i8] for alloca typesErik Desjardins-1/+1
2024-03-17add tests for PassMode::Cast fixesErik Desjardins-6/+22
Tests added in cast-target-abi.rs, covering the single element, array, and prefix cases in `CastTarget::llvm_type`, and the Rust-is-larger/smaller cases in the Rust<->ABI copying code. ffi-out-of-bounds-loads.rs was overhauled to be runnable on any platform. Its alignment also increases due to the removal of a `min` in the previous commit; this was probably an insufficient workaround for this issue or similar. The higher alignment is fine, since the alloca is actually aligned to 8 bytes, as the test checks now confirm.
2024-03-06compiletest: Add a `//@ needs-threads` directiveAlex Crichton-1/+1
This commit is extracted from #122036 and adds a new directive to the `compiletest` test runner, `//@ needs-threads`. This is intended to capture the need that a target must implement threading to execute a specific test, typically one that uses `std::thread`. This is primarily done for WebAssembly targets which currently do not have threads by default. This enables transitioning a lot of `//@ ignore-wasm*`-style ignores into a more self-documenting `//@ needs-threads` directive. Additionally the `wasm32-wasi-preview1-threads` target, for example, does actually have threads, but isn't tested in CI at this time. This change enables running these tests for that target, but not other wasm targets.
2024-02-22[AUTO_GENERATED] Migrate compiletest to use `ui_test`-style `//@` directives许杰友 Jieyou Xu (Joe)-8/+8
2024-01-30Remove `ffi_returns_twice` featureclubby789-11/+0
2023-07-29tests/codegen/c-variadic* -> cffi/c-variadic*Jubilee Young-0/+118
2023-07-29tests/codegen/ffi-* -> cffi/ffi-*Jubilee Young-0/+62