From 89c96859a2d794000679165568639e8113468179 Mon Sep 17 00:00:00 2001 From: Juan Hoyos <19413848+hoyosjs@users.noreply.github.com> Date: Mon, 25 Aug 2025 10:00:32 -0700 Subject: [PATCH 01/20] [release/8.0] Bump usages of MicroBuild task to v4 (#119027) * Bump usages of MicroBuild task to v4 Version 2 is not equipped for PRC required connections * Remove MicroBuild signing step from build job It's not used to sign the DAC * Add connection identifier --- eng/pipelines/coreclr/templates/build-job.yml | 11 ----------- .../official/jobs/prepare-signed-artifacts.yml | 6 +++++- 2 files changed, 5 insertions(+), 12 deletions(-) diff --git a/eng/pipelines/coreclr/templates/build-job.yml b/eng/pipelines/coreclr/templates/build-job.yml index ebaeae5e124042..7790560bcb5eba 100644 --- a/eng/pipelines/coreclr/templates/build-job.yml +++ b/eng/pipelines/coreclr/templates/build-job.yml @@ -124,17 +124,6 @@ jobs: - ${{ if and(eq(variables['System.TeamProject'], 'internal'), ne(variables['Build.Reason'], 'PullRequest')) }}: - template: /eng/pipelines/common/restore-internal-tools.yml - # Install MicroBuild for signing the DAC and DBI - - ${{ if and(eq(variables['System.TeamProject'], 'internal'), eq(parameters.signBinaries, true), eq(parameters.osGroup, 'windows')) }}: - - task: MicroBuildSigningPlugin@2 - displayName: Install MicroBuild plugin for Signing - inputs: - signType: $(SignType) - zipSources: false - feedSource: https://dnceng.pkgs.visualstudio.com/_packaging/MicroBuildToolset/nuget/v3/index.json - continueOnError: false - condition: and(succeeded(), in(variables['SignType'], 'real', 'test')) - - ${{ if ne(variables['System.TeamProject'], 'public') }}: - ${{ if ne(parameters.osGroup, 'windows') }}: - task: Bash@3 diff --git a/eng/pipelines/official/jobs/prepare-signed-artifacts.yml b/eng/pipelines/official/jobs/prepare-signed-artifacts.yml index 4327746620095b..540f392e796389 100644 --- a/eng/pipelines/official/jobs/prepare-signed-artifacts.yml +++ b/eng/pipelines/official/jobs/prepare-signed-artifacts.yml @@ -36,12 +36,16 @@ jobs: - ${{ if eq(parameters.isOfficialBuild, true) }}: - task: NuGetAuthenticate@1 - - task: MicroBuildSigningPlugin@2 + - task: MicroBuildSigningPlugin@4 displayName: Install MicroBuild plugin for Signing inputs: signType: $(SignType) zipSources: false feedSource: https://dnceng.pkgs.visualstudio.com/_packaging/MicroBuildToolset/nuget/v3/index.json + ConnectedPMEServiceName: 248d384a-b39b-46e3-8ad5-c2c210d5e7ca + env: + TeamName: $(_TeamName) + MicroBuildOutputFolderOverride: '$(Agent.TempDirectory)' continueOnError: false condition: and(succeeded(), in(variables['SignType'], 'real', 'test')) From 1d346eb790fc2c00170cc9f45016d82117616575 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Wed, 27 Aug 2025 14:33:44 +0200 Subject: [PATCH 02/20] [release/8.0-staging] make Http2_RequestFailsWithAppropriateHttpProtocolException test more deterministic (#119103) * make Http2_IncorrectServerPreface_RequestFailsWithAppropriateHttpProtocolException test more deterministic * feedback --------- Co-authored-by: wfurt --- .../tests/FunctionalTests/HttpClientHandlerTest.Http2.cs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/libraries/System.Net.Http/tests/FunctionalTests/HttpClientHandlerTest.Http2.cs b/src/libraries/System.Net.Http/tests/FunctionalTests/HttpClientHandlerTest.Http2.cs index a9b1be6e7766a2..3036935ef5533d 100644 --- a/src/libraries/System.Net.Http/tests/FunctionalTests/HttpClientHandlerTest.Http2.cs +++ b/src/libraries/System.Net.Http/tests/FunctionalTests/HttpClientHandlerTest.Http2.cs @@ -139,7 +139,8 @@ public async Task Http2_StreamResetByServerBeforePrefix_RequestFailsWithGoawayPr Http2LoopbackConnection connection = await server.AcceptConnectionAsync(timeout: null); _ = await connection.ReadSettingsAsync(); - + // Wait until client starts sending request + _ = await connection.ReadFrameAsync(TestHelper.PassingTestTimeout); GoAwayFrame goAwayFrame = new GoAwayFrame(lastStreamId: 0, (int)ProtocolErrors.HTTP_1_1_REQUIRED, additionalDebugData: Array.Empty(), streamId: 0); await connection.WriteFrameAsync(goAwayFrame); @@ -363,6 +364,8 @@ public async Task Http2_IncorrectServerPreface_RequestFailsWithAppropriateHttpPr Http2LoopbackConnection connection = await server.AcceptConnectionAsync(); await connection.ReadSettingsAsync(); + // Wait until client starts sending request + _ = await connection.ReadFrameAsync(TestHelper.PassingTestTimeout); await connection.SendGoAway(0, ProtocolErrors.INTERNAL_ERROR); await AssertProtocolErrorAsync(sendTask, ProtocolErrors.INTERNAL_ERROR); From 7442eca81279c7e1db3c9563b3ac0c0efe56f23c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alexander=20K=C3=B6plinger?= Date: Thu, 4 Sep 2025 13:00:14 +0200 Subject: [PATCH 03/20] [maccatalyst] Check for -Wno-overriding-option for compatibility with clang in Xcode 16.3+ (#119260) (#119303) https://github.com/llvm/llvm-project/commit/1c66d08b0137cef7761b8220d3b7cb7833f57cdb renamed the option `-Wno-overriding-t-option` to `-Wno-overriding-option`. This caused some configure time checks in CMake to fail because of hitting an unknown compiler option. (cherry picked from commit 4b8a47869b384ccdb4e885d8efcf6a53c3467dd3) (cherry picked from commit f08548f4522345b4c84e52f1dcd0f516f1ae0f77) --- eng/native/configurecompiler.cmake | 18 +++++++++++++++--- src/mono/CMakeLists.txt | 21 +++++++++++++++++++++ src/mono/mono.proj | 2 -- 3 files changed, 36 insertions(+), 5 deletions(-) diff --git a/eng/native/configurecompiler.cmake b/eng/native/configurecompiler.cmake index 1882ceb68ffce6..9a8f16fb457642 100644 --- a/eng/native/configurecompiler.cmake +++ b/eng/native/configurecompiler.cmake @@ -635,9 +635,21 @@ if (CLR_CMAKE_HOST_UNIX) # a value for mmacosx-version-min (blank CMAKE_OSX_DEPLOYMENT_TARGET gets # replaced with a default value, and always gets expanded to an OS version. # https://gitlab.kitware.com/cmake/cmake/-/issues/20132 - # We need to disable the warning that -tagret replaces -mmacosx-version-min - set(DISABLE_OVERRIDING_MIN_VERSION_ERROR -Wno-overriding-t-option) - add_link_options(-Wno-overriding-t-option) + # We need to disable the warning that -target replaces -mmacosx-version-min + # + # With https://github.com/llvm/llvm-project/commit/1c66d08b0137cef7761b8220d3b7cb7833f57cdb clang renamed the option so we need to check for both + check_c_compiler_flag("-Wno-overriding-option" COMPILER_SUPPORTS_W_NO_OVERRIDING_OPTION) + if (COMPILER_SUPPORTS_W_NO_OVERRIDING_OPTION) + set(DISABLE_OVERRIDING_MIN_VERSION_ERROR -Wno-overriding-option) + else() + check_c_compiler_flag("-Wno-overriding-t-option" COMPILER_SUPPORTS_W_NO_OVERRIDING_T_OPTION) + if (COMPILER_SUPPORTS_W_NO_OVERRIDING_T_OPTION) + set(DISABLE_OVERRIDING_MIN_VERSION_ERROR -Wno-overriding-t-option) + else() + message(FATAL_ERROR "Compiler does not support -Wno-overriding-option or -Wno-overriding-t-option, needed for Mac Catalyst builds.") + endif() + endif() + add_link_options(${DISABLE_OVERRIDING_MIN_VERSION_ERROR}) if(CLR_CMAKE_HOST_ARCH_ARM64) set(MACOS_VERSION_MIN_FLAGS "-target arm64-apple-ios14.2-macabi") add_link_options(-target arm64-apple-ios14.2-macabi) diff --git a/src/mono/CMakeLists.txt b/src/mono/CMakeLists.txt index 8320e4c4cf145b..b1fa4eacae0d51 100644 --- a/src/mono/CMakeLists.txt +++ b/src/mono/CMakeLists.txt @@ -551,6 +551,27 @@ if(GCC) set(WARNINGS "${WARNINGS} -Qunused-arguments -Wno-tautological-compare -Wno-parentheses-equality -Wno-self-assign -Wno-return-stack-address -Wno-constant-logical-operand -Wno-zero-length-array -Wno-asm-operand-widths") endif() + if (HOST_MACCAT) + # Somewhere between CMake 3.17 and 3.19.4, it became impossible to not pass + # a value for mmacosx-version-min (blank CMAKE_OSX_DEPLOYMENT_TARGET gets + # replaced with a default value, and always gets expanded to an OS version. + # https://gitlab.kitware.com/cmake/cmake/-/issues/20132 + # We need to disable the warning that -target replaces -mmacosx-version-min + # + # With https://github.com/llvm/llvm-project/commit/1c66d08b0137cef7761b8220d3b7cb7833f57cdb clang renamed the option so we need to check for both + check_c_compiler_flag("-Wno-overriding-option" COMPILER_SUPPORTS_W_NO_OVERRIDING_OPTION) + if (COMPILER_SUPPORTS_W_NO_OVERRIDING_OPTION) + set(WARNINGS "${WARNINGS} -Wno-overriding-option") + else() + check_c_compiler_flag("-Wno-overriding-t-option" COMPILER_SUPPORTS_W_NO_OVERRIDING_T_OPTION) + if (COMPILER_SUPPORTS_W_NO_OVERRIDING_T_OPTION) + set(WARNINGS "${WARNINGS} -Wno-overriding-t-option") + else() + message(FATAL_ERROR "Compiler does not support -Wno-overriding-option or -Wno-overriding-t-option, needed for Mac Catalyst builds.") + endif() + endif() + endif() + check_c_compiler_flag("-Werror=incompatible-pointer-types" WERROR_INCOMPATIBLE_POINTER_TYPES) if(WERROR_INCOMPATIBLE_POINTER_TYPES) set(WERROR_C "${WERROR_C} -Werror=incompatible-pointer-types") diff --git a/src/mono/mono.proj b/src/mono/mono.proj index d0e704abbdf5a7..47fdbe483d6876 100644 --- a/src/mono/mono.proj +++ b/src/mono/mono.proj @@ -392,8 +392,6 @@ <_MonoCMakeArgs Include="-DCMAKE_SYSTEM_VARIANT=maccatalyst" /> - - <_MonoCPPFLAGS Include="-Wno-overriding-t-option" /> <_MonoCFlags Condition="'$(TargetArchitecture)' == 'arm64'" Include="-target arm64-apple-ios14.2-macabi" /> <_MonoCFlags Condition="'$(TargetArchitecture)' == 'x64'" Include="-target x86_64-apple-ios13.5-macabi" /> <_MonoCFLAGS Condition="'$(TargetArchitecture)' == 'arm64'" Include="-arch arm64" /> From 5a2385059d0005c427512ece017becc67f2a2bee Mon Sep 17 00:00:00 2001 From: Manish Godse <61718172+mangod9@users.noreply.github.com> Date: Fri, 5 Sep 2025 09:08:24 -0700 Subject: [PATCH 04/20] [release/8.0-staging] Reapply distribute free regions (#117736) * Reapply "[release/8.0-staging] improve distribute_free_regions (#115023)" (#117543) This reverts commit 41fa3fb6eadffdec377b5ad9b06ffef673cc5dd1. * Port a missing age to age_free_regions This change was missing from the initial port. * fix build break. --- src/coreclr/gc/gc.cpp | 613 +++++++++++++++++++++++++++------------- src/coreclr/gc/gcpriv.h | 32 ++- 2 files changed, 443 insertions(+), 202 deletions(-) diff --git a/src/coreclr/gc/gc.cpp b/src/coreclr/gc/gc.cpp index 74143fc8df86de..d4295540580a73 100644 --- a/src/coreclr/gc/gc.cpp +++ b/src/coreclr/gc/gc.cpp @@ -2487,6 +2487,8 @@ uint32_t gc_heap::m_high_memory_load_th; uint32_t gc_heap::v_high_memory_load_th; +uint32_t gc_heap::almost_high_memory_load_th; + bool gc_heap::is_restricted_physical_mem; uint64_t gc_heap::total_physical_mem = 0; @@ -12730,35 +12732,29 @@ void gc_heap::rearrange_heap_segments(BOOL compacting) #endif //!USE_REGIONS #if defined(USE_REGIONS) -// trim down the list of free regions pointed at by free_list down to target_count, moving the extra ones to surplus_list -static void remove_surplus_regions (region_free_list* free_list, region_free_list* surplus_list, size_t target_count) +// trim down the list of regions pointed at by src down to target_count, moving the extra ones to dest +static void trim_region_list (region_free_list* dest, region_free_list* src, size_t target_count) { - while (free_list->get_num_free_regions() > target_count) + while (src->get_num_free_regions() > target_count) { - // remove one region from the heap's free list - heap_segment* region = free_list->unlink_region_front(); - - // and put it on the surplus list - surplus_list->add_region_front (region); + heap_segment* region = src->unlink_region_front(); + dest->add_region_front (region); } } -// add regions from surplus_list to free_list, trying to reach target_count -static int64_t add_regions (region_free_list* free_list, region_free_list* surplus_list, size_t target_count) +// add regions from src to dest, trying to grow the size of dest to target_count +static int64_t grow_region_list (region_free_list* dest, region_free_list* src, size_t target_count) { int64_t added_count = 0; - while (free_list->get_num_free_regions() < target_count) + while (dest->get_num_free_regions() < target_count) { - if (surplus_list->get_num_free_regions() == 0) + if (src->get_num_free_regions() == 0) break; added_count++; - // remove one region from the surplus list - heap_segment* region = surplus_list->unlink_region_front(); - - // and put it on the heap's free list - free_list->add_region_front (region); + heap_segment* region = src->unlink_region_front(); + dest->add_region_front (region); } return added_count; } @@ -13240,12 +13236,102 @@ void region_free_list::sort_by_committed_and_age() } tail_free_region = prev; } -#endif //USE_REGIONS +void gc_heap::age_free_regions (const char* msg) +{ + // If we are doing an ephemeral GC as a precursor to a BGC, then we will age all of the region + // kinds during the ephemeral GC and skip the call to age_free_regions during the BGC itself. + bool age_all_region_kinds = (settings.condemned_generation == max_generation); + + if (!age_all_region_kinds) + { +#ifdef MULTIPLE_HEAPS + gc_heap* hp = g_heaps[0]; +#else //MULTIPLE_HEAPS + gc_heap* hp = pGenGCHeap; +#endif //MULTIPLE_HEAPS + age_all_region_kinds = (hp->current_bgc_state == bgc_initialized); + } + + if (age_all_region_kinds) + { + global_free_huge_regions.age_free_regions(); + } + +#ifdef MULTIPLE_HEAPS + for (int i = 0; i < n_heaps; i++) + { + gc_heap* hp = g_heaps[i]; +#else //MULTIPLE_HEAPS + { + gc_heap* hp = pGenGCHeap; + const int i = 0; +#endif //MULTIPLE_HEAPS + + if (age_all_region_kinds) + { + // age and print all kinds of free regions + region_free_list::age_free_regions (hp->free_regions); + region_free_list::print (hp->free_regions, i, msg); + } + else + { + // age and print only basic free regions + hp->free_regions[basic_free_region].age_free_regions(); + hp->free_regions[basic_free_region].print (i, msg); + } + } +} + +// distribute_free_regions is called during all blocking GCs and in the start of the BGC mark phase +// unless we already called it during an ephemeral GC right before the BGC. +// +// Free regions are stored on the following permanent lists: +// - global_regions_to_decommit +// - global_free_huge_regions +// - (per-heap) free_regions +// and the following lists that are local to distribute_free_regions: +// - aged_regions +// - surplus_regions +// +// For reason_induced_aggressive GCs, we decommit all regions. Therefore, the below description is +// for other GC types. +// +// distribute_free_regions steps: +// +// 1. Process region ages +// a. Move all huge regions from free_regions to global_free_huge_regions. +// (The intention is that free_regions shouldn't contain any huge regions outside of the period +// where a GC reclaims them and distribute_free_regions moves them to global_free_huge_regions, +// though perhaps BGC can leave them there. Future work could verify and assert this.) +// b. Move any basic region in global_regions_to_decommit (which means we intended to decommit them +// but haven't done so yet) to surplus_regions +// c. Move all huge regions that are past the age threshold from global_free_huge_regions to aged_regions +// d. Move all basic/large regions that are past the age threshold from free_regions to aged_regions +// 2. Move all regions from aged_regions to global_regions_to_decommit. Note that the intention is to +// combine this with move_highest_free_regions in a future change, which is why we don't just do this +// in steps 1c/1d. +// 3. Compute the required per-heap budgets for SOH (basic regions) and the balance. The budget for LOH +// (large) is zero as we are using an entirely age-based approach. +// balance = (number of free regions) - budget +// 4. Decide if we are going to distribute or decommit a nonzero balance. To distribute, we adjust the +// per-heap budgets, so after this step the LOH (large) budgets can be positive. +// a. A negative balance (deficit) for SOH (basic) will be distributed it means we expect to use +// more memory than we have on the free lists. A negative balance for LOH (large) isn't possible +// for LOH since the budgets start at zero. +// b. For SOH (basic), we will decommit surplus regions unless we are in a foreground GC during BGC. +// c. For LOH (large), we will distribute surplus regions since we are using an entirely age-based +// approach. However, if we are in a high-memory-usage scenario, we will decommit. In this case, +// we will also decommit the huge regions in global_free_huge_regions. Note that they were not +// originally included in the balance because they are kept in a global list. Only basic/large +// regions are kept in per-heap lists where they can be distributed. +// 5. Implement the distribute-or-decommit strategy. To distribute, we simply move regions across heaps, +// using surplus_regions as a holding space. To decommit, for server GC we generally leave them on the +// global_regions_to_decommit list and decommit them over time. However, in high-memory-usage scenarios, +// we will immediately decommit some or all of these regions. For workstation GC, we decommit a limited +// amount and move the rest back to the (one) heap's free_list. void gc_heap::distribute_free_regions() { -#ifdef USE_REGIONS - const int kind_count = large_free_region + 1; #ifdef MULTIPLE_HEAPS BOOL joined_last_gc_before_oom = FALSE; @@ -13262,6 +13348,8 @@ void gc_heap::distribute_free_regions() #endif //MULTIPLE_HEAPS if (settings.reason == reason_induced_aggressive) { + global_regions_to_decommit[huge_free_region].transfer_regions (&global_free_huge_regions); + #ifdef MULTIPLE_HEAPS for (int i = 0; i < n_heaps; i++) { @@ -13312,22 +13400,22 @@ void gc_heap::distribute_free_regions() } // first step: accumulate the number of free regions and the budget over all heaps - // and move huge regions to global free list - size_t total_num_free_regions[kind_count] = { 0, 0 }; - size_t total_budget_in_region_units[kind_count] = { 0, 0 }; + // + // The initial budget will only be calculated for basic free regions. For large regions, the initial budget + // is zero, and distribute-vs-decommit will be determined entirely by region ages and whether we are in a + // high memory usage scenario. Distributing a surplus/deficit of regions can change the budgets that are used. + size_t total_num_free_regions[count_distributed_free_region_kinds] = { 0, 0 }; + size_t total_budget_in_region_units[count_distributed_free_region_kinds] = { 0, 0 }; + + size_t heap_budget_in_region_units[count_distributed_free_region_kinds][MAX_SUPPORTED_CPUS] = {}; + size_t min_heap_budget_in_region_units[count_distributed_free_region_kinds][MAX_SUPPORTED_CPUS] = {}; + region_free_list aged_regions[count_free_region_kinds]; + region_free_list surplus_regions[count_distributed_free_region_kinds]; + + // we may still have regions left on the regions_to_decommit list - + // use these to fill the budget as well + surplus_regions[basic_free_region].transfer_regions (&global_regions_to_decommit[basic_free_region]); - size_t num_decommit_regions_by_time = 0; - size_t size_decommit_regions_by_time = 0; - size_t heap_budget_in_region_units[MAX_SUPPORTED_CPUS][kind_count]; - size_t min_heap_budget_in_region_units[MAX_SUPPORTED_CPUS]; - size_t region_size[kind_count] = { global_region_allocator.get_region_alignment(), global_region_allocator.get_large_region_alignment() }; - region_free_list surplus_regions[kind_count]; - for (int kind = basic_free_region; kind < kind_count; kind++) - { - // we may still have regions left on the regions_to_decommit list - - // use these to fill the budget as well - surplus_regions[kind].transfer_regions (&global_regions_to_decommit[kind]); - } #ifdef MULTIPLE_HEAPS for (int i = 0; i < n_heaps; i++) { @@ -13335,167 +13423,87 @@ void gc_heap::distribute_free_regions() #else //MULTIPLE_HEAPS { gc_heap* hp = pGenGCHeap; - // just to reduce the number of #ifdefs in the code below - const int i = 0; - const int n_heaps = 1; #endif //MULTIPLE_HEAPS - for (int kind = basic_free_region; kind < kind_count; kind++) - { - // If there are regions in free that haven't been used in AGE_IN_FREE_TO_DECOMMIT GCs we always decommit them. - region_free_list& region_list = hp->free_regions[kind]; - heap_segment* next_region = nullptr; - for (heap_segment* region = region_list.get_first_free_region(); region != nullptr; region = next_region) - { - next_region = heap_segment_next (region); - int age_in_free_to_decommit = min (max (AGE_IN_FREE_TO_DECOMMIT, n_heaps), MAX_AGE_IN_FREE); - // when we are about to get OOM, we'd like to discount the free regions that just have the initial page commit as they are not useful - if ((heap_segment_age_in_free (region) >= age_in_free_to_decommit) || - ((get_region_committed_size (region) == GC_PAGE_SIZE) && joined_last_gc_before_oom)) - { - num_decommit_regions_by_time++; - size_decommit_regions_by_time += get_region_committed_size (region); - dprintf (REGIONS_LOG, ("h%2d region %p age %2d, decommit", - i, heap_segment_mem (region), heap_segment_age_in_free (region))); - region_free_list::unlink_region (region); - region_free_list::add_region (region, global_regions_to_decommit); - } - } - - total_num_free_regions[kind] += region_list.get_num_free_regions(); - } - global_free_huge_regions.transfer_regions (&hp->free_regions[huge_free_region]); - - heap_budget_in_region_units[i][basic_free_region] = 0; - min_heap_budget_in_region_units[i] = 0; - heap_budget_in_region_units[i][large_free_region] = 0; - } - - for (int gen = soh_gen0; gen < total_generation_count; gen++) - { - if ((gen <= soh_gen2) && - total_budget_in_region_units[basic_free_region] >= (total_num_free_regions[basic_free_region] + - surplus_regions[basic_free_region].get_num_free_regions())) - { - // don't accumulate budget from higher soh generations if we cannot cover lower ones - dprintf (REGIONS_LOG, ("out of free regions - skipping gen %d budget = %zd >= avail %zd", - gen, - total_budget_in_region_units[basic_free_region], - total_num_free_regions[basic_free_region] + surplus_regions[basic_free_region].get_num_free_regions())); - continue; - } -#ifdef MULTIPLE_HEAPS - for (int i = 0; i < n_heaps; i++) - { - gc_heap* hp = g_heaps[i]; -#else //MULTIPLE_HEAPS - { - gc_heap* hp = pGenGCHeap; - // just to reduce the number of #ifdefs in the code below - const int i = 0; - const int n_heaps = 1; -#endif //MULTIPLE_HEAPS - ptrdiff_t budget_gen = max (hp->estimate_gen_growth (gen), 0); - int kind = gen >= loh_generation; - size_t budget_gen_in_region_units = (budget_gen + (region_size[kind] - 1)) / region_size[kind]; - dprintf (REGIONS_LOG, ("h%2d gen %d has an estimated growth of %zd bytes (%zd regions)", i, gen, budget_gen, budget_gen_in_region_units)); - if (gen <= soh_gen2) - { - // preserve the budget for the previous generation - we should not go below that - min_heap_budget_in_region_units[i] = heap_budget_in_region_units[i][kind]; - } - heap_budget_in_region_units[i][kind] += budget_gen_in_region_units; - total_budget_in_region_units[kind] += budget_gen_in_region_units; - } } - dprintf (1, ("moved %2zd regions (%8zd) to decommit based on time", num_decommit_regions_by_time, size_decommit_regions_by_time)); + move_all_aged_regions(total_num_free_regions, aged_regions, joined_last_gc_before_oom); + // For now, we just decommit right away, but eventually these will be used in move_highest_free_regions + move_regions_to_decommit(aged_regions); - global_free_huge_regions.transfer_regions (&global_regions_to_decommit[huge_free_region]); + size_t total_basic_free_regions = total_num_free_regions[basic_free_region] + surplus_regions[basic_free_region].get_num_free_regions(); + total_budget_in_region_units[basic_free_region] = compute_basic_region_budgets(heap_budget_in_region_units[basic_free_region], min_heap_budget_in_region_units[basic_free_region], total_basic_free_regions); - size_t free_space_in_huge_regions = global_free_huge_regions.get_size_free_regions(); + bool aggressive_decommit_large_p = joined_last_gc_before_oom || dt_high_memory_load_p() || near_heap_hard_limit_p(); - ptrdiff_t num_regions_to_decommit[kind_count]; - int region_factor[kind_count] = { 1, LARGE_REGION_FACTOR }; -#ifdef TRACE_GC - const char* kind_name[count_free_region_kinds] = { "basic", "large", "huge"}; -#endif // TRACE_GC + int region_factor[count_distributed_free_region_kinds] = { 1, LARGE_REGION_FACTOR }; #ifndef MULTIPLE_HEAPS // just to reduce the number of #ifdefs in the code below const int n_heaps = 1; #endif //!MULTIPLE_HEAPS - size_t num_huge_region_units_to_consider[kind_count] = { 0, free_space_in_huge_regions / region_size[large_free_region] }; - - for (int kind = basic_free_region; kind < kind_count; kind++) + for (int kind = basic_free_region; kind < count_distributed_free_region_kinds; kind++) { - num_regions_to_decommit[kind] = surplus_regions[kind].get_num_free_regions(); - - dprintf(REGIONS_LOG, ("%zd %s free regions, %zd regions budget, %zd regions on decommit list, %zd huge regions to consider", + dprintf(REGIONS_LOG, ("%zd %s free regions, %zd regions budget, %zd regions on surplus list", total_num_free_regions[kind], - kind_name[kind], + free_region_kind_name[kind], total_budget_in_region_units[kind], - num_regions_to_decommit[kind], - num_huge_region_units_to_consider[kind])); + surplus_regions[kind].get_num_free_regions())); // check if the free regions exceed the budget // if so, put the highest free regions on the decommit list - total_num_free_regions[kind] += num_regions_to_decommit[kind]; + total_num_free_regions[kind] += surplus_regions[kind].get_num_free_regions(); - ptrdiff_t balance = total_num_free_regions[kind] + num_huge_region_units_to_consider[kind] - total_budget_in_region_units[kind]; + ptrdiff_t balance_to_distribute = total_num_free_regions[kind] - total_budget_in_region_units[kind]; - if ( -#ifdef BACKGROUND_GC - background_running_p() || -#endif - (balance < 0)) + if (distribute_surplus_p(balance_to_distribute, kind, aggressive_decommit_large_p)) { - dprintf (REGIONS_LOG, ("distributing the %zd %s regions deficit", -balance, kind_name[kind])); - #ifdef MULTIPLE_HEAPS - // we may have a deficit or - if background GC is going on - a surplus. + // we may have a deficit or - for large regions or if background GC is going on - a surplus. // adjust the budget per heap accordingly - if (balance != 0) + if (balance_to_distribute != 0) { + dprintf (REGIONS_LOG, ("distributing the %zd %s regions deficit", -balance_to_distribute, free_region_kind_name[kind])); + ptrdiff_t curr_balance = 0; ptrdiff_t rem_balance = 0; for (int i = 0; i < n_heaps; i++) { - curr_balance += balance; + curr_balance += balance_to_distribute; ptrdiff_t adjustment_per_heap = curr_balance / n_heaps; curr_balance -= adjustment_per_heap * n_heaps; - ptrdiff_t new_budget = (ptrdiff_t)heap_budget_in_region_units[i][kind] + adjustment_per_heap; - ptrdiff_t min_budget = (kind == basic_free_region) ? (ptrdiff_t)min_heap_budget_in_region_units[i] : 0; + ptrdiff_t new_budget = (ptrdiff_t)heap_budget_in_region_units[kind][i] + adjustment_per_heap; + ptrdiff_t min_budget = (ptrdiff_t)min_heap_budget_in_region_units[kind][i]; dprintf (REGIONS_LOG, ("adjusting the budget for heap %d from %zd %s regions by %zd to %zd", i, - heap_budget_in_region_units[i][kind], - kind_name[kind], + heap_budget_in_region_units[kind][i], + free_region_kind_name[kind], adjustment_per_heap, max (min_budget, new_budget))); - heap_budget_in_region_units[i][kind] = max (min_budget, new_budget); - rem_balance += new_budget - heap_budget_in_region_units[i][kind]; + heap_budget_in_region_units[kind][i] = max (min_budget, new_budget); + rem_balance += new_budget - heap_budget_in_region_units[kind][i]; } assert (rem_balance <= 0); - dprintf (REGIONS_LOG, ("remaining balance: %zd %s regions", rem_balance, kind_name[kind])); + dprintf (REGIONS_LOG, ("remaining balance: %zd %s regions", rem_balance, free_region_kind_name[kind])); // if we have a left over deficit, distribute that to the heaps that still have more than the minimum while (rem_balance < 0) { for (int i = 0; i < n_heaps; i++) { - size_t min_budget = (kind == basic_free_region) ? min_heap_budget_in_region_units[i] : 0; - if (heap_budget_in_region_units[i][kind] > min_budget) + size_t min_budget = min_heap_budget_in_region_units[kind][i]; + if (heap_budget_in_region_units[kind][i] > min_budget) { dprintf (REGIONS_LOG, ("adjusting the budget for heap %d from %zd %s regions by %d to %zd", i, - heap_budget_in_region_units[i][kind], - kind_name[kind], + heap_budget_in_region_units[kind][i], + free_region_kind_name[kind], -1, - heap_budget_in_region_units[i][kind] - 1)); + heap_budget_in_region_units[kind][i] - 1)); - heap_budget_in_region_units[i][kind] -= 1; + heap_budget_in_region_units[kind][i] -= 1; rem_balance += 1; if (rem_balance == 0) break; @@ -13507,35 +13515,44 @@ void gc_heap::distribute_free_regions() } else { - num_regions_to_decommit[kind] = balance; + assert (balance_to_distribute >= 0); + + ptrdiff_t balance_to_decommit = balance_to_distribute; + if (kind == large_free_region) + { + // huge regions aren't part of balance_to_distribute because they are kept in a global list + // and therefore can't be distributed across heaps + balance_to_decommit += global_free_huge_regions.get_size_free_regions() / global_region_allocator.get_large_region_alignment(); + } + dprintf(REGIONS_LOG, ("distributing the %zd %s regions, removing %zd regions", total_budget_in_region_units[kind], - kind_name[kind], - num_regions_to_decommit[kind])); + free_region_kind_name[kind], + balance_to_decommit)); - if (num_regions_to_decommit[kind] > 0) + if (balance_to_decommit > 0) { // remember how many regions we had on the decommit list already due to aging size_t num_regions_to_decommit_before = global_regions_to_decommit[kind].get_num_free_regions(); // put the highest regions on the decommit list - global_region_allocator.move_highest_free_regions (num_regions_to_decommit[kind]*region_factor[kind], + global_region_allocator.move_highest_free_regions (balance_to_decommit * region_factor[kind], kind == basic_free_region, global_regions_to_decommit); dprintf (REGIONS_LOG, ("Moved %zd %s regions to decommit list", - global_regions_to_decommit[kind].get_num_free_regions(), kind_name[kind])); + global_regions_to_decommit[kind].get_num_free_regions(), free_region_kind_name[kind])); if (kind == basic_free_region) { - // we should now have num_regions_to_decommit[kind] regions more on the decommit list + // we should now have 'balance' regions more on the decommit list assert (global_regions_to_decommit[kind].get_num_free_regions() == - num_regions_to_decommit_before + (size_t)num_regions_to_decommit[kind]); + num_regions_to_decommit_before + (size_t)balance_to_decommit); } else { dprintf (REGIONS_LOG, ("Moved %zd %s regions to decommit list", - global_regions_to_decommit[huge_free_region].get_num_free_regions(), kind_name[huge_free_region])); + global_regions_to_decommit[huge_free_region].get_num_free_regions(), free_region_kind_name[huge_free_region])); // cannot assert we moved any regions because there may be a single huge region with more than we want to decommit } @@ -13543,7 +13560,7 @@ void gc_heap::distribute_free_regions() } } - for (int kind = basic_free_region; kind < kind_count; kind++) + for (int kind = basic_free_region; kind < count_distributed_free_region_kinds; kind++) { #ifdef MULTIPLE_HEAPS // now go through all the heaps and remove any free regions above the target count @@ -13551,16 +13568,16 @@ void gc_heap::distribute_free_regions() { gc_heap* hp = g_heaps[i]; - if (hp->free_regions[kind].get_num_free_regions() > heap_budget_in_region_units[i][kind]) + if (hp->free_regions[kind].get_num_free_regions() > heap_budget_in_region_units[kind][i]) { dprintf (REGIONS_LOG, ("removing %zd %s regions from heap %d with %zd regions, budget is %zd", - hp->free_regions[kind].get_num_free_regions() - heap_budget_in_region_units[i][kind], - kind_name[kind], + hp->free_regions[kind].get_num_free_regions() - heap_budget_in_region_units[kind][i], + free_region_kind_name[kind], i, hp->free_regions[kind].get_num_free_regions(), - heap_budget_in_region_units[i][kind])); + heap_budget_in_region_units[kind][i])); - remove_surplus_regions (&hp->free_regions[kind], &surplus_regions[kind], heap_budget_in_region_units[i][kind]); + trim_region_list (&surplus_regions[kind], &hp->free_regions[kind], heap_budget_in_region_units[kind][i]); } } // finally go through all the heaps and distribute any surplus regions to heaps having too few free regions @@ -13574,15 +13591,15 @@ void gc_heap::distribute_free_regions() #endif //MULTIPLE_HEAPS // second pass: fill all the regions having less than budget - if (hp->free_regions[kind].get_num_free_regions() < heap_budget_in_region_units[i][kind]) + if (hp->free_regions[kind].get_num_free_regions() < heap_budget_in_region_units[kind][i]) { - int64_t num_added_regions = add_regions (&hp->free_regions[kind], &surplus_regions[kind], heap_budget_in_region_units[i][kind]); + int64_t num_added_regions = grow_region_list (&hp->free_regions[kind], &surplus_regions[kind], heap_budget_in_region_units[kind][i]); dprintf (REGIONS_LOG, ("added %zd %s regions to heap %d - now has %zd, budget is %zd", (size_t)num_added_regions, - kind_name[kind], + free_region_kind_name[kind], i, hp->free_regions[kind].get_num_free_regions(), - heap_budget_in_region_units[i][kind])); + heap_budget_in_region_units[kind][i])); } hp->free_regions[kind].sort_by_committed_and_age(); } @@ -13594,7 +13611,221 @@ void gc_heap::distribute_free_regions() } } + decide_on_decommit_strategy(aggressive_decommit_large_p); +} + +void gc_heap::move_all_aged_regions(size_t total_num_free_regions[count_distributed_free_region_kinds], region_free_list aged_regions[count_free_region_kinds], bool joined_last_gc_before_oom) +{ + move_aged_regions(aged_regions, global_free_huge_regions, huge_free_region, joined_last_gc_before_oom); + #ifdef MULTIPLE_HEAPS + for (int i = 0; i < n_heaps; i++) + { + gc_heap* hp = g_heaps[i]; +#else //MULTIPLE_HEAPS + { + gc_heap* hp = pGenGCHeap; +#endif //MULTIPLE_HEAPS + + for (int kind = basic_free_region; kind < count_distributed_free_region_kinds; kind++) + { + move_aged_regions(aged_regions, hp->free_regions[kind], static_cast(kind), joined_last_gc_before_oom); + total_num_free_regions[kind] += hp->free_regions[kind].get_num_free_regions(); + } + } +} + +void gc_heap::move_aged_regions(region_free_list dest[count_free_region_kinds], region_free_list& src, free_region_kind kind, bool joined_last_gc_before_oom) +{ + heap_segment* next_region = nullptr; + for (heap_segment* region = src.get_first_free_region(); region != nullptr; region = next_region) + { + next_region = heap_segment_next (region); + // when we are about to get OOM, we'd like to discount the free regions that just have the initial page commit as they are not useful + if (aged_region_p(region, kind) || + ((get_region_committed_size (region) == GC_PAGE_SIZE) && joined_last_gc_before_oom)) + { + region_free_list::unlink_region (region); + region_free_list::add_region (region, dest); + } + } +} + +bool gc_heap::aged_region_p(heap_segment* region, free_region_kind kind) +{ +#ifndef MULTIPLE_HEAPS + const int n_heaps = 1; +#endif + + int age_in_free_to_decommit; + switch (kind) + { + case basic_free_region: + age_in_free_to_decommit = max(AGE_IN_FREE_TO_DECOMMIT_BASIC, n_heaps); + break; + case large_free_region: + age_in_free_to_decommit = AGE_IN_FREE_TO_DECOMMIT_LARGE; + break; + case huge_free_region: + age_in_free_to_decommit = AGE_IN_FREE_TO_DECOMMIT_HUGE; + break; + default: + assert(!"unexpected kind"); + age_in_free_to_decommit = 0; + } + + age_in_free_to_decommit = min (age_in_free_to_decommit, MAX_AGE_IN_FREE); + return (heap_segment_age_in_free (region) >= age_in_free_to_decommit); +} + +void gc_heap::move_regions_to_decommit(region_free_list regions[count_free_region_kinds]) +{ + for (int kind = basic_free_region; kind < count_free_region_kinds; kind++) + { + dprintf (1, ("moved %2zd %s regions (%8zd) to decommit based on time", + regions[kind].get_num_free_regions(), free_region_kind_name[kind], regions[kind].get_size_committed_in_free())); + } + for (int kind = basic_free_region; kind < count_free_region_kinds; kind++) + { + heap_segment* next_region = nullptr; + for (heap_segment* region = regions[kind].get_first_free_region(); region != nullptr; region = next_region) + { + next_region = heap_segment_next (region); + dprintf (REGIONS_LOG, ("region %p age %2d, decommit", + heap_segment_mem (region), heap_segment_age_in_free (region))); + region_free_list::unlink_region (region); + region_free_list::add_region (region, global_regions_to_decommit); + } + } + for (int kind = basic_free_region; kind < count_free_region_kinds; kind++) + { + assert(regions[kind].get_num_free_regions() == 0); + } +} + +size_t gc_heap::compute_basic_region_budgets( + size_t heap_basic_budget_in_region_units[MAX_SUPPORTED_CPUS], + size_t min_heap_basic_budget_in_region_units[MAX_SUPPORTED_CPUS], + size_t total_basic_free_regions) +{ + const size_t region_size = global_region_allocator.get_region_alignment(); + size_t total_budget_in_region_units = 0; + + for (int gen = soh_gen0; gen <= max_generation; gen++) + { + if (total_budget_in_region_units >= total_basic_free_regions) + { + // don't accumulate budget from higher soh generations if we cannot cover lower ones + dprintf (REGIONS_LOG, ("out of free regions - skipping gen %d budget = %zd >= avail %zd", + gen, + total_budget_in_region_units, + total_basic_free_regions)); + break; + } + +#ifdef MULTIPLE_HEAPS + for (int i = 0; i < n_heaps; i++) + { + gc_heap* hp = g_heaps[i]; +#else //MULTIPLE_HEAPS + { + gc_heap* hp = pGenGCHeap; + // just to reduce the number of #ifdefs in the code below + const int i = 0; +#endif //MULTIPLE_HEAPS + ptrdiff_t budget_gen = max (hp->estimate_gen_growth (gen), (ptrdiff_t)0); + size_t budget_gen_in_region_units = (budget_gen + (region_size - 1)) / region_size; + dprintf (REGIONS_LOG, ("h%2d gen %d has an estimated growth of %zd bytes (%zd regions)", i, gen, budget_gen, budget_gen_in_region_units)); + + // preserve the budget for the previous generation - we should not go below that + min_heap_basic_budget_in_region_units[i] = heap_basic_budget_in_region_units[i]; + + heap_basic_budget_in_region_units[i] += budget_gen_in_region_units; + total_budget_in_region_units += budget_gen_in_region_units; + } + } + + return total_budget_in_region_units; +} + +bool gc_heap::near_heap_hard_limit_p() +{ + if (heap_hard_limit) + { + int current_percent_heap_hard_limit = (int)((float)current_total_committed * 100.0 / (float)heap_hard_limit); + dprintf (REGIONS_LOG, ("committed %zd is %d%% of limit %zd", + current_total_committed, current_percent_heap_hard_limit, heap_hard_limit)); + if (current_percent_heap_hard_limit >= 90) + { + return true; + } + } + + return false; +} + +bool gc_heap::distribute_surplus_p(ptrdiff_t balance, int kind, bool aggressive_decommit_large_p) +{ + if (balance < 0) + { + return true; + } + + if (kind == basic_free_region) + { +#ifdef BACKGROUND_GC + // This is detecting FGCs that run during BGCs. It is not detecting ephemeral GCs that + // (possibly) run right before a BGC as background_running_p() is not yet true at that point. + return (background_running_p() && (settings.condemned_generation != max_generation)); +#else + return false; +#endif + } + + return !aggressive_decommit_large_p; +} + +void gc_heap::decide_on_decommit_strategy(bool joined_last_gc_before_oom) +{ +#ifdef MULTIPLE_HEAPS + if (joined_last_gc_before_oom || g_low_memory_status) + { + dprintf (REGIONS_LOG, ("low memory - decommitting everything (last_gc_before_oom=%d, g_low_memory_status=%d)", joined_last_gc_before_oom, g_low_memory_status)); + + while (decommit_step(DECOMMIT_TIME_STEP_MILLISECONDS)) + { + } + return; + } + + ptrdiff_t size_to_decommit_for_heap_hard_limit = 0; + if (heap_hard_limit) + { + size_to_decommit_for_heap_hard_limit = (ptrdiff_t)(current_total_committed - (heap_hard_limit * (MAX_ALLOWED_MEM_LOAD / 100.0f))); + size_to_decommit_for_heap_hard_limit = max(size_to_decommit_for_heap_hard_limit, (ptrdiff_t)0); + } + + // For the various high memory load situations, we're not using the process size at all. In + // particular, if we had a large process and smaller processes running in the same container, + // then we will treat them the same if the container reaches reaches high_memory_load_th. In + // the future, we could consider additional complexity to try to reclaim more memory from + // larger processes than smaller ones. + ptrdiff_t size_to_decommit_for_physical = 0; + if (settings.entry_memory_load >= high_memory_load_th) + { + size_t entry_used_physical_mem = total_physical_mem - entry_available_physical_mem; + size_t goal_used_physical_mem = (size_t)(((almost_high_memory_load_th) / 100.0) * total_physical_mem); + size_to_decommit_for_physical = entry_used_physical_mem - goal_used_physical_mem; + } + + size_t size_to_decommit = max(size_to_decommit_for_heap_hard_limit, size_to_decommit_for_physical); + if (size_to_decommit > 0) + { + dprintf (REGIONS_LOG, ("low memory - decommitting %zd (for heap_hard_limit: %zd, for physical: %zd)", size_to_decommit, size_to_decommit_for_heap_hard_limit, size_to_decommit_for_physical)); + + decommit_step(size_to_decommit / DECOMMIT_SIZE_PER_MILLISECOND); + } + for (int kind = basic_free_region; kind < count_free_region_kinds; kind++) { if (global_regions_to_decommit[kind].get_num_free_regions() != 0) @@ -13616,7 +13847,7 @@ void gc_heap::distribute_free_regions() if (ephemeral_elapsed >= DECOMMIT_TIME_STEP_MILLISECONDS) { gc_last_ephemeral_decommit_time = dd_time_clock (dd0); - size_t decommit_step_milliseconds = min (ephemeral_elapsed, (10*1000)); + size_t decommit_step_milliseconds = min (ephemeral_elapsed, (size_t)(10 * 1000)); decommit_step (decommit_step_milliseconds); } @@ -13629,8 +13860,8 @@ void gc_heap::distribute_free_regions() } } #endif //MULTIPLE_HEAPS -#endif //USE_REGIONS } +#endif //USE_REGIONS #ifdef WRITE_WATCH uint8_t* g_addresses [array_size+2]; // to get around the bug in GetWriteWatch @@ -22812,22 +23043,12 @@ void gc_heap::gc1() for (int i = 0; i < gc_heap::n_heaps; i++) { g_heaps[i]->descr_generations ("END"); -#ifdef USE_REGIONS - if (settings.condemned_generation == max_generation) - { - // age and print all kinds of free regions - region_free_list::age_free_regions (g_heaps[i]->free_regions); - region_free_list::print (g_heaps[i]->free_regions, i, "END"); - } - else - { - // age and print only basic free regions - g_heaps[i]->free_regions[basic_free_region].age_free_regions(); - g_heaps[i]->free_regions[basic_free_region].print (i, "END"); - } -#endif //USE_REGIONS } +#ifdef USE_REGIONS + age_free_regions ("END"); +#endif //USE_REGIONS + fire_pevents(); update_end_ngc_time(); pm_full_gc_init_or_clear(); @@ -22861,18 +23082,7 @@ void gc_heap::gc1() compute_gc_and_ephemeral_range (settings.condemned_generation, true); stomp_write_barrier_ephemeral (ephemeral_low, ephemeral_high, map_region_to_generation_skewed, (uint8_t)min_segment_size_shr); - if (settings.condemned_generation == max_generation) - { - // age and print all kinds of free regions - region_free_list::age_free_regions(free_regions); - region_free_list::print(free_regions, 0, "END"); - } - else - { - // age and print only basic free regions - free_regions[basic_free_region].age_free_regions(); - free_regions[basic_free_region].print (0, "END"); - } + age_free_regions ("END"); #endif //USE_REGIONS update_end_ngc_time(); @@ -37913,6 +38123,16 @@ void gc_heap::background_mark_phase () if (bgc_t_join.joined()) #endif //MULTIPLE_HEAPS { +#ifdef USE_REGIONS + // There's no need to distribute a second time if we just did an ephemeral GC, and we don't want to + // age the free regions twice. + if (!do_ephemeral_gc_p) + { + distribute_free_regions (); + age_free_regions ("BGC"); + } +#endif //USE_REGIONS + #ifdef FEATURE_USE_SOFTWARE_WRITE_WATCH_FOR_GC_HEAP // Resetting write watch for software write watch is pretty fast, much faster than for hardware write watch. Reset // can be done while the runtime is suspended or after the runtime is restarted, the preference was to reset while @@ -52653,8 +52873,8 @@ bool gc_heap::compute_memory_settings(bool is_initialization, uint32_t& nhp, uin uint32_t highmem_th_from_config = (uint32_t)GCConfig::GetGCHighMemPercent(); if (highmem_th_from_config) { - high_memory_load_th = min (99, highmem_th_from_config); - v_high_memory_load_th = min (99, (highmem_th_from_config + 7)); + high_memory_load_th = min (99u, highmem_th_from_config); + v_high_memory_load_th = min (99u, (high_memory_load_th + 7)); #ifdef FEATURE_EVENT_TRACE high_mem_percent_from_config = highmem_th_from_config; #endif //FEATURE_EVENT_TRACE @@ -52679,6 +52899,7 @@ bool gc_heap::compute_memory_settings(bool is_initialization, uint32_t& nhp, uin } m_high_memory_load_th = min ((high_memory_load_th + 5), v_high_memory_load_th); + almost_high_memory_load_th = (high_memory_load_th > 5) ? (high_memory_load_th - 5) : 1; // avoid underflow of high_memory_load_th - 5 return true; } diff --git a/src/coreclr/gc/gcpriv.h b/src/coreclr/gc/gcpriv.h index cce6c5ee28adf0..317264023a81a0 100644 --- a/src/coreclr/gc/gcpriv.h +++ b/src/coreclr/gc/gcpriv.h @@ -1403,14 +1403,19 @@ enum interesting_data_point #ifdef USE_REGIONS enum free_region_kind { - basic_free_region, - large_free_region, - huge_free_region, - count_free_region_kinds, + basic_free_region = 0, + large_free_region = 1, + count_distributed_free_region_kinds = 2, + huge_free_region = 2, + count_free_region_kinds = 3, }; static_assert(count_free_region_kinds == FREE_REGION_KINDS, "Keep count_free_region_kinds in sync with FREE_REGION_KINDS, changing this is not a version breaking change."); +#ifdef TRACE_GC +static const char * const free_region_kind_name[count_free_region_kinds] = { "basic", "large", "huge"}; +#endif // TRACE_GC + class region_free_list { size_t num_free_regions; @@ -1717,6 +1722,19 @@ class gc_heap PER_HEAP_ISOLATED_METHOD void verify_region_to_generation_map(); PER_HEAP_ISOLATED_METHOD void compute_gc_and_ephemeral_range (int condemned_gen_number, bool end_of_gc_p); + + PER_HEAP_ISOLATED_METHOD void distribute_free_regions(); + PER_HEAP_ISOLATED_METHOD void move_all_aged_regions(size_t total_num_free_regions[count_distributed_free_region_kinds], region_free_list aged_regions[count_free_region_kinds], bool joined_last_gc_before_oom); + PER_HEAP_ISOLATED_METHOD void move_aged_regions(region_free_list dest[count_free_region_kinds], region_free_list& src, free_region_kind kind, bool joined_last_gc_before_oom); + PER_HEAP_ISOLATED_METHOD bool aged_region_p(heap_segment* region, free_region_kind kind); + PER_HEAP_ISOLATED_METHOD void move_regions_to_decommit(region_free_list oregions[count_free_region_kinds]); + PER_HEAP_ISOLATED_METHOD size_t compute_basic_region_budgets(size_t heap_basic_budget_in_region_units[MAX_SUPPORTED_CPUS], size_t min_heap_basic_budget_in_region_units[MAX_SUPPORTED_CPUS], size_t total_basic_free_regions); + PER_HEAP_ISOLATED_METHOD bool near_heap_hard_limit_p(); + PER_HEAP_ISOLATED_METHOD bool distribute_surplus_p(ptrdiff_t balance, int kind, bool aggressive_decommit_large_p); + PER_HEAP_ISOLATED_METHOD void decide_on_decommit_strategy(bool joined_last_gc_before_oom); + + PER_HEAP_ISOLATED_METHOD void age_free_regions (const char* msg); + #ifdef STRESS_REGIONS PER_HEAP_METHOD void pin_by_gc (uint8_t* object); #endif //STRESS_REGIONS @@ -2420,7 +2438,6 @@ class gc_heap PER_HEAP_METHOD void rearrange_heap_segments(BOOL compacting); #endif //!USE_REGIONS PER_HEAP_METHOD void delay_free_segments(); - PER_HEAP_ISOLATED_METHOD void distribute_free_regions(); #ifdef BACKGROUND_GC PER_HEAP_ISOLATED_METHOD void reset_write_watch_for_gc_heap(void* base_address, size_t region_size); PER_HEAP_ISOLATED_METHOD void get_write_watch_for_gc_heap(bool reset, void *base_address, size_t region_size, void** dirty_pages, uintptr_t* dirty_page_count_ref, bool is_runtime_suspended); @@ -4352,6 +4369,7 @@ class gc_heap PER_HEAP_ISOLATED_FIELD_INIT_ONLY uint32_t high_memory_load_th; PER_HEAP_ISOLATED_FIELD_INIT_ONLY uint32_t m_high_memory_load_th; PER_HEAP_ISOLATED_FIELD_INIT_ONLY uint32_t v_high_memory_load_th; + PER_HEAP_ISOLATED_FIELD_INIT_ONLY uint32_t almost_high_memory_load_th; PER_HEAP_ISOLATED_FIELD_INIT_ONLY bool is_restricted_physical_mem; PER_HEAP_ISOLATED_FIELD_INIT_ONLY uint64_t mem_one_percent; PER_HEAP_ISOLATED_FIELD_INIT_ONLY uint64_t total_physical_mem; @@ -5265,7 +5283,9 @@ class heap_segment // GCs. We stop at 99. It's initialized to 0 when a region is added to // the region's free list. #define MAX_AGE_IN_FREE 99 - #define AGE_IN_FREE_TO_DECOMMIT 20 + #define AGE_IN_FREE_TO_DECOMMIT_BASIC 20 + #define AGE_IN_FREE_TO_DECOMMIT_LARGE 5 + #define AGE_IN_FREE_TO_DECOMMIT_HUGE 2 int age_in_free; // This is currently only used by regions that are swept in plan - // we then thread this list onto the generation's free list. From 337b4068f2c4717a4b0b91d1c6971d5e2c89ef0b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marie=20P=C3=ADchov=C3=A1?= <11718369+ManickaP@users.noreply.github.com> Date: Tue, 9 Sep 2025 08:31:41 +0200 Subject: [PATCH 05/20] [release/8.0-staging][HTTP] Stress fix for docker compose (#119454) * [HTTP] Stress fix for docker compose Backport of #119274 to release/10.0 /cc @ManickaP ## Customer Impact - [ ] Customer reported - [x] Found internally Wind down docker compose between individual runs in HTTP stress. ## Regression - [x] Yes - [ ] No Infra update. ## Testing CI stress runs. ## Risk Low. Test only change. * Add docker-compose down command before up --- eng/pipelines/libraries/stress/http.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/eng/pipelines/libraries/stress/http.yml b/eng/pipelines/libraries/stress/http.yml index 9b77085862e6c9..0ffa778a44e857 100644 --- a/eng/pipelines/libraries/stress/http.yml +++ b/eng/pipelines/libraries/stress/http.yml @@ -73,6 +73,7 @@ extends: export SERVER_DUMPS_SHARE="$(Build.ArtifactStagingDirectory)/dumps/server/2.0" export HTTPSTRESS_CLIENT_ARGS="$HTTPSTRESS_CLIENT_ARGS -http 2.0" export HTTPSTRESS_SERVER_ARGS="$HTTPSTRESS_SERVER_ARGS -http 2.0" + docker-compose down docker-compose up --abort-on-container-exit --no-color displayName: Run HttpStress - HTTP 2.0 condition: and(eq(variables['buildRuntime.succeeded'], 'true'), eq(variables['buildStress.succeeded'], 'true')) @@ -83,6 +84,7 @@ extends: export SERVER_DUMPS_SHARE="$(Build.ArtifactStagingDirectory)/dumps/server/1.1" export HTTPSTRESS_CLIENT_ARGS="$HTTPSTRESS_CLIENT_ARGS -http 1.1" export HTTPSTRESS_SERVER_ARGS="$HTTPSTRESS_SERVER_ARGS -http 1.1" + docker-compose down docker-compose up --abort-on-container-exit --no-color displayName: Run HttpStress - HTTP 1.1 condition: and(eq(variables['buildRuntime.succeeded'], 'true'), eq(variables['buildStress.succeeded'], 'true')) From 4c0faa136ee35b4444a56643dc2ddf51591835f9 Mon Sep 17 00:00:00 2001 From: "dotnet-maestro[bot]" <42748379+dotnet-maestro[bot]@users.noreply.github.com> Date: Thu, 11 Sep 2025 15:58:54 +0200 Subject: [PATCH 06/20] Update dependencies from https://github.com/dotnet/hotreload-utils build 20250811.2 (#118591) Microsoft.DotNet.HotReload.Utils.Generator.BuildTool From Version 8.0.0-alpha.0.25378.2 -> To Version 8.0.0-alpha.0.25411.2 Co-authored-by: dotnet-maestro[bot] --- NuGet.config | 3 --- eng/Version.Details.xml | 4 ++-- eng/Versions.props | 2 +- 3 files changed, 3 insertions(+), 6 deletions(-) diff --git a/NuGet.config b/NuGet.config index 02506c2fe5754d..f6e25f4daf50d1 100644 --- a/NuGet.config +++ b/NuGet.config @@ -9,9 +9,6 @@ - - - diff --git a/eng/Version.Details.xml b/eng/Version.Details.xml index c769a1f4836efc..f5393c1f5b3b21 100644 --- a/eng/Version.Details.xml +++ b/eng/Version.Details.xml @@ -354,9 +354,9 @@ https://dev.azure.com/dnceng/internal/_git/dotnet-optimization 67613417f5e1af250e6ddfba79f8f2885d8e90fb - + https://github.com/dotnet/hotreload-utils - 0dcc0d22fc7b9c4eb8c7ae571ae4213324b006a6 + 4583778b38f71bc05962b9da38dd1e9ee17525e7 https://github.com/dotnet/runtime-assets diff --git a/eng/Versions.props b/eng/Versions.props index 1c1e1719bbf3f6..686cf801af7ea0 100644 --- a/eng/Versions.props +++ b/eng/Versions.props @@ -198,7 +198,7 @@ 8.0.0-prerelease.25270.1 8.0.0-prerelease.25270.1 8.0.0-prerelease.25270.1 - 8.0.0-alpha.0.25378.2 + 8.0.0-alpha.0.25411.2 2.4.2 1.0.0 2.4.5 From 710042ee2b7887666faff7bf3a36c10a5781fdc4 Mon Sep 17 00:00:00 2001 From: "dotnet-maestro[bot]" <42748379+dotnet-maestro[bot]@users.noreply.github.com> Date: Thu, 11 Sep 2025 16:16:21 +0200 Subject: [PATCH 07/20] Update dependencies from https://github.com/dotnet/runtime-assets build 20250814.3 (#118757) Microsoft.DotNet.CilStrip.Sources , System.ComponentModel.TypeConverter.TestData , System.Data.Common.TestData , System.Drawing.Common.TestData , System.Formats.Tar.TestData , System.IO.Compression.TestData , System.IO.Packaging.TestData , System.Net.TestData , System.Private.Runtime.UnicodeData , System.Runtime.Numerics.TestData , System.Runtime.TimeZoneData , System.Security.Cryptography.X509Certificates.TestData , System.Text.RegularExpressions.TestData , System.Windows.Extensions.TestData From Version 8.0.0-beta.25311.1 -> To Version 8.0.0-beta.25414.3 Co-authored-by: dotnet-maestro[bot] --- eng/Version.Details.xml | 56 ++++++++++++++++++++--------------------- eng/Versions.props | 28 ++++++++++----------- 2 files changed, 42 insertions(+), 42 deletions(-) diff --git a/eng/Version.Details.xml b/eng/Version.Details.xml index f5393c1f5b3b21..57eb8ca622e8ec 100644 --- a/eng/Version.Details.xml +++ b/eng/Version.Details.xml @@ -185,57 +185,57 @@ https://github.com/dotnet/arcade 2ce3f8c7b2614c2b19985b669ffcd934bc39ffd1 - + https://github.com/dotnet/runtime-assets - 1ef844c35b4db6c120722d0abcc64dba0d3d0685 + e8f3528a061b4f6b944f13ad87382d7964b46c7e - + https://github.com/dotnet/runtime-assets - 1ef844c35b4db6c120722d0abcc64dba0d3d0685 + e8f3528a061b4f6b944f13ad87382d7964b46c7e - + https://github.com/dotnet/runtime-assets - 1ef844c35b4db6c120722d0abcc64dba0d3d0685 + e8f3528a061b4f6b944f13ad87382d7964b46c7e - + https://github.com/dotnet/runtime-assets - 1ef844c35b4db6c120722d0abcc64dba0d3d0685 + e8f3528a061b4f6b944f13ad87382d7964b46c7e - + https://github.com/dotnet/runtime-assets - 1ef844c35b4db6c120722d0abcc64dba0d3d0685 + e8f3528a061b4f6b944f13ad87382d7964b46c7e - + https://github.com/dotnet/runtime-assets - 1ef844c35b4db6c120722d0abcc64dba0d3d0685 + e8f3528a061b4f6b944f13ad87382d7964b46c7e - + https://github.com/dotnet/runtime-assets - 1ef844c35b4db6c120722d0abcc64dba0d3d0685 + e8f3528a061b4f6b944f13ad87382d7964b46c7e - + https://github.com/dotnet/runtime-assets - 1ef844c35b4db6c120722d0abcc64dba0d3d0685 + e8f3528a061b4f6b944f13ad87382d7964b46c7e - + https://github.com/dotnet/runtime-assets - 1ef844c35b4db6c120722d0abcc64dba0d3d0685 + e8f3528a061b4f6b944f13ad87382d7964b46c7e - + https://github.com/dotnet/runtime-assets - 1ef844c35b4db6c120722d0abcc64dba0d3d0685 + e8f3528a061b4f6b944f13ad87382d7964b46c7e - + https://github.com/dotnet/runtime-assets - 1ef844c35b4db6c120722d0abcc64dba0d3d0685 + e8f3528a061b4f6b944f13ad87382d7964b46c7e - + https://github.com/dotnet/runtime-assets - 1ef844c35b4db6c120722d0abcc64dba0d3d0685 + e8f3528a061b4f6b944f13ad87382d7964b46c7e - + https://github.com/dotnet/runtime-assets - 1ef844c35b4db6c120722d0abcc64dba0d3d0685 + e8f3528a061b4f6b944f13ad87382d7964b46c7e https://github.com/dotnet/llvm-project @@ -358,9 +358,9 @@ https://github.com/dotnet/hotreload-utils 4583778b38f71bc05962b9da38dd1e9ee17525e7 - + https://github.com/dotnet/runtime-assets - 1ef844c35b4db6c120722d0abcc64dba0d3d0685 + e8f3528a061b4f6b944f13ad87382d7964b46c7e https://github.com/dotnet/roslyn diff --git a/eng/Versions.props b/eng/Versions.props index 686cf801af7ea0..9401207d99e00e 100644 --- a/eng/Versions.props +++ b/eng/Versions.props @@ -153,20 +153,20 @@ 4.5.0 8.0.0-rc.1.23406.6 - 8.0.0-beta.25311.1 - 8.0.0-beta.25311.1 - 8.0.0-beta.25311.1 - 8.0.0-beta.25311.1 - 8.0.0-beta.25311.1 - 8.0.0-beta.25311.1 - 8.0.0-beta.25311.1 - 8.0.0-beta.25311.1 - 8.0.0-beta.25311.1 - 8.0.0-beta.25311.1 - 8.0.0-beta.25311.1 - 8.0.0-beta.25311.1 - 8.0.0-beta.25311.1 - 8.0.0-beta.25311.1 + 8.0.0-beta.25414.3 + 8.0.0-beta.25414.3 + 8.0.0-beta.25414.3 + 8.0.0-beta.25414.3 + 8.0.0-beta.25414.3 + 8.0.0-beta.25414.3 + 8.0.0-beta.25414.3 + 8.0.0-beta.25414.3 + 8.0.0-beta.25414.3 + 8.0.0-beta.25414.3 + 8.0.0-beta.25414.3 + 8.0.0-beta.25414.3 + 8.0.0-beta.25414.3 + 8.0.0-beta.25414.3 1.0.0-prerelease.23566.3 1.0.0-prerelease.23566.3 From e599df301bec2cf38d41f8c859072f9359ab6563 Mon Sep 17 00:00:00 2001 From: "dotnet-maestro[bot]" <42748379+dotnet-maestro[bot]@users.noreply.github.com> Date: Fri, 12 Sep 2025 08:55:10 -0700 Subject: [PATCH 08/20] [release/8.0-staging] Update dependencies from dotnet/icu (#118537) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Update dependencies from https://github.com/dotnet/icu build 20250611.1 Microsoft.NETCore.Runtime.ICU.Transport From Version 8.0.0-rtm.23523.2 -> To Version 8.0.0-rtm.25311.1 * Update dependencies from https://github.com/dotnet/icu build 20250808.1 Microsoft.NETCore.Runtime.ICU.Transport From Version 8.0.0-rtm.23523.2 -> To Version 8.0.0-rtm.25408.1 --------- Co-authored-by: dotnet-maestro[bot] Co-authored-by: Alexander Köplinger --- eng/Version.Details.xml | 4 ++-- eng/Versions.props | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/eng/Version.Details.xml b/eng/Version.Details.xml index 57eb8ca622e8ec..05fcdaeee37e7c 100644 --- a/eng/Version.Details.xml +++ b/eng/Version.Details.xml @@ -1,8 +1,8 @@ - + https://github.com/dotnet/icu - e76010c828e5913da4b6a5332f4d8b14f660dd88 + 9392a78454c1978e7b19c50d85e85c57550399e1 https://github.com/dotnet/msquic diff --git a/eng/Versions.props b/eng/Versions.props index 9401207d99e00e..55bee915e2bc9d 100644 --- a/eng/Versions.props +++ b/eng/Versions.props @@ -229,7 +229,7 @@ 8.0.0-rc.1.23406.6 - 8.0.0-rtm.23523.2 + 8.0.0-rtm.25408.1 2.4.8 8.0.0-alpha.1.23527.1 From 06f8bc8486a2b5f2bd822049da4c3d35c6f61d2c Mon Sep 17 00:00:00 2001 From: "dotnet-maestro[bot]" <42748379+dotnet-maestro[bot]@users.noreply.github.com> Date: Sat, 13 Sep 2025 06:22:53 -0700 Subject: [PATCH 09/20] Update dependencies from https://github.com/dotnet/source-build-reference-packages build 20250828.6 (#119668) On relative base path root Microsoft.SourceBuild.Intermediate.source-build-reference-packages From Version 8.0.0-alpha.1.25269.2 -> To Version 8.0.0-alpha.1.25428.6 Co-authored-by: dotnet-maestro[bot] --- eng/Version.Details.xml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/eng/Version.Details.xml b/eng/Version.Details.xml index 05fcdaeee37e7c..9a2d9055c2e693 100644 --- a/eng/Version.Details.xml +++ b/eng/Version.Details.xml @@ -99,9 +99,9 @@ 6fd14a46f7bc405f4ba53b1e691c76fdc6324b0b - + https://github.com/dotnet/source-build-reference-packages - cee2d057118e3ad3c58a72a23271ad88b87d4d4d + 0b4984f8ee945e02a39ef0f72dc9f7ceab65c14f From 6ac31acadacb2572fd1b32563904df8f05bc6d37 Mon Sep 17 00:00:00 2001 From: "dotnet-maestro[bot]" <42748379+dotnet-maestro[bot]@users.noreply.github.com> Date: Sat, 13 Sep 2025 10:49:21 -0700 Subject: [PATCH 10/20] [release/8.0-staging] Update dependencies from dotnet/xharness (#118535) * Update dependencies from https://github.com/dotnet/xharness build 20250725.2 Microsoft.DotNet.XHarness.CLI , Microsoft.DotNet.XHarness.TestRunners.Common , Microsoft.DotNet.XHarness.TestRunners.Xunit From Version 8.0.0-prerelease.25270.1 -> To Version 8.0.0-prerelease.25375.2 * Update dependencies from https://github.com/dotnet/xharness build 20250827.2 On relative base path root Microsoft.DotNet.XHarness.CLI , Microsoft.DotNet.XHarness.TestRunners.Common , Microsoft.DotNet.XHarness.TestRunners.Xunit From Version 8.0.0-prerelease.25270.1 -> To Version 8.0.0-prerelease.25427.2 --------- Co-authored-by: dotnet-maestro[bot] Co-authored-by: Tanner Gooding --- .config/dotnet-tools.json | 2 +- eng/Version.Details.xml | 12 ++++++------ eng/Versions.props | 6 +++--- 3 files changed, 10 insertions(+), 10 deletions(-) diff --git a/.config/dotnet-tools.json b/.config/dotnet-tools.json index d38d5d68f88dab..601c4fd768e837 100644 --- a/.config/dotnet-tools.json +++ b/.config/dotnet-tools.json @@ -15,7 +15,7 @@ ] }, "microsoft.dotnet.xharness.cli": { - "version": "8.0.0-prerelease.25270.1", + "version": "8.0.0-prerelease.25427.2", "commands": [ "xharness" ] diff --git a/eng/Version.Details.xml b/eng/Version.Details.xml index 9a2d9055c2e693..82ad0b67a72b5d 100644 --- a/eng/Version.Details.xml +++ b/eng/Version.Details.xml @@ -322,17 +322,17 @@ https://github.com/dotnet/runtime edbd5c769a19798b6955050baccf99e6797d3208 - + https://github.com/dotnet/xharness - c3f3d30ca6a7630b38e061043d4489559c06d4cc + fc7f1ca0ff5b949ba7b7500e5aa9a01e4a43d894 - + https://github.com/dotnet/xharness - c3f3d30ca6a7630b38e061043d4489559c06d4cc + fc7f1ca0ff5b949ba7b7500e5aa9a01e4a43d894 - + https://github.com/dotnet/xharness - c3f3d30ca6a7630b38e061043d4489559c06d4cc + fc7f1ca0ff5b949ba7b7500e5aa9a01e4a43d894 https://github.com/dotnet/arcade diff --git a/eng/Versions.props b/eng/Versions.props index 55bee915e2bc9d..173ae1bf967fae 100644 --- a/eng/Versions.props +++ b/eng/Versions.props @@ -195,9 +195,9 @@ 1.1.0 17.4.0-preview-20220707-01 - 8.0.0-prerelease.25270.1 - 8.0.0-prerelease.25270.1 - 8.0.0-prerelease.25270.1 + 8.0.0-prerelease.25427.2 + 8.0.0-prerelease.25427.2 + 8.0.0-prerelease.25427.2 8.0.0-alpha.0.25411.2 2.4.2 1.0.0 From f0dfc2ffbc3243066804b9e87b5fd6a84acc9433 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Sat, 13 Sep 2025 10:51:07 -0700 Subject: [PATCH 11/20] [automated] Merge branch 'release/8.0' => 'release/8.0-staging' (#118491) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Update dependencies from https://github.com/dotnet/emsdk build 20250721.2 Microsoft.SourceBuild.Intermediate.emsdk , Microsoft.NET.Workload.Emscripten.Current.Manifest-8.0.100 From Version 8.0.19-servicing.25353.2 -> To Version 8.0.19-servicing.25371.2 * Update dependencies from https://github.com/dotnet/emsdk build 20250804.3 Microsoft.SourceBuild.Intermediate.emsdk , Microsoft.NET.Workload.Emscripten.Current.Manifest-8.0.100 From Version 8.0.19-servicing.25353.2 -> To Version 8.0.19-servicing.25404.3 * Update dependencies from https://github.com/dotnet/emsdk build 20250804.5 Microsoft.SourceBuild.Intermediate.emsdk , Microsoft.NET.Workload.Emscripten.Current.Manifest-8.0.100 From Version 8.0.19-servicing.25353.2 -> To Version 8.0.20-servicing.25404.5 * Update branding to 8.0.20 (#118348) * Merging internal commits for release/8.0 (#118452) Co-authored-by: Mirroring * Update dependencies from https://github.com/dotnet/emsdk build 20250811.2 Microsoft.SourceBuild.Intermediate.emsdk , Microsoft.NET.Workload.Emscripten.Current.Manifest-8.0.100 From Version 8.0.19-servicing.25353.2 -> To Version 8.0.20-servicing.25411.2 * Update dependencies from https://github.com/dotnet/emsdk build 20250811.4 Microsoft.SourceBuild.Intermediate.emsdk , Microsoft.NET.Workload.Emscripten.Current.Manifest-8.0.100 From Version 8.0.19-servicing.25353.2 -> To Version 8.0.20-servicing.25411.4 Dependency coherency updates runtime.linux-arm64.Microsoft.NETCore.Runtime.ObjWriter,runtime.linux-x64.Microsoft.NETCore.Runtime.ObjWriter,runtime.linux-musl-arm64.Microsoft.NETCore.Runtime.ObjWriter,runtime.linux-musl-x64.Microsoft.NETCore.Runtime.ObjWriter,runtime.win-arm64.Microsoft.NETCore.Runtime.ObjWriter,runtime.win-x64.Microsoft.NETCore.Runtime.ObjWriter,runtime.osx-arm64.Microsoft.NETCore.Runtime.ObjWriter,runtime.osx-x64.Microsoft.NETCore.Runtime.ObjWriter,runtime.linux-arm64.Microsoft.NETCore.Runtime.JIT.Tools,runtime.linux-x64.Microsoft.NETCore.Runtime.JIT.Tools,runtime.linux-musl-arm64.Microsoft.NETCore.Runtime.JIT.Tools,runtime.linux-musl-x64.Microsoft.NETCore.Runtime.JIT.Tools,runtime.win-arm64.Microsoft.NETCore.Runtime.JIT.Tools,runtime.win-x64.Microsoft.NETCore.Runtime.JIT.Tools,runtime.osx-arm64.Microsoft.NETCore.Runtime.JIT.Tools,runtime.osx-x64.Microsoft.NETCore.Runtime.JIT.Tools,runtime.linux-arm64.Microsoft.NETCore.Runtime.Mono.LLVM.Sdk,runtime.linux-arm64.Microsoft.NETCore.Runtime.Mono.LLVM.Tools,runtime.linux-musl-arm64.Microsoft.NETCore.Runtime.Mono.LLVM.Sdk,runtime.linux-musl-arm64.Microsoft.NETCore.Runtime.Mono.LLVM.Tools,runtime.linux-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Sdk,runtime.linux-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Tools,runtime.linux-musl-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Sdk,runtime.linux-musl-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Tools,runtime.win-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Sdk,runtime.win-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Tools,runtime.osx-arm64.Microsoft.NETCore.Runtime.Mono.LLVM.Sdk,runtime.osx-arm64.Microsoft.NETCore.Runtime.Mono.LLVM.Tools,runtime.osx-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Sdk,runtime.osx-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Tools From Version 16.0.5-alpha.1.24362.2 -> To Version 16.0.5-alpha.1.25311.1 (parent: Microsoft.NET.Workload.Emscripten.Current.Manifest-8.0.100 * Update dependencies from https://github.com/dotnet/emsdk build 20250818.3 Microsoft.SourceBuild.Intermediate.emsdk , Microsoft.NET.Workload.Emscripten.Current.Manifest-8.0.100 From Version 8.0.19-servicing.25353.2 -> To Version 8.0.20-servicing.25418.3 * Update branding to 8.0.21 (#119279) * [release/8.0] Update dependencies from dotnet/emsdk (#119065) * Update dependencies from https://github.com/dotnet/emsdk build 20250825.2 Microsoft.SourceBuild.Intermediate.emsdk , Microsoft.NET.Workload.Emscripten.Current.Manifest-8.0.100 From Version 8.0.20-servicing.25418.3 -> To Version 8.0.20-servicing.25425.2 * Update dependencies from https://github.com/dotnet/emsdk build 20250901.2 Microsoft.SourceBuild.Intermediate.emsdk , Microsoft.NET.Workload.Emscripten.Current.Manifest-8.0.100 From Version 8.0.20-servicing.25418.3 -> To Version 8.0.20-servicing.25451.2 * Update dependencies from https://github.com/dotnet/emsdk build 20250902.3 Microsoft.SourceBuild.Intermediate.emsdk , Microsoft.NET.Workload.Emscripten.Current.Manifest-8.0.100 From Version 8.0.20-servicing.25418.3 -> To Version 8.0.21-servicing.25452.3 * Update dependencies from https://github.com/dotnet/emsdk build 20250908.3 Microsoft.SourceBuild.Intermediate.emsdk , Microsoft.NET.Workload.Emscripten.Current.Manifest-8.0.100 From Version 8.0.20-servicing.25418.3 -> To Version 8.0.21-servicing.25458.3 --------- Co-authored-by: dotnet-maestro[bot] * Update dependencies from https://github.com/dotnet/cecil build 20250907.1 (#119618) Microsoft.DotNet.Cecil From Version 0.11.4-alpha.23509.2 -> To Version 0.11.4-alpha.25457.1 Co-authored-by: dotnet-maestro[bot] --------- Co-authored-by: Mirroring Co-authored-by: dotnet-maestro[bot] Co-authored-by: vseanreesermsft <78103370+vseanreesermsft@users.noreply.github.com> Co-authored-by: David Cantú Co-authored-by: Sean Reeser Co-authored-by: Tanner Gooding Co-authored-by: dotnet-maestro[bot] <42748379+dotnet-maestro[bot]@users.noreply.github.com> --- NuGet.config | 1 + eng/Version.Details.xml | 132 ++++++++++++++++++++-------------------- eng/Versions.props | 68 ++++++++++----------- 3 files changed, 101 insertions(+), 100 deletions(-) diff --git a/NuGet.config b/NuGet.config index f6e25f4daf50d1..6471ea519c49c5 100644 --- a/NuGet.config +++ b/NuGet.config @@ -9,6 +9,7 @@ + diff --git a/eng/Version.Details.xml b/eng/Version.Details.xml index 82ad0b67a72b5d..1609b309fa2df5 100644 --- a/eng/Version.Details.xml +++ b/eng/Version.Details.xml @@ -12,69 +12,69 @@ https://github.com/dotnet/wcf 7f504aabb1988e9a093c1e74d8040bd52feb2f01 - + https://github.com/dotnet/llvm-project - 0eac01ff3c4a8d1dbe6452dd2d8b75395bbf2b3d + 0a471ebbe6a4a9c095169dd531b825a4370f57f3 - + https://github.com/dotnet/llvm-project - 0eac01ff3c4a8d1dbe6452dd2d8b75395bbf2b3d + 0a471ebbe6a4a9c095169dd531b825a4370f57f3 - + https://github.com/dotnet/llvm-project - 0eac01ff3c4a8d1dbe6452dd2d8b75395bbf2b3d + 0a471ebbe6a4a9c095169dd531b825a4370f57f3 - + https://github.com/dotnet/llvm-project - 0eac01ff3c4a8d1dbe6452dd2d8b75395bbf2b3d + 0a471ebbe6a4a9c095169dd531b825a4370f57f3 - + https://github.com/dotnet/llvm-project - 0eac01ff3c4a8d1dbe6452dd2d8b75395bbf2b3d + 0a471ebbe6a4a9c095169dd531b825a4370f57f3 - + https://github.com/dotnet/llvm-project - 0eac01ff3c4a8d1dbe6452dd2d8b75395bbf2b3d + 0a471ebbe6a4a9c095169dd531b825a4370f57f3 - + https://github.com/dotnet/llvm-project - 0eac01ff3c4a8d1dbe6452dd2d8b75395bbf2b3d + 0a471ebbe6a4a9c095169dd531b825a4370f57f3 - + https://github.com/dotnet/llvm-project - 0eac01ff3c4a8d1dbe6452dd2d8b75395bbf2b3d + 0a471ebbe6a4a9c095169dd531b825a4370f57f3 - + https://github.com/dotnet/llvm-project - 0eac01ff3c4a8d1dbe6452dd2d8b75395bbf2b3d + 0a471ebbe6a4a9c095169dd531b825a4370f57f3 - + https://github.com/dotnet/llvm-project - 0eac01ff3c4a8d1dbe6452dd2d8b75395bbf2b3d + 0a471ebbe6a4a9c095169dd531b825a4370f57f3 - + https://github.com/dotnet/llvm-project - 0eac01ff3c4a8d1dbe6452dd2d8b75395bbf2b3d + 0a471ebbe6a4a9c095169dd531b825a4370f57f3 - + https://github.com/dotnet/llvm-project - 0eac01ff3c4a8d1dbe6452dd2d8b75395bbf2b3d + 0a471ebbe6a4a9c095169dd531b825a4370f57f3 - + https://github.com/dotnet/llvm-project - 0eac01ff3c4a8d1dbe6452dd2d8b75395bbf2b3d + 0a471ebbe6a4a9c095169dd531b825a4370f57f3 - + https://github.com/dotnet/llvm-project - 0eac01ff3c4a8d1dbe6452dd2d8b75395bbf2b3d + 0a471ebbe6a4a9c095169dd531b825a4370f57f3 - + https://github.com/dotnet/llvm-project - 0eac01ff3c4a8d1dbe6452dd2d8b75395bbf2b3d + 0a471ebbe6a4a9c095169dd531b825a4370f57f3 - + https://github.com/dotnet/llvm-project - 0eac01ff3c4a8d1dbe6452dd2d8b75395bbf2b3d + 0a471ebbe6a4a9c095169dd531b825a4370f57f3 https://github.com/dotnet/command-line-api @@ -85,18 +85,18 @@ 02fe27cd6a9b001c8feb7938e6ef4b3799745759 - + https://github.com/dotnet/cecil - 45dd3a73dd5b64b010c4251303b3664bb30df029 + e84d2f3e542c3bc970a5b2053aebffea995561d9 - + https://github.com/dotnet/emsdk - 6fd14a46f7bc405f4ba53b1e691c76fdc6324b0b + ea366a7a40bc588c70ef59376040130baf864c85 - + https://github.com/dotnet/emsdk - 6fd14a46f7bc405f4ba53b1e691c76fdc6324b0b + ea366a7a40bc588c70ef59376040130baf864c85 @@ -237,61 +237,61 @@ https://github.com/dotnet/runtime-assets e8f3528a061b4f6b944f13ad87382d7964b46c7e - + https://github.com/dotnet/llvm-project - 0eac01ff3c4a8d1dbe6452dd2d8b75395bbf2b3d + 0a471ebbe6a4a9c095169dd531b825a4370f57f3 - + https://github.com/dotnet/llvm-project - 0eac01ff3c4a8d1dbe6452dd2d8b75395bbf2b3d + 0a471ebbe6a4a9c095169dd531b825a4370f57f3 - + https://github.com/dotnet/llvm-project - 0eac01ff3c4a8d1dbe6452dd2d8b75395bbf2b3d + 0a471ebbe6a4a9c095169dd531b825a4370f57f3 - + https://github.com/dotnet/llvm-project - 0eac01ff3c4a8d1dbe6452dd2d8b75395bbf2b3d + 0a471ebbe6a4a9c095169dd531b825a4370f57f3 - + https://github.com/dotnet/llvm-project - 0eac01ff3c4a8d1dbe6452dd2d8b75395bbf2b3d + 0a471ebbe6a4a9c095169dd531b825a4370f57f3 - + https://github.com/dotnet/llvm-project - 0eac01ff3c4a8d1dbe6452dd2d8b75395bbf2b3d + 0a471ebbe6a4a9c095169dd531b825a4370f57f3 - + https://github.com/dotnet/llvm-project - 0eac01ff3c4a8d1dbe6452dd2d8b75395bbf2b3d + 0a471ebbe6a4a9c095169dd531b825a4370f57f3 - + https://github.com/dotnet/llvm-project - 0eac01ff3c4a8d1dbe6452dd2d8b75395bbf2b3d + 0a471ebbe6a4a9c095169dd531b825a4370f57f3 - + https://github.com/dotnet/llvm-project - 0eac01ff3c4a8d1dbe6452dd2d8b75395bbf2b3d + 0a471ebbe6a4a9c095169dd531b825a4370f57f3 - + https://github.com/dotnet/llvm-project - 0eac01ff3c4a8d1dbe6452dd2d8b75395bbf2b3d + 0a471ebbe6a4a9c095169dd531b825a4370f57f3 - + https://github.com/dotnet/llvm-project - 0eac01ff3c4a8d1dbe6452dd2d8b75395bbf2b3d + 0a471ebbe6a4a9c095169dd531b825a4370f57f3 - + https://github.com/dotnet/llvm-project - 0eac01ff3c4a8d1dbe6452dd2d8b75395bbf2b3d + 0a471ebbe6a4a9c095169dd531b825a4370f57f3 - + https://github.com/dotnet/llvm-project - 0eac01ff3c4a8d1dbe6452dd2d8b75395bbf2b3d + 0a471ebbe6a4a9c095169dd531b825a4370f57f3 - + https://github.com/dotnet/llvm-project - 0eac01ff3c4a8d1dbe6452dd2d8b75395bbf2b3d + 0a471ebbe6a4a9c095169dd531b825a4370f57f3 https://github.com/dotnet/runtime diff --git a/eng/Versions.props b/eng/Versions.props index 173ae1bf967fae..2441d21f812788 100644 --- a/eng/Versions.props +++ b/eng/Versions.props @@ -1,11 +1,11 @@ - 8.0.19 + 8.0.21 8 0 - 19 + 21 8.0.100 7.0.20 6.0.36 @@ -110,14 +110,14 @@ 8.0.0-rc.1.23406.6 8.0.0-preview.7.23325.2 - 16.0.5-alpha.1.24362.2 - 16.0.5-alpha.1.24362.2 - 16.0.5-alpha.1.24362.2 - 16.0.5-alpha.1.24362.2 - 16.0.5-alpha.1.24362.2 - 16.0.5-alpha.1.24362.2 - 16.0.5-alpha.1.24362.2 - 16.0.5-alpha.1.24362.2 + 16.0.5-alpha.1.25311.1 + 16.0.5-alpha.1.25311.1 + 16.0.5-alpha.1.25311.1 + 16.0.5-alpha.1.25311.1 + 16.0.5-alpha.1.25311.1 + 16.0.5-alpha.1.25311.1 + 16.0.5-alpha.1.25311.1 + 16.0.5-alpha.1.25311.1 6.0.0 1.1.1 @@ -225,7 +225,7 @@ 8.0.0-rc.1.23406.6 - 0.11.4-alpha.23509.2 + 0.11.4-alpha.25457.1 8.0.0-rc.1.23406.6 @@ -234,37 +234,37 @@ 2.4.8 8.0.0-alpha.1.23527.1 - 16.0.5-alpha.1.24362.2 - 16.0.5-alpha.1.24362.2 - 16.0.5-alpha.1.24362.2 - 16.0.5-alpha.1.24362.2 - 16.0.5-alpha.1.24362.2 - 16.0.5-alpha.1.24362.2 - 16.0.5-alpha.1.24362.2 - 16.0.5-alpha.1.24362.2 - 16.0.5-alpha.1.24362.2 - 16.0.5-alpha.1.24362.2 - 16.0.5-alpha.1.24362.2 - 16.0.5-alpha.1.24362.2 - 16.0.5-alpha.1.24362.2 - 16.0.5-alpha.1.24362.2 + 16.0.5-alpha.1.25311.1 + 16.0.5-alpha.1.25311.1 + 16.0.5-alpha.1.25311.1 + 16.0.5-alpha.1.25311.1 + 16.0.5-alpha.1.25311.1 + 16.0.5-alpha.1.25311.1 + 16.0.5-alpha.1.25311.1 + 16.0.5-alpha.1.25311.1 + 16.0.5-alpha.1.25311.1 + 16.0.5-alpha.1.25311.1 + 16.0.5-alpha.1.25311.1 + 16.0.5-alpha.1.25311.1 + 16.0.5-alpha.1.25311.1 + 16.0.5-alpha.1.25311.1 - 8.0.19 + 8.0.21 $(MicrosoftNETWorkloadEmscriptenCurrentManifest80100Version) 1.1.87-gba258badda - 16.0.5-alpha.1.24362.2 - 16.0.5-alpha.1.24362.2 - 16.0.5-alpha.1.24362.2 - 16.0.5-alpha.1.24362.2 - 16.0.5-alpha.1.24362.2 - 16.0.5-alpha.1.24362.2 - 16.0.5-alpha.1.24362.2 - 16.0.5-alpha.1.24362.2 + 16.0.5-alpha.1.25311.1 + 16.0.5-alpha.1.25311.1 + 16.0.5-alpha.1.25311.1 + 16.0.5-alpha.1.25311.1 + 16.0.5-alpha.1.25311.1 + 16.0.5-alpha.1.25311.1 + 16.0.5-alpha.1.25311.1 + 16.0.5-alpha.1.25311.1 3.1.7 1.0.406601 From f1f345979aaba5f1104c19071319da2d646dd600 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Mon, 15 Sep 2025 09:57:01 +0200 Subject: [PATCH 12/20] Do not check status, it's irrelevant whether to asses if H/3 is working. (#119523) Co-authored-by: ManickaP --- .../tests/FunctionalTests/HttpClientHandlerTest.Http3.cs | 2 -- 1 file changed, 2 deletions(-) diff --git a/src/libraries/System.Net.Http/tests/FunctionalTests/HttpClientHandlerTest.Http3.cs b/src/libraries/System.Net.Http/tests/FunctionalTests/HttpClientHandlerTest.Http3.cs index b9de74a38a0457..49026e7126c4a0 100644 --- a/src/libraries/System.Net.Http/tests/FunctionalTests/HttpClientHandlerTest.Http3.cs +++ b/src/libraries/System.Net.Http/tests/FunctionalTests/HttpClientHandlerTest.Http3.cs @@ -730,7 +730,6 @@ public async Task Public_Interop_ExactVersion_Success(string uri) }; using HttpResponseMessage response = await client.SendAsync(request).WaitAsync(TimeSpan.FromSeconds(20)); - Assert.Equal(HttpStatusCode.OK, response.StatusCode); Assert.Equal(3, response.Version.Major); } @@ -749,7 +748,6 @@ public async Task Public_Interop_ExactVersion_BufferContent_Success(string uri) }; using HttpResponseMessage response = await client.SendAsync(request, HttpCompletionOption.ResponseContentRead).WaitAsync(TimeSpan.FromSeconds(20)); - Assert.Equal(HttpStatusCode.OK, response.StatusCode); Assert.Equal(3, response.Version.Major); var content = await response.Content.ReadAsStringAsync(); From 03c5271bcd7dfab3935d652e34f339beb436c078 Mon Sep 17 00:00:00 2001 From: "dotnet-maestro[bot]" <42748379+dotnet-maestro[bot]@users.noreply.github.com> Date: Mon, 15 Sep 2025 12:48:09 +0200 Subject: [PATCH 13/20] [release/8.0-staging] Update dependencies from dotnet/arcade (#118540) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Update dependencies from https://github.com/dotnet/arcade build 20250807.1 Microsoft.DotNet.Arcade.Sdk , Microsoft.DotNet.Build.Tasks.Archives , Microsoft.DotNet.Build.Tasks.Feed , Microsoft.DotNet.Build.Tasks.Installers , Microsoft.DotNet.Build.Tasks.Packaging , Microsoft.DotNet.Build.Tasks.TargetFramework , Microsoft.DotNet.Build.Tasks.Templating , Microsoft.DotNet.Build.Tasks.Workloads , Microsoft.DotNet.CodeAnalysis , Microsoft.DotNet.GenAPI , Microsoft.DotNet.GenFacades , Microsoft.DotNet.Helix.Sdk , Microsoft.DotNet.PackageTesting , Microsoft.DotNet.RemoteExecutor , Microsoft.DotNet.SharedFramework.Sdk , Microsoft.DotNet.VersionTools.Tasks , Microsoft.DotNet.XUnitConsoleRunner , Microsoft.DotNet.XUnitExtensions From Version 8.0.0-beta.25310.3 -> To Version 8.0.0-beta.25407.1 * Bump MicrosoftDotnetSdkInternalVersion * Update dependencies from https://github.com/dotnet/arcade build 20250911.1 On relative base path root Microsoft.DotNet.Arcade.Sdk , Microsoft.DotNet.Build.Tasks.Archives , Microsoft.DotNet.Build.Tasks.Feed , Microsoft.DotNet.Build.Tasks.Installers , Microsoft.DotNet.Build.Tasks.Packaging , Microsoft.DotNet.Build.Tasks.TargetFramework , Microsoft.DotNet.Build.Tasks.Templating , Microsoft.DotNet.Build.Tasks.Workloads , Microsoft.DotNet.CodeAnalysis , Microsoft.DotNet.GenAPI , Microsoft.DotNet.GenFacades , Microsoft.DotNet.Helix.Sdk , Microsoft.DotNet.PackageTesting , Microsoft.DotNet.RemoteExecutor , Microsoft.DotNet.SharedFramework.Sdk , Microsoft.DotNet.VersionTools.Tasks , Microsoft.DotNet.XUnitExtensions From Version 8.0.0-beta.25310.3 -> To Version 8.0.0-beta.25461.1 Microsoft.DotNet.XUnitConsoleRunner From Version 2.5.1-beta.25310.3 -> To Version 2.5.1-beta.25461.1 * Bump MicrosoftDotnetSdkInternalVersion --------- Co-authored-by: dotnet-maestro[bot] Co-authored-by: Alexander Köplinger --- eng/Version.Details.xml | 72 +++++++++---------- eng/Versions.props | 32 ++++----- eng/common/SetupNugetSources.ps1 | 4 +- eng/common/SetupNugetSources.sh | 4 +- eng/common/templates-official/job/job.yml | 18 +++-- .../templates-official/job/onelocbuild.yml | 6 +- .../job/publish-build-assets.yml | 13 ++-- .../templates-official/job/source-build.yml | 4 ++ .../job/source-index-stage1.yml | 2 +- .../templates-official/jobs/codeql-build.yml | 2 +- eng/common/templates-official/jobs/jobs.yml | 2 + .../templates-official/jobs/source-build.yml | 5 ++ .../post-build/post-build.yml | 8 +-- .../post-build/trigger-subscription.yml | 2 +- .../steps/add-build-to-channel.yml | 2 +- .../templates-official/steps/execute-sdl.yml | 14 ++-- .../steps/generate-sbom.yml | 2 +- .../templates-official/steps/publish-logs.yml | 6 +- .../templates-official/steps/source-build.yml | 14 ++-- .../variables/sdl-variables.yml | 2 +- eng/common/templates/job/job.yml | 16 +++-- eng/common/templates/job/onelocbuild.yml | 6 +- .../templates/job/publish-build-assets.yml | 13 ++-- eng/common/templates/job/source-build.yml | 4 ++ .../templates/job/source-index-stage1.yml | 2 +- eng/common/templates/jobs/codeql-build.yml | 2 +- eng/common/templates/jobs/jobs.yml | 2 + eng/common/templates/jobs/source-build.yml | 5 ++ .../templates/post-build/post-build.yml | 8 +-- .../post-build/setup-maestro-vars.yml | 2 +- .../post-build/trigger-subscription.yml | 2 +- .../templates/steps/add-build-to-channel.yml | 2 +- eng/common/templates/steps/execute-sdl.yml | 14 ++-- eng/common/templates/steps/generate-sbom.yml | 2 +- eng/common/templates/steps/publish-logs.yml | 6 +- eng/common/templates/steps/source-build.yml | 14 ++-- .../templates/variables/sdl-variables.yml | 2 +- eng/common/tools.ps1 | 2 +- global.json | 10 +-- 39 files changed, 191 insertions(+), 137 deletions(-) diff --git a/eng/Version.Details.xml b/eng/Version.Details.xml index 1609b309fa2df5..a7c6ccef802cc1 100644 --- a/eng/Version.Details.xml +++ b/eng/Version.Details.xml @@ -111,9 +111,9 @@ - + https://github.com/dotnet/arcade - 2ce3f8c7b2614c2b19985b669ffcd934bc39ffd1 + 958612453c58fd32328461580b19ce5ecf4aedd2 @@ -121,69 +121,69 @@ 73f0850939d96131c28cf6ea6ee5aacb4da0083a - + https://github.com/dotnet/arcade - 2ce3f8c7b2614c2b19985b669ffcd934bc39ffd1 + 958612453c58fd32328461580b19ce5ecf4aedd2 - + https://github.com/dotnet/arcade - 2ce3f8c7b2614c2b19985b669ffcd934bc39ffd1 + 958612453c58fd32328461580b19ce5ecf4aedd2 - + https://github.com/dotnet/arcade - 2ce3f8c7b2614c2b19985b669ffcd934bc39ffd1 + 958612453c58fd32328461580b19ce5ecf4aedd2 - + https://github.com/dotnet/arcade - 2ce3f8c7b2614c2b19985b669ffcd934bc39ffd1 + 958612453c58fd32328461580b19ce5ecf4aedd2 - + https://github.com/dotnet/arcade - 2ce3f8c7b2614c2b19985b669ffcd934bc39ffd1 + 958612453c58fd32328461580b19ce5ecf4aedd2 - + https://github.com/dotnet/arcade - 2ce3f8c7b2614c2b19985b669ffcd934bc39ffd1 + 958612453c58fd32328461580b19ce5ecf4aedd2 - + https://github.com/dotnet/arcade - 2ce3f8c7b2614c2b19985b669ffcd934bc39ffd1 + 958612453c58fd32328461580b19ce5ecf4aedd2 - + https://github.com/dotnet/arcade - 2ce3f8c7b2614c2b19985b669ffcd934bc39ffd1 + 958612453c58fd32328461580b19ce5ecf4aedd2 - + https://github.com/dotnet/arcade - 2ce3f8c7b2614c2b19985b669ffcd934bc39ffd1 + 958612453c58fd32328461580b19ce5ecf4aedd2 - + https://github.com/dotnet/arcade - 2ce3f8c7b2614c2b19985b669ffcd934bc39ffd1 + 958612453c58fd32328461580b19ce5ecf4aedd2 - + https://github.com/dotnet/arcade - 2ce3f8c7b2614c2b19985b669ffcd934bc39ffd1 + 958612453c58fd32328461580b19ce5ecf4aedd2 - + https://github.com/dotnet/arcade - 2ce3f8c7b2614c2b19985b669ffcd934bc39ffd1 + 958612453c58fd32328461580b19ce5ecf4aedd2 - + https://github.com/dotnet/arcade - 2ce3f8c7b2614c2b19985b669ffcd934bc39ffd1 + 958612453c58fd32328461580b19ce5ecf4aedd2 - + https://github.com/dotnet/arcade - 2ce3f8c7b2614c2b19985b669ffcd934bc39ffd1 + 958612453c58fd32328461580b19ce5ecf4aedd2 - + https://github.com/dotnet/arcade - 2ce3f8c7b2614c2b19985b669ffcd934bc39ffd1 + 958612453c58fd32328461580b19ce5ecf4aedd2 - + https://github.com/dotnet/arcade - 2ce3f8c7b2614c2b19985b669ffcd934bc39ffd1 + 958612453c58fd32328461580b19ce5ecf4aedd2 https://github.com/dotnet/runtime-assets @@ -334,9 +334,9 @@ https://github.com/dotnet/xharness fc7f1ca0ff5b949ba7b7500e5aa9a01e4a43d894 - + https://github.com/dotnet/arcade - 2ce3f8c7b2614c2b19985b669ffcd934bc39ffd1 + 958612453c58fd32328461580b19ce5ecf4aedd2 https://dev.azure.com/dnceng/internal/_git/dotnet-optimization diff --git a/eng/Versions.props b/eng/Versions.props index 2441d21f812788..98274f22f8d960 100644 --- a/eng/Versions.props +++ b/eng/Versions.props @@ -87,21 +87,21 @@ 8.0.100 - 8.0.0-beta.25310.3 - 8.0.0-beta.25310.3 - 8.0.0-beta.25310.3 - 8.0.0-beta.25310.3 - 8.0.0-beta.25310.3 - 2.5.1-beta.25310.3 - 8.0.0-beta.25310.3 - 8.0.0-beta.25310.3 - 8.0.0-beta.25310.3 - 8.0.0-beta.25310.3 - 8.0.0-beta.25310.3 - 8.0.0-beta.25310.3 - 8.0.0-beta.25310.3 - 8.0.0-beta.25310.3 - 8.0.0-beta.25310.3 + 8.0.0-beta.25461.1 + 8.0.0-beta.25461.1 + 8.0.0-beta.25461.1 + 8.0.0-beta.25461.1 + 8.0.0-beta.25461.1 + 2.5.1-beta.25461.1 + 8.0.0-beta.25461.1 + 8.0.0-beta.25461.1 + 8.0.0-beta.25461.1 + 8.0.0-beta.25461.1 + 8.0.0-beta.25461.1 + 8.0.0-beta.25461.1 + 8.0.0-beta.25461.1 + 8.0.0-beta.25461.1 + 8.0.0-beta.25461.1 6.0.0-preview.1.102 @@ -269,7 +269,7 @@ 3.1.7 1.0.406601 - 8.0.117 + 8.0.120 $(MicrosoftDotnetSdkInternalVersion) diff --git a/eng/common/SetupNugetSources.ps1 b/eng/common/SetupNugetSources.ps1 index efa2fd72bfaa22..59b2d55e1a330e 100644 --- a/eng/common/SetupNugetSources.ps1 +++ b/eng/common/SetupNugetSources.ps1 @@ -17,8 +17,8 @@ # displayName: Setup Private Feeds Credentials # condition: eq(variables['Agent.OS'], 'Windows_NT') # inputs: -# filePath: $(Build.SourcesDirectory)/eng/common/SetupNugetSources.ps1 -# arguments: -ConfigFile $(Build.SourcesDirectory)/NuGet.config -Password $Env:Token +# filePath: $(System.DefaultWorkingDirectory)/eng/common/SetupNugetSources.ps1 +# arguments: -ConfigFile $(System.DefaultWorkingDirectory)/NuGet.config -Password $Env:Token # env: # Token: $(dn-bot-dnceng-artifact-feeds-rw) diff --git a/eng/common/SetupNugetSources.sh b/eng/common/SetupNugetSources.sh index d387c7eac95e54..c0e7bbef21c467 100644 --- a/eng/common/SetupNugetSources.sh +++ b/eng/common/SetupNugetSources.sh @@ -18,8 +18,8 @@ # - task: Bash@3 # displayName: Setup Private Feeds Credentials # inputs: -# filePath: $(Build.SourcesDirectory)/eng/common/SetupNugetSources.sh -# arguments: $(Build.SourcesDirectory)/NuGet.config $Token +# filePath: $(System.DefaultWorkingDirectory)/eng/common/SetupNugetSources.sh +# arguments: $(System.DefaultWorkingDirectory)/NuGet.config $Token # condition: ne(variables['Agent.OS'], 'Windows_NT') # env: # Token: $(dn-bot-dnceng-artifact-feeds-rw) diff --git a/eng/common/templates-official/job/job.yml b/eng/common/templates-official/job/job.yml index 98ccbd7a9c16ec..4cca1114fccaa2 100644 --- a/eng/common/templates-official/job/job.yml +++ b/eng/common/templates-official/job/job.yml @@ -21,6 +21,7 @@ parameters: # See schema documentation - https://github.com/dotnet/arcade/blob/master/Documentation/AzureDevOps/TemplateSchema.md artifacts: '' enableMicrobuild: false + microbuildUseESRP: true enablePublishBuildArtifacts: false enablePublishBuildAssets: false enablePublishTestResults: false @@ -37,7 +38,7 @@ parameters: # Sbom related params enableSbom: true PackageVersion: 7.0.0 - BuildDropPath: '$(Build.SourcesDirectory)/artifacts' + BuildDropPath: '$(System.DefaultWorkingDirectory)/artifacts' ManifestDirPath: $(Build.ArtifactStagingDirectory)/sbom jobs: @@ -135,6 +136,11 @@ jobs: signType: $(_SignType) zipSources: false feedSource: https://dnceng.pkgs.visualstudio.com/_packaging/MicroBuildToolset/nuget/v3/index.json + ${{ if eq(parameters.microbuildUseESRP, true) }}: + ${{ if eq(variables['System.TeamProject'], 'DevDiv') }}: + ConnectedPMEServiceName: 6cc74545-d7b9-4050-9dfa-ebefcc8961ea + ${{ else }}: + ConnectedPMEServiceName: 248d384a-b39b-46e3-8ad5-c2c210d5e7ca env: TeamName: $(_TeamName) MicroBuildOutputFolderOverride: '$(Agent.TempDirectory)' @@ -161,7 +167,7 @@ jobs: inputs: languages: ${{ coalesce(parameters.richCodeNavigationLanguage, 'csharp') }} environment: ${{ coalesce(parameters.richCodeNavigationEnvironment, 'production') }} - richNavLogOutputDirectory: $(Build.SourcesDirectory)/artifacts/bin + richNavLogOutputDirectory: $(System.DefaultWorkingDirectory)/artifacts/bin uploadRichNavArtifacts: ${{ coalesce(parameters.richCodeNavigationUploadArtifacts, false) }} continueOnError: true @@ -220,7 +226,7 @@ jobs: - task: 1ES.PublishBuildArtifacts@1 displayName: Publish Logs inputs: - PathtoPublish: '$(Build.SourcesDirectory)/artifacts/log/$(_BuildConfig)' + PathtoPublish: '$(System.DefaultWorkingDirectory)/artifacts/log/$(_BuildConfig)' PublishLocation: Container ArtifactName: ${{ coalesce(parameters.enablePublishBuildArtifacts.artifactName, '$(Agent.Os)_$(Agent.JobName)' ) }} continueOnError: true @@ -232,7 +238,7 @@ jobs: inputs: testResultsFormat: 'xUnit' testResultsFiles: '*.xml' - searchFolder: '$(Build.SourcesDirectory)/artifacts/TestResults/$(_BuildConfig)' + searchFolder: '$(System.DefaultWorkingDirectory)/artifacts/TestResults/$(_BuildConfig)' testRunTitle: ${{ coalesce(parameters.testRunTitle, parameters.name, '$(System.JobName)') }}-xunit mergeTestResults: ${{ parameters.mergeTestResults }} continueOnError: true @@ -243,7 +249,7 @@ jobs: inputs: testResultsFormat: 'VSTest' testResultsFiles: '*.trx' - searchFolder: '$(Build.SourcesDirectory)/artifacts/TestResults/$(_BuildConfig)' + searchFolder: '$(System.DefaultWorkingDirectory)/artifacts/TestResults/$(_BuildConfig)' testRunTitle: ${{ coalesce(parameters.testRunTitle, parameters.name, '$(System.JobName)') }}-trx mergeTestResults: ${{ parameters.mergeTestResults }} continueOnError: true @@ -259,7 +265,7 @@ jobs: - ${{ if eq(parameters.enableBuildRetry, 'true') }}: - task: 1ES.PublishPipelineArtifact@1 inputs: - targetPath: '$(Build.SourcesDirectory)\eng\common\BuildConfiguration' + targetPath: '$(System.DefaultWorkingDirectory)\eng\common\BuildConfiguration' artifactName: 'BuildConfiguration' displayName: 'Publish build retry configuration' continueOnError: true diff --git a/eng/common/templates-official/job/onelocbuild.yml b/eng/common/templates-official/job/onelocbuild.yml index 52b4d05d3f8dd6..68e7a65605c556 100644 --- a/eng/common/templates-official/job/onelocbuild.yml +++ b/eng/common/templates-official/job/onelocbuild.yml @@ -8,7 +8,7 @@ parameters: CeapexPat: $(dn-bot-ceapex-package-r) # PAT for the loc AzDO instance https://dev.azure.com/ceapex GithubPat: $(BotAccount-dotnet-bot-repo-PAT) - SourcesDirectory: $(Build.SourcesDirectory) + SourcesDirectory: $(System.DefaultWorkingDirectory) CreatePr: true AutoCompletePr: false ReusePr: true @@ -63,7 +63,7 @@ jobs: - ${{ if ne(parameters.SkipLocProjectJsonGeneration, 'true') }}: - task: Powershell@2 inputs: - filePath: $(Build.SourcesDirectory)/eng/common/generate-locproject.ps1 + filePath: $(System.DefaultWorkingDirectory)/eng/common/generate-locproject.ps1 arguments: $(_GenerateLocProjectArguments) displayName: Generate LocProject.json condition: ${{ parameters.condition }} @@ -106,7 +106,7 @@ jobs: - task: 1ES.PublishBuildArtifacts@1 displayName: Publish LocProject.json inputs: - PathtoPublish: '$(Build.SourcesDirectory)/eng/Localize/' + PathtoPublish: '$(System.DefaultWorkingDirectory)/eng/Localize/' PublishLocation: Container ArtifactName: Loc condition: ${{ parameters.condition }} \ No newline at end of file diff --git a/eng/common/templates-official/job/publish-build-assets.yml b/eng/common/templates-official/job/publish-build-assets.yml index b2ccd9df68010e..7a320e9bab20a2 100644 --- a/eng/common/templates-official/job/publish-build-assets.yml +++ b/eng/common/templates-official/job/publish-build-assets.yml @@ -30,6 +30,8 @@ parameters: signingValidationAdditionalParameters: '' + repositoryAlias: self + jobs: - job: Asset_Registry_Publish @@ -65,6 +67,9 @@ jobs: os: windows steps: - ${{ if and(eq(parameters.runAsPublic, 'false'), ne(variables['System.TeamProject'], 'public'), notin(variables['Build.Reason'], 'PullRequest')) }}: + - checkout: ${{ parameters.repositoryAlias }} + fetchDepth: 3 + clean: true - task: DownloadBuildArtifacts@0 displayName: Download artifact inputs: @@ -82,7 +87,7 @@ jobs: azureSubscription: "Darc: Maestro Production" scriptType: ps scriptLocation: scriptPath - scriptPath: $(Build.SourcesDirectory)/eng/common/sdk-task.ps1 + scriptPath: $(System.DefaultWorkingDirectory)/eng/common/sdk-task.ps1 arguments: > -task PublishBuildAssets -restore -msbuildEngine dotnet /p:ManifestsPath='$(Build.StagingDirectory)/Download/AssetManifests' @@ -115,7 +120,7 @@ jobs: inputs: targetType: inline script: | - $symbolExclusionfile = "$(Build.SourcesDirectory)/eng/SymbolPublishingExclusionsFile.txt" + $symbolExclusionfile = "$(System.DefaultWorkingDirectory)/eng/SymbolPublishingExclusionsFile.txt" if(Test-Path -Path $symbolExclusionfile) { Write-Host "SymbolExclusionFile exists" @@ -130,7 +135,7 @@ jobs: displayName: Publish SymbolPublishingExclusionsFile Artifact condition: eq(variables['SymbolExclusionFile'], 'true') inputs: - PathtoPublish: '$(Build.SourcesDirectory)/eng/SymbolPublishingExclusionsFile.txt' + PathtoPublish: '$(System.DefaultWorkingDirectory)/eng/SymbolPublishingExclusionsFile.txt' PublishLocation: Container ArtifactName: ReleaseConfigs @@ -146,7 +151,7 @@ jobs: azureSubscription: "Darc: Maestro Production" scriptType: ps scriptLocation: scriptPath - scriptPath: $(Build.SourcesDirectory)/eng/common/post-build/publish-using-darc.ps1 + scriptPath: $(System.DefaultWorkingDirectory)/eng/common/post-build/publish-using-darc.ps1 arguments: -BuildId $(BARBuildId) -PublishingInfraVersion 3 -AzdoToken '$(System.AccessToken)' diff --git a/eng/common/templates-official/job/source-build.yml b/eng/common/templates-official/job/source-build.yml index 4217d6d8b1481e..7b9c58a90c5ef7 100644 --- a/eng/common/templates-official/job/source-build.yml +++ b/eng/common/templates-official/job/source-build.yml @@ -31,6 +31,9 @@ parameters: # container and pool. platform: {} + # Optional list of directories to ignore for component governance scans. + cgIgnoreDirectories: [] + # If set to true and running on a non-public project, # Internal blob storage locations will be enabled. # This is not enabled by default because many repositories do not need internal sources @@ -73,3 +76,4 @@ jobs: - template: /eng/common/templates-official/steps/source-build.yml parameters: platform: ${{ parameters.platform }} + cgIgnoreDirectories: ${{ parameters.cgIgnoreDirectories }} diff --git a/eng/common/templates-official/job/source-index-stage1.yml b/eng/common/templates-official/job/source-index-stage1.yml index fb632b71a250b8..0579e692fc8131 100644 --- a/eng/common/templates-official/job/source-index-stage1.yml +++ b/eng/common/templates-official/job/source-index-stage1.yml @@ -59,7 +59,7 @@ jobs: - script: ${{ parameters.sourceIndexBuildCommand }} displayName: Build Repository - - script: $(Agent.TempDirectory)/.source-index/tools/BinLogToSln -i $(BinlogPath) -r $(Build.SourcesDirectory) -n $(Build.Repository.Name) -o .source-index/stage1output + - script: $(Agent.TempDirectory)/.source-index/tools/BinLogToSln -i $(BinlogPath) -r $(System.DefaultWorkingDirectory) -n $(Build.Repository.Name) -o .source-index/stage1output displayName: Process Binlog into indexable sln - ${{ if and(eq(parameters.runAsPublic, 'false'), ne(variables['System.TeamProject'], 'public'), notin(variables['Build.Reason'], 'PullRequest')) }}: diff --git a/eng/common/templates-official/jobs/codeql-build.yml b/eng/common/templates-official/jobs/codeql-build.yml index b68d3c2f31990f..f6476912a861f9 100644 --- a/eng/common/templates-official/jobs/codeql-build.yml +++ b/eng/common/templates-official/jobs/codeql-build.yml @@ -23,7 +23,7 @@ jobs: - name: DefaultGuardianVersion value: 0.109.0 - name: GuardianPackagesConfigFile - value: $(Build.SourcesDirectory)\eng\common\sdl\packages.config + value: $(System.DefaultWorkingDirectory)\eng\common\sdl\packages.config - name: GuardianVersion value: ${{ coalesce(parameters.overrideGuardianVersion, '$(DefaultGuardianVersion)') }} diff --git a/eng/common/templates-official/jobs/jobs.yml b/eng/common/templates-official/jobs/jobs.yml index 857a0f8ba43e84..803a95aacf4e01 100644 --- a/eng/common/templates-official/jobs/jobs.yml +++ b/eng/common/templates-official/jobs/jobs.yml @@ -40,6 +40,7 @@ parameters: enableSourceIndex: false sourceIndexParams: {} + repositoryAlias: self # Internal resources (telemetry, microbuild) can only be accessed from non-public projects, # and some (Microbuild) should only be applied to non-PR cases for internal builds. @@ -95,3 +96,4 @@ jobs: enablePublishBuildArtifacts: ${{ parameters.enablePublishBuildArtifacts }} artifactsPublishingAdditionalParameters: ${{ parameters.artifactsPublishingAdditionalParameters }} signingValidationAdditionalParameters: ${{ parameters.signingValidationAdditionalParameters }} + repositoryAlias: ${{ parameters.repositoryAlias }} diff --git a/eng/common/templates-official/jobs/source-build.yml b/eng/common/templates-official/jobs/source-build.yml index b9247be1547b73..21a346fbd6c70e 100644 --- a/eng/common/templates-official/jobs/source-build.yml +++ b/eng/common/templates-official/jobs/source-build.yml @@ -21,6 +21,9 @@ parameters: # one job runs on 'defaultManagedPlatform'. platforms: [] + # Optional list of directories to ignore for component governance scans. + cgIgnoreDirectories: [] + # If set to true and running on a non-public project, # Internal nuget and blob storage locations will be enabled. # This is not enabled by default because many repositories do not need internal sources @@ -44,6 +47,7 @@ jobs: parameters: jobNamePrefix: ${{ parameters.jobNamePrefix }} platform: ${{ platform }} + cgIgnoreDirectories: ${{ parameters.cgIgnoreDirectories }} enableInternalSources: ${{ parameters.enableInternalSources }} - ${{ if eq(length(parameters.platforms), 0) }}: @@ -51,4 +55,5 @@ jobs: parameters: jobNamePrefix: ${{ parameters.jobNamePrefix }} platform: ${{ parameters.defaultManagedPlatform }} + cgIgnoreDirectories: ${{ parameters.cgIgnoreDirectories }} enableInternalSources: ${{ parameters.enableInternalSources }} diff --git a/eng/common/templates-official/post-build/post-build.yml b/eng/common/templates-official/post-build/post-build.yml index b81b8770b34687..9fef8103991ccf 100644 --- a/eng/common/templates-official/post-build/post-build.yml +++ b/eng/common/templates-official/post-build/post-build.yml @@ -133,7 +133,7 @@ stages: - task: PowerShell@2 displayName: Validate inputs: - filePath: $(Build.SourcesDirectory)/eng/common/post-build/nuget-validation.ps1 + filePath: $(System.DefaultWorkingDirectory)/eng/common/post-build/nuget-validation.ps1 arguments: -PackagesPath $(Build.ArtifactStagingDirectory)/PackageArtifacts/ -ToolDestinationPath $(Agent.BuildDirectory)/Extract/ @@ -186,7 +186,7 @@ stages: filePath: eng\common\sdk-task.ps1 arguments: -task SigningValidation -restore -msbuildEngine vs /p:PackageBasePath='$(Build.ArtifactStagingDirectory)/PackageArtifacts' - /p:SignCheckExclusionsFile='$(Build.SourcesDirectory)/eng/SignCheckExclusionsFile.txt' + /p:SignCheckExclusionsFile='$(System.DefaultWorkingDirectory)/eng/SignCheckExclusionsFile.txt' ${{ parameters.signingValidationAdditionalParameters }} - template: ../steps/publish-logs.yml @@ -230,7 +230,7 @@ stages: - task: PowerShell@2 displayName: Validate inputs: - filePath: $(Build.SourcesDirectory)/eng/common/post-build/sourcelink-validation.ps1 + filePath: $(System.DefaultWorkingDirectory)/eng/common/post-build/sourcelink-validation.ps1 arguments: -InputPath $(Build.ArtifactStagingDirectory)/BlobArtifacts/ -ExtractPath $(Agent.BuildDirectory)/Extract/ -GHRepoName $(Build.Repository.Name) @@ -278,7 +278,7 @@ stages: azureSubscription: "Darc: Maestro Production" scriptType: ps scriptLocation: scriptPath - scriptPath: $(Build.SourcesDirectory)/eng/common/post-build/publish-using-darc.ps1 + scriptPath: $(System.DefaultWorkingDirectory)/eng/common/post-build/publish-using-darc.ps1 arguments: -BuildId $(BARBuildId) -PublishingInfraVersion ${{ parameters.publishingInfraVersion }} -AzdoToken '$(System.AccessToken)' diff --git a/eng/common/templates-official/post-build/trigger-subscription.yml b/eng/common/templates-official/post-build/trigger-subscription.yml index da669030daf6e9..52df7077482856 100644 --- a/eng/common/templates-official/post-build/trigger-subscription.yml +++ b/eng/common/templates-official/post-build/trigger-subscription.yml @@ -5,7 +5,7 @@ steps: - task: PowerShell@2 displayName: Triggering subscriptions inputs: - filePath: $(Build.SourcesDirectory)/eng/common/post-build/trigger-subscriptions.ps1 + filePath: $(System.DefaultWorkingDirectory)/eng/common/post-build/trigger-subscriptions.ps1 arguments: -SourceRepo $(Build.Repository.Uri) -ChannelId ${{ parameters.ChannelId }} -MaestroApiAccessToken $(MaestroAccessToken) diff --git a/eng/common/templates-official/steps/add-build-to-channel.yml b/eng/common/templates-official/steps/add-build-to-channel.yml index f67a210d62f3e5..5b6fec257ea7fd 100644 --- a/eng/common/templates-official/steps/add-build-to-channel.yml +++ b/eng/common/templates-official/steps/add-build-to-channel.yml @@ -5,7 +5,7 @@ steps: - task: PowerShell@2 displayName: Add Build to Channel inputs: - filePath: $(Build.SourcesDirectory)/eng/common/post-build/add-build-to-channel.ps1 + filePath: $(System.DefaultWorkingDirectory)/eng/common/post-build/add-build-to-channel.ps1 arguments: -BuildId $(BARBuildId) -ChannelId ${{ parameters.ChannelId }} -MaestroApiAccessToken $(MaestroApiAccessToken) diff --git a/eng/common/templates-official/steps/execute-sdl.yml b/eng/common/templates-official/steps/execute-sdl.yml index 301d5c591ebd13..d9dcd1e1cdeb9f 100644 --- a/eng/common/templates-official/steps/execute-sdl.yml +++ b/eng/common/templates-official/steps/execute-sdl.yml @@ -15,17 +15,17 @@ steps: - ${{ if ne(parameters.overrideGuardianVersion, '') }}: - pwsh: | - Set-Location -Path $(Build.SourcesDirectory)\eng\common\sdl + Set-Location -Path $(System.DefaultWorkingDirectory)\eng\common\sdl . .\sdl.ps1 - $guardianCliLocation = Install-Gdn -Path $(Build.SourcesDirectory)\.artifacts -Version ${{ parameters.overrideGuardianVersion }} + $guardianCliLocation = Install-Gdn -Path $(System.DefaultWorkingDirectory)\.artifacts -Version ${{ parameters.overrideGuardianVersion }} Write-Host "##vso[task.setvariable variable=GuardianCliLocation]$guardianCliLocation" displayName: Install Guardian (Overridden) - ${{ if eq(parameters.overrideGuardianVersion, '') }}: - pwsh: | - Set-Location -Path $(Build.SourcesDirectory)\eng\common\sdl + Set-Location -Path $(System.DefaultWorkingDirectory)\eng\common\sdl . .\sdl.ps1 - $guardianCliLocation = Install-Gdn -Path $(Build.SourcesDirectory)\.artifacts + $guardianCliLocation = Install-Gdn -Path $(System.DefaultWorkingDirectory)\.artifacts Write-Host "##vso[task.setvariable variable=GuardianCliLocation]$guardianCliLocation" displayName: Install Guardian @@ -38,7 +38,7 @@ steps: - ${{ if eq(parameters.overrideParameters, '') }}: - powershell: ${{ parameters.executeAllSdlToolsScript }} -GuardianCliLocation $(GuardianCliLocation) - -NugetPackageDirectory $(Build.SourcesDirectory)\.packages + -NugetPackageDirectory $(System.DefaultWorkingDirectory)\.packages -AzureDevOpsAccessToken $(dn-bot-dotnet-build-rw-code-rw) ${{ parameters.additionalParameters }} displayName: Execute SDL @@ -73,7 +73,7 @@ steps: flattenFolders: true sourceFolder: $(Agent.BuildDirectory)/.gdn/rc/ contents: '**/*.sarif' - targetFolder: $(Build.SourcesDirectory)/CodeAnalysisLogs + targetFolder: $(System.DefaultWorkingDirectory)/CodeAnalysisLogs condition: succeededOrFailed() # Use PublishBuildArtifacts because the SARIF extension only checks this case @@ -81,6 +81,6 @@ steps: - task: PublishBuildArtifacts@1 displayName: Publish SARIF files to CodeAnalysisLogs container inputs: - pathToPublish: $(Build.SourcesDirectory)/CodeAnalysisLogs + pathToPublish: $(System.DefaultWorkingDirectory)/CodeAnalysisLogs artifactName: CodeAnalysisLogs condition: succeededOrFailed() \ No newline at end of file diff --git a/eng/common/templates-official/steps/generate-sbom.yml b/eng/common/templates-official/steps/generate-sbom.yml index daf0957b68d762..1536353566c770 100644 --- a/eng/common/templates-official/steps/generate-sbom.yml +++ b/eng/common/templates-official/steps/generate-sbom.yml @@ -6,7 +6,7 @@ parameters: PackageVersion: 8.0.0 - BuildDropPath: '$(Build.SourcesDirectory)/artifacts' + BuildDropPath: '$(System.DefaultWorkingDirectory)/artifacts' PackageName: '.NET' ManifestDirPath: $(Build.ArtifactStagingDirectory)/sbom IgnoreDirectories: '' diff --git a/eng/common/templates-official/steps/publish-logs.yml b/eng/common/templates-official/steps/publish-logs.yml index 04012fed182a1f..af5a40b64c4bab 100644 --- a/eng/common/templates-official/steps/publish-logs.yml +++ b/eng/common/templates-official/steps/publish-logs.yml @@ -8,15 +8,15 @@ steps: inputs: targetType: inline script: | - New-Item -ItemType Directory $(Build.SourcesDirectory)/PostBuildLogs/${{parameters.StageLabel}}/${{parameters.JobLabel}}/ - Move-Item -Path $(Build.SourcesDirectory)/artifacts/log/Debug/* $(Build.SourcesDirectory)/PostBuildLogs/${{parameters.StageLabel}}/${{parameters.JobLabel}}/ + New-Item -ItemType Directory $(System.DefaultWorkingDirectory)/PostBuildLogs/${{parameters.StageLabel}}/${{parameters.JobLabel}}/ + Move-Item -Path $(System.DefaultWorkingDirectory)/artifacts/log/Debug/* $(System.DefaultWorkingDirectory)/PostBuildLogs/${{parameters.StageLabel}}/${{parameters.JobLabel}}/ continueOnError: true condition: always() - task: 1ES.PublishBuildArtifacts@1 displayName: Publish Logs inputs: - PathtoPublish: '$(Build.SourcesDirectory)/PostBuildLogs' + PathtoPublish: '$(System.DefaultWorkingDirectory)/PostBuildLogs' PublishLocation: Container ArtifactName: PostBuildLogs continueOnError: true diff --git a/eng/common/templates-official/steps/source-build.yml b/eng/common/templates-official/steps/source-build.yml index 829f17c34d118c..b63043da4b9f3f 100644 --- a/eng/common/templates-official/steps/source-build.yml +++ b/eng/common/templates-official/steps/source-build.yml @@ -12,6 +12,9 @@ parameters: # the usage of the properties on this object is split between the 'job' and 'steps' templates. platform: {} + # Optional list of directories to ignore for component governance scans. + cgIgnoreDirectories: [] + steps: # Build. Keep it self-contained for simple reusability. (No source-build-specific job variables.) - script: | @@ -26,8 +29,8 @@ steps: internalRestoreArgs= if [ '$(dn-bot-dnceng-artifact-feeds-rw)' != '$''(dn-bot-dnceng-artifact-feeds-rw)' ]; then # Temporarily work around https://github.com/dotnet/arcade/issues/7709 - chmod +x $(Build.SourcesDirectory)/eng/common/SetupNugetSources.sh - $(Build.SourcesDirectory)/eng/common/SetupNugetSources.sh $(Build.SourcesDirectory)/NuGet.config $(dn-bot-dnceng-artifact-feeds-rw) + chmod +x $(System.DefaultWorkingDirectory)/eng/common/SetupNugetSources.sh + $(System.DefaultWorkingDirectory)/eng/common/SetupNugetSources.sh $(System.DefaultWorkingDirectory)/NuGet.config $(dn-bot-dnceng-artifact-feeds-rw) internalRestoreArgs='/p:CopyWipIntoInnerSourceBuildRepo=true' # The 'Copy WIP' feature of source build uses git stash to apply changes from the original repo. @@ -101,7 +104,7 @@ steps: - task: CopyFiles@2 displayName: Prepare BuildLogs staging directory inputs: - SourceFolder: '$(Build.SourcesDirectory)' + SourceFolder: '$(System.DefaultWorkingDirectory)' Contents: | **/*.log **/*.binlog @@ -126,4 +129,7 @@ steps: - task: ComponentGovernanceComponentDetection@0 displayName: Component Detection (Exclude upstream cache) inputs: - ignoreDirectories: '$(Build.SourcesDirectory)/artifacts/source-build/self/src/artifacts/obj/source-built-upstream-cache' + ${{ if eq(length(parameters.cgIgnoreDirectories), 0) }}: + ignoreDirectories: '$(System.DefaultWorkingDirectory)/artifacts/source-build/self/src/artifacts/obj/source-built-upstream-cache' + ${{ else }}: + ignoreDirectories: ${{ join(',', parameters.cgIgnoreDirectories) }} diff --git a/eng/common/templates-official/variables/sdl-variables.yml b/eng/common/templates-official/variables/sdl-variables.yml index dbdd66d4a4b3a0..f1311bbb1b33d9 100644 --- a/eng/common/templates-official/variables/sdl-variables.yml +++ b/eng/common/templates-official/variables/sdl-variables.yml @@ -4,4 +4,4 @@ variables: - name: DefaultGuardianVersion value: 0.109.0 - name: GuardianPackagesConfigFile - value: $(Build.SourcesDirectory)\eng\common\sdl\packages.config \ No newline at end of file + value: $(System.DefaultWorkingDirectory)\eng\common\sdl\packages.config \ No newline at end of file diff --git a/eng/common/templates/job/job.yml b/eng/common/templates/job/job.yml index e295031c0985e9..80454d5a5587e8 100644 --- a/eng/common/templates/job/job.yml +++ b/eng/common/templates/job/job.yml @@ -37,7 +37,7 @@ parameters: # Sbom related params enableSbom: true PackageVersion: 7.0.0 - BuildDropPath: '$(Build.SourcesDirectory)/artifacts' + BuildDropPath: '$(System.DefaultWorkingDirectory)/artifacts' jobs: - job: ${{ parameters.name }} @@ -134,6 +134,10 @@ jobs: signType: $(_SignType) zipSources: false feedSource: https://dnceng.pkgs.visualstudio.com/_packaging/MicroBuildToolset/nuget/v3/index.json + ${{ if eq(variables['System.TeamProject'], 'DevDiv') }}: + ConnectedPMEServiceName: 6cc74545-d7b9-4050-9dfa-ebefcc8961ea + ${{ else }}: + ConnectedPMEServiceName: 248d384a-b39b-46e3-8ad5-c2c210d5e7ca env: TeamName: $(_TeamName) continueOnError: ${{ parameters.continueOnError }} @@ -159,7 +163,7 @@ jobs: inputs: languages: ${{ coalesce(parameters.richCodeNavigationLanguage, 'csharp') }} environment: ${{ coalesce(parameters.richCodeNavigationEnvironment, 'production') }} - richNavLogOutputDirectory: $(Build.SourcesDirectory)/artifacts/bin + richNavLogOutputDirectory: $(System.DefaultWorkingDirectory)/artifacts/bin uploadRichNavArtifacts: ${{ coalesce(parameters.richCodeNavigationUploadArtifacts, false) }} continueOnError: true @@ -216,7 +220,7 @@ jobs: - task: PublishBuildArtifacts@1 displayName: Publish Logs inputs: - PathtoPublish: '$(Build.SourcesDirectory)/artifacts/log/$(_BuildConfig)' + PathtoPublish: '$(System.DefaultWorkingDirectory)/artifacts/log/$(_BuildConfig)' PublishLocation: Container ArtifactName: ${{ coalesce(parameters.enablePublishBuildArtifacts.artifactName, '$(Agent.Os)_$(Agent.JobName)' ) }} continueOnError: true @@ -228,7 +232,7 @@ jobs: inputs: testResultsFormat: 'xUnit' testResultsFiles: '*.xml' - searchFolder: '$(Build.SourcesDirectory)/artifacts/TestResults/$(_BuildConfig)' + searchFolder: '$(System.DefaultWorkingDirectory)/artifacts/TestResults/$(_BuildConfig)' testRunTitle: ${{ coalesce(parameters.testRunTitle, parameters.name, '$(System.JobName)') }}-xunit mergeTestResults: ${{ parameters.mergeTestResults }} continueOnError: true @@ -239,7 +243,7 @@ jobs: inputs: testResultsFormat: 'VSTest' testResultsFiles: '*.trx' - searchFolder: '$(Build.SourcesDirectory)/artifacts/TestResults/$(_BuildConfig)' + searchFolder: '$(System.DefaultWorkingDirectory)/artifacts/TestResults/$(_BuildConfig)' testRunTitle: ${{ coalesce(parameters.testRunTitle, parameters.name, '$(System.JobName)') }}-trx mergeTestResults: ${{ parameters.mergeTestResults }} continueOnError: true @@ -253,7 +257,7 @@ jobs: IgnoreDirectories: ${{ parameters.componentGovernanceIgnoreDirectories }} - ${{ if eq(parameters.enableBuildRetry, 'true') }}: - - publish: $(Build.SourcesDirectory)\eng\common\BuildConfiguration + - publish: $(System.DefaultWorkingDirectory)\eng\common\BuildConfiguration artifact: BuildConfiguration displayName: Publish build retry configuration continueOnError: true diff --git a/eng/common/templates/job/onelocbuild.yml b/eng/common/templates/job/onelocbuild.yml index 60ab00c4de3acd..2cd3840c992720 100644 --- a/eng/common/templates/job/onelocbuild.yml +++ b/eng/common/templates/job/onelocbuild.yml @@ -8,7 +8,7 @@ parameters: CeapexPat: $(dn-bot-ceapex-package-r) # PAT for the loc AzDO instance https://dev.azure.com/ceapex GithubPat: $(BotAccount-dotnet-bot-repo-PAT) - SourcesDirectory: $(Build.SourcesDirectory) + SourcesDirectory: $(System.DefaultWorkingDirectory) CreatePr: true AutoCompletePr: false ReusePr: true @@ -60,7 +60,7 @@ jobs: - ${{ if ne(parameters.SkipLocProjectJsonGeneration, 'true') }}: - task: Powershell@2 inputs: - filePath: $(Build.SourcesDirectory)/eng/common/generate-locproject.ps1 + filePath: $(System.DefaultWorkingDirectory)/eng/common/generate-locproject.ps1 arguments: $(_GenerateLocProjectArguments) displayName: Generate LocProject.json condition: ${{ parameters.condition }} @@ -103,7 +103,7 @@ jobs: - task: PublishBuildArtifacts@1 displayName: Publish LocProject.json inputs: - PathtoPublish: '$(Build.SourcesDirectory)/eng/Localize/' + PathtoPublish: '$(System.DefaultWorkingDirectory)/eng/Localize/' PublishLocation: Container ArtifactName: Loc condition: ${{ parameters.condition }} \ No newline at end of file diff --git a/eng/common/templates/job/publish-build-assets.yml b/eng/common/templates/job/publish-build-assets.yml index cc2b346ba8baf0..2956d8117f73c0 100644 --- a/eng/common/templates/job/publish-build-assets.yml +++ b/eng/common/templates/job/publish-build-assets.yml @@ -30,6 +30,8 @@ parameters: signingValidationAdditionalParameters: '' + repositoryAlias: self + jobs: - job: Asset_Registry_Publish @@ -63,6 +65,9 @@ jobs: steps: - ${{ if and(eq(parameters.runAsPublic, 'false'), ne(variables['System.TeamProject'], 'public'), notin(variables['Build.Reason'], 'PullRequest')) }}: + - checkout: ${{ parameters.repositoryAlias }} + fetchDepth: 3 + clean: true - task: DownloadBuildArtifacts@0 displayName: Download artifact inputs: @@ -80,7 +85,7 @@ jobs: azureSubscription: "Darc: Maestro Production" scriptType: ps scriptLocation: scriptPath - scriptPath: $(Build.SourcesDirectory)/eng/common/sdk-task.ps1 + scriptPath: $(System.DefaultWorkingDirectory)/eng/common/sdk-task.ps1 arguments: > -task PublishBuildAssets -restore -msbuildEngine dotnet /p:ManifestsPath='$(Build.StagingDirectory)/Download/AssetManifests' @@ -111,7 +116,7 @@ jobs: inputs: targetType: inline script: | - $symbolExclusionfile = "$(Build.SourcesDirectory)/eng/SymbolPublishingExclusionsFile.txt" + $symbolExclusionfile = "$(System.DefaultWorkingDirectory)/eng/SymbolPublishingExclusionsFile.txt" if(Test-Path -Path $symbolExclusionfile) { Write-Host "SymbolExclusionFile exists" @@ -126,7 +131,7 @@ jobs: displayName: Publish SymbolPublishingExclusionsFile Artifact condition: eq(variables['SymbolExclusionFile'], 'true') inputs: - PathtoPublish: '$(Build.SourcesDirectory)/eng/SymbolPublishingExclusionsFile.txt' + PathtoPublish: '$(System.DefaultWorkingDirectory)/eng/SymbolPublishingExclusionsFile.txt' PublishLocation: Container ArtifactName: ReleaseConfigs @@ -142,7 +147,7 @@ jobs: azureSubscription: "Darc: Maestro Production" scriptType: ps scriptLocation: scriptPath - scriptPath: $(Build.SourcesDirectory)/eng/common/post-build/publish-using-darc.ps1 + scriptPath: $(System.DefaultWorkingDirectory)/eng/common/post-build/publish-using-darc.ps1 arguments: -BuildId $(BARBuildId) -PublishingInfraVersion 3 -AzdoToken '$(System.AccessToken)' diff --git a/eng/common/templates/job/source-build.yml b/eng/common/templates/job/source-build.yml index c48f95d93d916e..97021335cfc40b 100644 --- a/eng/common/templates/job/source-build.yml +++ b/eng/common/templates/job/source-build.yml @@ -31,6 +31,9 @@ parameters: # container and pool. platform: {} + # Optional list of directories to ignore for component governance scans. + cgIgnoreDirectories: [] + # If set to true and running on a non-public project, # Internal blob storage locations will be enabled. # This is not enabled by default because many repositories do not need internal sources @@ -72,3 +75,4 @@ jobs: - template: /eng/common/templates/steps/source-build.yml parameters: platform: ${{ parameters.platform }} + cgIgnoreDirectories: ${{ parameters.cgIgnoreDirectories }} diff --git a/eng/common/templates/job/source-index-stage1.yml b/eng/common/templates/job/source-index-stage1.yml index 8538f44bab28b7..81606fd9a541e6 100644 --- a/eng/common/templates/job/source-index-stage1.yml +++ b/eng/common/templates/job/source-index-stage1.yml @@ -58,7 +58,7 @@ jobs: - script: ${{ parameters.sourceIndexBuildCommand }} displayName: Build Repository - - script: $(Agent.TempDirectory)/.source-index/tools/BinLogToSln -i $(BinlogPath) -r $(Build.SourcesDirectory) -n $(Build.Repository.Name) -o .source-index/stage1output + - script: $(Agent.TempDirectory)/.source-index/tools/BinLogToSln -i $(BinlogPath) -r $(System.DefaultWorkingDirectory) -n $(Build.Repository.Name) -o .source-index/stage1output displayName: Process Binlog into indexable sln - ${{ if and(eq(parameters.runAsPublic, 'false'), ne(variables['System.TeamProject'], 'public'), notin(variables['Build.Reason'], 'PullRequest')) }}: diff --git a/eng/common/templates/jobs/codeql-build.yml b/eng/common/templates/jobs/codeql-build.yml index f7dc5ea4aaa63c..e8b43e3b4cba16 100644 --- a/eng/common/templates/jobs/codeql-build.yml +++ b/eng/common/templates/jobs/codeql-build.yml @@ -23,7 +23,7 @@ jobs: - name: DefaultGuardianVersion value: 0.109.0 - name: GuardianPackagesConfigFile - value: $(Build.SourcesDirectory)\eng\common\sdl\packages.config + value: $(System.DefaultWorkingDirectory)\eng\common\sdl\packages.config - name: GuardianVersion value: ${{ coalesce(parameters.overrideGuardianVersion, '$(DefaultGuardianVersion)') }} diff --git a/eng/common/templates/jobs/jobs.yml b/eng/common/templates/jobs/jobs.yml index 289bb2396ce83e..34387a8c7acddc 100644 --- a/eng/common/templates/jobs/jobs.yml +++ b/eng/common/templates/jobs/jobs.yml @@ -40,6 +40,7 @@ parameters: enableSourceIndex: false sourceIndexParams: {} + repositoryAlias: self # Internal resources (telemetry, microbuild) can only be accessed from non-public projects, # and some (Microbuild) should only be applied to non-PR cases for internal builds. @@ -95,3 +96,4 @@ jobs: enablePublishBuildArtifacts: ${{ parameters.enablePublishBuildArtifacts }} artifactsPublishingAdditionalParameters: ${{ parameters.artifactsPublishingAdditionalParameters }} signingValidationAdditionalParameters: ${{ parameters.signingValidationAdditionalParameters }} + repositoryAlias: ${{ parameters.repositoryAlias }} diff --git a/eng/common/templates/jobs/source-build.yml b/eng/common/templates/jobs/source-build.yml index 3ec997108107bc..4dde599add977d 100644 --- a/eng/common/templates/jobs/source-build.yml +++ b/eng/common/templates/jobs/source-build.yml @@ -21,6 +21,9 @@ parameters: # one job runs on 'defaultManagedPlatform'. platforms: [] + # Optional list of directories to ignore for component governance scans. + cgIgnoreDirectories: [] + # If set to true and running on a non-public project, # Internal nuget and blob storage locations will be enabled. # This is not enabled by default because many repositories do not need internal sources @@ -44,6 +47,7 @@ jobs: parameters: jobNamePrefix: ${{ parameters.jobNamePrefix }} platform: ${{ platform }} + cgIgnoreDirectories: ${{ parameters.cgIgnoreDirectories }} enableInternalSources: ${{ parameters.enableInternalSources }} - ${{ if eq(length(parameters.platforms), 0) }}: @@ -51,4 +55,5 @@ jobs: parameters: jobNamePrefix: ${{ parameters.jobNamePrefix }} platform: ${{ parameters.defaultManagedPlatform }} + cgIgnoreDirectories: ${{ parameters.cgIgnoreDirectories }} enableInternalSources: ${{ parameters.enableInternalSources }} diff --git a/eng/common/templates/post-build/post-build.yml b/eng/common/templates/post-build/post-build.yml index c3b6a3012fee18..6e5722dc2e1795 100644 --- a/eng/common/templates/post-build/post-build.yml +++ b/eng/common/templates/post-build/post-build.yml @@ -130,7 +130,7 @@ stages: - task: PowerShell@2 displayName: Validate inputs: - filePath: $(Build.SourcesDirectory)/eng/common/post-build/nuget-validation.ps1 + filePath: $(System.DefaultWorkingDirectory)/eng/common/post-build/nuget-validation.ps1 arguments: -PackagesPath $(Build.ArtifactStagingDirectory)/PackageArtifacts/ -ToolDestinationPath $(Agent.BuildDirectory)/Extract/ @@ -180,7 +180,7 @@ stages: filePath: eng\common\sdk-task.ps1 arguments: -task SigningValidation -restore -msbuildEngine vs /p:PackageBasePath='$(Build.ArtifactStagingDirectory)/PackageArtifacts' - /p:SignCheckExclusionsFile='$(Build.SourcesDirectory)/eng/SignCheckExclusionsFile.txt' + /p:SignCheckExclusionsFile='$(System.DefaultWorkingDirectory)/eng/SignCheckExclusionsFile.txt' ${{ parameters.signingValidationAdditionalParameters }} - template: ../steps/publish-logs.yml @@ -220,7 +220,7 @@ stages: - task: PowerShell@2 displayName: Validate inputs: - filePath: $(Build.SourcesDirectory)/eng/common/post-build/sourcelink-validation.ps1 + filePath: $(System.DefaultWorkingDirectory)/eng/common/post-build/sourcelink-validation.ps1 arguments: -InputPath $(Build.ArtifactStagingDirectory)/BlobArtifacts/ -ExtractPath $(Agent.BuildDirectory)/Extract/ -GHRepoName $(Build.Repository.Name) @@ -274,7 +274,7 @@ stages: azureSubscription: "Darc: Maestro Production" scriptType: ps scriptLocation: scriptPath - scriptPath: $(Build.SourcesDirectory)/eng/common/post-build/publish-using-darc.ps1 + scriptPath: $(System.DefaultWorkingDirectory)/eng/common/post-build/publish-using-darc.ps1 arguments: -BuildId $(BARBuildId) -PublishingInfraVersion ${{ parameters.publishingInfraVersion }} -AzdoToken '$(System.AccessToken)' diff --git a/eng/common/templates/post-build/setup-maestro-vars.yml b/eng/common/templates/post-build/setup-maestro-vars.yml index 64b9abc6850474..4347fa80b68455 100644 --- a/eng/common/templates/post-build/setup-maestro-vars.yml +++ b/eng/common/templates/post-build/setup-maestro-vars.yml @@ -32,7 +32,7 @@ steps: $AzureDevOpsBuildId = $Env:Build_BuildId } else { - . $(Build.SourcesDirectory)\eng\common\tools.ps1 + . $(System.DefaultWorkingDirectory)\eng\common\tools.ps1 $darc = Get-Darc $buildInfo = & $darc get-build ` --id ${{ parameters.BARBuildId }} ` diff --git a/eng/common/templates/post-build/trigger-subscription.yml b/eng/common/templates/post-build/trigger-subscription.yml index da669030daf6e9..52df7077482856 100644 --- a/eng/common/templates/post-build/trigger-subscription.yml +++ b/eng/common/templates/post-build/trigger-subscription.yml @@ -5,7 +5,7 @@ steps: - task: PowerShell@2 displayName: Triggering subscriptions inputs: - filePath: $(Build.SourcesDirectory)/eng/common/post-build/trigger-subscriptions.ps1 + filePath: $(System.DefaultWorkingDirectory)/eng/common/post-build/trigger-subscriptions.ps1 arguments: -SourceRepo $(Build.Repository.Uri) -ChannelId ${{ parameters.ChannelId }} -MaestroApiAccessToken $(MaestroAccessToken) diff --git a/eng/common/templates/steps/add-build-to-channel.yml b/eng/common/templates/steps/add-build-to-channel.yml index f67a210d62f3e5..5b6fec257ea7fd 100644 --- a/eng/common/templates/steps/add-build-to-channel.yml +++ b/eng/common/templates/steps/add-build-to-channel.yml @@ -5,7 +5,7 @@ steps: - task: PowerShell@2 displayName: Add Build to Channel inputs: - filePath: $(Build.SourcesDirectory)/eng/common/post-build/add-build-to-channel.ps1 + filePath: $(System.DefaultWorkingDirectory)/eng/common/post-build/add-build-to-channel.ps1 arguments: -BuildId $(BARBuildId) -ChannelId ${{ parameters.ChannelId }} -MaestroApiAccessToken $(MaestroApiAccessToken) diff --git a/eng/common/templates/steps/execute-sdl.yml b/eng/common/templates/steps/execute-sdl.yml index fe0ebf8c904eb7..047e8281ebc05d 100644 --- a/eng/common/templates/steps/execute-sdl.yml +++ b/eng/common/templates/steps/execute-sdl.yml @@ -15,17 +15,17 @@ steps: - ${{ if ne(parameters.overrideGuardianVersion, '') }}: - pwsh: | - Set-Location -Path $(Build.SourcesDirectory)\eng\common\sdl + Set-Location -Path $(System.DefaultWorkingDirectory)\eng\common\sdl . .\sdl.ps1 - $guardianCliLocation = Install-Gdn -Path $(Build.SourcesDirectory)\.artifacts -Version ${{ parameters.overrideGuardianVersion }} + $guardianCliLocation = Install-Gdn -Path $(System.DefaultWorkingDirectory)\.artifacts -Version ${{ parameters.overrideGuardianVersion }} Write-Host "##vso[task.setvariable variable=GuardianCliLocation]$guardianCliLocation" displayName: Install Guardian (Overridden) - ${{ if eq(parameters.overrideGuardianVersion, '') }}: - pwsh: | - Set-Location -Path $(Build.SourcesDirectory)\eng\common\sdl + Set-Location -Path $(System.DefaultWorkingDirectory)\eng\common\sdl . .\sdl.ps1 - $guardianCliLocation = Install-Gdn -Path $(Build.SourcesDirectory)\.artifacts + $guardianCliLocation = Install-Gdn -Path $(System.DefaultWorkingDirectory)\.artifacts Write-Host "##vso[task.setvariable variable=GuardianCliLocation]$guardianCliLocation" displayName: Install Guardian @@ -40,7 +40,7 @@ steps: - ${{ if eq(parameters.overrideParameters, '') }}: - powershell: ${{ parameters.executeAllSdlToolsScript }} -GuardianCliLocation $(GuardianCliLocation) - -NugetPackageDirectory $(Build.SourcesDirectory)\.packages + -NugetPackageDirectory $(System.DefaultWorkingDirectory)\.packages ${{ parameters.additionalParameters }} displayName: Execute SDL continueOnError: ${{ parameters.sdlContinueOnError }} @@ -76,7 +76,7 @@ steps: flattenFolders: true sourceFolder: $(Agent.BuildDirectory)/.gdn/rc/ contents: '**/*.sarif' - targetFolder: $(Build.SourcesDirectory)/CodeAnalysisLogs + targetFolder: $(System.DefaultWorkingDirectory)/CodeAnalysisLogs condition: succeededOrFailed() # Use PublishBuildArtifacts because the SARIF extension only checks this case @@ -84,6 +84,6 @@ steps: - task: PublishBuildArtifacts@1 displayName: Publish SARIF files to CodeAnalysisLogs container inputs: - pathToPublish: $(Build.SourcesDirectory)/CodeAnalysisLogs + pathToPublish: $(System.DefaultWorkingDirectory)/CodeAnalysisLogs artifactName: CodeAnalysisLogs condition: succeededOrFailed() \ No newline at end of file diff --git a/eng/common/templates/steps/generate-sbom.yml b/eng/common/templates/steps/generate-sbom.yml index 2b21eae4273288..b1fe8b3944b348 100644 --- a/eng/common/templates/steps/generate-sbom.yml +++ b/eng/common/templates/steps/generate-sbom.yml @@ -6,7 +6,7 @@ parameters: PackageVersion: 8.0.0 - BuildDropPath: '$(Build.SourcesDirectory)/artifacts' + BuildDropPath: '$(System.DefaultWorkingDirectory)/artifacts' PackageName: '.NET' ManifestDirPath: $(Build.ArtifactStagingDirectory)/sbom IgnoreDirectories: '' diff --git a/eng/common/templates/steps/publish-logs.yml b/eng/common/templates/steps/publish-logs.yml index 88f238f36bfd8d..e2f8413d8e19c6 100644 --- a/eng/common/templates/steps/publish-logs.yml +++ b/eng/common/templates/steps/publish-logs.yml @@ -8,15 +8,15 @@ steps: inputs: targetType: inline script: | - New-Item -ItemType Directory $(Build.SourcesDirectory)/PostBuildLogs/${{parameters.StageLabel}}/${{parameters.JobLabel}}/ - Move-Item -Path $(Build.SourcesDirectory)/artifacts/log/Debug/* $(Build.SourcesDirectory)/PostBuildLogs/${{parameters.StageLabel}}/${{parameters.JobLabel}}/ + New-Item -ItemType Directory $(System.DefaultWorkingDirectory)/PostBuildLogs/${{parameters.StageLabel}}/${{parameters.JobLabel}}/ + Move-Item -Path $(System.DefaultWorkingDirectory)/artifacts/log/Debug/* $(System.DefaultWorkingDirectory)/PostBuildLogs/${{parameters.StageLabel}}/${{parameters.JobLabel}}/ continueOnError: true condition: always() - task: PublishBuildArtifacts@1 displayName: Publish Logs inputs: - PathtoPublish: '$(Build.SourcesDirectory)/PostBuildLogs' + PathtoPublish: '$(System.DefaultWorkingDirectory)/PostBuildLogs' PublishLocation: Container ArtifactName: PostBuildLogs continueOnError: true diff --git a/eng/common/templates/steps/source-build.yml b/eng/common/templates/steps/source-build.yml index 41bbb915736a6e..ae06b26ea37340 100644 --- a/eng/common/templates/steps/source-build.yml +++ b/eng/common/templates/steps/source-build.yml @@ -12,6 +12,9 @@ parameters: # the usage of the properties on this object is split between the 'job' and 'steps' templates. platform: {} + # Optional list of directories to ignore for component governance scans. + cgIgnoreDirectories: [] + steps: # Build. Keep it self-contained for simple reusability. (No source-build-specific job variables.) - script: | @@ -26,8 +29,8 @@ steps: internalRestoreArgs= if [ '$(dn-bot-dnceng-artifact-feeds-rw)' != '$''(dn-bot-dnceng-artifact-feeds-rw)' ]; then # Temporarily work around https://github.com/dotnet/arcade/issues/7709 - chmod +x $(Build.SourcesDirectory)/eng/common/SetupNugetSources.sh - $(Build.SourcesDirectory)/eng/common/SetupNugetSources.sh $(Build.SourcesDirectory)/NuGet.config $(dn-bot-dnceng-artifact-feeds-rw) + chmod +x $(System.DefaultWorkingDirectory)/eng/common/SetupNugetSources.sh + $(System.DefaultWorkingDirectory)/eng/common/SetupNugetSources.sh $(System.DefaultWorkingDirectory)/NuGet.config $(dn-bot-dnceng-artifact-feeds-rw) internalRestoreArgs='/p:CopyWipIntoInnerSourceBuildRepo=true' # The 'Copy WIP' feature of source build uses git stash to apply changes from the original repo. @@ -101,7 +104,7 @@ steps: - task: CopyFiles@2 displayName: Prepare BuildLogs staging directory inputs: - SourceFolder: '$(Build.SourcesDirectory)' + SourceFolder: '$(System.DefaultWorkingDirectory)' Contents: | **/*.log **/*.binlog @@ -126,4 +129,7 @@ steps: - task: ComponentGovernanceComponentDetection@0 displayName: Component Detection (Exclude upstream cache) inputs: - ignoreDirectories: '$(Build.SourcesDirectory)/artifacts/source-build/self/src/artifacts/obj/source-built-upstream-cache' + ${{ if eq(length(parameters.cgIgnoreDirectories), 0) }}: + ignoreDirectories: '$(System.DefaultWorkingDirectory)/artifacts/source-build/self/src/artifacts/obj/source-built-upstream-cache' + ${{ else }}: + ignoreDirectories: ${{ join(',', parameters.cgIgnoreDirectories) }} diff --git a/eng/common/templates/variables/sdl-variables.yml b/eng/common/templates/variables/sdl-variables.yml index dbdd66d4a4b3a0..f1311bbb1b33d9 100644 --- a/eng/common/templates/variables/sdl-variables.yml +++ b/eng/common/templates/variables/sdl-variables.yml @@ -4,4 +4,4 @@ variables: - name: DefaultGuardianVersion value: 0.109.0 - name: GuardianPackagesConfigFile - value: $(Build.SourcesDirectory)\eng\common\sdl\packages.config \ No newline at end of file + value: $(System.DefaultWorkingDirectory)\eng\common\sdl\packages.config \ No newline at end of file diff --git a/eng/common/tools.ps1 b/eng/common/tools.ps1 index 82b2798ba307d5..bb048ad125a8cf 100644 --- a/eng/common/tools.ps1 +++ b/eng/common/tools.ps1 @@ -417,7 +417,7 @@ function InitializeVisualStudioMSBuild([bool]$install, [object]$vsRequirements = # Locate Visual Studio installation or download x-copy msbuild. $vsInfo = LocateVisualStudio $vsRequirements - if ($vsInfo -ne $null) { + if ($vsInfo -ne $null -and $env:ForceUseXCopyMSBuild -eq $null) { # Ensure vsInstallDir has a trailing slash $vsInstallDir = Join-Path $vsInfo.installationPath "\" $vsMajorVersion = $vsInfo.installationVersion.Split('.')[0] diff --git a/global.json b/global.json index fef3993456c853..a5c4619b098036 100644 --- a/global.json +++ b/global.json @@ -1,16 +1,16 @@ { "sdk": { - "version": "8.0.117", + "version": "8.0.120", "allowPrerelease": true, "rollForward": "major" }, "tools": { - "dotnet": "8.0.117" + "dotnet": "8.0.120" }, "msbuild-sdks": { - "Microsoft.DotNet.Arcade.Sdk": "8.0.0-beta.25310.3", - "Microsoft.DotNet.Helix.Sdk": "8.0.0-beta.25310.3", - "Microsoft.DotNet.SharedFramework.Sdk": "8.0.0-beta.25310.3", + "Microsoft.DotNet.Arcade.Sdk": "8.0.0-beta.25461.1", + "Microsoft.DotNet.Helix.Sdk": "8.0.0-beta.25461.1", + "Microsoft.DotNet.SharedFramework.Sdk": "8.0.0-beta.25461.1", "Microsoft.Build.NoTargets": "3.7.0", "Microsoft.Build.Traversal": "3.4.0", "Microsoft.NET.Sdk.IL": "8.0.0-rc.1.23406.6" From 50eb2465f79222bf5229c9ce2c60c01e01c8b051 Mon Sep 17 00:00:00 2001 From: "dotnet-maestro[bot]" <42748379+dotnet-maestro[bot]@users.noreply.github.com> Date: Mon, 15 Sep 2025 08:46:05 -0700 Subject: [PATCH 14/20] Update dependencies from https://github.com/dotnet/icu build 20250912.1 (#119676) On relative base path root Microsoft.NETCore.Runtime.ICU.Transport From Version 8.0.0-rtm.25408.1 -> To Version 8.0.0-rtm.25462.1 Co-authored-by: dotnet-maestro[bot] --- eng/Version.Details.xml | 4 ++-- eng/Versions.props | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/eng/Version.Details.xml b/eng/Version.Details.xml index a7c6ccef802cc1..fb0e05cc315c98 100644 --- a/eng/Version.Details.xml +++ b/eng/Version.Details.xml @@ -1,8 +1,8 @@ - + https://github.com/dotnet/icu - 9392a78454c1978e7b19c50d85e85c57550399e1 + 5ec8e0c36b1fb327e93f6ad5c26306c4c1423421 https://github.com/dotnet/msquic diff --git a/eng/Versions.props b/eng/Versions.props index 98274f22f8d960..aa1ed6123589ed 100644 --- a/eng/Versions.props +++ b/eng/Versions.props @@ -229,7 +229,7 @@ 8.0.0-rc.1.23406.6 - 8.0.0-rtm.25408.1 + 8.0.0-rtm.25462.1 2.4.8 8.0.0-alpha.1.23527.1 From 1e20b7b5df6c4405ccf99a891376999135380b5c Mon Sep 17 00:00:00 2001 From: Kevin Jones Date: Mon, 15 Sep 2025 18:54:01 -0400 Subject: [PATCH 15/20] Backport macOS 26 Tahoe test fixes to release/8.0-staging Backport dotnet/runtime#118652 Backport dotnet/runtime#118777 --- .../TestUtilities/System/PlatformDetection.Unix.cs | 1 + .../tests/X509Certificates/ChainTests.cs | 12 ++++++------ 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/src/libraries/Common/tests/TestUtilities/System/PlatformDetection.Unix.cs b/src/libraries/Common/tests/TestUtilities/System/PlatformDetection.Unix.cs index 18b1e0461cf670..17aa423c3aaebb 100644 --- a/src/libraries/Common/tests/TestUtilities/System/PlatformDetection.Unix.cs +++ b/src/libraries/Common/tests/TestUtilities/System/PlatformDetection.Unix.cs @@ -43,6 +43,7 @@ public static partial class PlatformDetection public static bool IsNotMacOsAppleSilicon => !IsMacOsAppleSilicon; public static bool IsAppSandbox => Environment.GetEnvironmentVariable("APP_SANDBOX_CONTAINER_ID") != null; public static bool IsNotAppSandbox => !IsAppSandbox; + public static bool IsApplePlatform26OrLater => IsOSXLike && Environment.OSVersion.Version.Major >= 26; // RedHat family covers RedHat and CentOS public static bool IsRedHatFamily => IsRedHatFamilyAndVersion(); diff --git a/src/libraries/System.Security.Cryptography/tests/X509Certificates/ChainTests.cs b/src/libraries/System.Security.Cryptography/tests/X509Certificates/ChainTests.cs index 200f6fdbf30916..e3e39b73f429f6 100644 --- a/src/libraries/System.Security.Cryptography/tests/X509Certificates/ChainTests.cs +++ b/src/libraries/System.Security.Cryptography/tests/X509Certificates/ChainTests.cs @@ -288,13 +288,13 @@ public static void SystemTrustCertificateWithCustomRootTrust(bool addCertificate // Check some known conditions. - if (PlatformDetection.UsesAppleCrypto) + if (OperatingSystem.IsLinux() || PlatformDetection.IsApplePlatform26OrLater) { - Assert.Equal(3, chain.ChainElements.Count); + Assert.Equal(2, chain.ChainElements.Count); } - else if (OperatingSystem.IsLinux()) + else if (PlatformDetection.IsOSXLike) { - Assert.Equal(2, chain.ChainElements.Count); + Assert.Equal(3, chain.ChainElements.Count); } } } @@ -1179,12 +1179,12 @@ public static void BuildChainForCertificateSignedWithDisallowedKey() chain.ChainPolicy.ExtraStore.Add(intermediateCert); Assert.False(chain.Build(cert)); - if (PlatformDetection.IsAndroid) + if (PlatformDetection.IsAndroid || PlatformDetection.IsApplePlatform26OrLater) { // Android always validates trust as part of building a path, // so violations comes back as PartialChain with no elements + // Apple 26 no longer block these SKIs since the roots are no longer trusted at all and are expired. Assert.Equal(X509ChainStatusFlags.PartialChain, chain.AllStatusFlags()); - Assert.Equal(0, chain.ChainElements.Count); } else { From a4e2c0473013f4b12caeb10465dd4a35d14b3c2e Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Mon, 15 Sep 2025 23:22:13 +0000 Subject: [PATCH 16/20] Disable test parallelization in OleDB tests (#119627) Attempts to fix #87783 Co-authored-by: Shay Rojansky --- src/libraries/System.Data.OleDb/tests/AssemblyInfo.cs | 7 +++++++ 1 file changed, 7 insertions(+) create mode 100644 src/libraries/System.Data.OleDb/tests/AssemblyInfo.cs diff --git a/src/libraries/System.Data.OleDb/tests/AssemblyInfo.cs b/src/libraries/System.Data.OleDb/tests/AssemblyInfo.cs new file mode 100644 index 00000000000000..6349558b2d1c35 --- /dev/null +++ b/src/libraries/System.Data.OleDb/tests/AssemblyInfo.cs @@ -0,0 +1,7 @@ +// Licensed to the .NET Foundation under one or more agreements. +// The .NET Foundation licenses this file to you under the MIT license. + +using Xunit; + +// The OleDB tests use the ACE driver, which has issues with concurrency. +[assembly: CollectionBehavior(DisableTestParallelization = true)] From 0f343183826a6f04d089207c3c78aebb1ae971b6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alexander=20K=C3=B6plinger?= Date: Thu, 18 Sep 2025 17:46:49 +0200 Subject: [PATCH 17/20] Remove darc-pub-dotnet-runtime-488a8a3 feed from Wasm tests --- src/mono/wasi/Wasi.Build.Tests/data/nuget8.config | 5 ----- src/mono/wasm/Wasm.Build.Tests/data/nuget8.config | 5 ----- 2 files changed, 10 deletions(-) diff --git a/src/mono/wasi/Wasi.Build.Tests/data/nuget8.config b/src/mono/wasi/Wasi.Build.Tests/data/nuget8.config index 4c33988a4365b8..dfdc8009c6a5d5 100644 --- a/src/mono/wasi/Wasi.Build.Tests/data/nuget8.config +++ b/src/mono/wasi/Wasi.Build.Tests/data/nuget8.config @@ -9,11 +9,6 @@ - - - - - diff --git a/src/mono/wasm/Wasm.Build.Tests/data/nuget8.config b/src/mono/wasm/Wasm.Build.Tests/data/nuget8.config index 4c33988a4365b8..dfdc8009c6a5d5 100644 --- a/src/mono/wasm/Wasm.Build.Tests/data/nuget8.config +++ b/src/mono/wasm/Wasm.Build.Tests/data/nuget8.config @@ -9,11 +9,6 @@ - - - - - From a3a0f0f6b57001d22276475e7bebd784be6d4cc4 Mon Sep 17 00:00:00 2001 From: "dotnet-maestro[bot]" <42748379+dotnet-maestro[bot]@users.noreply.github.com> Date: Fri, 19 Sep 2025 19:26:21 -0700 Subject: [PATCH 18/20] Update dependencies from https://github.com/dotnet/icu build 20250916.3 (#119791) On relative base path root Microsoft.NETCore.Runtime.ICU.Transport From Version 8.0.0-rtm.25462.1 -> To Version 8.0.0-rtm.25466.3 Co-authored-by: dotnet-maestro[bot] Co-authored-by: Tanner Gooding --- eng/Version.Details.xml | 4 ++-- eng/Versions.props | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/eng/Version.Details.xml b/eng/Version.Details.xml index 41aedf3281b163..d2da1be6c827d6 100644 --- a/eng/Version.Details.xml +++ b/eng/Version.Details.xml @@ -1,8 +1,8 @@ - + https://github.com/dotnet/icu - 5ec8e0c36b1fb327e93f6ad5c26306c4c1423421 + 447bcbcb6d371d48d3e6e6fb31d2db0818301362 https://github.com/dotnet/msquic diff --git a/eng/Versions.props b/eng/Versions.props index 6bcaa89f459e06..91539b3b8a5c93 100644 --- a/eng/Versions.props +++ b/eng/Versions.props @@ -229,7 +229,7 @@ 8.0.0-rc.1.23406.6 - 8.0.0-rtm.25462.1 + 8.0.0-rtm.25466.3 2.4.8 8.0.0-alpha.1.23527.1 From eae31564614d87e7e3f236d15c99efa7f284623f Mon Sep 17 00:00:00 2001 From: "dotnet-maestro[bot]" <42748379+dotnet-maestro[bot]@users.noreply.github.com> Date: Sat, 20 Sep 2025 12:05:26 -0700 Subject: [PATCH 19/20] Update dependencies from https://github.com/dotnet/runtime-assets build 20250917.2 (#119829) On relative base path root Microsoft.DotNet.CilStrip.Sources , System.ComponentModel.TypeConverter.TestData , System.Data.Common.TestData , System.Drawing.Common.TestData , System.Formats.Tar.TestData , System.IO.Compression.TestData , System.IO.Packaging.TestData , System.Net.TestData , System.Private.Runtime.UnicodeData , System.Runtime.Numerics.TestData , System.Runtime.TimeZoneData , System.Security.Cryptography.X509Certificates.TestData , System.Text.RegularExpressions.TestData , System.Windows.Extensions.TestData From Version 8.0.0-beta.25414.3 -> To Version 8.0.0-beta.25467.2 Co-authored-by: dotnet-maestro[bot] Co-authored-by: Tanner Gooding --- eng/Version.Details.xml | 56 ++++++++++++++++++++--------------------- eng/Versions.props | 28 ++++++++++----------- 2 files changed, 42 insertions(+), 42 deletions(-) diff --git a/eng/Version.Details.xml b/eng/Version.Details.xml index d2da1be6c827d6..96a07507eff546 100644 --- a/eng/Version.Details.xml +++ b/eng/Version.Details.xml @@ -185,57 +185,57 @@ https://github.com/dotnet/arcade 958612453c58fd32328461580b19ce5ecf4aedd2 - + https://github.com/dotnet/runtime-assets - e8f3528a061b4f6b944f13ad87382d7964b46c7e + f636e4a569ad29a54e9672dffdb77a00c0c4a62a - + https://github.com/dotnet/runtime-assets - e8f3528a061b4f6b944f13ad87382d7964b46c7e + f636e4a569ad29a54e9672dffdb77a00c0c4a62a - + https://github.com/dotnet/runtime-assets - e8f3528a061b4f6b944f13ad87382d7964b46c7e + f636e4a569ad29a54e9672dffdb77a00c0c4a62a - + https://github.com/dotnet/runtime-assets - e8f3528a061b4f6b944f13ad87382d7964b46c7e + f636e4a569ad29a54e9672dffdb77a00c0c4a62a - + https://github.com/dotnet/runtime-assets - e8f3528a061b4f6b944f13ad87382d7964b46c7e + f636e4a569ad29a54e9672dffdb77a00c0c4a62a - + https://github.com/dotnet/runtime-assets - e8f3528a061b4f6b944f13ad87382d7964b46c7e + f636e4a569ad29a54e9672dffdb77a00c0c4a62a - + https://github.com/dotnet/runtime-assets - e8f3528a061b4f6b944f13ad87382d7964b46c7e + f636e4a569ad29a54e9672dffdb77a00c0c4a62a - + https://github.com/dotnet/runtime-assets - e8f3528a061b4f6b944f13ad87382d7964b46c7e + f636e4a569ad29a54e9672dffdb77a00c0c4a62a - + https://github.com/dotnet/runtime-assets - e8f3528a061b4f6b944f13ad87382d7964b46c7e + f636e4a569ad29a54e9672dffdb77a00c0c4a62a - + https://github.com/dotnet/runtime-assets - e8f3528a061b4f6b944f13ad87382d7964b46c7e + f636e4a569ad29a54e9672dffdb77a00c0c4a62a - + https://github.com/dotnet/runtime-assets - e8f3528a061b4f6b944f13ad87382d7964b46c7e + f636e4a569ad29a54e9672dffdb77a00c0c4a62a - + https://github.com/dotnet/runtime-assets - e8f3528a061b4f6b944f13ad87382d7964b46c7e + f636e4a569ad29a54e9672dffdb77a00c0c4a62a - + https://github.com/dotnet/runtime-assets - e8f3528a061b4f6b944f13ad87382d7964b46c7e + f636e4a569ad29a54e9672dffdb77a00c0c4a62a https://github.com/dotnet/llvm-project @@ -358,9 +358,9 @@ https://github.com/dotnet/hotreload-utils 4583778b38f71bc05962b9da38dd1e9ee17525e7 - + https://github.com/dotnet/runtime-assets - e8f3528a061b4f6b944f13ad87382d7964b46c7e + f636e4a569ad29a54e9672dffdb77a00c0c4a62a https://github.com/dotnet/roslyn diff --git a/eng/Versions.props b/eng/Versions.props index 91539b3b8a5c93..41bb66139afdbf 100644 --- a/eng/Versions.props +++ b/eng/Versions.props @@ -153,20 +153,20 @@ 4.5.0 8.0.0-rc.1.23406.6 - 8.0.0-beta.25414.3 - 8.0.0-beta.25414.3 - 8.0.0-beta.25414.3 - 8.0.0-beta.25414.3 - 8.0.0-beta.25414.3 - 8.0.0-beta.25414.3 - 8.0.0-beta.25414.3 - 8.0.0-beta.25414.3 - 8.0.0-beta.25414.3 - 8.0.0-beta.25414.3 - 8.0.0-beta.25414.3 - 8.0.0-beta.25414.3 - 8.0.0-beta.25414.3 - 8.0.0-beta.25414.3 + 8.0.0-beta.25467.2 + 8.0.0-beta.25467.2 + 8.0.0-beta.25467.2 + 8.0.0-beta.25467.2 + 8.0.0-beta.25467.2 + 8.0.0-beta.25467.2 + 8.0.0-beta.25467.2 + 8.0.0-beta.25467.2 + 8.0.0-beta.25467.2 + 8.0.0-beta.25467.2 + 8.0.0-beta.25467.2 + 8.0.0-beta.25467.2 + 8.0.0-beta.25467.2 + 8.0.0-beta.25467.2 1.0.0-prerelease.23566.3 1.0.0-prerelease.23566.3 From ff9a099e7b1bc2b3b593fd8c9603f838e8f3dec7 Mon Sep 17 00:00:00 2001 From: Ahmet Ibrahim Aksoy Date: Mon, 22 Sep 2025 09:15:40 +0200 Subject: [PATCH 20/20] [release/8.0-staging] Disable Multicast SocketOption Test (#119888) --- .../tests/FunctionalTests/SocketOptionNameTest.cs | 1 + 1 file changed, 1 insertion(+) diff --git a/src/libraries/System.Net.Sockets/tests/FunctionalTests/SocketOptionNameTest.cs b/src/libraries/System.Net.Sockets/tests/FunctionalTests/SocketOptionNameTest.cs index b63d85e34c74fd..27bfefdfab9118 100644 --- a/src/libraries/System.Net.Sockets/tests/FunctionalTests/SocketOptionNameTest.cs +++ b/src/libraries/System.Net.Sockets/tests/FunctionalTests/SocketOptionNameTest.cs @@ -66,6 +66,7 @@ public void MulticastOption_CreateSocketSetGetOption_GroupAndInterfaceIndex_SetS [ConditionalFact(typeof(PlatformDetection), nameof(PlatformDetection.IsNotWindowsNanoNorServerCore))] // Skip on Nano: https://github.com/dotnet/runtime/issues/26286 [ActiveIssue("https://github.com/dotnet/runtime/issues/113827", typeof(PlatformDetection), nameof(PlatformDetection.IsAppleMobile))] + [SkipOnPlatform(TestPlatforms.OSX, "Multicast interface selection fails on macOS 14+ due to changes in how the system handles network interface parameters")] public async Task MulticastInterface_Set_AnyInterface_Succeeds() { // On all platforms, index 0 means "any interface"