未验证 提交 86cebb31 编写于 作者: J Juan Hoyos 提交者: GitHub

Infrastructure: correct dependencies and clean helix agent from stray corerun procs (#54094)

* Add dependency on coreclr in monojit/monointerpreter jobs explicitly to solve pipeline issue #53842
* Use Helix Pre/Post hooks to kill linkering corerun instances to work around ARM64 agent issues
Co-authored-by: NKunal Pathak <Kunal.Pathak@microsoft.com>
上级 4bb1318a
......@@ -64,6 +64,8 @@ jobs:
- '${{ parameters.runtimeFlavor }}_common_test_build_p1_AnyOS_AnyCPU_${{parameters.buildConfig }}'
- ${{ if ne(parameters.stagedBuild, true) }}:
- ${{ if or( eq(parameters.runtimeVariant, 'minijit'), eq(parameters.runtimeVariant, 'monointerpreter')) }}:
# This is needed for creating a CORE_ROOT in the current design.
- ${{ format('coreclr_{0}_product_build_{1}{2}_{3}_{4}', '', parameters.osGroup, parameters.osSubgroup, parameters.archType, parameters.buildConfig) }}
# minijit and mono interpreter runtimevariants do not require any special build of the runtime
- ${{ format('{0}_{1}_product_build_{2}{3}_{4}_{5}', parameters.runtimeFlavor, '', parameters.osGroup, parameters.osSubgroup, parameters.archType, parameters.buildConfig) }}
- ${{ if not(or(eq(parameters.runtimeVariant, 'minijit'), eq(parameters.runtimeVariant, 'monointerpreter'))) }}:
......
......@@ -85,6 +85,10 @@
<WorkItemTimeout>5:00</WorkItemTimeout>
</PropertyGroup>
<ItemGroup Condition=" '$(AGENT_OS)' == 'Windows_NT' ">
<HelixPreCommand Include="taskkill.exe /f /im corerun.exe"/>
<HelixPostCommand Include="taskkill.exe /f /im corerun.exe"/>
</ItemGroup>
<!-- We're currently not using .dotnet on the Helix agents -->
<!--
<ItemGroup Condition=" '$(AGENT_OS)' == 'Windows_NT' ">
......@@ -94,11 +98,12 @@
<ItemGroup Condition=" '$(AGENT_OS)' != 'Windows_NT' ">
<HelixPreCommand Include="export PATH=$HELIX_CORRELATION_PAYLOAD/.dotnet:$PATH" Condition=" '$(CollectionType)' == 'crossgen2' "/>
</ItemGroup>
-->
<PropertyGroup>
<HelixPreCommands>@(HelixPreCommand)</HelixPreCommands>
<HelixPostCommands>@(HelixPostCommand)</HelixPostCommands>
</PropertyGroup>
-->
<ItemGroup>
<HelixCorrelationPayload Include="$(CorrelationPayloadDirectory)">
......
......@@ -68,6 +68,11 @@
<HelixPreCommand Condition="'$(TargetsWindows)' != 'true' and '$(BrowserHost)' != 'windows'" Include="export MONO_ENV_OPTIONS='$(MonoEnvOptions)'" />
</ItemGroup>
<ItemGroup Condition="'$(TargetsWindows)' == 'true' or '$(BrowserHost)' == 'windows'">
<HelixPreCommand Include="taskkill.exe /f /im corerun.exe"/>
<HelixPostCommand Include="taskkill.exe /f /im corerun.exe"/>
</ItemGroup>
<ItemGroup Condition="'$(TargetOS)' == 'Browser' and '$(BrowserHost)' != 'windows'">
<HelixPreCommand Condition="'$(Scenario)' != 'WasmTestOnBrowser'" Include="export XHARNESS_COMMAND=test" />
<HelixPreCommand Condition="'$(Scenario)' == 'WasmTestOnBrowser'" Include="export XHARNESS_COMMAND=test-browser" />
......@@ -82,7 +87,7 @@
</ItemGroup>
<PropertyGroup Condition="'$(TargetOS)' == 'Browser'">
<!--
<!--
We are hosting the payloads for the WASM/browser on kestrel in the xharness process.
We also run some network tests to this server and so, we are running it on both HTTP and HTTPS.
For the HTTPS endpoint we need development SSL certificate.
......
......@@ -39,7 +39,7 @@
PALTestsDir=$(_PALTestsDir)
</_PropertiesToPass>
<_PropertiesToPass Condition="'$(TargetOS)' == 'Browser' Or '$(TargetOS)' == 'Android'">
$(_PropertiesToPass);
IncludeDotNetCli=$(IncludeDotNetCli);
......@@ -47,7 +47,7 @@
DotNetCliPackageType=$(DotNetCliPackageType);
DotNetCliVersion=$(DotNetCliVersion)
</_PropertiesToPass>
</PropertyGroup>
</PropertyGroup>
<Message Text="DotNetCliVersion: $(DotNetCliVersion)" Importance="High" />
<Message Text="DotNetCliPackageType: $(DotNetCliPackageType)" Importance="High" />
<Message Text="HelixRuntimeRid: $(HelixRuntimeRid)" Importance="High" />
......@@ -95,7 +95,7 @@
<IncludeDotNetCli>true</IncludeDotNetCli>
<DotNetCliPackageType>runtime</DotNetCliPackageType>
<DotNetCliVersion>$(BundledNETCoreAppPackageVersion)</DotNetCliVersion>
<DotNetCliRuntime>$(HelixRuntimeRid)</DotNetCliRuntime>
<DotNetCliRuntime>$(HelixRuntimeRid)</DotNetCliRuntime>
</PropertyGroup>
<PropertyGroup Condition="'$(TargetOS)' == 'Browser' Or '$(TargetOS)' == 'Android'">
......@@ -168,7 +168,7 @@
<!-- Remove the managed pdbs from our payloads.
This is for performance reasons to reduce our helix payload size -->
<ReducedPayloadFiles Include="@(_PayloadFiles)" Condition=" '%(Extension)' != '.pdb' " />
<ReducedPayloadFilesFinal Include="@(ReducedPayloadFiles)" Condition=" '%(Extension)' != '.sh' and '$(TestWrapperTargetsWindows)' == 'true' "/>
<ReducedPayloadFilesFinal Include="@(ReducedPayloadFiles)" Condition=" '%(Extension)' != '.cmd' and '$(TestWrapperTargetsWindows)' != 'true' "/>
</ItemGroup>
......@@ -202,7 +202,7 @@
</Target>
<Target Name="PreparePALTestArchive">
<Exec Condition="'$(PALTestsDir)' != '' and '$(TestWrapperTargetsWindows)' != 'true'"
<Exec Condition="'$(PALTestsDir)' != '' and '$(TestWrapperTargetsWindows)' != 'true'"
WorkingDirectory="$(PALTestsDir)"
Command="tar -czvf $(PayloadsRootDirectory)paltests.tar.gz `ls -A`"/>
</Target>
......@@ -234,7 +234,7 @@
<RunCrossGen2 Condition=" '$(RunCrossGen2)' != 'true' ">false</RunCrossGen2>
<LongRunningGCTests Condition=" '$(LongRunningGCTests)' != 'true' ">false</LongRunningGCTests>
<GcSimulatorTests Condition=" '$(GcSimulatorTests)' != 'true' ">false</GcSimulatorTests>
<TestRunNamePrefix Condition="'$(RuntimeFlavorDisplayName)' != ''">$(RuntimeFlavorDisplayName) </TestRunNamePrefix>
<TestRunNamePrefix Condition="'$(RuntimeFlavorDisplayName)' != ''">$(RuntimeFlavorDisplayName) </TestRunNamePrefix>
<TestRunNamePrefix Condition=" '$(RunCrossGen)' == 'true' ">R2R </TestRunNamePrefix>
<TestRunNamePrefix Condition=" '$(RunCrossGen2)' == 'true' ">R2R-CG2 </TestRunNamePrefix>
<TestRunNamePrefix Condition=" '$(Scenario)' == 'normal' ">$(TestRunNamePrefix)$(TargetOS) $(TargetArchitecture) $(Configuration) @ </TestRunNamePrefix>
......@@ -251,6 +251,7 @@
<!-- WARNING: HelixPreCommand ItemGroup is intentionally minimal and should be kept that way. -->
<ItemGroup Condition=" '$(TestWrapperTargetsWindows)' == 'true' ">
<HelixPreCommand Include="taskkill.exe /f /im corerun.exe"/>
<HelixPreCommand Include="set CORE_ROOT=%HELIX_CORRELATION_PAYLOAD%" />
<!-- Set _NT_SYMBOL_PATH so VM _ASSERTE() asserts can find the symbol files when doing stack walks -->
<HelixPreCommand Include="set _NT_SYMBOL_PATH=%HELIX_CORRELATION_PAYLOAD%\PDB" />
......@@ -268,6 +269,10 @@
<HelixPreCommand Include="type %__TestEnv%" />
</ItemGroup>
<ItemGroup Condition=" '$(TestWrapperTargetsWindows)' == 'true' ">
<HelixPostCommand Include="taskkill.exe /f /im corerun.exe"/>
</ItemGroup>
<ItemGroup Condition=" '$(TestWrapperTargetsWindows)' != 'true' ">
<HelixPreCommand Include="export CORE_ROOT=$HELIX_CORRELATION_PAYLOAD" />
<HelixPreCommand Include="export RunCrossGen2=1" Condition=" '$(RunCrossGen)' == 'true' " />
......@@ -286,6 +291,7 @@
<PropertyGroup>
<HelixPreCommands>@(HelixPreCommand)</HelixPreCommands>
<HelixPostCommands>@(HelixPostCommand)</HelixPostCommands>
</PropertyGroup>
<PropertyGroup Condition=" '$(TestWrapperTargetsWindows)' == 'true' ">
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册