Movatterモバイル変換


[0]ホーム

URL:


GitHub

Linux

Architecture Customization

Julia can be built for a non-generic architecture by configuring theARCH Makefile variable in aMake.user file. See the appropriate section ofMake.inc for additional customization options, such asMARCH andJULIA_CPU_TARGET.

For example, to build for Pentium 4, setMARCH=pentium4 and install the necessary system libraries for linking. On Ubuntu, these may include lib32gfortran-6-dev, lib32gcc1, and lib32stdc++6, among others.

You can also setMARCH=native inMake.user for a maximum-performance build customized for the current machine CPU.

Linux Build Troubleshooting

ProblemPossible Solution
OpenBLAS build failureSet one of the following build options inMake.user and build again: <ul><li>OPENBLAS_TARGET_ARCH=BARCELONA (AMD CPUs) orOPENBLAS_TARGET_ARCH=NEHALEM (Intel CPUs)<ul>SetOPENBLAS_DYNAMIC_ARCH = 0 to disable compiling multiple architectures in a single binary.</ul></li><li>OPENBLAS_NO_AVX2 = 1 disables AVX2 instructions, allowing OpenBLAS to compile withOPENBLAS_DYNAMIC_ARCH = 1 using old versions of binutils </li><li>USE_SYSTEM_BLAS=1 uses the system providedlibblas <ul><li>SetLIBBLAS=-lopenblas andLIBBLASNAME=libopenblas to force the use of the system provided OpenBLAS when multiple BLAS versions are installed. </li></ul></li></ul><p> If you get an error that looks like../kernel/x86_64/dgemm_kernel_4x4_haswell.S:1709: Error: no such instruction: `vpermpd $ 0xb1,%ymm0,%ymm0', then you need to setOPENBLAS_DYNAMIC_ARCH = 0 orOPENBLAS_NO_AVX2 = 1, or you need a newer version ofbinutils (2.18 or newer). (Issue #7653)</p><p> If the linker cannot findgfortran and you get an error likejulia /usr/bin/x86_64-linux-gnu-ld: cannot find -lgfortran, check the path withgfortran -print-file-name=libgfortran.so and use the output to export something similar to this:export LDFLAGS=-L/usr/lib/gcc/x86_64-linux-gnu/8/. SeeIssue #6150.</p>
Illegal Instruction errorCheck if your CPU supports AVX while your OS does not (e.g. through virtualization, as described inthis issue).

Settings


This document was generated withDocumenter.jl version 1.16.0 onThursday 20 November 2025. Using Julia version 1.12.2.


[8]ページ先頭

©2009-2025 Movatter.jp