From: Tomáš Rylek Date: Tue, 14 Mar 2023 22:59:42 +0000 (+0100) Subject: Add references to xunit.*.dll to CLRTest.Crossgen.targets (#83413) X-Git-Tag: accepted/tizen/unified/riscv/20231226.055536~3482 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=2efdd7ec8566369926a3527411b0c95f2691416c;p=platform%2Fupstream%2Fdotnet%2Fruntime.git Add references to xunit.*.dll to CLRTest.Crossgen.targets (#83413) This change fixes the exceptions thrown from Crossgen2 JIT interface when JIT tries to resolve tokens from xunit.assert. As a secondary effect the frequent exception throws triggered the race condition https://github.com/dotnet/runtime/issues/81884 triggering non-deterministic native CoreCLR runtime failures on arm64. I was originally reluctant to fix this primary issue until the native runtime bug is understood as otherwise this fix would just cause the issue to stop manifesting without being actually fixed. As the runtime bug has been fixed by now, I am fixing Crossgen2 executions to stop hitting these resolution exceptions. Thanks Tomas --- diff --git a/src/tests/Common/CLRTest.CrossGen.targets b/src/tests/Common/CLRTest.CrossGen.targets index 850c0c62d9b..a69ae678bb3 100644 --- a/src/tests/Common/CLRTest.CrossGen.targets +++ b/src/tests/Common/CLRTest.CrossGen.targets @@ -103,6 +103,7 @@ if [ ! -z ${RunCrossGen2+x} ]%3B then echo -o:$__OutputFile>>$__ResponseFile echo -r:$CORE_ROOT/System.*.dll>>$__ResponseFile echo -r:$CORE_ROOT/Microsoft.*.dll>>$__ResponseFile + echo -r:$CORE_ROOT/xunit.*.dll>>$__ResponseFile echo -r:$CORE_ROOT/mscorlib.dll>>$__ResponseFile echo --verify-type-and-field-layout>>$__ResponseFile echo --method-layout:random>>$__ResponseFile @@ -259,6 +260,7 @@ if defined RunCrossGen2 ( ) echo -r:!CORE_ROOT!\System.*.dll>>!__ResponseFile! echo -r:!CORE_ROOT!\Microsoft.*.dll>>!__ResponseFile! + echo -r:!CORE_ROOT!\xunit.*.dll>>!__ResponseFile! echo -r:!CORE_ROOT!\mscorlib.dll>>!__ResponseFile! echo -r:!CORE_ROOT!\netstandard.dll>>!__ResponseFile! echo -O>>!__ResponseFile!