mirror of
https://github.com/ziglang/zig.git
synced 2024-11-14 16:13:24 +00:00
llvm: disable LTO on C ABI tests
This required disabling some failing tests. See #14908
This commit is contained in:
parent
f821543e4b
commit
a707f380a5
@ -20,6 +20,11 @@ static void assert_or_panic(bool ok) {
|
||||
# define ZIG_RISCV32
|
||||
#endif
|
||||
|
||||
#if defined(__aarch64__) && defined(__linux__)
|
||||
// TODO: https://github.com/ziglang/zig/issues/14908
|
||||
#define ZIG_BUG_14908
|
||||
#endif
|
||||
|
||||
#ifdef __i386__
|
||||
# define ZIG_NO_I128
|
||||
#endif
|
||||
@ -263,8 +268,10 @@ void run_c_tests(void) {
|
||||
}
|
||||
#endif
|
||||
|
||||
#ifndef ZIG_BUG_14908
|
||||
zig_i8(-1);
|
||||
zig_i16(-2);
|
||||
#endif
|
||||
zig_i32(-3);
|
||||
zig_i64(-4);
|
||||
|
||||
|
@ -813,6 +813,11 @@ extern fn c_ret_medium_vec() MediumVec;
|
||||
test "medium simd vector" {
|
||||
if (comptime builtin.cpu.arch.isPPC64()) return error.SkipZigTest;
|
||||
|
||||
if (builtin.cpu.arch == .x86_64 and builtin.os.tag == .linux) {
|
||||
// TODO: https://github.com/ziglang/zig/issues/14908
|
||||
return error.SkipZigTest;
|
||||
}
|
||||
|
||||
c_medium_vec(.{ 1, 2, 3, 4 });
|
||||
|
||||
var x = c_ret_medium_vec();
|
||||
@ -832,6 +837,11 @@ test "big simd vector" {
|
||||
if (comptime builtin.cpu.arch.isPPC64()) return error.SkipZigTest;
|
||||
if (builtin.cpu.arch == .x86_64 and builtin.os.tag == .macos and builtin.mode != .Debug) return error.SkipZigTest;
|
||||
|
||||
if (builtin.cpu.arch == .x86_64 and builtin.os.tag == .linux) {
|
||||
// TODO: https://github.com/ziglang/zig/issues/14908
|
||||
return error.SkipZigTest;
|
||||
}
|
||||
|
||||
c_big_vec(.{ 1, 2, 3, 4, 5, 6, 7, 8 });
|
||||
|
||||
var x = c_ret_big_vec();
|
||||
|
@ -1133,12 +1133,9 @@ pub fn addCAbiTests(b: *std.Build, skip_non_native: bool, skip_release: bool) *S
|
||||
test_step.linkLibC();
|
||||
test_step.addCSourceFile("test/c_abi/cfuncs.c", &.{"-std=c99"});
|
||||
|
||||
// test-c-abi should test both with LTO on and with LTO off. Only
|
||||
// some combinations are passing currently:
|
||||
// https://github.com/ziglang/zig/issues/14908
|
||||
if (c_abi_target.isWindows()) {
|
||||
test_step.want_lto = false;
|
||||
}
|
||||
// This test is intentionally trying to check if the external ABI is
|
||||
// done properly. LTO would be a hindrance to this.
|
||||
test_step.want_lto = false;
|
||||
|
||||
const run = b.addRunArtifact(test_step);
|
||||
run.skip_foreign_checks = true;
|
||||
|
Loading…
Reference in New Issue
Block a user