Open anj00 opened 2 years ago
I tried smaller json message and it looks like runnig fine. it is really once it gets big (both message itself and number of messages to parse) I seem to be able to repeat the crash
Maybe you are running out of memory? Did you monitor RAM usage? I can't reproduce the crash, but running the example consumes a lot of RAM.
Maybe, but I doubt. it crashes right away. I tried with "julia --threads 2" I don't see any memory spikes in the process monitor (but maybe because it crashes really fast). And I have 64GB total and 37GB available. In single treaded loop the available memory drops to 25GB. Then at the beginning of the multithreaded loop the available memory starts growing (gc?) and then crashes.
So if single threaded it went from 37 down to 25. then in really worst case 2 threads should be fine going down to 12GB. Should be plenty (and we don't yet count effects for swap, unloading unused apps and gc)
I can't reproduce the crash,
Nice, so maybe it is related to os or julia version or some other setup.
Just to double check you really got println("done parsing using $(Threads.nthreads()) threads")
? cause in my case the crash is silent. i.e. it looks like julia processed the file fine, but the above message just not present and this is the hint that it actually quit earlier than it finished the loop
Just to double check you really got println("done parsing using $(Threads.nthreads()) threads")
Yes.
This was on Linux, 8 threads, 16GB RAM.
Indeed, on the same windows pc running ubuntu linux as an app and running with julia 1.7.2, JSON v0.21.3
above code works all fine.
I also tried that code on another windows pc (clean julia/JSON install). And it crashes (silently) all the same
So it is really a Windows issue (not sure if it is JSON or deeper Julia's problem). Any idea how to move forward here?
Any chance solving this for windows users?
I have an array of relatively large JSON messages. They take a while to process in a single threaded loop. However trying to run the loop in multithreaded mode crashes julia. Wonder if this is JSON or julia bug (or my bug).
calling this file like this I 100% crash in the multithreaded loop (single thread runs fine all the time). I don't get any message julia just exits
julia --threads 16 debug_json.jl
I tried smaller json message and it looks like runnig fine. it is really once it gets big (both message itself and number of messages to parse) I seem to be able to repeat the crash
I run
Win10
,julia 1.7.2
andJSON v0.21.3
At this point I would be happy with a workaround if one exists.