nV News Forums

 
 

nV News Forums (http://www.nvnews.net/vbulletin/index.php)
-   NVIDIA Linux (http://www.nvnews.net/vbulletin/forumdisplay.php?f=14)
-   -   Opengl throws std::bad_alloc - but why? (http://www.nvnews.net/vbulletin/showthread.php?t=153566)

pootle 07-29-10 12:43 PM

Opengl throws std::bad_alloc - but why?
 
I'm writing a mapping application (C++) on ubuntu, but while I still have loads of free memory, opengl is throwing this exception. (well I assume its opengl, I'm using GTKMM)

I'm using drivers 256.40 running on kernel 2.6.31-22-generic 32 bit.

The PC has 3Gb of RAM and system monitor shows the app using just under 80Mb of RAM, but with less than 20% of total system RAM used.

I quadrupled the stack limit, just in case it was stack related, but this didn't make any difference. most other settings are unlimited. I'm miles away from 32 bit limit's here by the looks of it.

How can I track down where the problem really is?

Code:

ulimit -a
core file size          (blocks, -c) 0
data seg size          (kbytes, -d) unlimited
scheduling priority            (-e) 20
file size              (blocks, -f) unlimited
pending signals                (-i) 16382
max locked memory      (kbytes, -l) 64
max memory size        (kbytes, -m) unlimited
open files                      (-n) 1024
pipe size            (512 bytes, -p) 8
POSIX message queues    (bytes, -q) 819200
real-time priority              (-r) 0
stack size              (kbytes, -s) 32768
cpu time              (seconds, -t) unlimited
max user processes              (-u) unlimited
virtual memory          (kbytes, -v) unlimited
file locks                      (-x) unlimited


AaronP 07-29-10 01:05 PM

Re: Opengl throws std::bad_alloc - but why?
 
I don't think OpenGL ever throws C++ exceptions, so it must be GTKMM doing it. Can you get a backtrace where the exception is thrown? If you'd like somebody to take a look, please attach a standalone test case that reproduces the problem.


All times are GMT -5. The time now is 03:27 AM.

Powered by vBulletin® Version 3.7.1
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Copyright 1998 - 2014, nV News.