Specifying jemalloc
Bisheng Compiler supports the jemalloc library. jemalloc is a general malloc implementation that is integrated into the toolchain as a dynamic library to reduce memory fragments and improve concurrency performance.
Enabling mode:
1 | clang -O3 -ljemalloc |
The dynamic link library file of jemalloc is stored in the BiShengCompiler-4.1.0-aarch64-linux/lib directory. You can use -ljemalloc only after this directory is added to LD_LIBRARY_PATH. Otherwise, you need to add -L$(library) to specify the library path during compilation.
Parent topic: BiSheng Compiler Options