Too much RAM being used for compilation. #1148
Replies: 3 comments
-
Are you sure that is correct? The Intel(R) Core(TM) i7-8750H CPU that you listed has 6 cores, and 12 threads. Have you tried limiting the number of parallel project builds? For example: For your CPU it would be set to 12, so reduce it until you get acceptable memory usage. Check this info as well to see if it helps: |
Beta Was this translation helpful? Give feedback.
-
Another way: |
Beta Was this translation helpful? Give feedback.
-
@TheNachoBIT Unless I'm mistaken, this is not a bug or an issue related to Axmol, but rather related to compiling large C++ projects on your system. The more appropriate place for this topic would have been dicussions. @halx99 If you agree that this isn't a problem with Axmol, then please do move this to the discussions forum. |
Beta Was this translation helpful? Give feedback.
-
Issue:
In the process of compiling the game, when building the engine, 16 cl.exe processes kick in (because i'm using an 8-core CPU).
All of them start slowly when they start compiling the first "CC(Name).cpp" files, with each process consuming about 20MB-30MB of RAM, so far so good.
But after the first 10 scripts, that memory will start increasing, resulting in all 16 cl.exe processes consuming up to 400MB-500MB and that number keeps increasing, at this point it starts to consume from 3.8GB to 4.5GB of RAM, and in 10 seconds this value goes much higher.
It comes to a point where there's not enough RAM and its starts asking for Virtual Memory, which obviously freezes the machine, and it can stay frozen for 30 minutes or more, to the point that you can't move the mouse because of how slow it gets.
This is dangerous because it can put the machine in risk of getting a BSOD due to running out of memory (it happened to me once trying to compile and test another big engine).
I tried applying every setting:
-j2
to the cmake build command. Nothing changes./cgthreads2
in theCMAKE_CXX_FLAGS
. Nothing changes.CMAKE_BUILD_PARALLEL_LEVEL
to 2. Nothing changes.So I really don't know what to do to compile it without making it a RAM eater.
If you need more info about this please let me know.
Beta Was this translation helpful? Give feedback.
All reactions