Just filed a radar for a nasty memory leak that we've uncovered in
Mac OS's OpenGL. My co-worker and I have both lost two days on this
issue and took the time out to create a repro project, so hopefully
the radar won't fall into a black hole... The radar ID is 5545171
and I'll repeat it below for the list archives (since I didn't find
anything relating to it)...
Also, to Geoff Stahl and any others at apple who this may concern,
our new software title presses on OpenGL pretty hard, so if you guys
are still looking for test/diagnostic apps for OpenGL, all we need is
the specs for how the test app should be set up (we uncovered this
leak by just running our software for a couple days straight while
logging memory usage).
Summary:
Using glLineWidth() and glPointSize() in a particular way triggers a
major memory leak inside the OpenGL subsystem.
Steps to Reproduce:
1) From command line, start the top util (top -u)
2) Compile an the Xcode project located at http://musicmeetsart.com/
LineWidthTroubles.zip
3) Watch "LineWidthTroubles" using top. In just a few seconds after
starting it, you'll see its memory consumption rocket up! Be sure to
quit it after 10 seconds or else your machine will start to grind!
Expected Results:
By looking at the half page of of code in main.cpp, there's not a
single allocation or malloc, so the memory footprint of the
LineWidthTroubles app should remain constant.
Actual Results:
The LineWidthTroubles memory footprint rapidly grows. If left alone,
the app will take up gigs of memory within half a minute -- just use
the top command line util 'top -u'.
Regression:
So far, LineWidthTroubles will behave as described above on:
- a 6 month old c2d MacBook Pro 17" (RadeonX1600) running 10.4.10
- a 1.5 year old intel c2d iMac (RadeonX1600) running 10.4.10
- a 2.5 year old single core G5 iMac (Radeon 9600) running 10.4.10
Notes:
Playing around with main.cpp reveals that the placement of glPointSize
() is critical as well as the presence of using adding a random value
to the line width.
Note that main.cpp uses plain vanilla OpenGL 1.0 and is trivial to
follow, so this isn't any case of using an esoteric extension, etc.
In the words of a Gary Larson Farside cartoon, "Helf!!"
Thanks,
Andy
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Mac-opengl mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/mac-opengl/email@hidden