Re: [gem5-users] Debugging std::bad_alloc memory errors in gem5
Thank you, Ciro. Turned out that by disabling most of the (classic) cache stat handlers, I was able to free up a lot of memory. Subhankar Pal | PhD Candidate, CSE | University of Michigan On March 25, 2020 at 4:38:52 AM, Ciro Santilli (ciro.santi...@gmail.com) wrote: I would try to put prints/PDB on src/python/m5/stats/__init__.py where enable is called. On Wed, Mar 25, 2020 at 5:35 AM Subhankar Pal wrote: > > Hi, > > I am trying to run simulations in SE mode with a 1000+ (simple) cores. I get the following error once m5.instantiate() is called. > Traceback (most recent call last): > File "", line 1, in > File "/home/subh/gem5/src/python/m5/main.py", line 436, in main > exec filecode in scope > File “configs/se_mod.py", line 1586, in > m5.instantiate() > File "/home/subh/gem5/src/python/m5/simulate.py", line 139, in instantiate > stats.enable() > File "/home/subh/gem5/src/python/m5/stats/__init__.py", line 180, in enable > stat.enable() > MemoryError: std::bad_alloc > > My system is a heavily modified se.py and I have multiple custom memObjects, some of which allocate memory, i.e. using functions similar to createBackingStore() in src/mem/physical.cc. > > Is there an easy way to track down which memObject class allocates the most memory, or at least which memObject the allocation fails for? I have tried invoking gem5.opt with gdb, but I don’t get a backtrace, presumably because the failure happens in a Python function call. > > Thank for any help. > > Subhankar Pal | PhD Candidate, CSE | University of Michigan > ___ > gem5-users mailing list > gem5-users@gem5.org > http://m5sim.org/cgi-bin/mailman/listinfo/gem5-users ___ gem5-users mailing list gem5-users@gem5.org http://m5sim.org/cgi-bin/mailman/listinfo/gem5-users
Re: [gem5-users] Debugging std::bad_alloc memory errors in gem5
I would try to put prints/PDB on src/python/m5/stats/__init__.py where enable is called. On Wed, Mar 25, 2020 at 5:35 AM Subhankar Pal wrote: > > Hi, > > I am trying to run simulations in SE mode with a 1000+ (simple) cores. I get > the following error once m5.instantiate() is called. > Traceback (most recent call last): > File "", line 1, in > File "/home/subh/gem5/src/python/m5/main.py", line 436, in main > exec filecode in scope > File “configs/se_mod.py", line 1586, in > m5.instantiate() > File "/home/subh/gem5/src/python/m5/simulate.py", line 139, in instantiate > stats.enable() > File "/home/subh/gem5/src/python/m5/stats/__init__.py", line 180, in enable > stat.enable() > MemoryError: std::bad_alloc > > My system is a heavily modified se.py and I have multiple custom memObjects, > some of which allocate memory, i.e. using functions similar to > createBackingStore() in src/mem/physical.cc. > > Is there an easy way to track down which memObject class allocates the most > memory, or at least which memObject the allocation fails for? I have tried > invoking gem5.opt with gdb, but I don’t get a backtrace, presumably because > the failure happens in a Python function call. > > Thank for any help. > > Subhankar Pal | PhD Candidate, CSE | University of Michigan > ___ > gem5-users mailing list > gem5-users@gem5.org > http://m5sim.org/cgi-bin/mailman/listinfo/gem5-users ___ gem5-users mailing list gem5-users@gem5.org http://m5sim.org/cgi-bin/mailman/listinfo/gem5-users
[gem5-users] Debugging std::bad_alloc memory errors in gem5
Hi, I am trying to run simulations in SE mode with a 1000+ (simple) cores. I get the following error once m5.instantiate() is called. Traceback (most recent call last): File "", line 1, in File "/home/subh/gem5/src/python/m5/main.py", line 436, in main exec filecode in scope File “configs/se_mod.py", line 1586, in m5.instantiate() File "/home/subh/gem5/src/python/m5/simulate.py", line 139, in instantiate stats.enable() File "/home/subh/gem5/src/python/m5/stats/__init__.py", line 180, in enable stat.enable() MemoryError: std::bad_alloc My system is a heavily modified se.py and I have multiple custom memObjects, some of which allocate memory, i.e. using functions similar to createBackingStore() in src/mem/physical.cc. Is there an easy way to track down which memObject class allocates the most memory, or at least which memObject the allocation fails for? I have tried invoking gem5.opt with gdb, but I don’t get a backtrace, presumably because the failure happens in a Python function call. Thank for any help. Subhankar Pal | PhD Candidate, CSE | University of Michigan ___ gem5-users mailing list gem5-users@gem5.org http://m5sim.org/cgi-bin/mailman/listinfo/gem5-users