Bug 14456

Summary: internal-error: virtual memory exhausted
Product: gdb Reporter: Tomas <thamos>
Component: c++Assignee: Not yet assigned to anyone <unassigned>
Status: WAITING ---    
Severity: normal CC: dje, keiths, pedro
Priority: P2    
Version: 7.4   
Target Milestone: ---   
Host: Target:
Build: Last reconfirmed:

Description Tomas 2012-08-11 16:03:27 UTC
GDB (with python support) crashes with following description:

C:/MinGW/msys/1.0/src/gdb/gdb-python-7.4-1-mingw32-src/gdb-python-7.4-2/src/gdb-7.4/gdb/utils.c:1246: internal-error: virtual memory exhausted: can't allocate 2009222722 bytes.

when stepping into x constructor (main) in this C++ code:

#include <string>

class T
{
public:
    T(std::string str)
    {
    }
};


int main() {
    std::string str = "";
    T x(str);
    return 0;
}
Comment 1 Keith Seitz 2012-08-14 17:07:18 UTC
I tried to reproduce this but failed on both 7.4.1-20120718-cvs and 7.5.50-20120808-cvs (HEAD from one week ago).

Does the problem occur if you disable pretty-printing of STL containers?

I don't suppose you could reproduce the error and provide a stack backtrace? That would be incredibly useful.
Comment 2 dje 2014-11-17 23:14:28 UTC
Perhaps related, perhaps not, but fyi,
see pr 17614 for an OOM with a backtrace.