Created
February 22, 2017 01:51
-
-
Save andreasnoack/52027e05d62a65d0c8c077ebdf1cf91e to your computer and use it in GitHub Desktop.
Memory debuggin in Julia
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Yichao: | |
1. no need to edit any code | |
2. compile it with `WITH_GC_DEBUG_ENV` make variable | |
this should enable detection of 4 envs | |
and turn on gc verifier | |
(so the gc will be much slower even without any env set) | |
the three I used the most often are `JULIA_GC_ALLOC_PRINT=0:10 JULIA_GC_ALLOC_OTHER=r0:1000 JULIA_GC_ALLOC_POOL=r0:1000` | |
(not the default val, just whatever copied from my cmdline history) | |
Andreas: | |
so just something like `cd src;make clean;make WITH_GC_DEBUG_ENV=1` should do it? | |
Yichao: | |
right | |
format is, "r"(optional, randomize interval when specified) | |
and `start[:step[:end]]` | |
step default to 1 | |
end default to max int |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment