Skip to content

Extract SuperPMI into a separate component #64035

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Jan 21, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion eng/Subsets.props
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@
</PropertyGroup>

<PropertyGroup>
<DefaultCoreClrSubsets>clr.native+linuxdac+clr.corelib+clr.tools+clr.nativecorelib+clr.packages+clr.nativeaotlibs</DefaultCoreClrSubsets>
<DefaultCoreClrSubsets>clr.native+linuxdac+clr.corelib+clr.tools+clr.nativecorelib+clr.packages+clr.nativeaotlibs+clr.spmi</DefaultCoreClrSubsets>
<!-- Even on platforms that do not support the CoreCLR runtime, we still want to build ilasm/ildasm. -->
<DefaultCoreClrSubsets Condition="'$(PrimaryRuntimeFlavor)' != 'CoreCLR'">clr.iltools+clr.packages</DefaultCoreClrSubsets>

Expand Down Expand Up @@ -112,6 +112,7 @@
<SubsetName Include="Clr.Hosts" Description="The CoreCLR corerun test host." />
<SubsetName Include="Clr.Jit" Description="The JIT for the CoreCLR .NET runtime." />
<SubsetName Include="Clr.AllJits" Description="All of the cross-targeting JIT compilers for the CoreCLR .NET runtime." />
<SubsetName Include="Clr.Spmi" Description="SuperPMI, a tool for CoreCLR JIT testing." />
<SubsetName Include="Clr.CoreLib" Description="The managed System.Private.CoreLib library for CoreCLR." />
<SubsetName Include="Clr.NativeCoreLib" Description="Run crossgen on System.Private.CoreLib library for CoreCLR." />
<SubsetName Include="Clr.Tools" Description="Managed tools that support CoreCLR development and testing." />
Expand Down Expand Up @@ -206,6 +207,10 @@
<ClrRuntimeBuildSubsets>$(ClrRuntimeBuildSubsets);ClrNativeAotSubset=true</ClrRuntimeBuildSubsets>
</PropertyGroup>

<PropertyGroup Condition="$(_subset.Contains('+clr.spmi+'))">
<ClrRuntimeBuildSubsets>$(ClrRuntimeBuildSubsets);ClrSpmiSubset=true</ClrRuntimeBuildSubsets>
</PropertyGroup>

<ItemGroup Condition="'$(ClrRuntimeBuildSubsets)' != '' or $(_subset.Contains('+clr.nativeprereqs+'))">
<ProjectToBuild Include="$(CoreClrProjectRoot)runtime-prereqs.proj" Category="clr" />
</ItemGroup>
Expand Down
4 changes: 2 additions & 2 deletions eng/pipelines/coreclr/templates/build-jit-job.yml
Original file line number Diff line number Diff line change
Expand Up @@ -107,10 +107,10 @@ jobs:

# Build CoreCLR JIT
- ${{ if ne(parameters.osGroup, 'windows') }}:
- script: $(Build.SourcesDirectory)/src/coreclr/build-runtime$(scriptExt) $(buildConfig) $(archType) $(crossArg) -ci $(compilerArg) -component alljits
- script: $(Build.SourcesDirectory)/src/coreclr/build-runtime$(scriptExt) $(buildConfig) $(archType) $(crossArg) -ci $(compilerArg) -component alljits -component spmi
displayName: Build CoreCLR JIT
- ${{ if eq(parameters.osGroup, 'windows') }}:
- script: set __TestIntermediateDir=int&&$(Build.SourcesDirectory)/src/coreclr/build-runtime$(scriptExt) $(buildConfig) $(archType) -ci -component alljits
- script: set __TestIntermediateDir=int&&$(Build.SourcesDirectory)/src/coreclr/build-runtime$(scriptExt) $(buildConfig) $(archType) -ci -component alljits -component spmi
displayName: Build CoreCLR JIT

- ${{ if eq(parameters.uploadAs, 'azureBlob') }}:
Expand Down
4 changes: 2 additions & 2 deletions eng/pipelines/coreclr/templates/build-job.yml
Original file line number Diff line number Diff line change
Expand Up @@ -132,10 +132,10 @@ jobs:
value: ''
- ${{ if ne(parameters.testGroup, 'innerloop') }}:
- name: clrRuntimeComponentsBuildArg
value: '-component runtime -component alljits -component paltests -component nativeaot '
value: '-component runtime -component alljits -component paltests -component nativeaot -component spmi '
- ${{ if and(eq(parameters.osGroup, 'Linux'), eq(parameters.archType, 'x86')) }}:
- name: clrRuntimeComponentsBuildArg
value: '-component runtime -component jit -component iltools '
value: '-component runtime -component jit -component iltools -component spmi '

