Skip to content

Instantly share code, notes, and snippets.

@SafeteeWoW
Created December 12, 2017 11:13
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save SafeteeWoW/73fcc52a141376c200acab0606555c75 to your computer and use it in GitHub Desktop.
Save SafeteeWoW/73fcc52a141376c200acab0606555c75 to your computer and use it in GitHub Desktop.
local libS = LibStub:GetLibrary("AceSerializer-3.0")
local libR = LibStub:GetLibrary("RCSerializer-3.0")
local libC = LibStub:GetLibrary("LibCompress")
local libCE = libC:GetAddonEncodeTable()
local t = RCLootCouncil.db.profile
local s1 = libS:Serialize(t)
local c1 = libCE:Encode(libC:Compress(s1))
print("AceSerializer", s1:len())
print("After Compress", c1:len())
local s2 = libR:Serialize(t)
local c2 = libCE:Encode(libC:Compress(s2))
print("RCSerializer", s2:len())
print("After Compress", c2:len())
print("Improvment: " ,(c1:len()-c2:len())/c1:len()*100)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment