Squashed history of the earlier README and patch commits. Original history kept locally on branch backup/pre-squash. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019W3rwtugSE5NbbiWQCbbKX
16 lines
1.1 KiB
Lua
16 lines
1.1 KiB
Lua
format = string.format; local now = 1000; function GetTime() return now end
|
|
function UnitAffectingCombat() return true end function UnitIsAFK() return false end
|
|
DEFAULT_CHAT_FRAME = { AddMessage = function(_, m) print(" " .. m) end }; SlashCmdList = {}
|
|
local F; function CreateFrame() local G = { e = {} }; F = F or G; local F = G; function F:RegisterEvent(x) end; function F:UnregisterEvent() end; function F:SetScript(k, f) self[k] = f end; return F end
|
|
collectgarbage(); dofile(arg[1]); event, arg1 = "ADDON_LOADED", "GentleGC"; F.OnEvent()
|
|
SlashCmdList.GENTLEGC("headroom 4"); SlashCmdList.GENTLEGC("debug 2")
|
|
event = "PLAYER_REGEN_DISABLED"; F.OnEvent()
|
|
local _, t1 = gcinfo()
|
|
local keep = {} for i = 1, 60000 do keep[i] = {i} end -- live growth past raised threshold
|
|
keep = nil; local g = {} for i = 1, 60000 do g[i] = {i} end g = nil
|
|
arg1 = 1.1; F.OnUpdate()
|
|
local used, t2 = gcinfo()
|
|
print("re-raised headroom after in-combat auto GC:", t2 >= used + 4*1024 - 1 and "PASS" or "FAIL", t1, t2, used)
|
|
event = "PLAYER_REGEN_ENABLED"; F.OnEvent()
|
|
SlashCmdList.GENTLEGC("status")
|