Jump to content

Lights causes memory leak


Dreikblack
 Share

Go to solution Solved by Josh,

Recommended Posts

I narrowed the problem down further.

Bindless textures have a huge memory leak in Nvidia's current drivers. Simply getting the bindless handle and making the texture resident causes memory to be allocated each frame, even when no camera is in use.

My job is to make tools you love, with the features you want, and performance you can't live without.

Link to comment
Share on other sites

Specifically, it's the call to glMakeTextureHandleResidentARB that causes memory to continously leak.

My job is to make tools you love, with the features you want, and performance you can't live without.

Link to comment
Share on other sites

Response from Nvidia:

Quote

 

Hi Josh,

Thanks for reaching out and sorry for delayed response , the ticket somehow slips from my view for days . The ticket is routed to our engineering team and we will give a check soon . Will keep you updated here .
Best,
Yuki

 

 

  • Like 1

My job is to make tools you love, with the features you want, and performance you can't live without.

Link to comment
Share on other sites

From Nvidia:

Quote

 

Hi Josh,

Our engineer was able to reproduce this on a Geforce 1080 . But no 'repro' on a GeForce 2070 . I checked a little bit of your Forum topic that there is no mention to it on 2070 , but you filed the ticket with 2070 . Can you please be more specific on if you see the issue on 2070 there ? Thanks .
Best,
Yuki

 

 

My job is to make tools you love, with the features you want, and performance you can't live without.

Link to comment
Share on other sites

  • 3 weeks later...

Yeah, they asked for source code and I just sent them the RenderTexture class source code. If that is not enough I will need to create a simpler app from scratch to produce the error.

My job is to make tools you love, with the features you want, and performance you can't live without.

Link to comment
Share on other sites

  • 2 weeks later...
On 8/5/2024 at 9:23 AM, Josh said:

So you are saying the increased memory that mysteriously appears on some machines is due to stack memory?

This code should be added to the main loop, but I don't think it explains the problem:

while (PeekEvent()) WaitEvent();

The memory was running very slowly, but by putting this in, it remains stable. 

image.thumb.png.6a54c99d8b8f3665ad5627ddb750bcdb.png

 

 //Main loop
 while (window->GetClosed() == false and window->GetKeyDown(KEY_ESCAPE) == false)
 {
     GUI->Update();
     world->Update();
     world->Render(window->GetFrameBuffer());
     while (PeekEvent()) WaitEvent();
 }

 

Mars.jpg.89ab63a64eebc1f5ada0ab82b66a1f8c.jpg

 

 

Link to comment
Share on other sites

image.thumb.png.23b76a0c0942707f907d60b0d6835346.png

 

aWhen I load the default map I have memory leaks, the windows task manager shows how the memory is going up, however I have started to remove elements from the scenery, and finally I have removed the models of the boxes and the default character, and the program is now stable.

Mars.jpg.89ab63a64eebc1f5ada0ab82b66a1f8c.jpg

 

 

Link to comment
Share on other sites

  • Solution

Response from Nvidia:

Quote

 

Hi Josh ,

Sorry for keeping you waiting for our updates . Good news , the issue is root caused and fixed in house . The fix will aim a next new feature branch driver 565 series in next month soon . Please keep close attention to our driver release page . You are also welcome to comment here if you need help in confirming a fix version . Thanks again for reporting a bug ticket to us .

Best,
Yuki

 

This means that @Dreikblack identified and caused a major driver bug to be fixed by Nvidia. Great job!

  • Like 2
  • Upvote 1

My job is to make tools you love, with the features you want, and performance you can't live without.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...