• FEATURED

View more

View more

View more

### Image of the Day Submit

IOTD | Top Screenshots

### The latest, straight to your Inbox.

Subscribe to GameDev.net Direct to receive the latest updates and exclusive content.

# Memory usage increasing over time

Old topic!

Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

12 replies to this topic

### #1/ Janissary   Banned

Posted 27 October 2013 - 10:31 AM

Hi. I have an empty OpenGL 3.3 application using GLEW and GLFW, with a simple code like this:

bool running = true;

if( !glfwOpenWindow( 800,600, 0,0,0,0,0,0, GLFW_WINDOW ) )
{
glfwTerminate();
}

glewInit();

while( running )
{
glClear( GL_COLOR_BUFFER_BIT );
glfwSwapBuffers();
running = glfwGetWindowParam( GLFW_OPENED );
}

glfwTerminate();


When I run the application and open the Windows Task Manager, the memory usage of the process doesn't stop growing, it starts at something near 8,600 K and then this number is increased by 4 every 3 to 10 seconds, approximately.

Oh my god, what do I do?

### #2Barbossa  Members

Posted 27 October 2013 - 11:24 AM

Stay calm ;)

It does not seem like a real leak, at least if it is growing so slow. I don't see any error in your code. The taskmanager is not really a tool for checking for memory leaks, so you might go ahead and check out a leak detector like https://vld.codeplex.com/releases for Visual Studio in case you have a feeling that there is indeed a leak.

Doesn't look like it for me, but checking never hurts

### #3/ Janissary   Banned

Posted 27 October 2013 - 01:16 PM

There are no memory leaks, I used the CRT thing before for checking. I think it it is not a leak problem, because there are no allocations made by me on the loop, only these simple gl calls. I tested other non-empty OpenGL applications, they have a steady usage. They use FreeGLUT.

I tried to create a window and context manually, and drew a simple triangle, the memory usage is stable.

Maybe this is glew/glfw problem. Or Is that something I shouldn't be worried about?

Oh my god, what should I do now

### #4Kaptein  Prime Members

Posted 27 October 2013 - 02:44 PM

I recommend using glfw3

I have been using glfw before, and i've never had any growth, even slow

maybe it's just the newer nvidia drivers.. it could be anything

### #5/ Janissary   Banned

Posted 28 October 2013 - 05:46 AM

Didn't know GLFW had a new version. I won't use glfw3. It has become so stupid. There is no library for Visual Studio 2010. Only for the Visual Crap 2012. Even the website looks stupid now. Even the function names: glfwWindowShouldClose, what the Hell? The header filename, glfw3.h? GLFW 2.7 was not glfw27.h, simply glfw.h.

I think I will search for another library to do this job. Or do it manually if I don't find one.

Thank you Kaptein.

### #6/ Janissary   Banned

Posted 28 October 2013 - 12:20 PM

I don't give a **** to this stupid number, keep pressing this stupid down arrow if you want, ********.

Edited by swiftcoder, 28 October 2013 - 12:59 PM.
inappropriate language hidden.

### #7fastcall22  Moderators

Posted 28 October 2013 - 01:28 PM

POPULAR

I won't use glfw3. It has become so stupid. There is no library for Visual Studio 2010.

What? It's right here: glfw-3.0.3.bin.WIN32.zip\glfw-3.0.3.bin.WIN32\lib-msvc100\glfw3.lib.

Only for the Visual Crap 2012.

Hmm? What do you have against Visual Studio 2012? It's solid and much more stable (in my experiences) than 2010.

Even the website looks stupid now.

It's a sign of the library community's health. To me, it appears much cleaner and organized.

Even the function names: glfwWindowShouldClose, what the Hell?

Check the documentation and read up on new functions you're not familiar with.

The header filename, glfw3.h? GLFW 2.7 was not glfw27.h, simply glfw.h.

Developing applications over time that eventually use different versions of the same library can make managing them in an IDE difficult. Visual Studio property pages help somewhat, but having an version number with the header and library names make it much more explicit and hard to mess up.

I don't give a **** to this stupid number, keep pressing this stupid down arrow if you want, ********.

This sort of caustic attitude isn't allowed these forums; try taking your frustrations to Twitter or Facebook.
zlib: eJzVVLsSAiEQ6/1qCwoK i7PxA/2S2zMOZljYB1TO ZG7OhUtiduH9egZQCJH9 KcJyo4Wq9t0/RXkKmjx+ cgU4FIMWHhKCU+o/Nx2R LEPgQWLtnfcErbiEl0u4 0UrMghhZewgYcptoEF42 YMj+Z1kg+bVvqxhyo17h nUf+h4b2W4bR4XO01TJ7 qFNzA7jjbxyL71Avh6Tv odnFk4hnxxAf4w6496Kd OgH7/RxC