- name: pgoInstrumentArg
value: ''
Expand Down
5 changes: 4 additions & 1 deletion src/coreclr/build-runtime.cmd
Original file line number Diff line number Diff line change
Expand Up @@ -345,6 +345,9 @@ for /f "delims=" %%a in ("-%__RequestedBuildComponents%-") do (
if not "!string:-nativeaot-=!"=="!string!" (
set __CMakeTarget=!__CMakeTarget! nativeaot
)
if not "!string:-spmi-=!"=="!string!" (
set __CMakeTarget=!__CMakeTarget! spmi
)
)
if [!__CMakeTarget!] == [] (
set __CMakeTarget=install
Expand Down Expand Up @@ -745,7 +748,7 @@ echo -all: Builds all configurations and platforms.
echo Build architecture: one of -x64, -x86, -arm, -arm64 ^(default: -x64^).
echo Build type: one of -Debug, -Checked, -Release ^(default: -Debug^).
echo -component ^<name^> : specify this option one or more times to limit components built to those specified.
echo Allowed ^<name^>: hosts jit alljits runtime paltests iltools
echo Allowed ^<name^>: hosts jit alljits runtime paltests iltools nativeaot spmi
echo -enforcepgo: verify after the build that PGO was used for key DLLs, and fail the build if not
echo -pgoinstrument: generate instrumented code for profile guided optimization enabled binaries.
echo -cmakeargs: user-settable additional arguments passed to CMake.
Expand Down
2 changes: 1 addition & 1 deletion src/coreclr/build-runtime.sh
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ usage_list+=("-pgodatapath: path to profile guided optimization data.")
usage_list+=("-pgoinstrument: generate instrumented code for profile guided optimization enabled binaries.")
usage_list+=("-skipcrossarchnative: Skip building cross-architecture native binaries.")
usage_list+=("-staticanalyzer: use scan_build static analyzer.")
usage_list+=("-component: Build individual components instead of the full project. Available options are 'hosts', 'jit', 'runtime', 'paltests', 'alljits', 'iltools', and 'nativeaot'. Can be specified multiple times.")
usage_list+=("-component: Build individual components instead of the full project. Available options are 'hosts', 'jit', 'runtime', 'paltests', 'alljits', 'iltools', 'nativeaot', and 'spmi'. Can be specified multiple times.")

setup_dirs_local()
{
Expand Down
1 change: 1 addition & 0 deletions src/coreclr/components.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ add_component(runtime)
add_component(paltests paltests_install)
add_component(iltools)
add_component(nativeaot)
add_component(spmi)

# Define coreclr_all as the fallback component and make every component depend on this component.
# iltools and paltests should be minimal subsets, so don't add a dependency on coreclr_misc
Expand Down
1 change: 1 addition & 0 deletions src/coreclr/runtime.proj
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@
<_CoreClrBuildArg Condition="'$(ClrAllJitsSubset)' == 'true'" Include="-component alljits" />
<_CoreClrBuildArg Condition="'$(ClrILToolsSubset)' == 'true'" Include="-component iltools" />
<_CoreClrBuildArg Condition="'$(ClrNativeAotSubset)' == 'true'" Include="-component nativeaot" />
<_CoreClrBuildArg Condition="'$(ClrSpmiSubset)' == 'true'" Include="-component spmi" />
</ItemGroup>

<PropertyGroup>
Expand Down
2 changes: 1 addition & 1 deletion src/coreclr/tools/superpmi/mcs/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -68,4 +68,4 @@ else()

endif(CLR_CMAKE_HOST_UNIX)

install_clr(TARGETS mcs DESTINATIONS .)
install_clr(TARGETS mcs DESTINATIONS . COMPONENT spmi)
Original file line number Diff line number Diff line change
Expand Up @@ -61,4 +61,4 @@ else()
)
endif(CLR_CMAKE_HOST_UNIX)

install_clr(TARGETS superpmi-shim-collector DESTINATIONS .)
install_clr(TARGETS superpmi-shim-collector DESTINATIONS . COMPONENT spmi)
Original file line number Diff line number Diff line change
Expand Up @@ -63,4 +63,4 @@ else()
)
endif(CLR_CMAKE_HOST_UNIX)

install_clr(TARGETS superpmi-shim-counter DESTINATIONS .)
install_clr(TARGETS superpmi-shim-counter DESTINATIONS . COMPONENT spmi)
Original file line number Diff line number Diff line change
Expand Up @@ -62,4 +62,4 @@ else()
)
endif(CLR_CMAKE_HOST_UNIX)

install_clr(TARGETS superpmi-shim-simple DESTINATIONS .)
install_clr(TARGETS superpmi-shim-simple DESTINATIONS . COMPONENT spmi)
2 changes: 1 addition & 1 deletion src/coreclr/tools/superpmi/superpmi/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -64,4 +64,4 @@ else()
)
endif(CLR_CMAKE_HOST_UNIX)

install_clr(TARGETS superpmi DESTINATIONS .)
install_clr(TARGETS superpmi DESTINATIONS . COMPONENT spmi)