From a53f34ff026bd4411cb9088b9441b01fcbcd9997 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcel=20M=C3=A4rtens?= Date: Wed, 14 Jul 2021 10:55:11 +0200 Subject: [PATCH 1/4] alternative to packaged_simd, as coverage does not compile withit, and it was left out in the simd feature --- world/Cargo.toml | 4 ++-- world/src/sim/erosion.rs | 16 +++++++++++++++- 2 files changed, 17 insertions(+), 3 deletions(-) diff --git a/world/Cargo.toml b/world/Cargo.toml index 954655f844..3ccc6027b5 100644 --- a/world/Cargo.toml +++ b/world/Cargo.toml @@ -5,7 +5,7 @@ authors = ["Joshua Barretto "] edition = "2018" [features] -simd = ["vek/platform_intrinsics"] +simd = ["vek/platform_intrinsics", "packed_simd"] bin_compression = ["lz-fear", "deflate", "flate2", "image/jpeg", "num-traits", "fallible-iterator", "kiddo", "clap", "rstar"] default = ["simd"] @@ -31,7 +31,7 @@ tracing = { version = "0.1", default-features = false } rand = "0.8" rand_chacha = "0.3" arr_macro = "0.1.2" -packed_simd = { package = "packed_simd_2", version = "0.3.5" } +packed_simd = { package = "packed_simd_2", version = "0.3.5", optional = true } rayon = "1.5" serde = { version = "1.0.110", features = ["derive"] } ron = { version = "0.6", default-features = false } diff --git a/world/src/sim/erosion.rs b/world/src/sim/erosion.rs index 9c83253c66..c73ac49b97 100644 --- a/world/src/sim/erosion.rs +++ b/world/src/sim/erosion.rs @@ -13,7 +13,7 @@ use itertools::izip; use noise::NoiseFn; use num::{Float, Zero}; use ordered_float::NotNan; -use packed_simd::m32; +#[cfg(feature = "simd")] use packed_simd::m32; use rayon::prelude::*; use std::{ cmp::{Ordering, Reverse}, @@ -607,6 +607,20 @@ fn get_max_slope( .into_boxed_slice() } +//simd alternative +#[cfg(not(feature = "simd"))] +#[derive(Copy, Clone)] +#[allow(non_camel_case_types)] +struct m32(u32); +#[cfg(not(feature = "simd"))] +impl m32 { + #[inline] + fn new(x: bool) -> Self { if x { Self(u32::MAX) } else { Self(u32::MIN) } } + + #[inline] + fn test(&self) -> bool { self.0 != 0 } +} + /// Erode all chunks by amount. /// /// Our equation is: From 6cb502c229d0dce8496e07e1706a02104936f714 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcel=20M=C3=A4rtens?= Date: Wed, 14 Jul 2021 10:25:29 +0200 Subject: [PATCH 2/4] extract relevant code in a script in order to remove duplicate coding with docker-ci repo export VELOREN_ASSETS without pwd to keep caching working --- .gitlab-ci.yml | 6 +----- .gitlab/CI/build.gitlab-ci.yml | 36 +++++++++------------------------ .gitlab/CI/check.gitlab-ci.yml | 10 ++++----- .gitlab/scripts/benchmark.sh | 4 ++++ .gitlab/scripts/ci.sh | 4 ++++ .gitlab/scripts/code-quality.sh | 6 ++++++ .gitlab/scripts/coverage.sh | 7 +++++++ .gitlab/scripts/env.sh | 6 ++++++ .gitlab/scripts/linux.sh | 6 ++++++ .gitlab/scripts/security.sh | 2 ++ .gitlab/scripts/unittest.sh | 7 +++++++ .gitlab/scripts/windows.sh | 7 +++++++ world/src/sim/erosion.rs | 2 +- 13 files changed, 65 insertions(+), 38 deletions(-) create mode 100755 .gitlab/scripts/benchmark.sh create mode 100755 .gitlab/scripts/ci.sh create mode 100755 .gitlab/scripts/code-quality.sh create mode 100755 .gitlab/scripts/coverage.sh create mode 100644 .gitlab/scripts/env.sh create mode 100755 .gitlab/scripts/linux.sh create mode 100755 .gitlab/scripts/security.sh create mode 100755 .gitlab/scripts/unittest.sh create mode 100755 .gitlab/scripts/windows.sh diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 2f165589cd..0419b023a1 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -33,11 +33,7 @@ before_script: - df -h / - free -h - cargo --version - - export DISABLE_GIT_LFS_CHECK=true - - export VELOREN_ASSETS="$(pwd)/assets" - - echo "VELOREN_ASSETS=$VELOREN_ASSETS" - - export RUSTFLAGS="-D warnings" - - export SHADERC_LIB_DIR=/shaderc/combined/ + - source ./.gitlab/scripts/env.sh - rm -rf target || echo "it seems that sometimes OLD data is left over" # 8866215 is the user that is used to sync data to the collaboration repos diff --git a/.gitlab/CI/build.gitlab-ci.yml b/.gitlab/CI/build.gitlab-ci.yml index 3fdbd8fe45..fd329f3510 100644 --- a/.gitlab/CI/build.gitlab-ci.yml +++ b/.gitlab/CI/build.gitlab-ci.yml @@ -6,11 +6,8 @@ unittests: GIT_DEPTH: 9999999999999 script: - ln -s /dockercache/target target - - rm -r target/debug/incremental/veloren_* || echo "all good" # TMP FIX FOR 2021-03-22-nightly - - cargo test --package veloren-i18n --lib test_all_localizations -- --nocapture --ignored - - cargo test --package veloren-common-assets asset_tweak::tests --features asset_tweak --lib - - rm -r target/debug/incremental* || echo "all good" # TMP FIX FOR 2021-03-22-nightly - - cargo test + - cat ./.gitlab/scripts/unittest.sh + - source ./.gitlab/scripts/unittest.sh retry: max: 2 @@ -23,12 +20,8 @@ benchmarks: script: - unset DISABLE_GIT_LFS_CHECK - ln -s /dockercache/target target - - ls -la target/* - - rm -r target/debug/incremental/veloren_* || echo "all good" # TMP FIX FOR 2021-03-22-nightly - - rm -r target/release/incremental/veloren_* || echo "all good" # TMP FIX FOR 2021-03-22-nightly - - rm -r target/debug/incremental/* || echo "all good" # TMP FIX FOR 2021-03-22-nightly - - rm -r target/release/incremental/* || echo "all good" # TMP FIX FOR 2021-03-22-nightly - - cargo bench || exit 0 #temp fix + - cat ./.gitlab/scripts/benchmark.sh + - source ./.gitlab/scripts/benchmark.sh - TAGUUID="Z$(cat /dev/urandom | tr -dc 'a-zA-Z0-9' | fold -w 16 | head -n 1)" || echo "ignore this returncode, dont ask me why, it works" - echo $TAGUUID - echo 'SET veloren.timestamp = "'"$(git show --no-patch --no-notes --pretty='%cd' HEAD)"'";' > upload.sql @@ -48,11 +41,8 @@ coverage: image: registry.gitlab.com/veloren/veloren-docker-ci/cache/tarpaulin:${CACHE_IMAGE_TAG} script: - ln -s /dockercache/target target - - rm -r target/debug/incremental/veloren_* || echo "all good" # TMP FIX FOR 2021-03-22-nightly - - find ./* -name "Cargo.toml" -exec sed -i 's/, "simd"]/]/g' {} \; - - find ./* -name "Cargo.toml" -exec sed -i 's/"simd"]/]/g' {} \; - - sed -i 's/vek /#vek /g' ./Cargo.toml; - - cargo tarpaulin -v -- --test-threads=2 + - cat ./.gitlab/scripts/coverage.sh + - source ./.gitlab/scripts/coverage.sh retry: max: 2 @@ -61,10 +51,8 @@ coverage: image: registry.gitlab.com/veloren/veloren-docker-ci/cache/release-linux:${CACHE_IMAGE_TAG} script: - ln -s /dockercache/target target - - rm -r target/release/incremental/veloren_* || echo "all good" # TMP FIX FOR 2021-03-22-nightly - - export VELOREN_USERDATA_STRATEGY=executable - - cargo build --release -p veloren-voxygen --no-default-features --features default-publish - - cargo build --release -p veloren-server-cli + - cat ./.gitlab/scripts/linux.sh + - source ./.gitlab/scripts/linux.sh - cp -r target/release/veloren-server-cli $CI_PROJECT_DIR - cp -r target/release/veloren-voxygen $CI_PROJECT_DIR artifacts: @@ -78,13 +66,9 @@ coverage: .twindows: image: registry.gitlab.com/veloren/veloren-docker-ci/cache/release-windows:${CACHE_IMAGE_TAG} script: - - update-alternatives --set x86_64-w64-mingw32-gcc /usr/bin/x86_64-w64-mingw32-gcc-posix - - update-alternatives --set x86_64-w64-mingw32-g++ /usr/bin/x86_64-w64-mingw32-g++-posix - ln -s /dockercache/target target - - rm -r target/release/incremental/veloren_* || echo "all good" # TMP FIX FOR 2021-03-22-nightly - - export VELOREN_USERDATA_STRATEGY=executable - - cargo build --target=x86_64-pc-windows-gnu --release -p veloren-voxygen --no-default-features --features default-publish - - cargo build --target=x86_64-pc-windows-gnu --release -p veloren-server-cli + - cat ./.gitlab/scripts/windows.sh + - source ./.gitlab/scripts/windows.sh - cp -r target/x86_64-pc-windows-gnu/release/veloren-server-cli.exe $CI_PROJECT_DIR - cp -r target/x86_64-pc-windows-gnu/release/veloren-voxygen.exe $CI_PROJECT_DIR - cp /usr/lib/gcc/x86_64-w64-mingw32/7.3-posix/libgcc_s_seh-1.dll $CI_PROJECT_DIR diff --git a/.gitlab/CI/check.gitlab-ci.yml b/.gitlab/CI/check.gitlab-ci.yml index c74f8d6aa1..fb8a13171a 100644 --- a/.gitlab/CI/check.gitlab-ci.yml +++ b/.gitlab/CI/check.gitlab-ci.yml @@ -5,11 +5,8 @@ code-quality: image: registry.gitlab.com/veloren/veloren-docker-ci/cache/quality:${CACHE_IMAGE_TAG} script: - ln -s /dockercache/target target - - rm -r target/debug/incremental/* || echo "all good" # TMP FIX FOR 2021-03-22-nightly - - cargo clippy --all-targets --locked --features="bin_compression,bin_csv,bin_graphviz,bin_bot,asset_tweak" -- -D warnings - # Ensure that the veloren-voxygen default-publish feature builds as it excludes some default features - - cargo clippy -p veloren-voxygen --locked --no-default-features --features="default-publish" -- -D warnings - - cargo fmt --all -- --check + - cat ./.gitlab/scripts/code-quality.sh + - source ./.gitlab/scripts/code-quality.sh security: extends: .recompile-branch @@ -18,4 +15,5 @@ security: allow_failure: true script: - ln -s /dockercache/target target - - cargo audit + - cat ./.gitlab/scripts/security.sh + - source ./.gitlab/scripts/security.sh diff --git a/.gitlab/scripts/benchmark.sh b/.gitlab/scripts/benchmark.sh new file mode 100755 index 0000000000..492f70d10b --- /dev/null +++ b/.gitlab/scripts/benchmark.sh @@ -0,0 +1,4 @@ +#!/bin/bash +rm -r target/release/incremental/veloren_* || echo "all good" # TMP FIX FOR 2021-03-22-nightly +rm -r target/release/incremental/* || echo "all good" # TMP FIX FOR 2021-03-22-nightly +time cargo bench \ No newline at end of file diff --git a/.gitlab/scripts/ci.sh b/.gitlab/scripts/ci.sh new file mode 100755 index 0000000000..8d72fc8339 --- /dev/null +++ b/.gitlab/scripts/ci.sh @@ -0,0 +1,4 @@ +#!/bin/bash +./.gitlab/scripts/security.sh +./.gitlab/scripts/code-quality.sh +./.gitlab/scripts/unittest.sh \ No newline at end of file diff --git a/.gitlab/scripts/code-quality.sh b/.gitlab/scripts/code-quality.sh new file mode 100755 index 0000000000..3a07d71057 --- /dev/null +++ b/.gitlab/scripts/code-quality.sh @@ -0,0 +1,6 @@ +#!/bin/bash +rm -r target/debug/incremental/* || echo "all good" # TMP FIX FOR 2021-03-22-nightly +time cargo clippy --all-targets --locked --features="bin_compression,bin_csv,bin_graphviz,bin_bot,asset_tweak" -- -D warnings && +# Ensure that the veloren-voxygen default-publish feature builds as it excludes some default features +time cargo clippy -p veloren-voxygen --locked --no-default-features --features="default-publish" -- -D warnings && +time cargo fmt --all -- --check \ No newline at end of file diff --git a/.gitlab/scripts/coverage.sh b/.gitlab/scripts/coverage.sh new file mode 100755 index 0000000000..f2a416d511 --- /dev/null +++ b/.gitlab/scripts/coverage.sh @@ -0,0 +1,7 @@ +#!/bin/bash +echo "modifying files in 5s, ctrl+c to abort" && sleep 5 +rm -r target/debug/incremental/veloren_* || echo "all good" # TMP FIX FOR 2021-03-22-nightly +find ./* -name "Cargo.toml" -exec sed -i 's/, "simd"]/]/g' {} \; +find ./* -name "Cargo.toml" -exec sed -i 's/"simd"]/]/g' {} \; +sed -i 's/vek /#vek /g' ./Cargo.toml; +time cargo tarpaulin --skip-clean -v -- --test-threads=2; \ No newline at end of file diff --git a/.gitlab/scripts/env.sh b/.gitlab/scripts/env.sh new file mode 100644 index 0000000000..710ba8a330 --- /dev/null +++ b/.gitlab/scripts/env.sh @@ -0,0 +1,6 @@ +#!/bin/bash +# exports default env variables in CI +export DISABLE_GIT_LFS_CHECK=true +export VELOREN_ASSETS="assets" +export RUSTFLAGS="-D warnings" +export SHADERC_LIB_DIR=/shaderc/combined/ \ No newline at end of file diff --git a/.gitlab/scripts/linux.sh b/.gitlab/scripts/linux.sh new file mode 100755 index 0000000000..3315a9366a --- /dev/null +++ b/.gitlab/scripts/linux.sh @@ -0,0 +1,6 @@ +#!/bin/bash +rm -r target/release/incremental/veloren_* || echo "all good" # TMP FIX FOR 2021-03-22-nightly +export VELOREN_USERDATA_STRATEGY=executable +time cargo build --release --no-default-features --features default-publish && +time cargo build --release -p veloren-server-cli +# eveluate --bin instead, last time i checked (2021-07-14) it was 2 minutes slower on release (but faster on debug) \ No newline at end of file diff --git a/.gitlab/scripts/security.sh b/.gitlab/scripts/security.sh new file mode 100755 index 0000000000..34de50c299 --- /dev/null +++ b/.gitlab/scripts/security.sh @@ -0,0 +1,2 @@ +#!/bin/bash +time cargo audit \ No newline at end of file diff --git a/.gitlab/scripts/unittest.sh b/.gitlab/scripts/unittest.sh new file mode 100755 index 0000000000..a4193d3914 --- /dev/null +++ b/.gitlab/scripts/unittest.sh @@ -0,0 +1,7 @@ +#!/bin/bash +export VELOREN_ASSETS="$(pwd)/assets" +rm -r target/debug/incremental/veloren_* || echo "all good" # TMP FIX FOR 2021-03-22-nightly +time cargo test --package veloren-i18n --lib test_all_localizations -- --nocapture --ignored && +time cargo test --package veloren-common-assets asset_tweak::tests --features asset_tweak --lib && +( rm -r target/debug/incremental* || echo "all good" ) && # TMP FIX FOR 2021-03-22-nightly +time cargo test \ No newline at end of file diff --git a/.gitlab/scripts/windows.sh b/.gitlab/scripts/windows.sh new file mode 100755 index 0000000000..bc7d849bd5 --- /dev/null +++ b/.gitlab/scripts/windows.sh @@ -0,0 +1,7 @@ +#!/bin/bash +update-alternatives --set x86_64-w64-mingw32-gcc /usr/bin/x86_64-w64-mingw32-gcc-posix +update-alternatives --set x86_64-w64-mingw32-g++ /usr/bin/x86_64-w64-mingw32-g++-posix +rm -r target/release/incremental/veloren_* || echo "all good" # TMP FIX FOR 2021-03-22-nightly +export VELOREN_USERDATA_STRATEGY=executable +time cargo build --target=x86_64-pc-windows-gnu --release --no-default-features --features default-publish && +time cargo build --target=x86_64-pc-windows-gnu --release -p veloren-server-cli \ No newline at end of file diff --git a/world/src/sim/erosion.rs b/world/src/sim/erosion.rs index c73ac49b97..7e4366a15c 100644 --- a/world/src/sim/erosion.rs +++ b/world/src/sim/erosion.rs @@ -607,7 +607,7 @@ fn get_max_slope( .into_boxed_slice() } -//simd alternative +// simd alternative #[cfg(not(feature = "simd"))] #[derive(Copy, Clone)] #[allow(non_camel_case_types)] From 9379aa929ae35a012e81b28602c74787f82a7709 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcel=20M=C3=A4rtens?= Date: Wed, 14 Jul 2021 14:52:16 +0200 Subject: [PATCH 3/4] no longer incremental builds in CI --- .gitlab/scripts/benchmark.sh | 2 -- .gitlab/scripts/code-quality.sh | 1 - .gitlab/scripts/coverage.sh | 1 - .gitlab/scripts/linux.sh | 1 - .gitlab/scripts/unittest.sh | 2 -- .gitlab/scripts/windows.sh | 1 - 6 files changed, 8 deletions(-) diff --git a/.gitlab/scripts/benchmark.sh b/.gitlab/scripts/benchmark.sh index 492f70d10b..7aa871b8ea 100755 --- a/.gitlab/scripts/benchmark.sh +++ b/.gitlab/scripts/benchmark.sh @@ -1,4 +1,2 @@ #!/bin/bash -rm -r target/release/incremental/veloren_* || echo "all good" # TMP FIX FOR 2021-03-22-nightly -rm -r target/release/incremental/* || echo "all good" # TMP FIX FOR 2021-03-22-nightly time cargo bench \ No newline at end of file diff --git a/.gitlab/scripts/code-quality.sh b/.gitlab/scripts/code-quality.sh index 3a07d71057..8b4146c7a8 100755 --- a/.gitlab/scripts/code-quality.sh +++ b/.gitlab/scripts/code-quality.sh @@ -1,5 +1,4 @@ #!/bin/bash -rm -r target/debug/incremental/* || echo "all good" # TMP FIX FOR 2021-03-22-nightly time cargo clippy --all-targets --locked --features="bin_compression,bin_csv,bin_graphviz,bin_bot,asset_tweak" -- -D warnings && # Ensure that the veloren-voxygen default-publish feature builds as it excludes some default features time cargo clippy -p veloren-voxygen --locked --no-default-features --features="default-publish" -- -D warnings && diff --git a/.gitlab/scripts/coverage.sh b/.gitlab/scripts/coverage.sh index f2a416d511..ced9c46f6e 100755 --- a/.gitlab/scripts/coverage.sh +++ b/.gitlab/scripts/coverage.sh @@ -1,6 +1,5 @@ #!/bin/bash echo "modifying files in 5s, ctrl+c to abort" && sleep 5 -rm -r target/debug/incremental/veloren_* || echo "all good" # TMP FIX FOR 2021-03-22-nightly find ./* -name "Cargo.toml" -exec sed -i 's/, "simd"]/]/g' {} \; find ./* -name "Cargo.toml" -exec sed -i 's/"simd"]/]/g' {} \; sed -i 's/vek /#vek /g' ./Cargo.toml; diff --git a/.gitlab/scripts/linux.sh b/.gitlab/scripts/linux.sh index 3315a9366a..9b6cf3be27 100755 --- a/.gitlab/scripts/linux.sh +++ b/.gitlab/scripts/linux.sh @@ -1,5 +1,4 @@ #!/bin/bash -rm -r target/release/incremental/veloren_* || echo "all good" # TMP FIX FOR 2021-03-22-nightly export VELOREN_USERDATA_STRATEGY=executable time cargo build --release --no-default-features --features default-publish && time cargo build --release -p veloren-server-cli diff --git a/.gitlab/scripts/unittest.sh b/.gitlab/scripts/unittest.sh index a4193d3914..9b1c59bfd5 100755 --- a/.gitlab/scripts/unittest.sh +++ b/.gitlab/scripts/unittest.sh @@ -1,7 +1,5 @@ #!/bin/bash export VELOREN_ASSETS="$(pwd)/assets" -rm -r target/debug/incremental/veloren_* || echo "all good" # TMP FIX FOR 2021-03-22-nightly time cargo test --package veloren-i18n --lib test_all_localizations -- --nocapture --ignored && time cargo test --package veloren-common-assets asset_tweak::tests --features asset_tweak --lib && -( rm -r target/debug/incremental* || echo "all good" ) && # TMP FIX FOR 2021-03-22-nightly time cargo test \ No newline at end of file diff --git a/.gitlab/scripts/windows.sh b/.gitlab/scripts/windows.sh index bc7d849bd5..a2f6964f36 100755 --- a/.gitlab/scripts/windows.sh +++ b/.gitlab/scripts/windows.sh @@ -1,7 +1,6 @@ #!/bin/bash update-alternatives --set x86_64-w64-mingw32-gcc /usr/bin/x86_64-w64-mingw32-gcc-posix update-alternatives --set x86_64-w64-mingw32-g++ /usr/bin/x86_64-w64-mingw32-g++-posix -rm -r target/release/incremental/veloren_* || echo "all good" # TMP FIX FOR 2021-03-22-nightly export VELOREN_USERDATA_STRATEGY=executable time cargo build --target=x86_64-pc-windows-gnu --release --no-default-features --features default-publish && time cargo build --target=x86_64-pc-windows-gnu --release -p veloren-server-cli \ No newline at end of file From ac10410782ebe18f24d8839b0b6c696029202bfd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcel=20M=C3=A4rtens?= Date: Thu, 15 Jul 2021 10:56:32 +0200 Subject: [PATCH 4/4] only build once, dont build multiple targets. save time Profiles: (all are build, all are release, all are --no-default-features --features="default-publish" ) A) -p veloren-voxygen AND -p veloren-server-cli B) NONE AND -p veloren-server-cli C) NONE D) NONE but server-cli/Cargo.toml has a default-publish feature Timings A) > time cargo build -p veloren-voxygen --release --no-default-features --features default-publish Compiling veloren-client v0.10.0 (/mnt/nfs/marcel/Entw/Rust/veloren/client) Compiling refinery v0.5.0 (https://gitlab.com/veloren/refinery.git?rev=8ecf4b4772d791e6c8c0a3f9b66a7530fad1af3e#8ecf4b47) Compiling gfx-auxil v0.9.0 (https://github.com/gfx-rs/gfx?rev=27a1dae3796d33d23812f2bb8c7e3b5aea18b521#27a1dae3) Compiling gfx-backend-gl v0.8.1 (https://github.com/gfx-rs/gfx?rev=27a1dae3796d33d23812f2bb8c7e3b5aea18b521#27a1dae3) Compiling veloren-server v0.10.0 (/mnt/nfs/marcel/Entw/Rust/veloren/server) Compiling wgpu v0.8.0 (https://github.com/gfx-rs/wgpu.git?rev=a92b8549a8e2cb9dac781bafc5ed32828f3caf46#a92b8549) Compiling wgpu-profiler v0.4.0 (https://github.com/Imberflur/wgpu-profiler?tag=wgpu-0.8#b156eb14) Finished release [optimized] target(s) in 16m 19s cargo build -p veloren-voxygen --release --no-default-features --features 3091.78s user 71.80s system 322% cpu 16:19.44 total > time cargo build --release -p veloren-server-cli Compiling veloren-world v0.10.0 (/mnt/nfs/marcel/Entw/Rust/veloren/world) Compiling refinery v0.5.0 (https://gitlab.com/veloren/refinery.git?rev=8ecf4b4772d791e6c8c0a3f9b66a7530fad1af3e#8ecf4b47) Compiling veloren-server v0.10.0 (/mnt/nfs/marcel/Entw/Rust/veloren/server) Compiling veloren-server-cli v0.10.0 (/mnt/nfs/marcel/Entw/Rust/veloren/server-cli) Finished release [optimized] target(s) in 6m 06s cargo build --release -p veloren-server-cli 1024.29s user 18.42s system 284% cpu 6:06.62 total B) > time cargo build --release --no-default-features --features default-publish Compiling veloren-client v0.10.0 (/mnt/nfs/marcel/Entw/Rust/veloren/client) Compiling veloren-voxygen-egui v0.9.0 (/mnt/nfs/marcel/Entw/Rust/veloren/voxygen/egui) Compiling gfx-auxil v0.9.0 (https://github.com/gfx-rs/gfx?rev=27a1dae3796d33d23812f2bb8c7e3b5aea18b521#27a1dae3) Compiling gfx-backend-gl v0.8.1 (https://github.com/gfx-rs/gfx?rev=27a1dae3796d33d23812f2bb8c7e3b5aea18b521#27a1dae3) Compiling refinery v0.5.0 (https://gitlab.com/veloren/refinery.git?rev=8ecf4b4772d791e6c8c0a3f9b66a7530fad1af3e#8ecf4b47) Compiling veloren-server v0.10.0 (/mnt/nfs/marcel/Entw/Rust/veloren/server) Compiling wgpu v0.8.0 (https://github.com/gfx-rs/wgpu.git?rev=a92b8549a8e2cb9dac781bafc5ed32828f3caf46#a92b8549) Compiling wgpu-profiler v0.4.0 (https://github.com/Imberflur/wgpu-profiler?tag=wgpu-0.8#b156eb14) Compiling veloren-voxygen-anim-dyn v0.10.0 (/mnt/nfs/marcel/Entw/Rust/veloren/voxygen/anim/dyn) Compiling veloren-voxygen-egui-dyn v0.9.0 (/mnt/nfs/marcel/Entw/Rust/veloren/voxygen/egui/dyn) Compiling veloren-server-cli v0.10.0 (/mnt/nfs/marcel/Entw/Rust/veloren/server-cli) Finished release [optimized] target(s) in 17m 10s cargo build --release --no-default-features --features default-publish 4415.58s user 91.10s system 437% cpu 17:10.66 total > time cargo build --release -p veloren-server-cli Compiling veloren-world v0.10.0 (/mnt/nfs/marcel/Entw/Rust/veloren/world) Compiling refinery v0.5.0 (https://gitlab.com/veloren/refinery.git?rev=8ecf4b4772d791e6c8c0a3f9b66a7530fad1af3e#8ecf4b47) Compiling veloren-server v0.10.0 (/mnt/nfs/marcel/Entw/Rust/veloren/server) Compiling veloren-server-cli v0.10.0 (/mnt/nfs/marcel/Entw/Rust/veloren/server-cli) Finished release [optimized] target(s) in 6m 08s cargo build --release -p veloren-server-cli 1123.93s user 23.01s system 311% cpu 6:08.14 total C) > time cargo build --release --no-default-features --features default-publish Compiling prometheus-hyper v0.1.2 Compiling authc v1.0.0 (https://gitlab.com/veloren/auth.git?rev=fb3dcbc4962b367253f8f2f92760ef44d2679c9a#fb3dcbc4) Compiling veloren-common-net v0.10.0 (/mnt/nfs/marcel/Entw/Rust/veloren/common/net) Compiling veloren-plugin-api v0.1.0 (/mnt/nfs/marcel/Entw/Rust/veloren/plugin/api) Compiling veloren-voxygen-anim v0.10.0 (/mnt/nfs/marcel/Entw/Rust/veloren/voxygen/anim) Compiling veloren-plugin-rt v0.1.0 (/mnt/nfs/marcel/Entw/Rust/veloren/plugin/rt) Compiling veloren-common-systems v0.10.0 (/mnt/nfs/marcel/Entw/Rust/veloren/common/systems) Compiling veloren-common-state v0.10.0 (/mnt/nfs/marcel/Entw/Rust/veloren/common/state) Compiling veloren-world v0.10.0 (/mnt/nfs/marcel/Entw/Rust/veloren/world) Compiling veloren-world v0.10.0 (/mnt/nfs/marcel/Entw/Rust/veloren/world) Compiling veloren-client v0.10.0 (/mnt/nfs/marcel/Entw/Rust/veloren/client) Compiling veloren-voxygen-egui v0.9.0 (/mnt/nfs/marcel/Entw/Rust/veloren/voxygen/egui) Compiling refinery v0.5.0 (https://gitlab.com/veloren/refinery.git?rev=8ecf4b4772d791e6c8c0a3f9b66a7530fad1af3e#8ecf4b47) Compiling veloren-server v0.10.0 (/mnt/nfs/marcel/Entw/Rust/veloren/server) Compiling gfx-auxil v0.9.0 (https://github.com/gfx-rs/gfx?rev=27a1dae3796d33d23812f2bb8c7e3b5aea18b521#27a1dae3) Compiling gfx-backend-gl v0.8.1 (https://github.com/gfx-rs/gfx?rev=27a1dae3796d33d23812f2bb8c7e3b5aea18b521#27a1dae3) Compiling wgpu v0.8.0 (https://github.com/gfx-rs/wgpu.git?rev=a92b8549a8e2cb9dac781bafc5ed32828f3caf46#a92b8549) Compiling wgpu-profiler v0.4.0 (https://github.com/Imberflur/wgpu-profiler?tag=wgpu-0.8#b156eb14) Compiling veloren-voxygen-anim-dyn v0.10.0 (/mnt/nfs/marcel/Entw/Rust/veloren/voxygen/anim/dyn) Compiling veloren-voxygen-egui-dyn v0.9.0 (/mnt/nfs/marcel/Entw/Rust/veloren/voxygen/egui/dyn) Compiling veloren-server-cli v0.10.0 (/mnt/nfs/marcel/Entw/Rust/veloren/server-cli) Finished release [optimized] target(s) in 16m 41s cargo build --release --no-default-features --features default-publish 4349.71s user 90.02s system 443% cpu 16:41.58 total D) > time cargo build --release --no-default-features --features default-publish Compiling prometheus-hyper v0.1.2 Compiling authc v1.0.0 (https://gitlab.com/veloren/auth.git?rev=fb3dcbc4962b367253f8f2f92760ef44d2679c9a#fb3dcbc4) Compiling veloren-common-net v0.10.0 (/mnt/nfs/marcel/Entw/Rust/veloren/common/net) Compiling veloren-plugin-api v0.1.0 (/mnt/nfs/marcel/Entw/Rust/veloren/plugin/api) Compiling veloren-voxygen-anim v0.10.0 (/mnt/nfs/marcel/Entw/Rust/veloren/voxygen/anim) Compiling veloren-plugin-rt v0.1.0 (/mnt/nfs/marcel/Entw/Rust/veloren/plugin/rt) Compiling veloren-common-state v0.10.0 (/mnt/nfs/marcel/Entw/Rust/veloren/common/state) Compiling veloren-common-systems v0.10.0 (/mnt/nfs/marcel/Entw/Rust/veloren/common/systems) Compiling veloren-world v0.10.0 (/mnt/nfs/marcel/Entw/Rust/veloren/world) Compiling veloren-client v0.10.0 (/mnt/nfs/marcel/Entw/Rust/veloren/client) Compiling veloren-voxygen-egui v0.9.0 (/mnt/nfs/marcel/Entw/Rust/veloren/voxygen/egui) Compiling refinery v0.5.0 (https://gitlab.com/veloren/refinery.git?rev=8ecf4b4772d791e6c8c0a3f9b66a7530fad1af3e#8ecf4b47) Compiling veloren-server v0.10.0 (/mnt/nfs/marcel/Entw/Rust/veloren/server) Compiling gfx-auxil v0.9.0 (https://github.com/gfx-rs/gfx?rev=27a1dae3796d33d23812f2bb8c7e3b5aea18b521#27a1dae3) Compiling gfx-backend-gl v0.8.1 (https://github.com/gfx-rs/gfx?rev=27a1dae3796d33d23812f2bb8c7e3b5aea18b521#27a1dae3) Compiling wgpu v0.8.0 (https://github.com/gfx-rs/wgpu.git?rev=a92b8549a8e2cb9dac781bafc5ed32828f3caf46#a92b8549) Compiling wgpu-profiler v0.4.0 (https://github.com/Imberflur/wgpu-profiler?tag=wgpu-0.8#b156eb14) Compiling veloren-voxygen-egui-dyn v0.9.0 (/mnt/nfs/marcel/Entw/Rust/veloren/voxygen/egui/dyn) Compiling veloren-voxygen-anim-dyn v0.10.0 (/mnt/nfs/marcel/Entw/Rust/veloren/voxygen/anim/dyn) Compiling veloren-server-cli v0.10.0 (/mnt/nfs/marcel/Entw/Rust/veloren/server-cli) Finished release [optimized] target(s) in 17m 30s cargo build --release --no-default-features --features default-publish 4462.34s user 92.17s system 433% cpu 17:31.00 total Hashes A) veloren-voxygen: e9de69144b4d459dc0da2775b2b87ac9 veloren-server-cli: 8c131c1b1daaa6efd0f83d95d9b5dad9 B) veloren-voxygen: 415e14ec1c14a6a559d2908b843d88d5 veloren-server-cli: 8c131c1b1daaa6efd0f83d95d9b5dad9 C) veloren-voxygen: 415e14ec1c14a6a559d2908b843d88d5 veloren-server-cli: 3bf56d0d0a76191a578ed5e71389f512 D) veloren-voxygen: 415e14ec1c14a6a559d2908b843d88d5 veloren-server-cli: c9dc4fb0bfcbd831150eebac788e2f71 Binary Sizes: A) veloren-voxygen: 156667288 veloren-server-cli: 85136736 B) veloren-voxygen: 162860552 veloren-server-cli: 85136736 C) veloren-voxygen: 162860552 veloren-server-cli: 95597304 D) veloren-voxygen: 162860552 veloren-server-cli: 95586360 Total Cache Size: A) 4.1G B) 5G C) 4.1G D) 4.1G --- .gitlab/CI/build.gitlab-ci.yml | 3 +-- .gitlab/CODEOWNERS | 3 ++- .gitlab/scripts/linux.sh | 1 - .gitlab/scripts/windows.sh | 3 +-- server-cli/Cargo.toml | 2 ++ 5 files changed, 6 insertions(+), 6 deletions(-) diff --git a/.gitlab/CI/build.gitlab-ci.yml b/.gitlab/CI/build.gitlab-ci.yml index fd329f3510..9e68e7ee91 100644 --- a/.gitlab/CI/build.gitlab-ci.yml +++ b/.gitlab/CI/build.gitlab-ci.yml @@ -97,8 +97,7 @@ coverage: script: - export MACOSX_DEPLOYMENT_TARGET="10.13" - export VELOREN_USERDATA_STRATEGY=executable - - cargo build --release -p veloren-voxygen --no-default-features --features default-publish - - cargo build --release -p veloren-server-cli + - cargo build --release --no-default-features --features default-publish - cp -r target/release/veloren-server-cli $CI_PROJECT_DIR - cp -r target/release/veloren-voxygen $CI_PROJECT_DIR artifacts: diff --git a/.gitlab/CODEOWNERS b/.gitlab/CODEOWNERS index 481f44ae39..6d851e1555 100644 --- a/.gitlab/CODEOWNERS +++ b/.gitlab/CODEOWNERS @@ -1,3 +1,4 @@ */Cargo.toml @xMAC94x Cargo.toml @xMAC94x -rust-toolchain @xMAC94x \ No newline at end of file +rust-toolchain @xMAC94x +.gitlab/scripts/* @xMAC94x \ No newline at end of file diff --git a/.gitlab/scripts/linux.sh b/.gitlab/scripts/linux.sh index 9b6cf3be27..e0530fc623 100755 --- a/.gitlab/scripts/linux.sh +++ b/.gitlab/scripts/linux.sh @@ -1,5 +1,4 @@ #!/bin/bash export VELOREN_USERDATA_STRATEGY=executable time cargo build --release --no-default-features --features default-publish && -time cargo build --release -p veloren-server-cli # eveluate --bin instead, last time i checked (2021-07-14) it was 2 minutes slower on release (but faster on debug) \ No newline at end of file diff --git a/.gitlab/scripts/windows.sh b/.gitlab/scripts/windows.sh index a2f6964f36..bbbc630b36 100755 --- a/.gitlab/scripts/windows.sh +++ b/.gitlab/scripts/windows.sh @@ -2,5 +2,4 @@ update-alternatives --set x86_64-w64-mingw32-gcc /usr/bin/x86_64-w64-mingw32-gcc-posix update-alternatives --set x86_64-w64-mingw32-g++ /usr/bin/x86_64-w64-mingw32-g++-posix export VELOREN_USERDATA_STRATEGY=executable -time cargo build --target=x86_64-pc-windows-gnu --release --no-default-features --features default-publish && -time cargo build --target=x86_64-pc-windows-gnu --release -p veloren-server-cli \ No newline at end of file +time cargo build --target=x86_64-pc-windows-gnu --release --no-default-features --features default-publish && \ No newline at end of file diff --git a/server-cli/Cargo.toml b/server-cli/Cargo.toml index b1a0b0c490..bbe0bd15f4 100644 --- a/server-cli/Cargo.toml +++ b/server-cli/Cargo.toml @@ -16,6 +16,8 @@ This package includes the official server CLI. [features] worldgen = ["server/worldgen"] +# needed to stay compatible with voxygens format +default-publish = ["default"] default = ["worldgen"] tracy = ["common-frontend/tracy"] plugins = ["server/plugins"]