Skip to content

Commit

Permalink
install LLVM in action instead of sh script
Browse files Browse the repository at this point in the history
  • Loading branch information
enitrat committed Dec 5, 2024
1 parent 87e029d commit 70f5db1
Show file tree
Hide file tree
Showing 7 changed files with 71 additions and 137 deletions.
11 changes: 0 additions & 11 deletions .github/actions/bootstrap/action.yml

This file was deleted.

12 changes: 0 additions & 12 deletions .github/actions/install_rust/action.yml

This file was deleted.

30 changes: 0 additions & 30 deletions .github/actions/setup_native_deps/action.yml

This file was deleted.

74 changes: 69 additions & 5 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -1,20 +1,84 @@
---

Check failure on line 1 in .github/workflows/ci.yml

View workflow job for this annotation

GitHub Actions / Trunk Check

checkov(CKV2_GHA_1)

[new] Ensure top-level permissions are not set to write-all

Check failure on line 1 in .github/workflows/ci.yml

View workflow job for this annotation

GitHub Actions / Trunk Check

prettier

Incorrect formatting, autoformat by running 'trunk fmt'
name: Workflow - CI

# trunk-ignore(checkov/CKV2_GHA_1)

on:
push:
branches: [main]
pull_request:
branches:
- main

permissions: read-all

jobs:
trunk:
name: Trunk
uses: ./.github/workflows/trunk-check.yml
runs-on: ubuntu-24.04
env:
MLIR_SYS_190_PREFIX: /usr/lib/llvm-19/
LLVM_SYS_191_PREFIX: /usr/lib/llvm-19/
TABLEGEN_190_PREFIX: /usr/lib/llvm-19/
steps:
- uses: actions/checkout@v4
- uses: dtolnay/[email protected]
with:
components: clippy, rustfmt
- uses: Swatinem/rust-cache@v2
- name: add llvm deb repository
uses: myci-actions/add-deb-repo@11
with:
repo: deb http://apt.llvm.org/jammy/ llvm-toolchain-jammy-19 main
repo-name: llvm-repo
keys-asc: https://apt.llvm.org/llvm-snapshot.gpg.key
- name: Install LLVM
run: sudo apt-get install llvm-19 llvm-19-dev llvm-19-runtime clang-19 clang-tools-19 lld-19 libpolly-19-dev libmlir-19-dev mlir-19-tools
- name: Trunk Check
uses: trunk-io/[email protected]

tests:
name: Rust tests
uses: ./.github/workflows/test.yml
runs-on: ubuntu-latest-16-cores
env:
MLIR_SYS_190_PREFIX: /usr/lib/llvm-19/
LLVM_SYS_191_PREFIX: /usr/lib/llvm-19/
TABLEGEN_190_PREFIX: /usr/lib/llvm-19/
timeout-minutes: 45
steps:
- uses: actions/checkout@v4
- uses: dtolnay/[email protected]
- uses: Swatinem/rust-cache@v2
- name: add llvm deb repository
uses: myci-actions/add-deb-repo@11
with:
repo: deb http://apt.llvm.org/jammy/ llvm-toolchain-jammy-19 main
repo-name: llvm-repo
keys-asc: https://apt.llvm.org/llvm-snapshot.gpg.key
- name: Install LLVM
run: sudo apt-get install llvm-19 llvm-19-dev llvm-19-runtime clang-19 clang-tools-19 lld-19 libpolly-19-dev libmlir-19-dev mlir-19-tools
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: 3.x
- name: fetch ef tests
run: make setup
- name: fetch Kakarot
run: make setup-kakarot
env:
GITHUB_TOKEN: ${{ github.token }}
- name: run tests v0
run: |
set -o pipefail
make vm-tests-v0-ci | tee test_v0.out
- name: run tests v1
run: |
make vm-tests-v1-ci | tee test_v1.out
set +o pipefail
- name: Retrieve ef-tests execution resources
run: python scripts/compute_resources.py
env:
KAKAROT_VERSION: v0,v1
# upload artifacts
- name: upload resources
uses: actions/upload-artifact@v3
with:
path: ./resources/
name: resources-usage
48 changes: 0 additions & 48 deletions .github/workflows/test.yml

This file was deleted.

27 changes: 0 additions & 27 deletions .github/workflows/trunk-check.yml

This file was deleted.

6 changes: 2 additions & 4 deletions scripts/dependencies.sh
Original file line number Diff line number Diff line change
Expand Up @@ -30,11 +30,9 @@ function setup_llvm_deps() {
brew install llvm@19
;;
Linux)
$SUDO bash -c 'curl https://apt.llvm.org/llvm.sh -Lo llvm.sh
bash ./llvm.sh 19 all
rm -f ./llvm.sh
apt update && apt install -y \
$SUDO bash -c 'apt update && apt-get install -y \
libgmp3-dev \
llvm-19 \
libmlir-19-dev \
libpolly-19-dev \
libzstd-dev \
Expand Down

0 comments on commit 70f5db1

Please sign in to comment.