Skip to content

[outerloop] System.Runtime.Numerics.Tests crash with exit code 137 in linux debug coreclr #104588

Closed

Description

@elinor-fung

Perhaps related to #98964

  Starting:    System.Runtime.Numerics.Tests (parallel test collections = on, max threads = 2)
./RunTests.sh: line 168:    21 Killed                  "$RUNTIME_PATH/dotnet" exec --runtimeconfig System.Runtime.Numerics.Tests.runtimeconfig.json --depsfile System.Runtime.Numerics.Tests.deps.json xunit.console.dll System.Runtime.Numerics.Tests.dll -xml testResults.xml -nologo -nocolor -trait category=OuterLoop -notrait category=IgnoreForCI -notrait category=failing $RSP_FILE
/root/helix/work/workitem/e
----- end Mon Jul 8 23:40:00 UTC 2024 ----- exit code 137 ----------------------------------------------------------
exit code 137 means SIGKILL Killed eg by kill

Build Information

Build: https://dev.azure.com/dnceng-public/cbb18261-c48f-4abb-8651-8cdcb5474649/_build/results?buildId=733224
Build error leg or test failing: System.Runtime.Numerics.Tests.WorkItemExecution
Pull request: #104501

Error Message

Fill the error message using step by step known issues guidance.

{
  "ErrorMessage": "",
  "ErrorPattern": "Killed.+System\\.Runtime\\.Numerics\\.Tests\\.runtimeconfig\\.json.+OuterLoop",
  "BuildRetry": false,
  "ExcludeConsoleLog": false
}

Known issue validation

Build: 🔎 https://dev.azure.com/dnceng-public/public/_build/results?buildId=733224
Error message validated: [Killed.+System\.Runtime\.Numerics\.Tests\.runtimeconfig\.json.+OuterLoop]
Result validation: ✅ Known issue matched with the provided build.
Validation performed at: 7/9/2024 4:39:02 AM UTC

Report

Build Definition Test Pull Request
1348023 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1348024 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1346988 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1346982 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1346205 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1346200 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1344749 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1344743 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1342774 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1342787 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1340764 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1340752 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1338901 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1338902 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1337099 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1337102 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1336164 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1336163 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1335394 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1335388 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1333882 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1333870 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1332089 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1332090 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1330131 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1330140 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1328030 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1328016 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1326197 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1326207 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1325496 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1325505 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1325049 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1325041 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1323323 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1323311 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1321713 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1321712 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1319903 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1319899 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1317746 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1317740 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1315852 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1315849 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1315051 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1315041 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1314382 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1314384 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1312762 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1312759 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1310949 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1310945 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1309172 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1309161 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1307322 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1307323 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1305407 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1305401 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1304476 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution
1304468 dotnet/runtime System.Runtime.Numerics.Tests.WorkItemExecution

Summary

24-Hour Hit Count 7-Day Hit Count 1-Month Count
2 14 56

Activity

  1. added
    blocking-outerloop
    Known Build Error
    on Jul 9, 2024
  2. ghost added
    needs-area-label
    on Jul 9, 2024
  3. added
    untriaged
    on Jul 9, 2024
  4. dotnet-policy-service commented on Jul 9, 2024

    @dotnet-policy-service
    Contributor

    Tagging subscribers to this area: @dotnet/area-system-numerics
    See info in area-owners.md if you want to be subscribed.

  5. removed
    needs-area-label
    on Jul 11, 2024
  6. added this to the 9.0.0 milestone on Jul 20, 2024
  7. removed
    untriaged
    on Jul 20, 2024
  8. tannergooding commented on Aug 8, 2024

    @tannergooding
    Member

    There is no dump and the only hint as to why the SIGKILL might have been raised is

    dmesg: read kernel buffer failed: Operation not permitted

    This seems like a more general flaky issue and not related to anything in the tests. I've not been able to repro locally so there's not much that can be done without some additional context or a reliable repro

  9. modified the milestones: 9.0.0, 10.0.0 on Sep 17, 2024
  10. ericstj commented on Nov 7, 2024

    @ericstj
    Member

    This is the highest-hitting libraries known build issue. Worth a look if you can determine the cause. https://helix.dot.net/BuildAnalysis/KnownIssues @tannergooding @jeffhandley

  11. modified the milestones: 10.0.0, Future on Jul 14, 2025
  12. danmoseley commented on Mar 24, 2026

    @danmoseley
    Contributor

    Note

    This comment was drafted with Copilot assistance.

    Investigation

    I looked at all 60 builds linked in the known issue report. Here's what the data shows:

    Configuration pattern:

    • All builds are release/8.0 scheduled outerloop, Release CoreCLR_Release
    • All 4 Linux legs fail 100% of the time (x64, arm64, musl-x64, musl-arm64)
    • Windows and macOS legs in these builds are failing for unrelated reasons — their Helix logs have zero references to System.Runtime.Numerics.Tests

    From the Helix console logs (e.g. this one):

    • Only 7 OuterLoop tests are discovered (out of 576 total)
    • The process is killed in ~18 seconds — well under the 1200-2700s work item timeout, so this is not a timeout
    • Tests run with max threads = 2 in parallel
    • Linux legs run inside Docker containers (Alpine/Ubuntu images on Azure Linux 3 VMs)
    • dmesg is denied, so the kernel OOM killer message can't be confirmed, but 18s + SIGKILL + Docker is strongly consistent with a cgroup memory limit hit

    Why this doesn't repro on main: On main, PR #102874 (May 2024) added BigInteger.MaxLength, capping allocations. The OuterLoop tests that shift by int.MaxValue would now throw OverflowException instead of allocating huge memory. PR #111841 subsequently fixed those tests to use smaller values (1 << 24 instead of int.MaxValue). PR #103423 also disabled parallelization for some threshold tests. None of these changes were backported to release/8.0.

    The likely culprit tests on 8.0 are the ones that shift BigInteger by int.MaxValue / 10 bits per iteration (up to 4x), creating values of ~107 MB each: LargeValueLogTests, DoubleExplicitCastFromLargeBigIntegerTests, and GetBitLengthTests which shifts by int.MaxValue. With 2 threads, peak memory could easily exceed Docker container limits.

    Possible fix for 8.0: Backport the test-only changes from #111841 and #103423 to reduce allocation sizes and disable parallelization, without needing the BigInteger.MaxLength behavioral change.

  13. danmoseley commented on Mar 28, 2026

    @danmoseley
    Contributor

    Fixed by #126011

  14. locked and limited conversation to collaborators on Apr 27, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

Known Build Errorarea-System.Numericsblocking-outerloop

Type

No type

Projects

No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions