perf: change flags, add optimizations

This commit is contained in:
DarkCat09 2025-03-13 20:20:46 +04:00
parent 11e8999e66
commit 6b3da81ed3
Signed by: DarkCat09
SSH key fingerprint: SHA256:SnH1iYY/ogxxRmt1I6piy+aVUUzrOWvfksQWfhZ8JUM

View file

@ -27,11 +27,13 @@ RUN git clone --single-branch --depth 1 \
WORKDIR /build/src
RUN bash get_source.sh
ENV CC=/usr/bin/gcc CXX=/usr/bin/g++ \
CFLAGS="-O3 -flto -fuse-linker-plugin" \
LDFLAGS="-Wl,-O1"
RUN bash configure \
--enable-libffi-bundling --enable-ddr --enable-jitserver \
--enable-fallback-linker --with-jtreg=/build/jtreg --with-boot-jdk=/build/bootjdk \
--with-openssl=system --with-extra-ldflags="-Wl,-z,noexecstack"
--with-boot-jdk=/build/bootjdk \
--with-openssl=system \
--enable-jvm-feature-link-time-opt
RUN make all JOBS=$(nproc)
# jlink by advice from https://adoptium.net/blog/2021/10/jlink-to-produce-own-runtime/