JuliaSIMD / JuliaSIMD/VectorizationBase.jl
Compilation on Linux fails
- Dominant language
- Julia
- Stars
- 72
- Forks
- 34
- PR merge metrics
- No merged PRs in 30d
Description
PackageCompiler AOT compilation fails with VectorizationBase on x86_64 when using the default portable CPU target.
Environment:
- Linux x86_64, Intel Xeon Gold 5120 (Skylake-SP, AVX-512)
- Julia 1.13.0; also reproduced with Julia 1.12.7
- current VectorizationBase
- current PackageCompiler
A normal Julia/JIT session works.
Minimal package:
Project.toml:
```
name = "VBAOTTest"
uuid = "a9bc8f41-f73d-4d89-b50e-5e279b86c421"
version = "0.1.0"
[deps]
VectorizationBase = "3d5dd08c-fd9d-11e8-17fa-ed2836048c2f"
```
src/VBAOTTest.jl:
```
module VBAOTTest
using VectorizationBase
function julia_main()::Cint
println("VBAOTTest")
return 0
end
end
```
The following code then fails:
```
using PackageCompiler
create_app(
pwd(),
joinpath(pwd(), "build");
executables = ["vbtest" => "julia_main"],
incremental = true,
force = true,
)
```
The error message is
```
LLVM ERROR: Cannot select:
... = X86ISD::RCP14 ...
In function: julia_inv_approx_...
```
with the source pointing to `VectorizationBase/src/llvm_intrin/intrin_funcs.jl`.
These are the results of some experiments with different configurations:
- default PackageCompiler cpu_target -> FAIL
- cpu_target="generic" -> FAIL
- cpu_target="skylake-avx512" -> SUCCESS
Removing the precompile workload from the original application does not change the failure.
Contributor guide
No contributing guide indexed for this repository
Research direction
Start with the minimal VBAOTTest package and the PackageCompiler create_app call, then inspect VectorizationBase/src/llvm_intrin/intrin_funcs.jl around the intrinsic producing julia_inv_approx_. Compare the default and generic cpu_target failures with the successful skylake-avx512 build; done means the portable AOT build succeeds without changing the reported application setup.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- julia
- Domain
- build-system, compilers
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Active
- Clarity
- Mostly clear
- Newbie friendliness
- 48/100