### #8/ Janissary   Banned

Posted 28 October 2013 - 01:51 PM

What? It's right here: glfw-3.0.3.bin.WIN32.zip\glfw-3.0.3.bin.WIN32\lib-msvc100\glfw3.lib.

Yes it's right there. My mistake, sorry.

Hmm? What do you have against Visual Studio 2012? It's solid and much more stable (in my experiences) than 2010.

It's full of useless features - too retarded-friendly, like everything tends to become over time.

It's a sign of the library community's health. To me, it appears much cleaner and organized.

Too retarded-friendly (like everything tends to become over time) and I couldn't find 2.7.7's documentation.

Check the documentation and read up on new functions you're not familiar with.

I was talking about the name of the function, which is stupid. It's the first time I see the word 'should' in a program.

Developing applications over time that eventually use different versions of the same library can make managing them in an IDE difficult. Visual Studio property pages help somewhat, but having an version number with the header and library names make it much more explicit and hard to mess up.

Why would one use two versions of GLFW in the same application? It's all the same crap.

This sort of caustic attitude isn't allowed these forums; try taking your frustrations to Twitter or Facebook.

That was unnecessary.

### #9mhagain  Members

Posted 28 October 2013 - 02:40 PM

POPULAR

That was unnecessary.

It was very necessary.

IANAM but the way you're casually dropping words like "retarded", mouthing off with obvious flamebait, and just generally coming on here with some kind of attitude problem is not a good way to fit in with even a moderately serious community.  This isn't the kind of community you seem to think it is and your behaviour in this thread is not conducive to getting good interaction from other members.

It appears that the gentleman thought C++ was extremely difficult and he was overjoyed that the machine was absorbing it; he understood that good C++ is difficult but the best C++ is well-nigh unintelligible.

### #10/ Janissary   Banned

Posted 28 October 2013 - 02:57 PM

Not it wasn't necessary. Okay, screw GLFW, it is a shitty library. This thread has become a down-vote ocean, too many assholes. Not that I give a shit about that number.

### #11fastcall22  Moderators

Posted 28 October 2013 - 04:03 PM

It's full of useless features - too retarded-friendly, like everything tends to become over time.

Well, there's notepad.exe and cl.exe; knock yourself out. As un-userfriendly as it gets.

Why would one use two versions of GLFW in the same application? It's all the same crap.

You wouldn't use two different versions of a library in the same application, silly! If you have ever developed more than one application, then using the "latest" version of a library at the times of both applications' development are going to be different. Including glfw.h in the application developed years earlier is going to break when you change your environment's paths to always use the latest versions of your libraries. (Again, with Visual Studio's property pages, this is possible.)

Too retarded-friendly (like everything tends to become over time) and I couldn't find 2.7.7's documentation.

I was talking about the name of the function, which is stupid. It's the first time I see the word 'should' in a program.

You can use a macro to hide it, if you really want to. You could even comment it!
// Wow, I'd rather rebuild an entire cross-platform library than to use the word "should" in a program.
#define glfwWindowIsOpen(window) (!glfwWindowShouldClose(window))


Edited by fastcall22, 28 October 2013 - 04:06 PM.

zlib: eJzVVLsSAiEQ6/1qCwoK i7PxA/2S2zMOZljYB1TO ZG7OhUtiduH9egZQCJH9 KcJyo4Wq9t0/RXkKmjx+ cgU4FIMWHhKCU+o/Nx2R LEPgQWLtnfcErbiEl0u4 0UrMghhZewgYcptoEF42 YMj+Z1kg+bVvqxhyo17h nUf+h4b2W4bR4XO01TJ7 qFNzA7jjbxyL71Avh6Tv odnFk4hnxxAf4w6496Kd OgH7/RxC

### #12/ Janissary   Banned

Posted 08 November 2013 - 02:31 AM

Success, I've got enough attention. Way to go, losers.

Posted 08 November 2013 - 04:15 AM

Janissary,

That is not an acceptable first reply to make after your previously issued warning.  You have been warned repeatedly for offensive and disrespectful behaviour, and have shown no sign of trying to participate constructively here.

As such, you are being permanently removed from our community -- please try to behave better in any other communities you join.

With the original poster banned and a number of posts off-topic I'm also closing this topic; anyone experiencing a similar problem should please feel free to start a new topic to get help.