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

Disable x265 Neon_Dotprod+ ASM on Linux/Arm64 for now #538

Merged
merged 2 commits into from
Feb 22, 2025
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
8 changes: 4 additions & 4 deletions builder/images/base-linuxarm64/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ RUN git clone --filter=blob:none --depth=1 https://github.com/yugr/Implib.so /op

ENV FFBUILD_TOOLCHAIN=aarch64-ffbuild-linux-gnu
ENV PATH="/opt/ct-ng/bin:${PATH}" \
FFBUILD_TARGET_FLAGS="--pkg-config=pkg-config --pkg-config-flags=--static --cross-prefix=${FFBUILD_TOOLCHAIN}- --arch=aarch64 --target-os=linux" \
FFBUILD_TARGET_FLAGS="--pkg-config=pkg-config --pkg-config-flags=--static --cross-prefix=${FFBUILD_TOOLCHAIN}- --arch=aarch64 --cpu=armv8-a --target-os=linux" \
FFBUILD_CROSS_PREFIX="${FFBUILD_TOOLCHAIN}-" \
FFBUILD_RUST_TARGET="aarch64-unknown-linux-gnu" \
FFBUILD_PREFIX=/opt/ffbuild \
Expand All @@ -56,8 +56,8 @@ ENV PATH="/opt/ct-ng/bin:${PATH}" \
AR="${FFBUILD_TOOLCHAIN}-gcc-ar" \
RANLIB="${FFBUILD_TOOLCHAIN}-gcc-ranlib" \
NM="${FFBUILD_TOOLCHAIN}-gcc-nm" \
CFLAGS="-static-libgcc -static-libstdc++ -I/opt/ffbuild/include -O2 -pipe -fPIC -DPIC -D_FORTIFY_SOURCE=2 -fstack-protector-strong -pthread" \
CXXFLAGS="-static-libgcc -static-libstdc++ -I/opt/ffbuild/include -O2 -pipe -fPIC -DPIC -D_FORTIFY_SOURCE=2 -fstack-protector-strong -pthread" \
LDFLAGS="-static-libgcc -static-libstdc++ -L/opt/ffbuild/lib -O2 -pipe -fstack-protector-strong -Wl,-z,relro,-z,now -pthread -lm" \
CFLAGS="-static-libgcc -static-libstdc++ -I/opt/ffbuild/include -O2 -pipe -march=armv8-a -fPIC -DPIC -D_FORTIFY_SOURCE=2 -fstack-protector-strong -pthread" \
CXXFLAGS="-static-libgcc -static-libstdc++ -I/opt/ffbuild/include -O2 -pipe -march=armv8-a -fPIC -DPIC -D_FORTIFY_SOURCE=2 -fstack-protector-strong -pthread" \
LDFLAGS="-static-libgcc -static-libstdc++ -L/opt/ffbuild/lib -O2 -pipe -march=armv8-a -fstack-protector-strong -Wl,-z,relro,-z,now -pthread -lm" \
STAGE_CFLAGS="-fvisibility=hidden -fno-semantic-interposition" \
STAGE_CXXFLAGS="-fvisibility=hidden -fno-semantic-interposition"
11 changes: 11 additions & 0 deletions builder/scripts.d/50-x265.sh
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,17 @@ ffbuild_dockerbuild() {
)
fi

# Wa for https://bitbucket.org/multicoreware/x265_git/issues/984/illegal-instruction-neon_dotprod-crashes
if [[ $TARGET == linuxarm64 ]]; then
common_config+=(
-DENABLE_NEON=ON
-DENABLE_NEON_DOTPROD=OFF
-DENABLE_NEON_I8MM=OFF
-DENABLE_SVE=OFF
-DENABLE_SVE2=OFF
)
fi

if [[ $TARGET != *32 ]]; then
mkdir 8bit 10bit 12bit
cmake "${common_config[@]}" -DHIGH_BIT_DEPTH=ON -DEXPORT_C_API=OFF -DENABLE_HDR10_PLUS=ON -DMAIN12=ON -S source -B 12bit &
Expand Down
Loading