Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

nameplates: potential memory leak in pfNameplates:OnUpdate() #1203

Closed
BensonLiu1121 opened this issue Sep 29, 2023 · 20 comments
Closed

nameplates: potential memory leak in pfNameplates:OnUpdate() #1203

BensonLiu1121 opened this issue Sep 29, 2023 · 20 comments

Comments

@BensonLiu1121
Copy link

**I installed Pfui, and I also installed quite a few other plugins. This causes my game to trigger a 'Next Memory Cleanup' every minute, and when it does, there's a noticeable lag on the page, and sometimes the game drops/or is abnormal. In the game's error directory, an error log is generated, An SMem3 error is displayed in the log:
I play Turtle server, Chinese Hogg


Exe: K:\WoWTurtle\ Warcraft turtle service [Asian service \ Russian service] client download (open download, 11 PM open service) \WoW.exe

Time: Sep 29, 2023 1:38:22.950 AM

User: admin

Computer: DESKTOP-QPV66F3


This application has encountered a critical error:
ERROR #124 (0x8510007c) Memory Invalid Block
Program: K:\WoWTurtle\ Warcraft turtle service [Asian service \ Russian service] client download (open download, 11 p.m. Open service) \WoW.exe
Object: SGroupPtr (.? AUSGroupPtr@@)

SMem3: Pointer does not refer to a valid allocated block of memory

WoWBuild: 5875


Stack Trace (Manual)

Address Frame Logical addr Module

006452BE 0019FE54 0001:002442BE K:\WoWTurtle\ Warcraft turtle service [Asian service \ Russian service] client download (open download, 11 PM open service) \WoW.exe
0064623A 0019FE68 0001:0024523A K:\WoWTurtle\ Warcraft turtle service [Asian service \ Russian service] client download (open download, 11 PM open service) \WoW.exe
006457C9 0019FE88 0001:002447C9K :\WoWTurtle\ Warcraft turtle service [Asian service \ Russian service] client download (open download, 11 PM open service) \WoW.exe
00646449 0019FE9C 0001:00245449 K:\WoWTurtle\ Warcraft turtle service [Asian service \ Russian service] client download (open download, 11 PM open service) \WoW.exe
006BD0D8 0019FF74 0001:002BC0D8 K:\WoWTurtle\ Warcraft turtle service [Asian service \ Russian service] client download (open download, open at 11pm) \WoW.exe
77147BA9 0019FF84 0001:00007BA9 C:\WINDOWS\System32\KERNEL32.DLL
77BDB79B 0019FFDC 0001:0006A79B C:\WINDOWS\SYSTEM32\ntdll.dll
77BDB71F 0019FFEC 0001:0006A71F C:\WINDOWS\SYSTEM32\ntdll.dll


Stack Trace (Using DBGHELP.DLL)

@BensonLiu1121
Copy link
Author

My Email: 27769001@qq.com

@BensonLiu1121
Copy link
Author

It may be a network problem, the game client is not closed, but the network is down, need to log in again

@shagu
Copy link
Owner

shagu commented Sep 29, 2023

Greetings, you could try to load pfDebug to see which of the addons are causing the increasing memory footprint. Clicking on the little box with memory info, will open the analyzer that lets you scan for frames and then show which of them are producing that much memory garbage.

@BensonLiu1121
Copy link
Author

BensonLiu1121 commented Sep 29, 2023 via email

@BensonLiu1121
Copy link
Author

The 'Memory Usage' is 120MB, then 'Next Memory Cleanup' should be '140MB.
140-120 =20MB, Whether to support adjusting this value, whether to support adjusting this value, Because I want to clear the cache less often

@BensonLiu1121
Copy link
Author

Or I wonder if I can support the ability to cancel memory clearing, because every time memory is cleared, it may cause network disconnection.
Maybe some other program cleaned up this part of memory, and then the plug-in cleaned up this part of memory, indicating that it did not clean successfully.

@shagu
Copy link
Owner

shagu commented Sep 29, 2023

It is nothing that pfUI does. It's done by the game itself. You gotta find the addon that is causing the memory leak.
Because using pfUI without any other addons has a stable memory footprint and does not trigger those cleanups.

@BensonLiu1121
Copy link
Author

oh... I see....I closed the other plugins and gave them a try

@BensonLiu1121
Copy link
Author

pfNameplates:onUpdate() Keep growing, Other plugins are not growing

@BensonLiu1121
Copy link
Author

I should try to open some plugins and listen for this

Copy link

This issue is stale because it has been open for 30 days with no activity.

@github-actions github-actions bot added the stale label Feb 26, 2024
@BensonLiu1121
Copy link
Author

BensonLiu1121 commented Feb 26, 2024 via email

@github-actions github-actions bot removed the stale label Feb 26, 2024
Copy link

This issue is stale because it has been open for 30 days with no activity.

@github-actions github-actions bot added the stale label Mar 28, 2024
@BensonLiu1121
Copy link
Author

BensonLiu1121 commented Mar 28, 2024 via email

@github-actions github-actions bot removed the stale label Mar 29, 2024
@shagu
Copy link
Owner

shagu commented Apr 20, 2024

I'll double check the pfNameplates code to see if there's a potential leak inside.
Do you have a clean way to reproduce it while only pfUI is running? Just to be sure it's not a conflict with another addon, and also giving me the option to review the potential changes I do.

@shagu shagu changed the title I think there is a serious but that has caused the game to quit. I want to turn off auto-clean memory, but I'm not sure how nameplates: potential memory leak in pfNameplates:OnUpdate() Apr 20, 2024
@shagu shagu self-assigned this Apr 20, 2024
@BensonLiu1121
Copy link
Author

BensonLiu1121 commented Apr 20, 2024 via email

@shagu
Copy link
Owner

shagu commented Apr 20, 2024

Once all nameplates are created, it remains stable at around ~350kb after it built like 20 nameplates.
At this point, I can't get the pfNameplates:OnUpdate() function to grow any further.
Been running around for 10 Minutes with all nameplates enabled now - It stays at 350kb.

@shagu shagu removed their assignment Apr 21, 2024
Copy link

This issue is stale because it has been open for 30 days with no activity.

@github-actions github-actions bot added the stale label May 22, 2024
@BensonLiu1121
Copy link
Author

BensonLiu1121 commented May 22, 2024 via email

@shagu
Copy link
Owner

shagu commented May 22, 2024

As you don't participate in the discussion, don't answer the open questions and just write "1111". I will now close this.
That shit gets annoying here. I will no longer waste my time for you.

@shagu shagu closed this as completed May 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants