Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add RISC-V + all default targets to LLVM build #788

Merged
merged 3 commits into from
Nov 23, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion conda-recipes/llvmdev/bld.bat
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,9 @@ set BUILD_CONFIG=Release
REM === Configure step ===

REM allow setting the targets to build as an environment variable
REM default is LLVM 11 default architectures + RISCV. Can remove this entire option in LLVM 13
if "%LLVM_TARGETS_TO_BUILD%"=="" (
set "LLVM_TARGETS_TO_BUILD=host;AMDGPU;NVPTX"
set "LLVM_TARGETS_TO_BUILD=host;AArch64;AMDGPU;ARM;BPF;Hexagon;Mips;MSP430;NVPTX;PowerPC;Sparc;SystemZ;X86;XCore;RISCV"
)
if "%ARCH%"=="32" (
set "ARCH_POSTFIX="
Expand Down
11 changes: 9 additions & 2 deletions conda-recipes/llvmdev/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@
set -x

# allow setting the targets to build as an environment variable
LLVM_TARGETS_TO_BUILD=${LLVM_TARGETS_TO_BUILD:-"host;AMDGPU;NVPTX"}
# default is LLVM 11 default architectures + RISCV. Can remove this entire option in LLVM 13
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, checked.

LLVM_TARGETS_TO_BUILD=${LLVM_TARGETS_TO_BUILD:-"host;AArch64;AMDGPU;ARM;BPF;Hexagon;Mips;MSP430;NVPTX;PowerPC;Sparc;SystemZ;X86;XCore;RISCV"}

# This is the clang compiler prefix
DARWIN_TARGET=x86_64-apple-darwin13.4.0
Expand Down Expand Up @@ -87,5 +88,11 @@ make install || exit $?
if [[ $ARCH == 'x86_64' ]]; then
bin/opt -S -vector-library=SVML -mcpu=haswell -O3 $RECIPE_DIR/numba-3016.ll | bin/FileCheck $RECIPE_DIR/numba-3016.ll || exit $?
fi

# run the tests, skip some on linux-32
cd ../test
../build/bin/llvm-lit -vv Transforms ExecutionEngine Analysis CodeGen/X86
if [[ $ARCH == 'i686' ]]; then
../build/bin/llvm-lit -vv Transforms Analysis CodeGen/X86
else
../build/bin/llvm-lit -vv Transforms ExecutionEngine Analysis CodeGen/X86
fi
2 changes: 1 addition & 1 deletion conda-recipes/llvmdev/meta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
{% set version = "11.1.0" %}
{% set sha256_llvm = "ce8508e318a01a63d4e8b3090ab2ded3c598a50258cc49e2625b9120d4c03ea5" %}
{% set sha256_lld = "017a788cbe1ecc4a949abf10755870519086d058a2e99f438829aef24f0c66ce" %}
{% set build_number = "3" %}
{% set build_number = "4" %}

package:
name: llvmdev
Expand Down
3 changes: 2 additions & 1 deletion conda-recipes/llvmdev_manylinux2014/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,8 @@ _cmake_config+=(-DHAVE_TERMIOS_H=OFF)
_cmake_config+=(-DCLANG_ENABLE_LIBXML=OFF)
_cmake_config+=(-DLIBOMP_INSTALL_ALIASES=OFF)
_cmake_config+=(-DLLVM_ENABLE_RTTI=OFF)
_cmake_config+=(-DLLVM_TARGETS_TO_BUILD="host;AMDGPU;NVPTX")
# default is LLVM 11 default architectures + RISCV. Can remove this entire option in LLVM 13
_cmake_config+=(-DLLVM_TARGETS_TO_BUILD="host;AArch64;AMDGPU;ARM;BPF;Hexagon;Mips;MSP430;NVPTX;PowerPC;Sparc;SystemZ;X86;XCore;RISCV")
_cmake_config+=(-DLLVM_EXPERIMENTAL_TARGETS_TO_BUILD=WebAssembly)
_cmake_config+=(-DLLVM_INCLUDE_UTILS=ON) # for llvm-lit
# TODO :: It would be nice if we had a cross-ecosystem 'BUILD_TIME_LIMITED' env var we could use to
Expand Down
2 changes: 1 addition & 1 deletion conda-recipes/llvmdev_manylinux2014/meta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
{% set version = "11.1.0" %}
{% set sha256_llvm = "ce8508e318a01a63d4e8b3090ab2ded3c598a50258cc49e2625b9120d4c03ea5" %}
{% set sha256_lld = "017a788cbe1ecc4a949abf10755870519086d058a2e99f438829aef24f0c66ce" %}
{% set build_number = "2" %}
{% set build_number = "3" %}

package:
name: llvmdev
Expand Down