Skip to content

Instantly share code, notes, and snippets.

@pawlos
Created January 14, 2017 11:23
Show Gist options
  • Save pawlos/6a5977436f8c9e60561d4afc63d9bfaa to your computer and use it in GitHub Desktop.
Save pawlos/6a5977436f8c9e60561d4afc63d9bfaa to your computer and use it in GitHub Desktop.
Check the amount of allocated memory
for t=1,500 do
for i=1,2 do
local l = "Hello world"
x = function() print(l) end
end
end
print(collectgarbage("count") * 1024)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment