From c6f5267686688aeabaa84aeb02efc2b411e7d64b Mon Sep 17 00:00:00 2001 From: Will Smith Date: Tue, 27 Sep 2022 09:04:11 -0700 Subject: [PATCH] Disabling disasm checks under certain testing environments (#76202) * Disabling disasm checks under certain testing environments * Add extra linux musl check * Add JitDisasm check back * Remove JitDisasm check * Re-enable musl * Do not run disasm checks under stress modes * Feedback, force a failure * Trying to fix targets * Trying to fix targets * Update Runtime_34937.cs --- src/tests/Common/CLRTest.Jit.targets | 45 ++++++++++++++++------------ 1 file changed, 26 insertions(+), 19 deletions(-) diff --git a/src/tests/Common/CLRTest.Jit.targets b/src/tests/Common/CLRTest.Jit.targets index ad751b734bb7c..4e4e363945e73 100644 --- a/src/tests/Common/CLRTest.Jit.targets +++ b/src/tests/Common/CLRTest.Jit.targets @@ -199,7 +199,10 @@ IF NOT DEFINED DoLink ( false - true + true + + true + true @@ -231,16 +234,18 @@ IF NOT DEFINED DoLink ( $(scriptPath)__jit_disasm_list.out ' dotnet $CORE_ROOT/SuperFileCheck/SuperFileCheck.dll --csharp-list-method-names "%(Identity)" --allow-unused-prefixes --check-prefixes=CHECK,$(TargetArchitecture.ToUpperInvariant()),$(TargetArchitecture.ToUpperInvariant())-$(TargetOS.ToUpperInvariant()) > "$(BashDisasmListOutputFile)" - ERRORLEVEL=$? - export COMPlus_JitDisasm=`cat $(BashDisasmListOutputFile)` - export COMPlus_JitDiffableDasm=1 - export COMPlus_JitStdOutFile=$(BashDisasmOutputFile) - if [[ $ERRORLEVEL -ne 0 ]] - then - echo EXECUTION OF FILECHECK - FAILED $ERRORLEVEL - exit 1 - fi', '%0a') +if [[ ( -z "$COMPlus_JitStress" ) && ( -z "$COMPlus_JitStressRegs" ) && ( -z "$COMPlus_TailcallStress" ) && ( "$COMPlus_TieredPGO" != "1" ) ]]; then + @(DisasmCheckFiles -> ' dotnet $CORE_ROOT/SuperFileCheck/SuperFileCheck.dll --csharp-list-method-names "%(Identity)" --allow-unused-prefixes --check-prefixes=CHECK,$(TargetArchitecture.ToUpperInvariant()),$(TargetArchitecture.ToUpperInvariant())-$(TargetOS.ToUpperInvariant()) > "$(BashDisasmListOutputFile)" + ERRORLEVEL=$? + export COMPlus_JitDisasm=`cat $(BashDisasmListOutputFile)` + export COMPlus_JitDiffableDasm=1 + export COMPlus_JitStdOutFile=$(BashDisasmOutputFile) + if [[ $ERRORLEVEL -ne 0 ]] + then + echo EXECUTION OF FILECHECK - FAILED $ERRORLEVEL + exit 1 + fi', '%0a') +fi ]]> @@ -276,14 +281,16 @@ fi ' dotnet %CORE_ROOT%\SuperFileCheck\SuperFileCheck.dll --csharp-list-method-names "%(Identity)" --check-prefixes=CHECK,$(TargetArchitecture.ToUpperInvariant()),$(TargetArchitecture.ToUpperInvariant())-$(TargetOS.ToUpperInvariant()) > "$(BatchDisasmListOutputFile)" - IF NOT "!ERRORLEVEL!" == "0" ( - ECHO EXECUTION OF FILECHECK LISTING METHOD NAMES - FAILED !ERRORLEVEL! - Exit /b 1 - )', '%0d%0a') - for /F "delims=" %%g in ($(BatchDisasmListOutputFile)) do set COMPlus_JitDisasm=%%g - set COMPlus_JitDiffableDasm=1 - set COMPlus_JitStdOutFile=$(BatchDisasmOutputFile) +IF "%COMPlus_JitStress%"=="" IF "%COMPlus_JitStressRegs%"=="" IF "%COMPlus_TailcallStress%"=="" IF NOT "%COMPlus_TieredPGO%" == "1" ( + @(DisasmCheckFiles -> ' dotnet %CORE_ROOT%\SuperFileCheck\SuperFileCheck.dll --csharp-list-method-names "%(Identity)" --check-prefixes=CHECK,$(TargetArchitecture.ToUpperInvariant()),$(TargetArchitecture.ToUpperInvariant())-$(TargetOS.ToUpperInvariant()) > "$(BatchDisasmListOutputFile)" + IF NOT "!ERRORLEVEL!" == "0" ( + ECHO EXECUTION OF FILECHECK LISTING METHOD NAMES - FAILED !ERRORLEVEL! + Exit /b 1 + )', '%0d%0a') + for /F "delims=" %%g in ($(BatchDisasmListOutputFile)) do set COMPlus_JitDisasm=%%g + set COMPlus_JitDiffableDasm=1 + set COMPlus_JitStdOutFile=$(BatchDisasmOutputFile) +) ]]>