Download
(2 Kb)
Download
Updated: 09-07-07 01:05 PM
Pictures
File Info
Updated:09-07-07 01:05 PM
Created:unknown
Downloads:5,481
Favorites:43
MD5:
GCTweak  Popular! (More than 5000 hits)
Version: r2
by: Cladhaire [More]
GCTweak is a small utility that will help keep your memory usage lower, by assisting the garbage collection system in World of Warcraft. Anytime your framerate is higher than the setting (30 by default) this addon will force the garbage collection system to continuing marking and deallocating objects. This will only happen when you are not in combat, and can be disabled and customized from the commandline.

/gctweak /gctweaker /gct:
/gct toggle - Toggles GCTweaker on or off
/gct <num> - Enables aggressive garbage collection above <num> frames per second
/gct debug - Toggles debug messages

You should set the FPS value to your "normal" frame rate to get the best performance. The addon is very careful to only take action when necessary, and never does anything during combat.

Please test this addon, and report back to me with your results (especially if you see a noticeable drop in frame rate, or memory usage). I've tested the addon quite a bit, and it has a very noticeable effect in resolving burst situations.

Thanks to Krka for talking through all the garbage collection issues, and pushing the idea of periodic collection.

TLDR Version:

Lua's incremental garbage collector only marks and deallocates in response to new allocations. As a result, the system can get into a deficit that makes it difficult to complete a full garbage collection cycle. In order to resolve this, I've created an addon which runs the garbage collection system periodically during system downtime to ensure you don't have an outstanding deficit of memory waiting to be collected.

Changelog:
Code:
2007-09-07 [r2]  artifici:

	* GCTweak.lua: * Small optimization suggested by ckknight

2007-09-07 [r1]  artifici:

	* GCTweak.lua (added), GCTweak.toc (added): * Initial import of
	  GCTweak
Post A Reply Comment Options
Unread 09-07-07, 12:25 PM  
amazing
A Defias Bandit

Forum posts: 2
File comments: 2
Uploads: 0
thanks for this, will help me and many others alot. keep up the great work clad
amazing is offline Report comment to moderator  
Reply With Quote
Unread 09-07-07, 02:26 PM  
ckknight
A Warpwood Thunder Caller
 
ckknight's Avatar
AddOn Author - Click to view AddOns

Forum posts: 90
File comments: 95
Uploads: 32
Now you just gotta convince Slouken to include this in WoW 2.3 ;-)
ckknight is offline Report comment to moderator  
Reply With Quote
Unread 09-07-07, 06:49 PM  
Nefarion
A Defias Bandit
 
Nefarion's Avatar
AddOn Author - Click to view AddOns

