diff --git a/NuGet.config b/NuGet.config
index 0dff023e179ae..961d774f91d77 100644
--- a/NuGet.config
+++ b/NuGet.config
@@ -10,6 +10,16 @@
+
+
+
+
+
+
+
+
+
+
diff --git a/eng/Version.Details.xml b/eng/Version.Details.xml
index b02016197ce7b..8c6dbdb2bf4f9 100644
--- a/eng/Version.Details.xml
+++ b/eng/Version.Details.xml
@@ -99,14 +99,14 @@
2674f580a4b1d27322914df8488498065e71a3f2
-
+
https://github.com/dotnet/source-build-reference-packages
- 6ed73280a6d70f7e7ac39c86f2abe8c10983f0bb
+ 30ed464acd37779c64e9dc652d4460543ebf9966
-
+
https://github.com/dotnet/source-build-externals
- 4f2151df120194f0268944f1b723c14820738fc8
+ fb970eccb0a9cae3092464e29cbabda0d4115049
@@ -185,57 +185,57 @@
https://github.com/dotnet/arcade
c9efa535175049eb9cba06cae1f8c3d5dbe768a9
-
+
https://github.com/dotnet/runtime-assets
- 20ef600733c107d19f57de4955dfb025d39b99e3
+ 50994571d2f8b4b689c7a0b96c96356fc444b406
-
+
https://github.com/dotnet/runtime-assets
- 20ef600733c107d19f57de4955dfb025d39b99e3
+ 50994571d2f8b4b689c7a0b96c96356fc444b406
-
+
https://github.com/dotnet/runtime-assets
- 20ef600733c107d19f57de4955dfb025d39b99e3
+ 50994571d2f8b4b689c7a0b96c96356fc444b406
-
+
https://github.com/dotnet/runtime-assets
- 20ef600733c107d19f57de4955dfb025d39b99e3
+ 50994571d2f8b4b689c7a0b96c96356fc444b406
-
+
https://github.com/dotnet/runtime-assets
- 20ef600733c107d19f57de4955dfb025d39b99e3
+ 50994571d2f8b4b689c7a0b96c96356fc444b406
-
+
https://github.com/dotnet/runtime-assets
- 20ef600733c107d19f57de4955dfb025d39b99e3
+ 50994571d2f8b4b689c7a0b96c96356fc444b406
-
+
https://github.com/dotnet/runtime-assets
- 20ef600733c107d19f57de4955dfb025d39b99e3
+ 50994571d2f8b4b689c7a0b96c96356fc444b406
-
+
https://github.com/dotnet/runtime-assets
- 20ef600733c107d19f57de4955dfb025d39b99e3
+ 50994571d2f8b4b689c7a0b96c96356fc444b406
-
+
https://github.com/dotnet/runtime-assets
- 20ef600733c107d19f57de4955dfb025d39b99e3
+ 50994571d2f8b4b689c7a0b96c96356fc444b406
-
+
https://github.com/dotnet/runtime-assets
- 20ef600733c107d19f57de4955dfb025d39b99e3
+ 50994571d2f8b4b689c7a0b96c96356fc444b406
-
+
https://github.com/dotnet/runtime-assets
- 20ef600733c107d19f57de4955dfb025d39b99e3
+ 50994571d2f8b4b689c7a0b96c96356fc444b406
-
+
https://github.com/dotnet/runtime-assets
- 20ef600733c107d19f57de4955dfb025d39b99e3
+ 50994571d2f8b4b689c7a0b96c96356fc444b406
-
+
https://github.com/dotnet/runtime-assets
- 20ef600733c107d19f57de4955dfb025d39b99e3
+ 50994571d2f8b4b689c7a0b96c96356fc444b406
https://github.com/dotnet/llvm-project
@@ -354,13 +354,13 @@
https://dev.azure.com/dnceng/internal/_git/dotnet-optimization
67613417f5e1af250e6ddfba79f8f2885d8e90fb
-
+
https://github.com/dotnet/hotreload-utils
- 9fd9805b21b21e16d1c81f0ffabd6ee81fe3e8a2
+ 907017dae648b642c122f9a34573bd88ea0d9730
-
+
https://github.com/dotnet/runtime-assets
- 20ef600733c107d19f57de4955dfb025d39b99e3
+ 50994571d2f8b4b689c7a0b96c96356fc444b406
https://github.com/dotnet/roslyn
diff --git a/eng/Versions.props b/eng/Versions.props
index c8639af14c99a..195b4176144e2 100644
--- a/eng/Versions.props
+++ b/eng/Versions.props
@@ -145,20 +145,20 @@
4.5.0
8.0.0-rc.1.23406.6
- 8.0.0-beta.24270.1
- 8.0.0-beta.24270.1
- 8.0.0-beta.24270.1
- 8.0.0-beta.24270.1
- 8.0.0-beta.24270.1
- 8.0.0-beta.24270.1
- 8.0.0-beta.24270.1
- 8.0.0-beta.24270.1
- 8.0.0-beta.24270.1
- 8.0.0-beta.24270.1
- 8.0.0-beta.24270.1
- 8.0.0-beta.24270.1
- 8.0.0-beta.24270.1
- 8.0.0-beta.24270.1
+ 8.0.0-beta.24362.2
+ 8.0.0-beta.24362.2
+ 8.0.0-beta.24362.2
+ 8.0.0-beta.24362.2
+ 8.0.0-beta.24362.2
+ 8.0.0-beta.24362.2
+ 8.0.0-beta.24362.2
+ 8.0.0-beta.24362.2
+ 8.0.0-beta.24362.2
+ 8.0.0-beta.24362.2
+ 8.0.0-beta.24362.2
+ 8.0.0-beta.24362.2
+ 8.0.0-beta.24362.2
+ 8.0.0-beta.24362.2
1.0.0-prerelease.23566.3
1.0.0-prerelease.23566.3
@@ -188,7 +188,7 @@
8.0.0-prerelease.24229.2
8.0.0-prerelease.24229.2
8.0.0-prerelease.24229.2
- 8.0.0-alpha.0.24365.1
+ 8.0.0-alpha.0.24402.1
2.4.2
1.0.0
2.4.5
diff --git a/eng/pipelines/coreclr/templates/helix-queues-setup.yml b/eng/pipelines/coreclr/templates/helix-queues-setup.yml
index 378396bc323a3..8f1d99396b463 100644
--- a/eng/pipelines/coreclr/templates/helix-queues-setup.yml
+++ b/eng/pipelines/coreclr/templates/helix-queues-setup.yml
@@ -48,7 +48,7 @@ jobs:
# Android x64
- ${{ if in(parameters.platform, 'android_x64') }}:
- - Ubuntu.1804.Amd64.Android.29.Open
+ - Ubuntu.2004.Amd64.Android.29.Open
# Browser wasm
- ${{ if eq(parameters.platform, 'browser_wasm') }}:
@@ -74,28 +74,28 @@ jobs:
- ${{ if eq(variables['System.TeamProject'], 'public') }}:
- (Ubuntu.2204.Arm64.Open)Ubuntu.2204.Armarch.Open@mcr.microsoft.com/dotnet-buildtools/prereqs:ubuntu-22.04-helix-arm64v8
- ${{ if eq(variables['System.TeamProject'], 'internal') }}:
- - (Ubuntu.1804.Arm64)Ubuntu.2204.ArmArch@mcr.microsoft.com/dotnet-buildtools/prereqs:ubuntu-18.04-helix-arm64v8
+ - (Ubuntu.2204.Arm64)Ubuntu.2204.ArmArch@mcr.microsoft.com/dotnet-buildtools/prereqs:ubuntu-22.04-helix-arm64v8
# Linux musl x64
- ${{ if eq(parameters.platform, 'linux_musl_x64') }}:
- ${{ if eq(variables['System.TeamProject'], 'public') }}:
- - (Alpine.317.Amd64.Open)Ubuntu.2204.Amd64.Open@mcr.microsoft.com/dotnet-buildtools/prereqs:alpine-3.17-helix-amd64
+ - (Alpine.318.Amd64.Open)Ubuntu.2204.Amd64.Open@mcr.microsoft.com/dotnet-buildtools/prereqs:alpine-3.18-helix-amd64
- ${{ if eq(variables['System.TeamProject'], 'internal') }}:
- - (Alpine.319.Amd64)Ubuntu.2204.Amd64@mcr.microsoft.com/dotnet-buildtools/prereqs:alpine-3.19-helix-amd64
+ - (Alpine.318.Amd64)Ubuntu.2204.Amd64@mcr.microsoft.com/dotnet-buildtools/prereqs:alpine-3.18-helix-amd64
# Linux musl arm32
- ${{ if eq(parameters.platform, 'linux_musl_arm') }}:
- ${{ if eq(variables['System.TeamProject'], 'public') }}:
- - (Alpine.317.Arm32.Open)Ubuntu.2204.ArmArch.Open@mcr.microsoft.com/dotnet-buildtools/prereqs:alpine-3.17-helix-arm32v7
+ - (Alpine.318.Arm32.Open)Ubuntu.2204.ArmArch.Open@mcr.microsoft.com/dotnet-buildtools/prereqs:alpine-3.18-helix-arm32v7
- ${{ if eq(variables['System.TeamProject'], 'internal') }}:
- - (Alpine.319.Arm32)Ubuntu.2204.ArmArch@mcr.microsoft.com/dotnet-buildtools/prereqs:alpine-3.19-helix-arm32v7
+ - (Alpine.318.Arm32)Ubuntu.2204.ArmArch@mcr.microsoft.com/dotnet-buildtools/prereqs:alpine-3.18-helix-arm32v7
# Linux musl arm64
- ${{ if eq(parameters.platform, 'linux_musl_arm64') }}:
- ${{ if eq(variables['System.TeamProject'], 'public') }}:
- - (Alpine.317.Arm64.Open)Ubuntu.2204.ArmArch.Open@mcr.microsoft.com/dotnet-buildtools/prereqs:alpine-3.17-helix-arm64v8
+ - (Alpine.318.Arm64.Open)Ubuntu.2204.ArmArch.Open@mcr.microsoft.com/dotnet-buildtools/prereqs:alpine-3.18-helix-arm64v8
- ${{ if eq(variables['System.TeamProject'], 'internal') }}:
- - (Alpine.319.Arm64)Ubuntu.2204.ArmArch@mcr.microsoft.com/dotnet-buildtools/prereqs:alpine-3.19-helix-arm64v8
+ - (Alpine.318.Arm64)Ubuntu.2204.ArmArch@mcr.microsoft.com/dotnet-buildtools/prereqs:alpine-3.18-helix-arm64v8
# Linux x64
- ${{ if eq(parameters.platform, 'linux_x64') }}:
diff --git a/eng/pipelines/extra-platforms/runtime-extra-platforms-other.yml b/eng/pipelines/extra-platforms/runtime-extra-platforms-other.yml
index e2e95c6bac573..d394fc8287107 100644
--- a/eng/pipelines/extra-platforms/runtime-extra-platforms-other.yml
+++ b/eng/pipelines/extra-platforms/runtime-extra-platforms-other.yml
@@ -93,7 +93,7 @@ jobs:
testGroup: innerloop
isSingleFile: true
nameSuffix: NativeAOT_Libs
- buildArgs: -s clr.aot+host.native+libs+libs.tests -c $(_BuildConfig) /p:TestNativeAot=true /p:ArchiveTests=true
+ buildArgs: -s clr.aot+host.native+libs+libs.tests -c $(_BuildConfig) /p:TestNativeAot=true /p:ArchiveTests=true /p:IlcUseServerGc=false
timeoutInMinutes: 300 # doesn't normally take this long, but I've seen Helix queues backed up for 160 minutes
# extra steps, run tests
extraStepsTemplate: /eng/pipelines/libraries/helix.yml
@@ -122,7 +122,7 @@ jobs:
testGroup: innerloop
isSingleFile: true
nameSuffix: NativeAOT_Checked_Libs
- buildArgs: -s clr.aot+host.native+libs+libs.tests -c $(_BuildConfig) -rc Checked /p:TestNativeAot=true /p:ArchiveTests=true
+ buildArgs: -s clr.aot+host.native+libs+libs.tests -c $(_BuildConfig) -rc Checked /p:TestNativeAot=true /p:ArchiveTests=true /p:IlcUseServerGc=false
timeoutInMinutes: 360
# extra steps, run tests
extraStepsTemplate: /eng/pipelines/libraries/helix.yml
@@ -151,7 +151,7 @@ jobs:
testGroup: innerloop
isSingleFile: true
nameSuffix: NativeAOT_Checked_Libs_SizeOpt
- buildArgs: -s clr.aot+host.native+libs+libs.tests -c $(_BuildConfig) -rc Checked /p:TestNativeAot=true /p:ArchiveTests=true /p:OptimizationPreference=Size
+ buildArgs: -s clr.aot+host.native+libs+libs.tests -c $(_BuildConfig) -rc Checked /p:TestNativeAot=true /p:ArchiveTests=true /p:OptimizationPreference=Size /p:IlcUseServerGc=false
timeoutInMinutes: 240
# extra steps, run tests
extraStepsTemplate: /eng/pipelines/libraries/helix.yml
@@ -180,7 +180,7 @@ jobs:
testGroup: innerloop
isSingleFile: true
nameSuffix: NativeAOT_Checked_Libs_SpeedOpt
- buildArgs: -s clr.aot+host.native+libs+libs.tests -c $(_BuildConfig) -rc Checked /p:TestNativeAot=true /p:ArchiveTests=true /p:OptimizationPreference=Speed
+ buildArgs: -s clr.aot+host.native+libs+libs.tests -c $(_BuildConfig) -rc Checked /p:TestNativeAot=true /p:ArchiveTests=true /p:OptimizationPreference=Speed /p:IlcUseServerGc=false
timeoutInMinutes: 240
# extra steps, run tests
extraStepsTemplate: /eng/pipelines/libraries/helix.yml
diff --git a/eng/pipelines/libraries/enterprise/linux.yml b/eng/pipelines/libraries/enterprise/linux.yml
index ccfda9fcaebe4..40552c1a0e18f 100644
--- a/eng/pipelines/libraries/enterprise/linux.yml
+++ b/eng/pipelines/libraries/enterprise/linux.yml
@@ -39,7 +39,7 @@ extends:
timeoutInMinutes: 120
pool:
name: $(DncEngPublicBuildPool)
- demands: ImageOverride -equals Build.Ubuntu.1804.Amd64.Open
+ demands: ImageOverride -equals Build.Ubuntu.2204.Amd64.Open
steps:
- bash: |
cd $(enterpriseTestsSetup)
diff --git a/eng/pipelines/libraries/helix-queues-setup.yml b/eng/pipelines/libraries/helix-queues-setup.yml
index d3d7e7b2e64f8..dcfa5a119db38 100644
--- a/eng/pipelines/libraries/helix-queues-setup.yml
+++ b/eng/pipelines/libraries/helix-queues-setup.yml
@@ -28,7 +28,7 @@ jobs:
# Linux arm
- ${{ if eq(parameters.platform, 'linux_arm') }}:
- ${{ if or(eq(parameters.jobParameters.isExtraPlatforms, true), eq(parameters.jobParameters.includeAllPlatforms, true)) }}:
- - (Debian.11.Arm32.Open)Ubuntu.2204.ArmArch.Open@mcr.microsoft.com/dotnet-buildtools/prereqs:debian-11-helix-arm32v7
+ - (Debian.12.Arm32.Open)Ubuntu.2204.ArmArch.Open@mcr.microsoft.com/dotnet-buildtools/prereqs:debian-12-helix-arm32v7
# Linux armv6
- ${{ if eq(parameters.platform, 'linux_armv6') }}:
@@ -42,18 +42,18 @@ jobs:
- ${{ if or(ne(parameters.jobParameters.isExtraPlatforms, true), eq(parameters.jobParameters.includeAllPlatforms, true)) }}:
- (Ubuntu.1804.Arm64.Open)Ubuntu.2204.ArmArch.Open@mcr.microsoft.com/dotnet-buildtools/prereqs:ubuntu-18.04-helix-arm64v8
- ${{ if or(ne(parameters.jobParameters.isExtraPlatforms, true), eq(parameters.jobParameters.includeAllPlatforms, true)) }}:
- - (Debian.11.Arm64.Open)Ubuntu.2204.Armarch.Open@mcr.microsoft.com/dotnet-buildtools/prereqs:debian-11-helix-arm64v8
+ - (Debian.12.Arm64.Open)Ubuntu.2204.Armarch.Open@mcr.microsoft.com/dotnet-buildtools/prereqs:debian-12-helix-arm64v8
# Linux musl x64
- ${{ if eq(parameters.platform, 'linux_musl_x64') }}:
- ${{ if or(ne(parameters.jobParameters.isExtraPlatforms, true), eq(parameters.jobParameters.includeAllPlatforms, true)) }}:
- - (Alpine.317.Amd64.Open)Ubuntu.2204.Amd64.Open@mcr.microsoft.com/dotnet-buildtools/prereqs:alpine-3.17-helix-amd64
+ - (Alpine.318.Amd64.Open)Ubuntu.2204.Amd64.Open@mcr.microsoft.com/dotnet-buildtools/prereqs:alpine-3.18-helix-amd64
- ${{ if or(eq(parameters.jobParameters.isExtraPlatforms, true), eq(parameters.jobParameters.includeAllPlatforms, true)) }}:
- - (Alpine.319.Amd64.Open)Ubuntu.2204.Amd64.Open@mcr.microsoft.com/dotnet-buildtools/prereqs:alpine-3.19-helix-amd64
+ - (Alpine.318.Amd64.Open)Ubuntu.2204.Amd64.Open@mcr.microsoft.com/dotnet-buildtools/prereqs:alpine-3.18-helix-amd64
# Linux musl arm64
- ${{ if and(eq(parameters.platform, 'linux_musl_arm64'), or(eq(parameters.jobParameters.isExtraPlatforms, true), eq(parameters.jobParameters.includeAllPlatforms, true))) }}:
- - (Alpine.317.Arm64.Open)ubuntu.2204.armarch.open@mcr.microsoft.com/dotnet-buildtools/prereqs:alpine-3.17-helix-arm64v8
+ - (Alpine.318.Arm64.Open)ubuntu.2204.armarch.open@mcr.microsoft.com/dotnet-buildtools/prereqs:alpine-3.18-helix-arm64v8
- (Alpine.319.Arm64.Open)ubuntu.2204.armarch.open@mcr.microsoft.com/dotnet-buildtools/prereqs:alpine-3.19-helix-arm64v8
# Linux x64
@@ -64,22 +64,22 @@ jobs:
- (Centos.9.Amd64.Open)Ubuntu.2204.Amd64.Open@mcr.microsoft.com/dotnet-buildtools/prereqs:centos-stream9-helix
- (Fedora.39.Amd64.Open)Ubuntu.2204.Amd64.Open@mcr.microsoft.com/dotnet-buildtools/prereqs:fedora-39-helix
- (Ubuntu.2204.Amd64.Open)Ubuntu.2204.Amd64.Open@mcr.microsoft.com/dotnet-buildtools/prereqs:ubuntu-22.04-helix-amd64
- - (Debian.11.Amd64.Open)Ubuntu.2204.Amd64.Open@mcr.microsoft.com/dotnet-buildtools/prereqs:debian-11-helix-amd64
+ - (Debian.12.Amd64.Open)Ubuntu.2204.Amd64.Open@mcr.microsoft.com/dotnet-buildtools/prereqs:debian-12-helix-amd64
- ${{ if or(ne(parameters.jobParameters.testScope, 'outerloop'), ne(parameters.jobParameters.runtimeFlavor, 'mono')) }}:
- ${{ if or(eq(parameters.jobParameters.isExtraPlatforms, true), eq(parameters.jobParameters.includeAllPlatforms, true)) }}:
- SLES.15.Amd64.Open
- (Fedora.39.Amd64.Open)Ubuntu.2204.amd64.open@mcr.microsoft.com/dotnet-buildtools/prereqs:fedora-39-helix
- Ubuntu.2204.Amd64.Open
- - (Debian.11.Amd64.Open)Ubuntu.2204.Amd64.Open@mcr.microsoft.com/dotnet-buildtools/prereqs:debian-11-helix-amd64
+ - (Debian.12.Amd64.Open)Ubuntu.2204.Amd64.Open@mcr.microsoft.com/dotnet-buildtools/prereqs:debian-12-helix-amd64
- (Mariner.2.0.Amd64.Open)Ubuntu.2204.amd64.open@mcr.microsoft.com/dotnet-buildtools/prereqs:cbl-mariner-2.0-helix-amd64
- (openSUSE.15.2.Amd64.Open)Ubuntu.2204.amd64.open@mcr.microsoft.com/dotnet-buildtools/prereqs:opensuse-15.2-helix-amd64
- ${{ if or(ne(parameters.jobParameters.isExtraPlatforms, true), eq(parameters.jobParameters.includeAllPlatforms, true)) }}:
- (Centos.9.Amd64.Open)Ubuntu.2204.Amd64.Open@mcr.microsoft.com/dotnet-buildtools/prereqs:centos-stream9-helix
- - (Debian.11.Amd64.Open)Ubuntu.2204.Amd64.Open@mcr.microsoft.com/dotnet-buildtools/prereqs:debian-11-helix-amd64
- - Ubuntu.1804.Amd64.Open
+ - (Debian.12.Amd64.Open)Ubuntu.2204.Amd64.Open@mcr.microsoft.com/dotnet-buildtools/prereqs:debian-12-helix-amd64
+ - Ubuntu.2004.Amd64.Open
- ${{ if or(eq(parameters.jobParameters.interpreter, 'true'), eq(parameters.jobParameters.isSingleFile, true)) }}:
# Limiting interp runs as we don't need as much coverage.
- - (Debian.11.Amd64.Open)Ubuntu.2204.Amd64.Open@mcr.microsoft.com/dotnet-buildtools/prereqs:debian-11-helix-amd64
+ - (Debian.12.Amd64.Open)Ubuntu.2204.Amd64.Open@mcr.microsoft.com/dotnet-buildtools/prereqs:debian-12-helix-amd64
# Linux s390x
- ${{ if eq(parameters.platform, 'linux_s390x') }}:
@@ -99,7 +99,7 @@ jobs:
# Android
- ${{ if in(parameters.platform, 'android_x86', 'android_x64', 'linux_bionic_x64') }}:
- - Ubuntu.1804.Amd64.Android.29.Open
+ - Ubuntu.2004.Amd64.Android.29.Open
- ${{ if in(parameters.platform, 'android_arm', 'android_arm64', 'linux_bionic_arm64') }}:
- Windows.11.Amd64.Android.Open
@@ -175,11 +175,11 @@ jobs:
# Browser WebAssembly
- ${{ if eq(parameters.platform, 'browser_wasm') }}:
- - (Ubuntu.1804.Amd64)Ubuntu.2204.Amd64.Open@mcr.microsoft.com/dotnet-buildtools/prereqs:ubuntu-18.04-helix-webassembly
+ - (Ubuntu.2204.Amd64)Ubuntu.2204.Amd64.Open@mcr.microsoft.com/dotnet-buildtools/prereqs:ubuntu-22.04-helix-webassembly
# Browser WebAssembly Firefox
- ${{ if eq(parameters.platform, 'browser_wasm_firefox') }}:
- - (Ubuntu.1804.Amd64)Ubuntu.2204.Amd64.Open@mcr.microsoft.com/dotnet-buildtools/prereqs:ubuntu-18.04-helix-webassembly
+ - (Ubuntu.2204.Amd64)Ubuntu.2204.Amd64.Open@mcr.microsoft.com/dotnet-buildtools/prereqs:ubuntu-22.04-helix-webassembly
# Browser WebAssembly windows
- ${{ if in(parameters.platform, 'browser_wasm_win', 'wasi_wasm_win') }}:
diff --git a/eng/pipelines/libraries/stress/http.yml b/eng/pipelines/libraries/stress/http.yml
index 68bfcef6c5081..f29a41fcd0a7e 100644
--- a/eng/pipelines/libraries/stress/http.yml
+++ b/eng/pipelines/libraries/stress/http.yml
@@ -38,7 +38,7 @@ extends:
DUMPS_SHARE_MOUNT_ROOT: "/dumps-share"
pool:
name: $(DncEngPublicBuildPool)
- demands: ImageOverride -equals 1es-ubuntu-1804-open
+ demands: ImageOverride -equals 1es-ubuntu-2204-open
steps:
- checkout: self
diff --git a/eng/pipelines/libraries/stress/ssl.yml b/eng/pipelines/libraries/stress/ssl.yml
index a70a18e828f04..1e8cddf228bcb 100644
--- a/eng/pipelines/libraries/stress/ssl.yml
+++ b/eng/pipelines/libraries/stress/ssl.yml
@@ -37,7 +37,7 @@ extends:
timeoutInMinutes: 120
pool:
name: $(DncEngPublicBuildPool)
- demands: ImageOverride -equals Build.Ubuntu.1804.Amd64.Open
+ demands: ImageOverride -equals Build.Ubuntu.2204.Amd64.Open
steps:
- checkout: self
diff --git a/eng/pipelines/runtime-official.yml b/eng/pipelines/runtime-official.yml
index 7cadf6a800f67..eb3d2c79eb7e6 100644
--- a/eng/pipelines/runtime-official.yml
+++ b/eng/pipelines/runtime-official.yml
@@ -442,9 +442,9 @@ extends:
buildConfig: release
platforms:
- linux_x64
- - linux_musl_x64
+ # - linux_musl_x64
- linux_arm64
- - linux_musl_arm64
+ # - linux_musl_arm64
jobParameters:
templatePath: 'templates-official'
buildArgs: -s mono+packs -c $(_BuildConfig)
diff --git a/eng/testing/scenarios/BuildWasmAppsJobsList.txt b/eng/testing/scenarios/BuildWasmAppsJobsList.txt
index e16c74fe4f075..9bb06b872bb6c 100644
--- a/eng/testing/scenarios/BuildWasmAppsJobsList.txt
+++ b/eng/testing/scenarios/BuildWasmAppsJobsList.txt
@@ -43,3 +43,5 @@ Wasm.Build.Tests.WasmTemplateTests
Wasm.Build.Tests.WorkloadTests
Wasm.Build.Tests.TestAppScenarios.ModuleConfigTests
Wasm.Build.Tests.MT.Blazor.SimpleMultiThreadedTests
+Wasm.Build.Tests.TestAppScenarios.WasmSdkDebugLevelTests
+Wasm.Build.Tests.TestAppScenarios.WasmAppBuilderDebugLevelTests
diff --git a/eng/testing/tests.wasm.targets b/eng/testing/tests.wasm.targets
index 4dc6b71005449..9e0fdaf3289e6 100644
--- a/eng/testing/tests.wasm.targets
+++ b/eng/testing/tests.wasm.targets
@@ -15,10 +15,7 @@
But we do want to set it for Configuration=Debug .
-->
-1
-
- reset-to-zero
+ 0
full
true
diff --git a/src/coreclr/System.Private.CoreLib/src/Internal/Runtime/InteropServices/InMemoryAssemblyLoader.cs b/src/coreclr/System.Private.CoreLib/src/Internal/Runtime/InteropServices/InMemoryAssemblyLoader.cs
index dc8d8ccb4c7cc..55e4227481724 100644
--- a/src/coreclr/System.Private.CoreLib/src/Internal/Runtime/InteropServices/InMemoryAssemblyLoader.cs
+++ b/src/coreclr/System.Private.CoreLib/src/Internal/Runtime/InteropServices/InMemoryAssemblyLoader.cs
@@ -49,7 +49,7 @@ private static unsafe void LoadInMemoryAssemblyInContextWhenSupported(IntPtr mod
///
/// The native module handle for the assembly.
/// The path to the assembly (as a pointer to a UTF-16 C string).
- /// Load context (currently must be IntPtr.Zero)
+ /// Load context (currently must be either IntPtr.Zero for default ALC or -1 for isolated ALC)
[UnmanagedCallersOnly]
[UnconditionalSuppressMessage("ReflectionAnalysis", "IL2026:RequiresUnreferencedCode",
Justification = "The same C++/CLI feature switch applies to LoadInMemoryAssembly and this function. We rely on the warning from LoadInMemoryAssembly.")]
@@ -58,9 +58,12 @@ public static unsafe void LoadInMemoryAssemblyInContext(IntPtr moduleHandle, Int
if (!IsSupported)
throw new NotSupportedException(SR.NotSupported_CppCli);
- ArgumentOutOfRangeException.ThrowIfNotEqual(loadContext, IntPtr.Zero);
+ if ((loadContext != IntPtr.Zero) && (loadContext != -1))
+ {
+ throw new ArgumentOutOfRangeException(nameof(loadContext));
+ }
- LoadInMemoryAssemblyInContextImpl(moduleHandle, assemblyPath, AssemblyLoadContext.Default);
+ LoadInMemoryAssemblyInContextImpl(moduleHandle, assemblyPath, (loadContext == IntPtr.Zero) ? AssemblyLoadContext.Default : null);
}
[RequiresUnreferencedCode("C++/CLI is not trim-compatible", Url = "https://aka.ms/dotnet-illink/nativehost")]
diff --git a/src/coreclr/gc/gc.cpp b/src/coreclr/gc/gc.cpp
index 1cf604da8a87b..81229e9cdab86 100644
--- a/src/coreclr/gc/gc.cpp
+++ b/src/coreclr/gc/gc.cpp
@@ -21595,10 +21595,13 @@ int gc_heap::generation_to_condemn (int n_initial,
}
#ifdef USE_REGIONS
- if (!try_get_new_free_region())
+ if (!check_only_p)
{
- dprintf (GTC_LOG, ("can't get an empty region -> full compacting"));
- last_gc_before_oom = TRUE;
+ if (!try_get_new_free_region())
+ {
+ dprintf (GTC_LOG, ("can't get an empty region -> full compacting"));
+ last_gc_before_oom = TRUE;
+ }
}
#endif //USE_REGIONS
diff --git a/src/coreclr/hosts/corerun/corerun.cpp b/src/coreclr/hosts/corerun/corerun.cpp
index 4e506b95c9746..858f72297f6bd 100644
--- a/src/coreclr/hosts/corerun/corerun.cpp
+++ b/src/coreclr/hosts/corerun/corerun.cpp
@@ -472,6 +472,7 @@ static void display_usage()
W(" -p, --property - Property to pass to runtime during initialization.\n")
W(" If a property value contains spaces, quote the entire argument.\n")
W(" May be supplied multiple times. Format: =.\n")
+ W(" -l, --preload - path to shared library to load before loading the CLR.\n")
W(" -d, --debug - causes corerun to wait for a debugger to attach before executing.\n")
W(" -e, --env - path to a .env file with environment variables that corerun should set.\n")
W(" -?, -h, --help - show this help.\n")
@@ -569,6 +570,22 @@ static bool parse_args(
config.user_defined_keys.push_back(std::move(key));
config.user_defined_values.push_back(std::move(value));
}
+ else if (pal::strcmp(option, W("l")) == 0 || (pal::strcmp(option, W("preload")) == 0))
+ {
+ i++;
+ if (i >= argc)
+ {
+ pal::fprintf(stderr, W("Option %s: missing shared library path\n"), arg);
+ break;
+ }
+
+ string_t library = argv[i];
+ pal::mod_t hMod;
+ if (!pal::try_load_library(library, hMod))
+ {
+ break;
+ }
+ }
else if (pal::strcmp(option, W("d")) == 0 || (pal::strcmp(option, W("debug")) == 0))
{
config.wait_to_debug = true;
diff --git a/src/coreclr/hosts/corerun/corerun.hpp b/src/coreclr/hosts/corerun/corerun.hpp
index f0e51a668fe22..567d7b9dc5062 100644
--- a/src/coreclr/hosts/corerun/corerun.hpp
+++ b/src/coreclr/hosts/corerun/corerun.hpp
@@ -224,6 +224,17 @@ namespace pal
return hMod != nullptr;
}
+ inline bool try_load_library(const pal::string_t& path, pal::mod_t& hMod)
+ {
+ hMod = (pal::mod_t)::LoadLibraryExW(path.c_str(), nullptr, 0);
+ if (hMod == nullptr)
+ {
+ pal::fprintf(stderr, W("Failed to load: '%s'. Error: 0x%08x\n"), path.c_str(), ::GetLastError());
+ return false;
+ }
+ return true;
+ }
+
inline bool try_load_coreclr(const pal::string_t& core_root, pal::mod_t& hMod)
{
pal::string_t coreclr_path = core_root;
@@ -602,6 +613,18 @@ namespace pal
return hMod != nullptr;
}
+ inline bool try_load_library(const pal::string_t& path, pal::mod_t& hMod)
+ {
+ hMod = (pal::mod_t)dlopen(path.c_str(), RTLD_NOW | RTLD_LOCAL);
+ if (hMod == nullptr)
+ {
+ pal::fprintf(stderr, W("Failed to load: '%s'. Error: %s\n"), path.c_str(), dlerror());
+ return false;
+ }
+ return true;
+ }
+
+
inline bool try_load_coreclr(const pal::string_t& core_root, pal::mod_t& hMod)
{
pal::string_t coreclr_path = core_root;
diff --git a/src/coreclr/inc/clrconfigvalues.h b/src/coreclr/inc/clrconfigvalues.h
index 7b356b0744399..13962a2060905 100644
--- a/src/coreclr/inc/clrconfigvalues.h
+++ b/src/coreclr/inc/clrconfigvalues.h
@@ -342,6 +342,8 @@ CONFIG_STRING_INFO(INTERNAL_TailCallMax, W("TailCallMax"), "")
RETAIL_CONFIG_STRING_INFO(EXTERNAL_TailCallOpt, W("TailCallOpt"), "")
RETAIL_CONFIG_DWORD_INFO(EXTERNAL_TailCallLoopOpt, W("TailCallLoopOpt"), 1, "Convert recursive tail calls to loops")
RETAIL_CONFIG_DWORD_INFO(EXTERNAL_Jit_NetFx40PInvokeStackResilience, W("NetFx40_PInvokeStackResilience"), (DWORD)-1, "Makes P/Invoke resilient against mismatched signature and calling convention (significant perf penalty).")
+RETAIL_CONFIG_DWORD_INFO(EXTERNAL_DisableOptimizedThreadStaticAccess, W("DisableOptimizedThreadStaticAccess"), (DWORD)0, "Disable the OptimizedThreadStaticAccess feature.")
+CONFIG_DWORD_INFO(EXTERNAL_AssertNotStaticTlsResolver, W("AssertNotStaticTlsResolver"), (DWORD)0, "Assert if we attempt to use the static tls resolver path.")
// AltJitAssertOnNYI should be 0 on targets where JIT is under development or bring up stage, so as to facilitate fallback to main JIT on hitting a NYI.
#if defined(TARGET_X86)
diff --git a/src/coreclr/jit/lowerxarch.cpp b/src/coreclr/jit/lowerxarch.cpp
index dad1df9ffcfb7..8f3150e7e7b18 100644
--- a/src/coreclr/jit/lowerxarch.cpp
+++ b/src/coreclr/jit/lowerxarch.cpp
@@ -8292,7 +8292,7 @@ bool Lowering::IsContainableHWIntrinsicOp(GenTreeHWIntrinsic* parentNode, GenTre
return false;
}
- return parentNode->OperIsEmbBroadcastCompatible();
+ return parentNode->OperIsEmbBroadcastCompatible() && comp->canUseEvexEncoding();
}
default:
diff --git a/src/coreclr/vm/arm64/asmhelpers.S b/src/coreclr/vm/arm64/asmhelpers.S
index 89dab80461c35..f766b9691278e 100644
--- a/src/coreclr/vm/arm64/asmhelpers.S
+++ b/src/coreclr/vm/arm64/asmhelpers.S
@@ -1035,4 +1035,18 @@ LEAF_ENTRY GetThreadStaticsVariableOffset, _TEXT
EPILOG_RETURN
LEAF_END GetThreadStaticsVariableOffset, _TEXT
// ------------------------------------------------------------------
+
+// ------------------------------------------------------------------
+// size_t GetTLSResolverAddress()
+
+// Helper to get the TLS resolver address. This will be then used to determine if we have a static or dynamic resolver.
+LEAF_ENTRY GetTLSResolverAddress, _TEXT
+ PROLOG_SAVE_REG_PAIR_INDEXED fp, lr, -32
+ adrp x0, :tlsdesc:t_ThreadStatics
+ ldr x1, [x0, #:tlsdesc_lo12:t_ThreadStatics]
+ mov x0, x1
+ EPILOG_RESTORE_REG_PAIR_INDEXED fp, lr, 32
+ EPILOG_RETURN
+LEAF_END GetTLSResolverAddress, _TEXT
+// ------------------------------------------------------------------
#endif // !TARGET_OSX
diff --git a/src/coreclr/vm/dllimport.cpp b/src/coreclr/vm/dllimport.cpp
index 31c4467b7982a..a8f23fcb2ac49 100644
--- a/src/coreclr/vm/dllimport.cpp
+++ b/src/coreclr/vm/dllimport.cpp
@@ -2268,15 +2268,7 @@ DWORD NDirectStubLinker::EmitProfilerBeginTransitionCallback(ILCodeStream* pcsEm
EmitLoadStubContext(pcsEmit, dwStubFlags);
}
- if (SF_IsForwardStub(dwStubFlags))
- {
- pcsEmit->EmitLDLOC(GetThreadLocalNum());
- }
- else
- {
- // we use a null pThread to indicate reverse interop
- pcsEmit->EmitLoadNullPtr();
- }
+ pcsEmit->EmitLDLOC(GetThreadLocalNum());
// In the unmanaged delegate case, we need the "this" object to retrieve the MD
// in StubHelpers::ProfilerEnterCallback().
diff --git a/src/coreclr/vm/eeconfig.cpp b/src/coreclr/vm/eeconfig.cpp
index 0f1de4d4fe788..37a89224617ce 100644
--- a/src/coreclr/vm/eeconfig.cpp
+++ b/src/coreclr/vm/eeconfig.cpp
@@ -112,6 +112,7 @@ HRESULT EEConfig::Init()
fJitFramed = false;
fJitMinOpts = false;
fJitEnableOptionalRelocs = false;
+ fDisableOptimizedThreadStaticAccess = false;
fPInvokeRestoreEsp = (DWORD)-1;
fNgenBindOptimizeNonGac = false;
@@ -548,6 +549,8 @@ HRESULT EEConfig::sync()
iJitOptimizeType = CLRConfig::GetConfigValue(CLRConfig::EXTERNAL_JitOptimizeType);
if (iJitOptimizeType > OPT_RANDOM) iJitOptimizeType = OPT_DEFAULT;
+ fDisableOptimizedThreadStaticAccess = CLRConfig::GetConfigValue(CLRConfig::EXTERNAL_DisableOptimizedThreadStaticAccess) != 0;
+
#ifdef TARGET_X86
fPInvokeRestoreEsp = CLRConfig::GetConfigValue(CLRConfig::EXTERNAL_Jit_NetFx40PInvokeStackResilience);
#endif
diff --git a/src/coreclr/vm/eeconfig.h b/src/coreclr/vm/eeconfig.h
index 6394f1b998c0f..3614e54320295 100644
--- a/src/coreclr/vm/eeconfig.h
+++ b/src/coreclr/vm/eeconfig.h
@@ -77,6 +77,7 @@ class EEConfig
bool JitFramed(void) const {LIMITED_METHOD_CONTRACT; return fJitFramed; }
bool JitMinOpts(void) const {LIMITED_METHOD_CONTRACT; return fJitMinOpts; }
bool JitEnableOptionalRelocs(void) const {LIMITED_METHOD_CONTRACT; return fJitEnableOptionalRelocs; }
+ bool DisableOptimizedThreadStaticAccess(void) const {LIMITED_METHOD_CONTRACT; return fDisableOptimizedThreadStaticAccess; }
// Tiered Compilation config
#if defined(FEATURE_TIERED_COMPILATION)
@@ -480,6 +481,7 @@ class EEConfig
bool fJitFramed; // Enable/Disable EBP based frames
bool fJitMinOpts; // Enable MinOpts for all jitted methods
bool fJitEnableOptionalRelocs; // Allow optional relocs
+ bool fDisableOptimizedThreadStaticAccess; // Disable OptimizedThreadStatic access
unsigned iJitOptimizeType; // 0=Blended,1=SmallCode,2=FastCode, default is 0=Blended
diff --git a/src/coreclr/vm/excep.cpp b/src/coreclr/vm/excep.cpp
index 9fe9376fd58ef..6d8e3a426bbaa 100644
--- a/src/coreclr/vm/excep.cpp
+++ b/src/coreclr/vm/excep.cpp
@@ -5336,6 +5336,10 @@ DefaultCatchHandler(PEXCEPTION_POINTERS pExceptionPointers,
FlushLogging(); // Flush any logging output
GCPROTECT_END();
+#ifdef HOST_WINDOWS
+ CreateCrashDumpIfEnabled();
+#endif
+
#ifdef _DEBUG
// Do not care about lock check for unhandled exception.
while (unbreakableLockCount)
diff --git a/src/coreclr/vm/jitinterface.cpp b/src/coreclr/vm/jitinterface.cpp
index 67e127bf91ea6..01ab9aae94463 100644
--- a/src/coreclr/vm/jitinterface.cpp
+++ b/src/coreclr/vm/jitinterface.cpp
@@ -1463,6 +1463,10 @@ void CEEInfo::getThreadLocalStaticBlocksInfo (CORINFO_THREAD_STATIC_BLOCKS_INFO*
EE_TO_JIT_TRANSITION_LEAF();
}
+#if !defined(TARGET_OSX) && defined(TARGET_UNIX) && defined(TARGET_ARM64)
+extern "C" size_t GetTLSResolverAddress();
+#endif // !TARGET_OSX && TARGET_UNIX && TARGET_ARM64
+
/*********************************************************************/
void CEEInfo::getFieldInfo (CORINFO_RESOLVED_TOKEN * pResolvedToken,
CORINFO_METHOD_HANDLE callerHandle,
@@ -1567,14 +1571,46 @@ void CEEInfo::getFieldInfo (CORINFO_RESOLVED_TOKEN * pResolvedToken,
fieldAccessor = CORINFO_FIELD_STATIC_SHARED_STATIC_HELPER;
pResult->helper = getSharedStaticsHelper(pField, pFieldMT);
+
+ bool optimizeThreadStaticAccess = false;
#if defined(TARGET_ARM)
// Optimization is disabled for linux/windows arm
#elif !defined(TARGET_WINDOWS) && defined(TARGET_X86)
// Optimization is disabled for linux/x86
#elif defined(TARGET_LINUX_MUSL) && defined(TARGET_ARM64)
// Optimization is disabled for linux musl arm64
+#elif !defined(TARGET_OSX) && defined(TARGET_UNIX) && defined(TARGET_ARM64)
+ // Optimization is enabled for linux/arm64 only for static resolver.
+ // For static resolver, the TP offset is same for all threads.
+ // For dynamic resolver, TP offset returned is for the current thread and
+ // will be different for the other threads.
+ uint32_t* resolverAddress = reinterpret_cast(GetTLSResolverAddress());
+ int ip = 0;
+ if ((resolverAddress[ip] == 0xd503201f) || (resolverAddress[ip] == 0xd503241f))
+ {
+ // nop might not be present in older resolver, so skip it.
+
+ // nop or hint 32
+ ip++;
+ }
+
+ if (
+ // ldr x0, [x0, #8]
+ (resolverAddress[ip] == 0xf9400400) &&
+ // ret
+ (resolverAddress[ip + 1] == 0xd65f03c0)
+ )
+ {
+ optimizeThreadStaticAccess = true;
+#ifdef _DEBUG
+ if (CLRConfig::GetConfigValue(CLRConfig::EXTERNAL_AssertNotStaticTlsResolver) != 0)
+ {
+ _ASSERTE(!"Detected static resolver in use when not expected");
+ }
+#endif
+ }
#else
- bool optimizeThreadStaticAccess = true;
+ optimizeThreadStaticAccess = true;
#if !defined(TARGET_OSX) && defined(TARGET_UNIX) && defined(TARGET_AMD64)
// For linux/x64, check if compiled coreclr as .so file and not single file.
// For single file, the `tls_index` might not be accurate.
@@ -1582,6 +1618,11 @@ void CEEInfo::getFieldInfo (CORINFO_RESOLVED_TOKEN * pResolvedToken,
optimizeThreadStaticAccess = GetTlsIndexObjectAddress() != nullptr;
#endif // !TARGET_OSX && TARGET_UNIX && TARGET_AMD64
+ if (g_pConfig->DisableOptimizedThreadStaticAccess())
+ {
+ optimizeThreadStaticAccess = false;
+ }
+
if (optimizeThreadStaticAccess)
{
// For windows x64/x86/arm64, linux x64/arm64/loongarch64/riscv64:
@@ -3898,8 +3939,18 @@ uint32_t CEEInfo::getClassAttribsInternal (CORINFO_CLASS_HANDLE clsHnd)
if (pMT->IsByRefLike())
ret |= CORINFO_FLG_BYREF_LIKE;
- if (pClass->IsUnsafeValueClass())
+ // In Reverse P/Invoke stubs, we are generating the code
+ // and we are not generating the code patterns that the GS checks
+ // are meant to catch.
+ // As a result, we can skip setting this flag.
+ // We do this as the GS checks (emitted when this flag is set)
+ // can break C++/CLI's copy-constructor semantics by missing copies.
+ if (pClass->IsUnsafeValueClass()
+ && !(m_pMethodBeingCompiled->IsILStub()
+ && dac_cast(m_pMethodBeingCompiled)->GetILStubType() == DynamicMethodDesc::StubNativeToCLRInterop))
+ {
ret |= CORINFO_FLG_UNSAFE_VALUECLASS;
+ }
}
if (pClass->HasExplicitFieldOffsetLayout() && pClass->HasOverlaidField())
ret |= CORINFO_FLG_OVERLAPPING_FIELDS;
diff --git a/src/coreclr/vm/readytoruninfo.cpp b/src/coreclr/vm/readytoruninfo.cpp
index e75373db8855a..fbf49abe88a8e 100644
--- a/src/coreclr/vm/readytoruninfo.cpp
+++ b/src/coreclr/vm/readytoruninfo.cpp
@@ -1945,7 +1945,7 @@ bool ReadyToRun_TypeGenericInfoMap::HasVariance(mdTypeDef input, bool *foundResu
bool ReadyToRun_TypeGenericInfoMap::HasConstraints(mdTypeDef input, bool *foundResult) const
{
ReadyToRunTypeGenericInfo typeGenericInfo = GetTypeGenericInfo(input, foundResult);
- return !!((uint8_t)typeGenericInfo & (uint8_t)ReadyToRunTypeGenericInfo::HasVariance);
+ return !!((uint8_t)typeGenericInfo & (uint8_t)ReadyToRunTypeGenericInfo::HasConstraints);
}
bool ReadyToRun_MethodIsGenericMap::IsGeneric(mdMethodDef input, bool *foundResult) const
diff --git a/src/coreclr/vm/stubhelpers.cpp b/src/coreclr/vm/stubhelpers.cpp
index 9988a912967cf..2fa6aecb1c1fe 100644
--- a/src/coreclr/vm/stubhelpers.cpp
+++ b/src/coreclr/vm/stubhelpers.cpp
@@ -552,6 +552,7 @@ FCIMPL3(SIZE_T, StubHelpers::ProfilerBeginTransitionCallback, SIZE_T pSecretPara
}
{
+ _ASSERTE(pThread != nullptr);
GCX_PREEMP_THREAD_EXISTS(pThread);
ProfilerManagedToUnmanagedTransitionMD(pRealMD, COR_PRF_TRANSITION_CALL);
@@ -582,6 +583,7 @@ FCIMPL2(void, StubHelpers::ProfilerEndTransitionCallback, MethodDesc* pRealMD, T
// and the transition requires us to set up a HMF.
HELPER_METHOD_FRAME_BEGIN_0();
{
+ _ASSERTE(pThread != nullptr);
GCX_PREEMP_THREAD_EXISTS(pThread);
ProfilerUnmanagedToManagedTransitionMD(pRealMD, COR_PRF_TRANSITION_RETURN);
diff --git a/src/installer/pkg/sfx/installers/dotnet-runtime-deps/dotnet-runtime-deps-debian.proj b/src/installer/pkg/sfx/installers/dotnet-runtime-deps/dotnet-runtime-deps-debian.proj
index be0713f05f750..f48ee38a1d78c 100644
--- a/src/installer/pkg/sfx/installers/dotnet-runtime-deps/dotnet-runtime-deps-debian.proj
+++ b/src/installer/pkg/sfx/installers/dotnet-runtime-deps/dotnet-runtime-deps-debian.proj
@@ -6,9 +6,9 @@
-
+
-
\ No newline at end of file
+
diff --git a/src/installer/tests/HostActivation.Tests/NativeHosting/Ijwhost.cs b/src/installer/tests/HostActivation.Tests/NativeHosting/Ijwhost.cs
index e7efe5eaafff8..062e6bcc58130 100644
--- a/src/installer/tests/HostActivation.Tests/NativeHosting/Ijwhost.cs
+++ b/src/installer/tests/HostActivation.Tests/NativeHosting/Ijwhost.cs
@@ -27,7 +27,7 @@ public void LoadLibrary()
{
string [] args = {
"ijwhost",
- sharedState.IjwLibraryPath,
+ sharedState.IjwApp.AppDll,
"NativeEntryPoint"
};
CommandResult result = sharedState.CreateNativeHostCommand(args, sharedState.RepoDirectories.BuiltDotnet)
@@ -38,6 +38,41 @@ public void LoadLibrary()
.And.HaveStdOutContaining("[C++/CLI] ManagedClass: AssemblyLoadContext = \"Default\" System.Runtime.Loader.DefaultAssemblyLoadContext");
}
+ [Theory]
+ [InlineData(true)]
+ [InlineData(false)]
+ public void LoadLibrary_ContextConfig(bool load_isolated)
+ {
+ // make a copy of a portion of the shared state because we will modify it
+ using (var app = sharedState.IjwApp.Copy())
+ {
+ string[] args = {
+ "ijwhost",
+ app.AppDll,
+ "NativeEntryPoint"
+ };
+
+ RuntimeConfig.FromFile(app.RuntimeConfigJson)
+ .WithProperty("System.Runtime.InteropServices.CppCLI.LoadComponentInIsolatedContext", load_isolated.ToString())
+ .Save();
+
+ CommandResult result = sharedState.CreateNativeHostCommand(args, sharedState.RepoDirectories.BuiltDotnet)
+ .Execute();
+
+ result.Should().Pass()
+ .And.HaveStdOutContaining("[C++/CLI] NativeEntryPoint: calling managed class");
+
+ if (load_isolated) // Assembly should be loaded in an isolated context
+ {
+ result.Should().HaveStdOutContaining("[C++/CLI] ManagedClass: AssemblyLoadContext = \"IsolatedComponentLoadContext");
+ }
+ else // Assembly should be loaded in the default context
+ {
+ result.Should().HaveStdOutContaining("[C++/CLI] ManagedClass: AssemblyLoadContext = \"Default\" System.Runtime.Loader.DefaultAssemblyLoadContext");
+ }
+ }
+ }
+
[Theory]
[InlineData(true)]
[InlineData(false)]
@@ -45,7 +80,7 @@ public void ManagedHost(bool selfContained)
{
string [] args = {
"ijwhost",
- sharedState.IjwLibraryPath,
+ sharedState.IjwApp.AppDll,
"NativeEntryPoint"
};
TestProjectFixture fixture = selfContained ? sharedState.ManagedHostFixture_SelfContained : sharedState.ManagedHostFixture_FrameworkDependent;
@@ -63,7 +98,7 @@ public void ManagedHost(bool selfContained)
public class SharedTestState : SharedTestStateBase
{
- public string IjwLibraryPath { get; }
+ public TestApp IjwApp {get;}
public TestProjectFixture ManagedHostFixture_FrameworkDependent { get; }
public TestProjectFixture ManagedHostFixture_SelfContained { get; }
@@ -71,7 +106,7 @@ public class SharedTestState : SharedTestStateBase
public SharedTestState()
{
string folder = Path.Combine(BaseDirectory, "ijw");
- Directory.CreateDirectory(folder);
+ IjwApp = new TestApp(folder, "ijw");
// Copy over ijwhost
string ijwhostName = "ijwhost.dll";
@@ -79,8 +114,7 @@ public SharedTestState()
// Copy over the C++/CLI test library
string ijwLibraryName = "ijw.dll";
- IjwLibraryPath = Path.Combine(folder, ijwLibraryName);
- File.Copy(Path.Combine(RepoDirectories.HostTestArtifacts, ijwLibraryName), IjwLibraryPath);
+ File.Copy(Path.Combine(RepoDirectories.HostTestArtifacts, ijwLibraryName), Path.Combine(folder, ijwLibraryName));
// Create a runtimeconfig.json for the C++/CLI test library
new RuntimeConfig(Path.Combine(folder, "ijw.runtimeconfig.json"))
diff --git a/src/libraries/Common/src/Interop/Unix/System.Security.Cryptography.Native/Interop.EvpPkey.cs b/src/libraries/Common/src/Interop/Unix/System.Security.Cryptography.Native/Interop.EvpPkey.cs
index 77b80634bd0ce..4e8659b5653b7 100644
--- a/src/libraries/Common/src/Interop/Unix/System.Security.Cryptography.Native/Interop.EvpPkey.cs
+++ b/src/libraries/Common/src/Interop/Unix/System.Security.Cryptography.Native/Interop.EvpPkey.cs
@@ -217,7 +217,8 @@ internal static ArraySegment RentEncodeSubjectPublicKeyInfo(SafeEvpPKeyHan
[LibraryImport(Libraries.CryptoNative, StringMarshalling = StringMarshalling.Utf8)]
private static partial SafeEvpPKeyHandle CryptoNative_LoadPrivateKeyFromEngine(
string engineName,
- string keyName);
+ string keyName,
+ [MarshalAs(UnmanagedType.Bool)] out bool haveEngine);
internal static SafeEvpPKeyHandle LoadPrivateKeyFromEngine(
string engineName,
@@ -226,7 +227,13 @@ internal static SafeEvpPKeyHandle LoadPrivateKeyFromEngine(
Debug.Assert(engineName is not null);
Debug.Assert(keyName is not null);
- SafeEvpPKeyHandle pkey = CryptoNative_LoadPrivateKeyFromEngine(engineName, keyName);
+ SafeEvpPKeyHandle pkey = CryptoNative_LoadPrivateKeyFromEngine(engineName, keyName, out bool haveEngine);
+
+ if (!haveEngine)
+ {
+ pkey.Dispose();
+ throw new CryptographicException(SR.Cryptography_EnginesNotSupported);
+ }
if (pkey.IsInvalid)
{
@@ -240,7 +247,8 @@ internal static SafeEvpPKeyHandle LoadPrivateKeyFromEngine(
[LibraryImport(Libraries.CryptoNative, StringMarshalling = StringMarshalling.Utf8)]
private static partial SafeEvpPKeyHandle CryptoNative_LoadPublicKeyFromEngine(
string engineName,
- string keyName);
+ string keyName,
+ [MarshalAs(UnmanagedType.Bool)] out bool haveEngine);
internal static SafeEvpPKeyHandle LoadPublicKeyFromEngine(
string engineName,
@@ -249,7 +257,13 @@ internal static SafeEvpPKeyHandle LoadPublicKeyFromEngine(
Debug.Assert(engineName is not null);
Debug.Assert(keyName is not null);
- SafeEvpPKeyHandle pkey = CryptoNative_LoadPublicKeyFromEngine(engineName, keyName);
+ SafeEvpPKeyHandle pkey = CryptoNative_LoadPublicKeyFromEngine(engineName, keyName, out bool haveEngine);
+
+ if (!haveEngine)
+ {
+ pkey.Dispose();
+ throw new CryptographicException(SR.Cryptography_EnginesNotSupported);
+ }
if (pkey.IsInvalid)
{
diff --git a/src/libraries/Common/tests/TestUtilities/System/PlatformDetection.Windows.cs b/src/libraries/Common/tests/TestUtilities/System/PlatformDetection.Windows.cs
index 1b570872d06d9..6a166b298cd51 100644
--- a/src/libraries/Common/tests/TestUtilities/System/PlatformDetection.Windows.cs
+++ b/src/libraries/Common/tests/TestUtilities/System/PlatformDetection.Windows.cs
@@ -25,6 +25,7 @@ public static partial class PlatformDetection
public static bool IsWindows8xOrLater => IsWindowsVersionOrLater(6, 2);
public static bool IsWindows10OrLater => IsWindowsVersionOrLater(10, 0);
public static bool IsWindowsServer2019 => IsWindows && IsNotWindowsNanoServer && GetWindowsVersion() == 10 && GetWindowsMinorVersion() == 0 && GetWindowsBuildVersion() == 17763;
+ public static bool IsWindowsServer2022 => IsWindows && IsNotWindowsNanoServer && GetWindowsVersion() == 10 && GetWindowsMinorVersion() == 0 && GetWindowsBuildVersion() == 20348;
public static bool IsWindowsNanoServer => IsWindows && (IsNotWindowsIoTCore && GetWindowsInstallationType().Equals("Nano Server", StringComparison.OrdinalIgnoreCase));
public static bool IsWindowsServerCore => IsWindows && GetWindowsInstallationType().Equals("Server Core", StringComparison.OrdinalIgnoreCase);
public static int WindowsVersion => IsWindows ? (int)GetWindowsVersion() : -1;
diff --git a/src/libraries/System.Diagnostics.EventLog/src/System.Diagnostics.EventLog.csproj b/src/libraries/System.Diagnostics.EventLog/src/System.Diagnostics.EventLog.csproj
index 96deaca0a27dd..5bf9cee3c8725 100644
--- a/src/libraries/System.Diagnostics.EventLog/src/System.Diagnostics.EventLog.csproj
+++ b/src/libraries/System.Diagnostics.EventLog/src/System.Diagnostics.EventLog.csproj
@@ -3,6 +3,8 @@
$(NetCoreAppCurrent)-windows;$(NetCoreAppCurrent);$(NetCoreAppPrevious)-windows;$(NetCoreAppPrevious);$(NetCoreAppMinimum)-windows;$(NetCoreAppMinimum);netstandard2.0;$(NetFrameworkMinimum)
true
true
+ true
+ 1
Provides the System.Diagnostics.EventLog class, which allows the applications to use the Windows event log service.
Commonly Used Types:
diff --git a/src/libraries/System.Diagnostics.EventLog/src/System/Diagnostics/Reader/NativeWrapper.cs b/src/libraries/System.Diagnostics.EventLog/src/System/Diagnostics/Reader/NativeWrapper.cs
index e4cebc7c2e1da..557ff992004ce 100644
--- a/src/libraries/System.Diagnostics.EventLog/src/System/Diagnostics/Reader/NativeWrapper.cs
+++ b/src/libraries/System.Diagnostics.EventLog/src/System/Diagnostics/Reader/NativeWrapper.cs
@@ -482,7 +482,8 @@ internal static EventLogHandle EvtGetPublisherMetadataPropertyHandle(EventLogHan
public static string EvtFormatMessage(EventLogHandle handle, uint msgId)
{
int bufferNeeded;
- bool status = UnsafeNativeMethods.EvtFormatMessage(handle, EventLogHandle.Zero, msgId, 0, null, UnsafeNativeMethods.EvtFormatMessageFlags.EvtFormatMessageId, 0, null, out bufferNeeded);
+ Span emptyBuffer = [ '\0' ]; // issue: https://github.com/dotnet/runtime/issues/100198
+ bool status = UnsafeNativeMethods.EvtFormatMessage(handle, EventLogHandle.Zero, msgId, 0, null, UnsafeNativeMethods.EvtFormatMessageFlags.EvtFormatMessageId, 0, emptyBuffer, out bufferNeeded);
int error = Marshal.GetLastWin32Error();
// ERROR_EVT_UNRESOLVED_VALUE_INSERT and its cousins are commonly returned for raw message text.
@@ -933,7 +934,8 @@ public static IList