-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Closed
Labels
area-vmUse area-vm for VM related issues, including code coverage, and the AOT and JIT backends.Use area-vm for VM related issues, including code coverage, and the AOT and JIT backends.library-ffitype-bugIncorrect behavior (everything from a crash to more subtle misbehavior)Incorrect behavior (everything from a crash to more subtle misbehavior)
Description
One of the tests returned a different value on the CL which forces Dart FFI to be entering and exiting safe points through slow paths.
The root cause seems to be that one of the arguments got corrupted.
SumSmallNumbers(0, 0, -2147483648, 0, 0, 225750201)Should have been:
SumSmallNumbers(0, 0, -2147483648, 0, 0, 0)Full test result:
/=====================================================================\
| ffi/function_test/2 is new and failed (RuntimeError, expected Pass) |
\=====================================================================/
--- Command "vm" (took 01.000838s):
set DART_CONFIGURATION=DebugX64 & set DART_SUPPRESS_WER=1 & set DART_CRASHPAD_HANDLER=C:\b\s\w\ir\cache\builder\sdk\out\DebugX64\crashpad_handler.exe & out\DebugX64\dart.exe --no-background-compilation --use-slow-path --ignore-unrecognized-flags --packages=C:\b\s\w\ir\cache\builder\sdk\.packages C:\b\s\w\ir\cache\builder\sdk\tests\ffi\function_test.dart
exit code:
255
stdout:
SumPlus42(3, 4)
returning 49
IntComputation(125, 250, 500, 1000)
returning 625
IntComputation(0, 0, 0, 9223372036854775807)
returning 9223372036854775807
IntComputation(0, 0, 0, -9223372036854775808)
returning -9223372036854775808
UintComputation(0, 0, 0, 9223372036854775807)
returning 9223372036854775807
UintComputation(0, 0, 0, 9223372036854775808)
returning 9223372036854775808
UintComputation(0, 0, 0, 18446744073709551615)
returning 18446744073709551615
SumSmallNumbers(-128, 0, 0, 0, 65512, 38800638)
returning 38866022
SumSmallNumbers(127, 0, 0, 0, 16001, 1073770285)
returning 1073786413
SumSmallNumbers(0, 0, 0, 0, 16001, 1073770285)
returning 1073786286
SumSmallNumbers(0, 0, 0, 255, 62816, 38800638)
returning 38863709
SumSmallNumbers(0, -32768, 0, 0, 62816, 38800638)
returning 38830686
SumSmallNumbers(0, 32767, 0, 0, 62816, 38800638)
returning 38896221
SumSmallNumbers(0, 0, 0, 0, 62816, 38800638)
returning 38863454
SumSmallNumbers(0, 0, 0, 0, 3768, 0)
returning 3768
SumSmallNumbers(0, 0, -2147483648, 0, 0, 225750201)
returning -1921733447
stderr:
Unhandled exception:
Expect.equals(expected: <-2147483648>, actual: <-1921733447>) fails.
#0 Expect._fail (package:expect/expect.dart:655:5)
#1 Expect.equals (package:expect/expect.dart:126:5)
#2 testTruncation (file:///C:/b/s/w/ir/cache/builder/sdk/tests/ffi/function_test.dart:202:10)
#3 main (file:///C:/b/s/w/ir/cache/builder/sdk/tests/ffi/function_test.dart:26:5)
#4 _startIsolate.<anonymous closure> (dart:isolate-patch/isolate_patch.dart:300:19)
#5 _RawReceivePortImpl._handleMessage (dart:isolate-patch/isolate_patch.dart:171:12)
--- Re-run this test:
python tools/test.py -n dartk-win-debug-x64 ffi/function_test/2
Metadata
Metadata
Assignees
Labels
area-vmUse area-vm for VM related issues, including code coverage, and the AOT and JIT backends.Use area-vm for VM related issues, including code coverage, and the AOT and JIT backends.library-ffitype-bugIncorrect behavior (everything from a crash to more subtle misbehavior)Incorrect behavior (everything from a crash to more subtle misbehavior)