build: switch back to clang-18 on alpine due to nilsimsa perf regression

This commit is contained in:
Marcus Holland-Moritz 2025-03-23 23:17:00 +01:00
parent cb883f6df4
commit 917ebdf00b
2 changed files with 6 additions and 3 deletions

View File

@ -16,6 +16,8 @@ RUN apk add --no-cache \
RUN apk add --no-cache \ RUN apk add --no-cache \
gcc \ gcc \
g++ \ g++ \
clang17 \
clang18 \
clang19 \ clang19 \
git \ git \
zstd \ zstd \
@ -54,6 +56,7 @@ RUN apk add --no-cache \
xz-static \ xz-static \
zstd-dev \ zstd-dev \
zstd-static \ zstd-static \
xxhash-dev \
lz4-dev \ lz4-dev \
range-v3-dev \ range-v3-dev \
libxml2-dev \ libxml2-dev \
@ -80,10 +83,9 @@ RUN wget -O - https://github.com/upx/upx/releases/download/v5.0.0/upx-5.0.0-$(ba
RUN pip3 install --break-system-packages --root-user-action ignore mistletoe RUN pip3 install --break-system-packages --root-user-action ignore mistletoe
RUN git config --global --add safe.directory /workspace RUN git config --global --add safe.directory /workspace
COPY install-static-libs.sh /usr/local/bin/install-static-libs.sh COPY install-static-libs.sh /usr/local/bin/install-static-libs.sh
RUN bash /usr/local/bin/install-static-libs.sh gcc clang-19 :alpine RUN bash /usr/local/bin/install-static-libs.sh gcc clang-18 :alpine
COPY install-mold.sh /usr/local/bin/install-mold.sh COPY install-mold.sh /usr/local/bin/install-mold.sh
RUN bash /usr/local/bin/install-mold.sh RUN bash /usr/local/bin/install-mold.sh
RUN adduser -G users -s bash -u 1000 -D mhx RUN adduser -G users -s bash -u 1000 -D mhx
RUN apk add --no-cache xxhash-dev
USER mhx USER mhx
ENTRYPOINT /workspace/.docker/build-linux.sh ENTRYPOINT /workspace/.docker/build-linux.sh

View File

@ -55,9 +55,10 @@ rm -rf build
mkdir build mkdir build
cd build cd build
# Stick to clang-18, clang-19 has a regression for nilsimsa performance
if [[ "$BUILD_DIST" == "alpine" ]]; then if [[ "$BUILD_DIST" == "alpine" ]]; then
GCC_VERSION= GCC_VERSION=
CLANG_VERSION=-19 CLANG_VERSION=-18
elif [[ "$BUILD_DIST" == "ubuntu-2204" ]]; then elif [[ "$BUILD_DIST" == "ubuntu-2204" ]]; then
GCC_VERSION=-12 GCC_VERSION=-12
CLANG_VERSION=-15 CLANG_VERSION=-15