diff options
author | Eric St. John <ericstj@microsoft.com> | 2019-02-20 03:35:49 +0300 |
---|---|---|
committer | Eric StJohn <ericstj@microsoft.com> | 2019-02-22 00:08:34 +0300 |
commit | e11a3e6a01b329b3b24fad39e865f7e6706c2ada (patch) | |
tree | 63f7f2feb03a72b6cba3ed17e29c721c256cf18e /eng/codeOptimization.targets | |
parent | c0f3a47e5b7d00ad5323feee0710b561dfeacab6 (diff) |
Restore IBC data and embed during Windows release builds
See the following docs.
https://github.com/dotnet/arcade/blob/dotnet/corefx@bac85242024ba867b6204b90c1522793093f5e31/Documentation/ArcadeSdk.md#ibc-optimization-data-embedding
We are using IBC data produced by our perf team and embedding into all builds of a DLL;
currently we don't distinguish cross-compiles of the same DLL, nor does arcade define any
conventions to do so. I've disabled it for references and not-supported assemblies.
Commit migrated from https://github.com/dotnet/corefx/commit/96661fad0e63a7869539fa0981c8b8be2f3824d3
Diffstat (limited to 'eng/codeOptimization.targets')
-rw-r--r-- | eng/codeOptimization.targets | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/eng/codeOptimization.targets b/eng/codeOptimization.targets new file mode 100644 index 00000000000..39bb002af4f --- /dev/null +++ b/eng/codeOptimization.targets @@ -0,0 +1,19 @@ +<Project ToolsVersion="14.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> + + <PropertyGroup Condition="'$(ApplyPartialNgenOptimization)' == ''"> + <ApplyPartialNgenOptimization Condition="'$(IsReferenceAssembly)' == 'true'">false</ApplyPartialNgenOptimization> + <ApplyPartialNgenOptimization Condition="'$(GeneratePlatformNotSupportedAssembly)' == 'true' OR '$(GeneratePlatformNotSupportedAssemblyMessage)' != ''">false</ApplyPartialNgenOptimization> + </PropertyGroup> + + <Target Name="SetApplyPartialNgenOptimization" + Condition="'$(ApplyPartialNgenOptimization)' == ''" + BeforeTargets="CoreCompile"> + <ItemGroup> + <_optimizationDataAssembly Include="$(IbcOptimizationDataDir)**\$(TargetFileName)" /> + </ItemGroup> + <PropertyGroup> + <ApplyPartialNgenOptimization Condition="'@(_optimizationDataAssembly)' != ''">true</ApplyPartialNgenOptimization> + </PropertyGroup> + </Target> + +</Project>
\ No newline at end of file |