Skip to content

FreeBSD: Fix more compiler tests #83319

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
Jul 29, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion test/ClangImporter/cfuncs_parse.swift
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,9 @@ func test_pow() {
// https://github.com/apple/swift/issues/51573
// long doubles in AAPCS64 and 64-bit Android are 128 bits, which is not
// supported by Swift, so don't test this.
#if !((os(Android) && _pointerBitWidth(_64)) || (os(Linux) && arch(arm64)))
#if !((os(Android) && _pointerBitWidth(_64)) ||
(os(Linux) && arch(arm64)) ||
(os(FreeBSD) && arch(arm64)))
func test_powl() {
powl(1.5, 2.5)
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@

// Locating the built libraries failed on Linux (construction of test case),
// but we primarily care about macOS in this test
// UNSUPPORTED: OS=linux-gnu
// UNSUPPORTED: OS=linux-gnu || OS=freebsd

// %env does not seem to work on Windows
// UNSUPPORTED: OS=windows-msvc
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@

// Locating the built libraries failed on Linux (construction of test case),
// but we primarily care about macOS in this test
// UNSUPPORTED: OS=linux-gnu
// UNSUPPORTED: OS=linux-gnu || OS=freebsd

// %env does not seem to work on Windows
// UNSUPPORTED: OS=windows-msvc
Expand Down Expand Up @@ -244,4 +244,4 @@ class AnotherImpl {}
// CHECK-SAME: ) to i64)
// CHECK-SAME: ) to i32
// CHECK-SAME: )
// CHECK-SAME: }, section "__TEXT,__const", no_sanitize_address, align 4
// CHECK-SAME: }, section "__TEXT,__const", no_sanitize_address, align 4
2 changes: 1 addition & 1 deletion test/IRGen/profiling_marker_thunks.swift
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
// RUN: %target-swift-frontend -module-name A -I %t -emit-ir %s | %FileCheck %s --check-prefix=NOTHUNK

// UNSUPPORTED: OS=windows-msvc
// UNSUPPORTED: OS=linux-gnu, OS=linux-android, OS=linux-androideabi
// UNSUPPORTED: OS=linux-gnu, OS=linux-android, OS=linux-androideabi, OS=freebsd

// UNSUPPORTED: CPU=arm64e

Expand Down
2 changes: 1 addition & 1 deletion test/Interpreter/cdecl_official_run.swift
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@

/// Build and run a binary from Swift and C code.
// RUN: %clang-no-modules -c %t/Client.c -o %t/Client.o -target %target-triple \
// RUN: -I %t -I %clang-include-dir -Werror -isysroot %sdk
// RUN: %target-pic-opt -I %t -I %clang-include-dir -Werror -isysroot %sdk
// RUN: %target-build-swift %t/Lib.swift %t/Client.o -O -o %t/a.out \
// RUN: -enable-experimental-feature CDecl -parse-as-library
// RUN: %target-codesign %t/a.out
Expand Down
2 changes: 1 addition & 1 deletion test/Prototypes/CollectionTransformers.swift
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,7 @@ import Darwin
import Dispatch

// FIXME: port to Linux.
// XFAIL: OS=linux-gnu, OS=windows-msvc, OS=openbsd, OS=linux-android
// XFAIL: OS=linux-gnu, OS=windows-msvc, OS=freebsd, OS=openbsd, OS=linux-android

// A wrapper for pthread_t with platform-independent interface.
public struct _stdlib_pthread_t : Equatable, Hashable {
Expand Down
5 changes: 5 additions & 0 deletions test/Sanitizers/asan/asan.swift
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
// XFAIL: OS=windows-msvc

// This test hangs on aarch64 FreeBSD
// XFAIL will try to run the test and the verify that the test fails, which
// still hits the hang.
// UNSUPPORTED: OS=freebsd && CPU=aarch64

// RUN: %target-swiftc_driver %s -g -sanitize=address -o %t_asan-binary
// RUN: %target-codesign %t_asan-binary
// RUN: env %env-ASAN_OPTIONS=abort_on_error=0 not %target-run %t_asan-binary 2>&1 | %FileCheck %s
Expand Down