##################################################################### Build instruction for Debian 11/Bullseye and 12/Bookworm arm64/aarch64 ###################################################################### Add LLVM/Clang 18 repository under su to file /etc/apt/sources.list.d/llvm18.list: If using Debian 11/Bullseye: $ su - # echo -e "deb [trusted=yes] http://apt.llvm.org/bullseye/ llvm-toolchain-bullseye-18 main \ndeb-src [trusted=yes] http://apt.llvm.org/bullseye/ llvm-toolchain-bullseye-18 main" >> /etc/apt/sources.list.d/llvm18.list If using Debian 12/Bookworm: $ su - # echo -e "deb [trusted=yes] http://apt.llvm.org/bookworm/ llvm-toolchain-bookworm-18 main \ndeb-src [trusted=yes] http://apt.llvm.org/bookworm/ llvm-toolchain-bookworm-18 main" >> /etc/apt/sources.list.d/llvm18.list Proceed to apt update and install necessary packages. E.g. clang-18 clang-tools-18 llvm-18 libclang-rt-18-dev Leave su and return to "user mode": # exit Download neural-amp-modeler-lv2 source code and enter the build directory: $ cd /tmp && git clone --recurse-submodules -j4 https://github.com/mikeoliphant/neural-amp-modeler-lv2 && cd neural-amp-modeler-lv2/build Export Clang 18 flags/parameters (compile with -Og) and then compile: $ export CC=clang-18 && export CXX=clang++-18 && export LD=lld-18 && export CFLAGS="-Og -fprofile-generate=/tmp/neural-amp-modeler-lv2/build" && export CXXFLAGS="-Og -fprofile-generate=/tmp/neural-amp-modeler-lv2/build" && export LDFLAGS="-Og -fprofile-generate=/tmp/neural-amp-modeler-lv2/build" $ cmake .. && make - Copy the created "neural_amp_modeler.lv2" folder to ~/.lv2/ - Run the plugin with your LV2 host of choice and try load several models with different activators, algorithms, settings, etc and adjust sliders randomly. - Close the plugin/host A .profraw file has been created in /tmp/neural-amp-modeler-lv2/build/ Go back to build directory and convert the .profraw data to "profile.profdata": $ cd /tmp/neural-amp-modeler-lv2/build/ $ llvm-profdata-18 merge -output profile.profdata RENAMETOACTUALFILENAME.profraw Remove all files in /tmp/neural-amp-modeler-lv2/build/ EXCEPT for profile.profdata . Compile with optimized flags/parameters: $ export CC=clang-18 && export CXX=clang++-18 && export LD=lld-18 && export CFLAGS="-Ofast -flto=thin -fopenacc -fopenmp -march=native -fprofile-use=/tmp/neural-amp-modeler-lv2/build/profile.profdata" && export CXXFLAGS="-Ofast -flto=thin -fopenacc -fopenmp -march=native -fprofile-use=/tmp/neural-amp-modeler-lv2/build/profile.profdata" && export LDFLAGS="-Ofast -flto=thin -fopenacc -fopenmp -march=native -fprofile-use=/tmp/neural-amp-modeler-lv2/build/profile.profdata" $ cmake .. -DBUILD_SHARED_LIBS=0 && make Move newly compiled optimized files and folder neural_amp_modeler.lv2 to directory ~/.lv2/ . Replace old files. Now you should have the following files: ~/.lv2/neural_amp_modeler.lv2/manifest.ttl ~/.lv2/neural_amp_modeler.lv2/neural_amp_modeler.so ~/.lv2/neural_amp_modeler.lv2/neural_amp_modeler.ttl UPDATE 20240823: Removed "-DCMAKE_BUILD_TYPE=Release" from cmake command. Changed -O3 to -Ofast. Added -fopenmp -march=native // R Gerthsson