Skip to content

[x64 arm32] the test smalloom terminated with signal SIGKILL #9780

Closed
@sergign60

Description

@sergign60

the test coreclr/tests/src/GC/Coverage/smalloom
used platforms
Linux signatov 4.4.0-112-generic #3921-Ubuntu SMP Fri Jan 19 11:48:36 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux
Linux localhost 3.10.65 dotnet/coreclr#1-Tizen SMP PREEMPT Fri Feb 2 22:29:33 UTC 2018 armv7l GNU/Linux

% ./corerun smalloom.exe
[1] 8137 killed ./corerun smalloom.exe

% gdb -q --args ./corerun smalloom.exe
Reading symbols from ./corerun...done.
gdb>run
Starting program: /share/WORK/overlay.x64/corerun smalloom.exe
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
[New Thread 0x7ffff4d7a700 (LWP 8347)]
[New Thread 0x7ffff436e700 (LWP 8348)]
[New Thread 0x7ffff3b6d700 (LWP 8349)]
[New Thread 0x7ffff2ff3700 (LWP 8350)]
[New Thread 0x7ffff200b700 (LWP 8351)]
[Thread 0x7ffff200b700 (LWP 8351) exited]
[New Thread 0x7ffff200b700 (LWP 8398)]
[Thread 0x7ffff200b700 (LWP 8398) exited]
[New Thread 0x7ffff200b700 (LWP 8399)]
[Thread 0x7ffff200b700 (LWP 8399) exited]
[Thread 0x7ffff2ff3700 (LWP 8350) exited]
[Thread 0x7ffff3b6d700 (LWP 8349) exited]
[Thread 0x7ffff436e700 (LWP 8348) exited]
[Thread 0x7ffff4d7a700 (LWP 8347) exited]

Program terminated with signal SIGKILL, Killed.
The program no longer exists.

the source:

// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.

//Regression test for Dev 10 bug 479239: GC hangs on x86 rather than throwing OOM
 
using System;
using System.Runtime;

class TestClass
{
  public static int Main()
  {
        ByteArrayList list = new ByteArrayList();


        try
        {
            while (true)
            {
                list.AddByteArray(84500);
            }
        }
        catch (OutOfMemoryException)
        {
        }

        Console.Write("NodesAllocated: ");
        Console.WriteLine(list.NodeCount);
        return 100;
   }

    class ByteArrayList
    {
        class Node
        {
            byte[] data = null;
            int size = 0;
            public Node next = null;

            public Node(int Size)
            {
              data = new byte[Size];
              size = Size;
            }

        }
       
        Node head;

        public int NodeCount = 0;
        public ByteArrayList()
        {
            head = null;
        }

        public void AddByteArray(int size)
        {
            Node newNode = new Node(size);

            if (head == null)
                head = newNode;
            else
            {
                newNode.next = head;
                head = newNode;
            }
            NodeCount++;
        }
    }

}

No any additional environment variables used

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions