建造LLVM吞噬了所有的公羊
我一直在尝试在系统[i7 + 16GB RAM]上安装LLVM。我一直在关注本教程:。但是在建筑物中,它会自动吞噬所有RAM,并且终端会自动关闭。有什么办法解决这个问题吗?
谢谢。
I have been trying to install LLVM on my system [i7 + 16GB RAM]. I have been following this tutorial : LLVM Install. But in building, it eats up all the RAM and the terminal closes automatically. Is there any way to solve this?
Thanks.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
构建过程中消耗的资源可能取决于各种因素:
build_shared_libs:on
)将减少内存的方式。-jn
用于降低RAM压力的TLDR:
Jn
尝试,-J(J)( n-2)
)。使用-J1
可能会使用较少的RAM,但需要很长时间才能构建。llvm_enable_runtimes
)和目标(例如,llvm_targets_to_build
)。这可能并不是微不足道的,因为它需要花费时间与cmakecache.txt文件。ninja
,而是调用ninja clang
或ninja opt
等。The resources consumed during build can depend on various factors:
BUILD_SHARED_LIBS:ON
) will consume way less memory.-jN
TLDR for reducing RAM pressure:
jN
try,-j(N-2)
). Using-j1
may use less RAM but would take long time to build.LLVM_ENABLE_RUNTIMES
) and targets (e.g.,LLVM_TARGETS_TO_BUILD
) as you can. This may not be trivial as it requires spending time with the CMakeCache.txt file.ninja
, invokeninja clang
, orninja opt
etc.我在这个项目上度过了半天。
我有一台PC i7,带有24GB的RAM基unubuntu 22.04。我尝试过(很多次),但不可能用GCC编译(我不是为什么)。
系统监视器有时显示20GB RAM的使用情况,无法达到汇编结束。构建系统(我选择的忍者)崩溃了很多次。
最后,我安装了Clang。
RAM使用率从未超过8GB。
我报告了我所做的事情(如果可以帮助任何人)
preesion ninja warree ninja conter以下链接如何用clang构建clang?
I've spent half day on this item.
I've a PC i7 with 24GB of RAM based un Ubuntu 22.04. I tried (many times) but was not possible to compile with gcc (and I don't why).
The system monitor sometimes shown 20GB ram usage and wasn't possible to reach the end of the compilation. The build system (I choosen ninja) crashed many times.
At the end I installed clang.
The ram usage never gone over 8GB.
I report what I did (if can help anyone)
follow this link How to build clang with clang?