From 01f6c8a2ee9fb5cb33c0364b4e564c9c1e8c383b Mon Sep 17 00:00:00 2001 From: Gilad Chase Date: Tue, 10 Dec 2024 16:03:17 +0200 Subject: [PATCH] fix(ci): hotfix for OOM regression Previous fix added stable- target, didn't work. For some reason the config.toml rustflags are no longer picked up in the CI, even though they still are locally. Adding the flags manually in the CI workflow works, but is gross. However, main is broken so for now this is it while we try to find the root cause. --- .cargo/config.toml | 3 +-- .github/workflows/blockifier_ci.yml | 2 +- .github/workflows/blockifier_compiled_cairo.yml | 2 +- .github/workflows/blockifier_reexecution_ci.yml | 2 +- .github/workflows/committer_ci.yml | 2 +- .github/workflows/committer_cli_push.yml | 2 +- .github/workflows/main.yml | 2 +- .github/workflows/main_pr.yml | 2 +- .github/workflows/papyrus_ci.yml | 2 +- .github/workflows/papyrus_docker-publish.yml | 2 +- .github/workflows/papyrus_nightly-tests-call.yml | 2 +- .github/workflows/papyrus_nightly-tests.yml | 2 +- .github/workflows/sequencer_integration_tests.yml | 2 +- .github/workflows/upload_artifacts_workflow.yml | 2 +- .github/workflows/verify-deps.yml | 2 +- 15 files changed, 15 insertions(+), 16 deletions(-) diff --git a/.cargo/config.toml b/.cargo/config.toml index 2150461d6e5..d392db9f437 100644 --- a/.cargo/config.toml +++ b/.cargo/config.toml @@ -9,6 +9,5 @@ TABLEGEN_190_PREFIX = "/usr/lib/llvm-19/" # https://nnethercote.github.io/perf-book/build-configuration.html#linking. # TODO: remove this once `rust` stabilizes `lld` as the default linker, currently only on nightly: # https://github.com/rust-lang/rust/issues/39915#issuecomment-618726211 -[target.x86_64-unknown-linux-gnu] -[target.stable-x86_64-unknown-linux-gnu] +[target.'cfg(all(target_os = "linux"))'] rustflags = ["-Clink-arg=-fuse-ld=lld"] diff --git a/.github/workflows/blockifier_ci.yml b/.github/workflows/blockifier_ci.yml index f4de270b92c..cffde84f5f2 100644 --- a/.github/workflows/blockifier_ci.yml +++ b/.github/workflows/blockifier_ci.yml @@ -35,7 +35,7 @@ on: - 'scripts/sequencer-ci.Dockerfile' env: - RUSTFLAGS: "-D warnings" + RUSTFLAGS: "-D warnings -C link-arg=-fuse-ld=lld" # On PR events, cancel existing CI runs on this same PR for this workflow. concurrency: diff --git a/.github/workflows/blockifier_compiled_cairo.yml b/.github/workflows/blockifier_compiled_cairo.yml index f3df06a83de..d8f6e010ec8 100644 --- a/.github/workflows/blockifier_compiled_cairo.yml +++ b/.github/workflows/blockifier_compiled_cairo.yml @@ -16,7 +16,7 @@ on: - 'scripts/dependencies.sh' env: - RUSTFLAGS: "-D warnings" + RUSTFLAGS: "-D warnings -C link-arg=-fuse-ld=lld" # On PR events, cancel existing CI runs on this same PR for this workflow. concurrency: diff --git a/.github/workflows/blockifier_reexecution_ci.yml b/.github/workflows/blockifier_reexecution_ci.yml index ebdd1eb9c12..91f6a13344f 100644 --- a/.github/workflows/blockifier_reexecution_ci.yml +++ b/.github/workflows/blockifier_reexecution_ci.yml @@ -20,7 +20,7 @@ on: - 'scripts/sequencer-ci.Dockerfile' env: - RUSTFLAGS: "-D warnings" + RUSTFLAGS: "-D warnings -C link-arg=-fuse-ld=lld" # On PR events, cancel existing CI runs on this same PR for this workflow. concurrency: diff --git a/.github/workflows/committer_ci.yml b/.github/workflows/committer_ci.yml index c284523ed10..2b7c1f620f6 100644 --- a/.github/workflows/committer_ci.yml +++ b/.github/workflows/committer_ci.yml @@ -19,7 +19,7 @@ on: - 'scripts/dependencies.sh' env: - RUSTFLAGS: "-D warnings" + RUSTFLAGS: "-D warnings -C link-arg=-fuse-ld=lld" # On PR events, cancel existing CI runs on this same PR for this workflow. concurrency: diff --git a/.github/workflows/committer_cli_push.yml b/.github/workflows/committer_cli_push.yml index 5690590674a..1d14b57553c 100644 --- a/.github/workflows/committer_cli_push.yml +++ b/.github/workflows/committer_cli_push.yml @@ -35,7 +35,7 @@ on: - 'scripts/dependencies.sh' env: - RUSTFLAGS: "-D warnings" + RUSTFLAGS: "-D warnings -C link-arg=-fuse-ld=lld" # On PR events, cancel existing CI runs on this same PR for this workflow. concurrency: diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 24f25b1b747..b878a01408c 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -18,7 +18,7 @@ on: env: CI: 1 - RUSTFLAGS: "-D warnings" + RUSTFLAGS: "-D warnings -C link-arg=-fuse-ld=lld" # On PR events, cancel existing CI runs on this same PR for this workflow. concurrency: diff --git a/.github/workflows/main_pr.yml b/.github/workflows/main_pr.yml index 93540b13e67..5d99b3831be 100644 --- a/.github/workflows/main_pr.yml +++ b/.github/workflows/main_pr.yml @@ -10,7 +10,7 @@ on: - edited env: - RUSTFLAGS: "-D warnings" + RUSTFLAGS: "-D warnings -C link-arg=-fuse-ld=lld" # On PR events, cancel existing CI runs on this same PR for this workflow. concurrency: diff --git a/.github/workflows/papyrus_ci.yml b/.github/workflows/papyrus_ci.yml index cf8f68ede82..894661e4b26 100644 --- a/.github/workflows/papyrus_ci.yml +++ b/.github/workflows/papyrus_ci.yml @@ -23,7 +23,7 @@ on: types: [checks_requested] env: - RUSTFLAGS: "-D warnings" + RUSTFLAGS: "-D warnings -C link-arg=-fuse-ld=lld" # On PR events, cancel existing CI runs on this same PR for this workflow. concurrency: diff --git a/.github/workflows/papyrus_docker-publish.yml b/.github/workflows/papyrus_docker-publish.yml index 4b1f01fb854..7815c7da723 100644 --- a/.github/workflows/papyrus_docker-publish.yml +++ b/.github/workflows/papyrus_docker-publish.yml @@ -28,7 +28,7 @@ concurrency: env: REGISTRY: ghcr.io REPO_NAME: ${{ github.repository }} - RUSTFLAGS: "-D warnings" + RUSTFLAGS: "-D warnings -C link-arg=-fuse-ld=lld" jobs: docker-build-push: diff --git a/.github/workflows/papyrus_nightly-tests-call.yml b/.github/workflows/papyrus_nightly-tests-call.yml index dc5896a66e8..6171e514e6c 100644 --- a/.github/workflows/papyrus_nightly-tests-call.yml +++ b/.github/workflows/papyrus_nightly-tests-call.yml @@ -17,7 +17,7 @@ on: required: true env: - RUSTFLAGS: "-D warnings" + RUSTFLAGS: "-D warnings -C link-arg=-fuse-ld=lld" jobs: GW-integration-test-call: diff --git a/.github/workflows/papyrus_nightly-tests.yml b/.github/workflows/papyrus_nightly-tests.yml index 1f913a92b8a..802760c292b 100644 --- a/.github/workflows/papyrus_nightly-tests.yml +++ b/.github/workflows/papyrus_nightly-tests.yml @@ -7,7 +7,7 @@ on: workflow_dispatch: # Uses ubuntu runner. env: - RUSTFLAGS: "-D warnings" + RUSTFLAGS: "-D warnings -C link-arg=-fuse-ld=lld" jobs: GW-integration-test-ubuntu: diff --git a/.github/workflows/sequencer_integration_tests.yml b/.github/workflows/sequencer_integration_tests.yml index 06225562a5c..685bd47f146 100644 --- a/.github/workflows/sequencer_integration_tests.yml +++ b/.github/workflows/sequencer_integration_tests.yml @@ -11,7 +11,7 @@ on: env: SEQUENCER_INTEGRATION_TESTS: 1 - RUSTFLAGS: "-D warnings" + RUSTFLAGS: "-D warnings -C link-arg=-fuse-ld=lld" # On PR events, cancel existing CI runs on this same PR for this workflow. concurrency: diff --git a/.github/workflows/upload_artifacts_workflow.yml b/.github/workflows/upload_artifacts_workflow.yml index 570d924383d..bf7261435a4 100644 --- a/.github/workflows/upload_artifacts_workflow.yml +++ b/.github/workflows/upload_artifacts_workflow.yml @@ -6,7 +6,7 @@ on: types: [completed] env: - RUSTFLAGS: "-D warnings" + RUSTFLAGS: "-D warnings -C link-arg=-fuse-ld=lld" jobs: native-blockifier-artifacts-push: diff --git a/.github/workflows/verify-deps.yml b/.github/workflows/verify-deps.yml index 58c2897f8ce..eb11c7cfaa9 100644 --- a/.github/workflows/verify-deps.yml +++ b/.github/workflows/verify-deps.yml @@ -5,7 +5,7 @@ on: - cron: '0 0 * * *' # Runs at 00:00 UTC every day env: - RUSTFLAGS: "-D warnings" + RUSTFLAGS: "-D warnings -C link-arg=-fuse-ld=lld" jobs: latest_deps: