From a835e2d9f0d5a7bf5de2dec915b633ddcedfea67 Mon Sep 17 00:00:00 2001 From: Manuel Drehwald Date: Fri, 29 Mar 2024 22:53:42 -0400 Subject: [PATCH 01/19] Update enzyme-ci.yml We don't need to build LLD (takes 2.5 min), we just want to use some LLD for linking. We also don't need llvm plugins. --- .github/workflows/enzyme-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/enzyme-ci.yml b/.github/workflows/enzyme-ci.yml index c233b049e1d6d..f13b8ac07739f 100644 --- a/.github/workflows/enzyme-ci.yml +++ b/.github/workflows/enzyme-ci.yml @@ -49,7 +49,7 @@ jobs: mkdir -p build cd build rm -f config.toml - ../configure --enable-llvm-link-shared --enable-llvm-plugins --enable-llvm-enzyme --release-channel=nightly --enable-llvm-assertions --enable-lld --enable-option-checking --enable-ninja --disable-docs + ../configure --enable-llvm-link-shared --enable-llvm-enzyme --use-lld="self-contained" --release-channel=nightly --enable-llvm-assertions --enable-option-checking --enable-ninja --disable-docs ../x.py build --stage 1 library/std library/proc_macro library/test tools/rustdoc rustup toolchain link enzyme build/host/stage1 - name: checkout Enzyme/rustbook From 9102303a30b068b6a1977773e68323afaea0759e Mon Sep 17 00:00:00 2001 From: Manuel Drehwald Date: Fri, 29 Mar 2024 22:55:25 -0400 Subject: [PATCH 02/19] Update enzyme-ci.yml --- .github/workflows/enzyme-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/enzyme-ci.yml b/.github/workflows/enzyme-ci.yml index f13b8ac07739f..4fbafbfcb86ca 100644 --- a/.github/workflows/enzyme-ci.yml +++ b/.github/workflows/enzyme-ci.yml @@ -49,7 +49,7 @@ jobs: mkdir -p build cd build rm -f config.toml - ../configure --enable-llvm-link-shared --enable-llvm-enzyme --use-lld="self-contained" --release-channel=nightly --enable-llvm-assertions --enable-option-checking --enable-ninja --disable-docs + ../configure --enable-llvm-link-shared --enable-llvm-enzyme --use-lld=self-contained --release-channel=nightly --enable-llvm-assertions --enable-option-checking --enable-ninja --disable-docs ../x.py build --stage 1 library/std library/proc_macro library/test tools/rustdoc rustup toolchain link enzyme build/host/stage1 - name: checkout Enzyme/rustbook From 3fbad1c4b2302d3a028961b9361567d0f05b01ab Mon Sep 17 00:00:00 2001 From: Manuel Drehwald Date: Fri, 29 Mar 2024 23:10:40 -0400 Subject: [PATCH 03/19] Update .github/workflows/enzyme-ci.yml Co-authored-by: Jed Brown --- .github/workflows/enzyme-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/enzyme-ci.yml b/.github/workflows/enzyme-ci.yml index 4fbafbfcb86ca..92b653ac3cb16 100644 --- a/.github/workflows/enzyme-ci.yml +++ b/.github/workflows/enzyme-ci.yml @@ -49,7 +49,7 @@ jobs: mkdir -p build cd build rm -f config.toml - ../configure --enable-llvm-link-shared --enable-llvm-enzyme --use-lld=self-contained --release-channel=nightly --enable-llvm-assertions --enable-option-checking --enable-ninja --disable-docs + ../configure --enable-llvm-link-shared --enable-llvm-enzyme --use-lld=\"self-contained\" --release-channel=nightly --enable-llvm-assertions --enable-option-checking --enable-ninja --disable-docs ../x.py build --stage 1 library/std library/proc_macro library/test tools/rustdoc rustup toolchain link enzyme build/host/stage1 - name: checkout Enzyme/rustbook From fc5641129b548deca89476601d52dd941f026a41 Mon Sep 17 00:00:00 2001 From: Manuel Drehwald Date: Fri, 29 Mar 2024 23:25:27 -0400 Subject: [PATCH 04/19] Update enzyme-ci.yml --- .github/workflows/enzyme-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/enzyme-ci.yml b/.github/workflows/enzyme-ci.yml index 92b653ac3cb16..a42098b92dd56 100644 --- a/.github/workflows/enzyme-ci.yml +++ b/.github/workflows/enzyme-ci.yml @@ -49,7 +49,7 @@ jobs: mkdir -p build cd build rm -f config.toml - ../configure --enable-llvm-link-shared --enable-llvm-enzyme --use-lld=\"self-contained\" --release-channel=nightly --enable-llvm-assertions --enable-option-checking --enable-ninja --disable-docs + ../configure --enable-llvm-link-shared --enable-llvm-enzyme --use-lld=true --release-channel=nightly --enable-llvm-assertions --enable-option-checking --enable-ninja --disable-docs ../x.py build --stage 1 library/std library/proc_macro library/test tools/rustdoc rustup toolchain link enzyme build/host/stage1 - name: checkout Enzyme/rustbook From dc0baf9616f621bad7803f24393e3cd77ae0c781 Mon Sep 17 00:00:00 2001 From: Manuel Drehwald Date: Fri, 29 Mar 2024 23:28:06 -0400 Subject: [PATCH 05/19] Update enzyme-ci.yml or will it be --enable-use-lld? stay tuned. --- .github/workflows/enzyme-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/enzyme-ci.yml b/.github/workflows/enzyme-ci.yml index a42098b92dd56..2efd669ffc825 100644 --- a/.github/workflows/enzyme-ci.yml +++ b/.github/workflows/enzyme-ci.yml @@ -49,7 +49,7 @@ jobs: mkdir -p build cd build rm -f config.toml - ../configure --enable-llvm-link-shared --enable-llvm-enzyme --use-lld=true --release-channel=nightly --enable-llvm-assertions --enable-option-checking --enable-ninja --disable-docs + ../configure --enable-llvm-link-shared --enable-llvm-enzyme --use-lld --release-channel=nightly --enable-llvm-assertions --enable-option-checking --enable-ninja --disable-docs ../x.py build --stage 1 library/std library/proc_macro library/test tools/rustdoc rustup toolchain link enzyme build/host/stage1 - name: checkout Enzyme/rustbook From 76ace6fff3a39fc219c09495f61f0241f362aa85 Mon Sep 17 00:00:00 2001 From: Manuel Drehwald Date: Fri, 29 Mar 2024 23:29:04 -0400 Subject: [PATCH 06/19] Update enzyme-ci.yml --- .github/workflows/enzyme-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/enzyme-ci.yml b/.github/workflows/enzyme-ci.yml index 2efd669ffc825..59a91f87a52ba 100644 --- a/.github/workflows/enzyme-ci.yml +++ b/.github/workflows/enzyme-ci.yml @@ -49,7 +49,7 @@ jobs: mkdir -p build cd build rm -f config.toml - ../configure --enable-llvm-link-shared --enable-llvm-enzyme --use-lld --release-channel=nightly --enable-llvm-assertions --enable-option-checking --enable-ninja --disable-docs + ../configure --enable-llvm-link-shared --enable-llvm-enzyme --enable-use-lld --release-channel=nightly --enable-llvm-assertions --enable-option-checking --enable-ninja --disable-docs ../x.py build --stage 1 library/std library/proc_macro library/test tools/rustdoc rustup toolchain link enzyme build/host/stage1 - name: checkout Enzyme/rustbook From 4a509dd6782aff39dd6d58dd3944516e70de3f23 Mon Sep 17 00:00:00 2001 From: Manuel Drehwald Date: Fri, 29 Mar 2024 23:31:00 -0400 Subject: [PATCH 07/19] Update enzyme-ci.yml authored-by: @jedbrown --- .github/workflows/enzyme-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/enzyme-ci.yml b/.github/workflows/enzyme-ci.yml index 59a91f87a52ba..942ffd3791b4e 100644 --- a/.github/workflows/enzyme-ci.yml +++ b/.github/workflows/enzyme-ci.yml @@ -49,7 +49,7 @@ jobs: mkdir -p build cd build rm -f config.toml - ../configure --enable-llvm-link-shared --enable-llvm-enzyme --enable-use-lld --release-channel=nightly --enable-llvm-assertions --enable-option-checking --enable-ninja --disable-docs + ../configure --enable-llvm-link-shared --enable-llvm-enzyme --set=rust.use-lld=self-contained --release-channel=nightly --enable-llvm-assertions --enable-option-checking --enable-ninja --disable-docs ../x.py build --stage 1 library/std library/proc_macro library/test tools/rustdoc rustup toolchain link enzyme build/host/stage1 - name: checkout Enzyme/rustbook From 338d43ac3d40a5b49169c1bc7f45502084467e30 Mon Sep 17 00:00:00 2001 From: Manuel Drehwald Date: Fri, 29 Mar 2024 23:33:17 -0400 Subject: [PATCH 08/19] Update enzyme-ci.yml --- .github/workflows/enzyme-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/enzyme-ci.yml b/.github/workflows/enzyme-ci.yml index 942ffd3791b4e..c943949b115f4 100644 --- a/.github/workflows/enzyme-ci.yml +++ b/.github/workflows/enzyme-ci.yml @@ -49,7 +49,7 @@ jobs: mkdir -p build cd build rm -f config.toml - ../configure --enable-llvm-link-shared --enable-llvm-enzyme --set=rust.use-lld=self-contained --release-channel=nightly --enable-llvm-assertions --enable-option-checking --enable-ninja --disable-docs + ../configure --enable-llvm-link-shared --enable-llvm-enzyme --set=rust.use-lld=true --release-channel=nightly --enable-llvm-assertions --enable-option-checking --enable-ninja --disable-docs ../x.py build --stage 1 library/std library/proc_macro library/test tools/rustdoc rustup toolchain link enzyme build/host/stage1 - name: checkout Enzyme/rustbook From 8f1459b04892eb6dd2940e87b10a5e45786560ab Mon Sep 17 00:00:00 2001 From: Manuel Drehwald Date: Sat, 30 Mar 2024 00:56:54 -0400 Subject: [PATCH 09/19] Update enzyme-ci.yml --- .github/workflows/enzyme-ci.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/enzyme-ci.yml b/.github/workflows/enzyme-ci.yml index c943949b115f4..1c6d302c1f00d 100644 --- a/.github/workflows/enzyme-ci.yml +++ b/.github/workflows/enzyme-ci.yml @@ -46,6 +46,8 @@ jobs: key: ${{ matrix.os }}-enzyme-${{ steps.enzyme-commit.outputs.HEAD }} - name: Build run: | + apt-get -y update + apt-get install -y lld mkdir -p build cd build rm -f config.toml From 2bbd6ae2271fa4dced9ca0aa0d80c9b0dc5f1959 Mon Sep 17 00:00:00 2001 From: Manuel Drehwald Date: Sat, 30 Mar 2024 08:35:30 -0400 Subject: [PATCH 10/19] Update .github/workflows/enzyme-ci.yml Co-authored-by: Tim Gymnich --- .github/workflows/enzyme-ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/enzyme-ci.yml b/.github/workflows/enzyme-ci.yml index 1c6d302c1f00d..37f9313cdaf17 100644 --- a/.github/workflows/enzyme-ci.yml +++ b/.github/workflows/enzyme-ci.yml @@ -46,8 +46,8 @@ jobs: key: ${{ matrix.os }}-enzyme-${{ steps.enzyme-commit.outputs.HEAD }} - name: Build run: | - apt-get -y update - apt-get install -y lld + sudo apt-get -y update + sudo apt-get install -y lld mkdir -p build cd build rm -f config.toml From d097239cb565be410a1dd344319828e74c7ce154 Mon Sep 17 00:00:00 2001 From: Manuel Drehwald Date: Sat, 30 Mar 2024 08:47:42 -0400 Subject: [PATCH 11/19] Update enzyme-ci.yml --- .github/workflows/enzyme-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/enzyme-ci.yml b/.github/workflows/enzyme-ci.yml index 37f9313cdaf17..4bb3e653736ec 100644 --- a/.github/workflows/enzyme-ci.yml +++ b/.github/workflows/enzyme-ci.yml @@ -47,7 +47,7 @@ jobs: - name: Build run: | sudo apt-get -y update - sudo apt-get install -y lld + sudo apt-get install -y lld-17 mkdir -p build cd build rm -f config.toml From b4a9252997493121a554d33a0952677b512be9d8 Mon Sep 17 00:00:00 2001 From: William Moses Date: Sat, 30 Mar 2024 19:53:20 -0400 Subject: [PATCH 12/19] Use vendored llvm --- .github/workflows/enzyme-ci.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/enzyme-ci.yml b/.github/workflows/enzyme-ci.yml index 4bb3e653736ec..fbb9ddd1664fe 100644 --- a/.github/workflows/enzyme-ci.yml +++ b/.github/workflows/enzyme-ci.yml @@ -46,6 +46,8 @@ jobs: key: ${{ matrix.os }}-enzyme-${{ steps.enzyme-commit.outputs.HEAD }} - name: Build run: | + wget -O - https://apt.llvm.org/llvm-snapshot.gpg.key|sudo apt-key add - + sudo apt-add-repository "deb http://apt.llvm.org/`lsb_release -c | cut -f2`/ llvm-toolchain-`lsb_release -c | cut -f2`-17 main" || true sudo apt-get -y update sudo apt-get install -y lld-17 mkdir -p build From c10a5ea6141dcfe90c4e799d072d05259d9799bd Mon Sep 17 00:00:00 2001 From: William Moses Date: Sun, 14 Apr 2024 17:57:52 -0700 Subject: [PATCH 13/19] Update enzyme-ci.yml --- .github/workflows/enzyme-ci.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/enzyme-ci.yml b/.github/workflows/enzyme-ci.yml index fbb9ddd1664fe..328025bc0b8f4 100644 --- a/.github/workflows/enzyme-ci.yml +++ b/.github/workflows/enzyme-ci.yml @@ -53,6 +53,7 @@ jobs: mkdir -p build cd build rm -f config.toml + alias lld=lld-17 ../configure --enable-llvm-link-shared --enable-llvm-enzyme --set=rust.use-lld=true --release-channel=nightly --enable-llvm-assertions --enable-option-checking --enable-ninja --disable-docs ../x.py build --stage 1 library/std library/proc_macro library/test tools/rustdoc rustup toolchain link enzyme build/host/stage1 From 11cbbc923d9eec99064c44268620131e8e50a2ca Mon Sep 17 00:00:00 2001 From: William Moses Date: Sun, 14 Apr 2024 18:04:45 -0700 Subject: [PATCH 14/19] Update enzyme-ci.yml --- .github/workflows/enzyme-ci.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/enzyme-ci.yml b/.github/workflows/enzyme-ci.yml index 328025bc0b8f4..39dd152b996f8 100644 --- a/.github/workflows/enzyme-ci.yml +++ b/.github/workflows/enzyme-ci.yml @@ -54,6 +54,7 @@ jobs: cd build rm -f config.toml alias lld=lld-17 + alias ld=lld-17 ../configure --enable-llvm-link-shared --enable-llvm-enzyme --set=rust.use-lld=true --release-channel=nightly --enable-llvm-assertions --enable-option-checking --enable-ninja --disable-docs ../x.py build --stage 1 library/std library/proc_macro library/test tools/rustdoc rustup toolchain link enzyme build/host/stage1 From 84fe2693025b13f34a10f69550bef76270ace172 Mon Sep 17 00:00:00 2001 From: Tim Gymnich Date: Mon, 15 Apr 2024 15:43:38 +0200 Subject: [PATCH 15/19] Update enzyme-ci.yml --- .github/workflows/enzyme-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/enzyme-ci.yml b/.github/workflows/enzyme-ci.yml index 39dd152b996f8..53389998427d8 100644 --- a/.github/workflows/enzyme-ci.yml +++ b/.github/workflows/enzyme-ci.yml @@ -55,7 +55,7 @@ jobs: rm -f config.toml alias lld=lld-17 alias ld=lld-17 - ../configure --enable-llvm-link-shared --enable-llvm-enzyme --set=rust.use-lld=true --release-channel=nightly --enable-llvm-assertions --enable-option-checking --enable-ninja --disable-docs + ../configure --enable-llvm-link-shared --enable-llvm-enzyme --set=rust.use-lld=self-contained --release-channel=nightly --enable-llvm-assertions --enable-option-checking --enable-ninja --disable-docs ../x.py build --stage 1 library/std library/proc_macro library/test tools/rustdoc rustup toolchain link enzyme build/host/stage1 - name: checkout Enzyme/rustbook From 9ec11394556c7db454a69183d15fa36524380b78 Mon Sep 17 00:00:00 2001 From: Tim Gymnich Date: Mon, 15 Apr 2024 16:04:17 +0200 Subject: [PATCH 16/19] Update enzyme-ci.yml --- .github/workflows/enzyme-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/enzyme-ci.yml b/.github/workflows/enzyme-ci.yml index 53389998427d8..8a0d4faeadbbe 100644 --- a/.github/workflows/enzyme-ci.yml +++ b/.github/workflows/enzyme-ci.yml @@ -55,7 +55,7 @@ jobs: rm -f config.toml alias lld=lld-17 alias ld=lld-17 - ../configure --enable-llvm-link-shared --enable-llvm-enzyme --set=rust.use-lld=self-contained --release-channel=nightly --enable-llvm-assertions --enable-option-checking --enable-ninja --disable-docs + ../configure --enable-llvm-link-shared --enable-llvm-enzyme --set=rust.lld=true --set=rust.use-lld=self-contained --release-channel=nightly --enable-llvm-assertions --enable-option-checking --enable-ninja --disable-docs ../x.py build --stage 1 library/std library/proc_macro library/test tools/rustdoc rustup toolchain link enzyme build/host/stage1 - name: checkout Enzyme/rustbook From 722096ae0a5af6108c1ef2d08ad091fcf5b11a26 Mon Sep 17 00:00:00 2001 From: Tim Gymnich Date: Mon, 15 Apr 2024 16:16:09 +0200 Subject: [PATCH 17/19] Revert "Update enzyme-ci.yml" This reverts commit 9ec11394556c7db454a69183d15fa36524380b78. --- .github/workflows/enzyme-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/enzyme-ci.yml b/.github/workflows/enzyme-ci.yml index 8a0d4faeadbbe..53389998427d8 100644 --- a/.github/workflows/enzyme-ci.yml +++ b/.github/workflows/enzyme-ci.yml @@ -55,7 +55,7 @@ jobs: rm -f config.toml alias lld=lld-17 alias ld=lld-17 - ../configure --enable-llvm-link-shared --enable-llvm-enzyme --set=rust.lld=true --set=rust.use-lld=self-contained --release-channel=nightly --enable-llvm-assertions --enable-option-checking --enable-ninja --disable-docs + ../configure --enable-llvm-link-shared --enable-llvm-enzyme --set=rust.use-lld=self-contained --release-channel=nightly --enable-llvm-assertions --enable-option-checking --enable-ninja --disable-docs ../x.py build --stage 1 library/std library/proc_macro library/test tools/rustdoc rustup toolchain link enzyme build/host/stage1 - name: checkout Enzyme/rustbook From a107468945ef6a7cb7c7ef4b0a8a5bb99850470e Mon Sep 17 00:00:00 2001 From: Tim Gymnich Date: Mon, 15 Apr 2024 16:23:19 +0200 Subject: [PATCH 18/19] Revert "Update enzyme-ci.yml" This reverts commit 84fe2693025b13f34a10f69550bef76270ace172. --- .github/workflows/enzyme-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/enzyme-ci.yml b/.github/workflows/enzyme-ci.yml index 53389998427d8..39dd152b996f8 100644 --- a/.github/workflows/enzyme-ci.yml +++ b/.github/workflows/enzyme-ci.yml @@ -55,7 +55,7 @@ jobs: rm -f config.toml alias lld=lld-17 alias ld=lld-17 - ../configure --enable-llvm-link-shared --enable-llvm-enzyme --set=rust.use-lld=self-contained --release-channel=nightly --enable-llvm-assertions --enable-option-checking --enable-ninja --disable-docs + ../configure --enable-llvm-link-shared --enable-llvm-enzyme --set=rust.use-lld=true --release-channel=nightly --enable-llvm-assertions --enable-option-checking --enable-ninja --disable-docs ../x.py build --stage 1 library/std library/proc_macro library/test tools/rustdoc rustup toolchain link enzyme build/host/stage1 - name: checkout Enzyme/rustbook From 696abaac600e792130ce4199ae097457610a1741 Mon Sep 17 00:00:00 2001 From: Manuel Drehwald Date: Fri, 19 Apr 2024 18:20:12 -0400 Subject: [PATCH 19/19] Fxing lld rebuild Co-authored-by: I-Al-Istannen --- .github/workflows/enzyme-ci.yml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/.github/workflows/enzyme-ci.yml b/.github/workflows/enzyme-ci.yml index 39dd152b996f8..3d0e7980fda66 100644 --- a/.github/workflows/enzyme-ci.yml +++ b/.github/workflows/enzyme-ci.yml @@ -50,11 +50,15 @@ jobs: sudo apt-add-repository "deb http://apt.llvm.org/`lsb_release -c | cut -f2`/ llvm-toolchain-`lsb_release -c | cut -f2`-17 main" || true sudo apt-get -y update sudo apt-get install -y lld-17 + mkdir lld-path-manipulation + ln -s "$(which lld-17)" lld-path-manipulation/lld + ln -s "$(which lld-17)" lld-path-manipulation/ld + ln -s "$(which lld-17)" lld-path-manipulation/ld.lld + ln -s "$(which lld-17)" lld-path-manipulation/lld-17 + export PATH="$PWD/lld-path-manipulation:$PATH" mkdir -p build cd build rm -f config.toml - alias lld=lld-17 - alias ld=lld-17 ../configure --enable-llvm-link-shared --enable-llvm-enzyme --set=rust.use-lld=true --release-channel=nightly --enable-llvm-assertions --enable-option-checking --enable-ninja --disable-docs ../x.py build --stage 1 library/std library/proc_macro library/test tools/rustdoc rustup toolchain link enzyme build/host/stage1