Open
Description
Description
If a Test has a list of arguments of type Int128
or UInt128
, the test crashes on arm64 Linux with the following backtrace:
◇ Test uint128(value:) started.
◇ Test case passing 1 argument value → 0 to uint128(value:) started.
*** Signal 11: Backtracing from 0xffffb85a8b5c... done ***
*** Program crashed: Bad pointer dereference at 0x50b01f41ec003610 ***
Platform: arm64 Linux (Ubuntu 22.04.5 LTS)
Thread 0 crashed:
0 0x0000ffffb85a8b5c swift::RefCounts<swift::RefCountBitsT<(swift::RefCountInlinedness)1> >::incrementSlow(swift::RefCountBitsT<(swift::RefCountInlinedness)1>, unsigned int) + 112 in libswiftCore.so
1 [ra] [system] 0x0000aaaae51231b4 $s16TestPackageTests7uint1280A0fMp_7__localfMu_ swiftlang/swift-testing#1 @Sendable (value:_:) in $s16TestPackageTests7uint1280A0fMp_17Z9469a9d2f0a6db32fMu_@Sendable (value:) + 107 in TestPackagePackageTests.xctest at /tmp/swift-generated-sources/@__swiftmacro_16TestPackageTests7uint1280A0fMp_.swift
2 [ra] 0x0000ffffb812caa0 swift::runJobInEstablishedExecutorContext(swift::Job*) + 411 in libswift_Concurrency.so
3 [ra] 0x0000ffffb812d7c8 swift_job_run + 167 in libswift_Concurrency.so
4 [ra] 0x0000ffffb7e2bc74 _dispatch_continuation_pop + 267 in libdispatch.so
5 [ra] 0x0000ffffb7e2bab0 _dispatch_async_redirect_invoke + 179 in libdispatch.so
6 [ra] 0x0000ffffb7e35310 _dispatch_worker_thread + 431 in libdispatch.so
7 [ra] 0x0000ffffb6b5d5b8 <unknown> in libc.so.6
...
Registers:
x0 0x0000aaaae5123c30 c0 06 80 3d e8 03 16 aa c8 1a 00 f9 c8 82 00 91 À··=è··ªÈ··ùÈ···
x1 0xaa1603e83d8006c0 12255987731934480064
x2 0x0000000000000001 1
x3 0x0000000000000000 0
x4 0x0000000000000000 0
x5 0x0000000000000003 3
x6 0x000000000000021a 538
x7 0x0000000000000010 16
x8 0x50b01f41ec003600 5814181486928082432
x9 0x0000ffffa4024480 00 00 00 00 00 00 00 00 70 00 00 00 00 00 00 00 ········p·······
x10 0x0000ffffb8170260 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ················
x11 0x0000000000000000 0
x12 0x0000000000000000 0
x13 0x0000000000000000 0
x14 0x0000000000000400 1024
x15 0x0000000000000000 0
x16 0x0000ffffb85641ac fd 7b bd a9 f5 0b 00 f9 f4 4f 02 a9 fd 03 00 91 ý{½©õ··ùôO·©ý···
x17 0x0000aaaae51800a0 ac 41 56 b8 ff ff 00 00 98 7b 0f e5 aa aa 00 00 ¬AV¸ÿÿ···{·åªª··
x18 0x0000000000000000 0
x19 0x0000aaaae5123c30 c0 06 80 3d e8 03 16 aa c8 1a 00 f9 c8 82 00 91 À··=è··ªÈ··ùÈ···
x20 0x50b01f41ec003610 5814181486928082448
x21 0x0000000000000001 1
x22 0x0000ffffa4024460 f0 43 02 a4 ff ff 00 00 44 30 12 e5 aa aa 00 00 ðC·¤ÿÿ··D0·åªª··
x23 0x0000ffffb3bef828 94 10 00 00 00 00 00 00 c0 15 00 ac ff ff 00 00 ········À··¬ÿÿ··
x24 0x0000ffffa4020b00 80 0a 02 a4 ff ff 00 00 b8 ab eb b6 ff ff 00 00 ···¤ÿÿ··¸«ë¶ÿÿ··
x25 0x0000000000005015 20501
x26 0x0000ffffb3bef7e0 50 16 00 ac ff ff 00 00 00 00 00 00 00 00 00 00 P··¬ÿÿ··········
x27 0x0000000000000000 0
x28 0x0000000000000000 0
fp 0x0000ffffb3bee4a0 30 e5 be b3 ff ff 00 00 b4 31 12 e5 aa aa 00 00 0å¾³ÿÿ··´1·åªª··
lr 0x0000aaaae51231b4 e9 13 40 f9 a8 83 5e f8 a2 03 5f f8 c2 01 00 b4 é·@ù¨·^ø¢·_øÂ··´
sp 0x0000ffffb3bee4a0 30 e5 be b3 ff ff 00 00 b4 31 12 e5 aa aa 00 00 0å¾³ÿÿ··´1·åªª··
pc 0x0000ffffb85a8b5c 96 22 7f c8 96 22 29 c8 c9 ff ff 35 bf 06 00 71 ·"·È·")ÈÉÿÿ5¿··q
Images (19 omitted):
0x0000aaaae50f0000–0x0000aaaae5166468 9572918aaf8fee2b4c87e925b06f5ea38c8c501f TestPackagePackageTests.xctest /Repos/Public/testPack/.build/aarch64-unknown-linux-gnu/debug/TestPackagePackageTests.xctest
0x0000ffffb6ae0000–0x0000ffffb6c673fc a10ee556ec5706640b27d9a9c346cb29e9516cec libc.so.6 /usr/lib/aarch64-linux-gnu/libc.so.6
0x0000ffffb7e00000–0x0000ffffb7e4afb0 ddb478dcf79ea26ff1f63fc4719254bfc6f33d1a libdispatch.so /usr/lib/swift/linux/libdispatch.so
0x0000ffffb80c0000–0x0000ffffb814cce8 0d58bdf37c0ee22e9608c21a7c3da2ffb63e35d7 libswift_Concurrency.so /usr/lib/swift/linux/libswift_Concurrency.so
0x0000ffffb8170000–0x0000ffffb86b2b88 91f2d8cf180486b26ccd6b6ac40496080b797490 libswiftCore.so /usr/lib/swift/linux/libswiftCore.so
Backtrace took 0.01s
error: Exited with unexpected signal code 11
Reproduction
@Test(arguments: [UInt128.min]) func uint128(value: UInt128) {
}
Expected behavior
The test should not crash
Environment
Swift version 6.2-dev (LLVM 7f9c8ab4840f392, Swift 7387f85ba276f02)
Target: aarch64-unknown-linux-gnu
Build config: +assertions
↳ Testing Library Version: 6.3-dev (d5b5c5967072052)
Linux nightly-jammy 6.1.68 swiftlang/swift-testing#1 SMP Fri Nov 22 18:05:17 UTC 2024 aarch64 aarch64 aarch64 GNU/Linux
Tested in recent nightly-jammy and nightly-noble containers. Only crashes on arm64, works on x86_64
Additional information
No response