Forum posts: 2
File comments: 57
Uploads: 20
Originally posted by ckknight
Now you just gotta convince Slouken to include this in WoW 2.3 ;-)
Originally posted by Slouken (http://forums.worldofwarcraft.com/th...71465210&sid=1)
FYI, something along these lines is in for 2.3.
Woot.
Nefarion is offline Report comment to moderator  
Reply With Quote
Unread 09-07-07, 07:58 PM  
Cladhaire
Salad!
 
Cladhaire's Avatar
WoWInterface Super Moderator
AddOn Author - Click to view AddOns

Forum posts: 1933
File comments: 4479
Uploads: 18
Originally posted by JaedxRapture
Woot.
I'm sneaky
__________________
"There's only one thing that I know how to do well and I've often been told that you only can do what you know how to do well, and that's be you-- be what you're like-- be like yourself. And so I'm having a wonderful time, but I'd rather be whistling in the dark..."
Cladhaire is offline Report comment to moderator  
Reply With Quote
Unread 09-07-07, 10:25 PM  
Flarin
A Frostmaul Preserver
 
Flarin's Avatar
AddOn Author - Click to view AddOns

Forum posts: 290
File comments: 152
Uploads: 1
I play on a laptop and my FPS fluctuates quite often, forcing this program to run a garbage collection a few times a minute on my machine. I have set it much lower than 30- actually my normal FPS is in the 20s, so I set it to 14. But, perhaps because my video card is on the motherboard and only 128mb the FPS frequantly dips down to 14/13/12 then pops back up, sometimes as high as 30.

Would it be feasible - or even possible - to keep track of the last collection time and if it is within a certain amount of time and / or a certain amount of memory increase THEN run?

Not sure this would help, what are your thoughts? Thanks for your time.
__________________

"I will crush and destroy and...ooo...shiny..."

[SIGPIC][/SIGPIC]
Flarin is offline Report comment to moderator  
Reply With Quote
Unread 09-07-07, 10:28 PM  
Cladhaire
Salad!
 
Cladhaire's Avatar
WoWInterface Super Moderator
AddOn Author - Click to view AddOns

Forum posts: 1933
File comments: 4479
Uploads: 18
Originally posted by Flarin
I play on a laptop and my FPS fluctuates quite often, forcing this program to run a garbage collection a few times a minute on my machine. I have set it much lower than 30- actually my normal FPS is in the 20s, so I set it to 14. But, perhaps because my video card is on the motherboard and only 128mb the FPS frequantly dips down to 14/13/12 then pops back up, sometimes as high as 30.

Would it be feasible - or even possible - to keep track of the last collection time and if it is within a certain amount of time and / or a certain amount of memory increase THEN run?

Not sure this would help, what are your thoughts? Thanks for your time.
Not really, that's not how incremental garbage collection works. If you don't have issues with the game as-is, feel free to not run the addon. Have you tried setting it as low as 10, and seeing how that effects you?
__________________
"There's only one thing that I know how to do well and I've often been told that you only can do what you know how to do well, and that's be you-- be what you're like-- be like yourself. And so I'm having a wonderful time, but I'd rather be whistling in the dark..."
Cladhaire is offline Report comment to moderator  
Reply With Quote
Unread 09-08-07, 02:52 AM  
stqn
A Deviate Faerie Dragon

Forum posts: 10
File comments: 76
Uploads: 0
Originally posted by Flarin
I play on a laptop and my FPS fluctuates quite often, forcing this program to run a garbage collection a few times a minute on my machine. I have set it much lower than 30- actually my normal FPS is in the 20s, so I set it to 14. But, perhaps because my video card is on the motherboard and only 128mb the FPS frequantly dips down to 14/13/12 then pops back up, sometimes as high as 30.
FYI, the recommended VRAM for WoW is only 64MB, which is what I have on my laptop, and the game runs fine! However I have disabled a few graphics options and enabled LOD.

More interesting to you and users of GCTweak, I think, is the AddOn FrameRate Adjuster which lets you select a desired frame rate (say, 30 fps), and will automatically change the distance of vision to try and keep that frame rate.

I have both FRA and GCT set to 35 fps, and GCTweak seems to be running not so often with no remarkable drop in frame rate... I can't say if GCT changed anything yet though.
stqn is offline Report comment to moderator  
Reply With Quote
Unread 09-08-07, 07:59 AM  
Cladhaire
Salad!
 
Cladhaire's Avatar
WoWInterface Super Moderator
AddOn Author - Click to view AddOns

Forum posts: 1933
File comments: 4479
Uploads: 18
I have both FRA and GCT set to 35 fps, and GCTweak seems to be running not so often with no remarkable drop in frame rate... I can't say if GCT changed anything yet though. [/b]
Testing GCT is really simple, and I can assure you, it's working :P
__________________
"There's only one thing that I know how to do well and I've often been told that you only can do what you know how to do well, and that's be you-- be what you're like-- be like yourself. And so I'm having a wonderful time, but I'd rather be whistling in the dark..."
Cladhaire is offline Report comment to moderator  
Reply With Quote
Unread 09-09-07, 01:32 AM  
stqn
A Deviate Faerie Dragon

Forum posts: 10
File comments: 76
Uploads: 0
Originally posted by Cladhaire
Testing GCT is really simple, and I can assure you, it's working :P
I'm sure you're right . When I wrote the last post, I hadn't read your explanation on the official WoW forums. I thought GCT only did something when it displayed a message (with messages enabled, of course.)

Now, after looking at the source code, I think I understand: GCT triggers a Garbage Collection step at each frame (when the fps count is high enough), but that step takes a very short amount of time, so there's no way that can trigger a drop in frame rate. The only noticeable effect would be the AddOns memory usage decreasing. When GCT tells us that it finished a GC cycle, it doesn't mean that it did more work than in the previous frames...
Last edited by stqn : 09-09-07 at 01:36 AM.
stqn is offline Report comment to moderator  
Reply With Quote
Unread 09-09-07, 07:32 AM  
Cladhaire
Salad!
 
Cladhaire's Avatar
WoWInterface Super Moderator
AddOn Author - Click to view AddOns

Forum posts: 1933
File comments: 4479
Uploads: 18
Originally posted by stqn
I'm sure you're right . When I wrote the last post, I hadn't read your explanation on the official WoW forums. I thought GCT only did something when it displayed a message (with messages enabled, of course.)

Now, after looking at the source code, I think I understand: GCT triggers a Garbage Collection step at each frame (when the fps count is high enough), but that step takes a very short amount of time, so there's no way that can trigger a drop in frame rate. The only noticeable effect would be the AddOns memory usage decreasing. When GCT tells us that it finished a GC cycle, it doesn't mean that it did more work than in the previous frames...
Correct, thats just a message to let you know that your memory should be close to the base, since a full garbage collection cycle will have just completed. Make 2 megs worth of garbage without GCT, and see how long it takes for it to get collected. Then enable GCT, and see the difference.
__________________
"There's only one thing that I know how to do well and I've often been told that you only can do what you know how to do well, and that's be you-- be what you're like-- be like yourself. And so I'm having a wonderful time, but I'd rather be whistling in the dark..."
Cladhaire is offline Report comment to moderator  
Reply With Quote
Unread 09-09-07, 12:45 PM  
MidgetMage55
Grinch!
 
MidgetMage55's Avatar
AddOn Author - Click to view AddOns

Forum posts: 1498
File comments: 66
Uploads: 2
Never fails that when you release a mod i alway end up adding it to my favorites. Another fantastic mod!
__________________

I think Hong Kong Phooey was a ninja AND a pirate. That was just too much awesome. - Yhor
MidgetMage55 is offline Report comment to moderator  
Reply With Quote
Unread 09-10-07, 08:36 AM  
Geboran
A Rage Talon Dragon Guard

Forum posts: 308
File comments: 34
Uploads: 0
I have been having issues with frame rates and could use some help trying to get them "higher".

I currently have 1GB of ram in my machine and a 256mb video card. Even without the recommended 2GB of ram WoW should run pretty good, right?

I average somewhere in the neighborhood between 2fps to 10fps in large cities and some battlegrounds at times, and anywhere from 11fps-25fps everywhere else. What would I need to set this addon at in order to help with frame rates?

Also.... any suggestions on other addons to use to help with adjusting the framerates to 30+?

Regards,
__________________
------------------------------------------
Geboran - Level 70 Paladin
<Evolution>
Stormreaver (US), Alliance
Geboran is offline Report comment to moderator  
Reply With Quote
Unread 09-10-07, 10:35 AM  
Cladhaire
Salad!
 
Cladhaire's Avatar
WoWInterface Super Moderator
AddOn Author - Click to view AddOns

Forum posts: 1933
File comments: 4479
Uploads: 18
Originally posted by Geboran
I have been having issues with frame rates and could use some help trying to get them "higher".

I currently have 1GB of ram in my machine and a 256mb video card. Even without the recommended 2GB of ram WoW should run pretty good, right?

I average somewhere in the neighborhood between 2fps to 10fps in large cities and some battlegrounds at times, and anywhere from 11fps-25fps everywhere else. What would I need to set this addon at in order to help with frame rates?

Also.... any suggestions on other addons to use to help with adjusting the framerates to 30+?

Regards,
Your video settings are the #1 reason for FPS drops. This addon serves another purpose entirely, which is to help clean up excess garbage when the UI gets behind. As for framerates, tinkering with your video settings will be the biggest gain you find.
__________________
"There's only one thing that I know how to do well and I've often been told that you only can do what you know how to do well, and that's be you-- be what you're like-- be like yourself. And so I'm having a wonderful time, but I'd rather be whistling in the dark..."
Cladhaire is offline Report comment to moderator  
Reply With Quote
Unread 09-10-07, 11:02 AM  
Geboran
A Rage Talon Dragon Guard

Forum posts: 308
File comments: 34
Uploads: 0
Right. And I see a noticable difference when I use the addon "as is".

I was hoping to hear from some more experienced players how I should go about adjusting my video settings to increase FPS without degrading video quality so much that it makes the game "unplayable".
__________________
------------------------------------------
Geboran - Level 70 Paladin
<Evolution>
Stormreaver (US), Alliance
Geboran is offline Report comment to moderator  
Reply With Quote
Unread 09-10-07, 11:05 AM  
Cladhaire
Salad!
 
Cladhaire's Avatar
WoWInterface Super Moderator
AddOn Author - Click to view AddOns

Forum posts: 1933
File comments: 4479
Uploads: 18
Originally posted by Geboran
Right. And I see a noticable difference when I use the addon "as is".

I was hoping to hear from some more experienced players how I should go about adjusting my video settings to increase FPS without degrading video quality so much that it makes the game "unplayable".
There is an older addon that changes your video decisions depending on which zone you're in. I dont recall what it would be called right now.. but its the best I can think of.
__________________
"There's only one thing that I know how to do well and I've often been told that you only can do what you know how to do well, and that's be you-- be what you're like-- be like yourself. And so I'm having a wonderful time, but I'd rather be whistling in the dark..."
Cladhaire is offline Report comment to moderator  
Reply With Quote
Post A Reply



Category Jump:

Support AddOn Development!

You have just downloaded by the author . If you like this AddOn why not consider supporting the author? This author has set up a donation account. Donations ensure that authors can continue to develop useful tools for everyone.