Skip to content

Commit e66a063

Browse files
authored
v23.09.00
v23.09.00
2 parents d413db2 + 443f751 commit e66a063

File tree

204 files changed

+3026
-766
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

204 files changed

+3026
-766
lines changed

.dockerignore

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
.gitignore

.github/copy-pr-bot.yaml

+4
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
# Configuration file for `copy-pr-bot` GitHub App
2+
# https://docs.gha-runners.nvidia.com/apps/copy-pr-bot/
3+
4+
enabled: true

.github/ops-bot.yaml

-4
This file was deleted.

.github/workflows/ci-gh.yml

+14-98
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
name: Build cunumeric on GH
1+
name: Build and test cunumeric on GH
22

33
concurrency:
4-
group: ci-gpu-on-${{ github.event_name }}-from-${{ github.ref_name }}
4+
group: ci-build-and-test-on-${{ github.event_name }}-from-${{ github.ref_name }}
55
cancel-in-progress: true
66

77
on:
@@ -11,99 +11,15 @@ on:
1111
- "branch-*"
1212

1313
jobs:
14-
build:
15-
permissions:
16-
id-token: write # This is required for configure-aws-credentials
17-
contents: read # This is required for actions/checkout
18-
19-
# Ref: https://docs.rapids.ai/resources/github-actions/#cpu-labels for `linux-amd64-cpu4`
20-
runs-on: ${{ github.repository == 'nv-legate/cunumeric' && 'linux-amd64-cpu4' || 'ubuntu-latest' }}
21-
container:
22-
options: -u root
23-
image: rapidsai/devcontainers:23.06-cpp-cuda11.8-mambaforge-ubuntu22.04
24-
volumes:
25-
- ${{ github.workspace }}/out:/tmp/out
26-
env:
27-
DEFAULT_CONDA_ENV: legate
28-
PYTHONDONTWRITEBYTECODE: 1
29-
SCCACHE_REGION: us-east-2
30-
SCCACHE_BUCKET: rapids-sccache-east
31-
SCCACHE_S3_KEY_PREFIX: legate-cunumeric-dev
32-
GH_TOKEN: "${{ secrets.PERSONAL_ACCESS_TOKEN || secrets.GITHUB_TOKEN }}"
33-
GITHUB_TOKEN: "${{ secrets.PERSONAL_ACCESS_TOKEN || secrets.GITHUB_TOKEN }}"
34-
VAULT_HOST: "${{ secrets.PERSONAL_ACCESS_TOKEN && 'https://vault.ops.k8s.rapids.ai' || '' }}"
35-
VAULT_S3_TTL: "28800s" # 8 hours
36-
37-
steps:
38-
- name: Checkout legate.core
39-
uses: actions/checkout@v3
40-
with:
41-
repository: nv-legate/legate.core
42-
fetch-depth: 0
43-
path: legate
44-
45-
- name: Checkout cunumeric (= this repo)
46-
uses: actions/checkout@v3
47-
with:
48-
fetch-depth: 0
49-
path: cunumeric
50-
51-
- name: Setup
52-
shell: bash -eo pipefail {0}
53-
run: |
54-
export LEGATE_SHA=$(cat cunumeric/cmake/versions.json | jq -r '.packages.legate_core.git_tag')
55-
echo "Checking out LEGATE_SHA: ${LEGATE_SHA}"
56-
git -C legate checkout $LEGATE_SHA
57-
58-
cp -ar legate/continuous_integration/home/coder/.gitconfig /home/coder/;
59-
cp -ar legate/continuous_integration/home/coder/.local /home/coder/;
60-
mv legate /home/coder/legate
61-
62-
cp -ar cunumeric/continuous_integration/home/coder/.local/bin/* /home/coder/.local/bin/;
63-
mv cunumeric /home/coder/cunumeric;
64-
65-
chmod a+x /home/coder/.local/bin/*;
66-
chown -R coder:coder /home/coder/;
67-
chown -R coder:coder /tmp/out;
68-
69-
- if: github.repository == 'nv-legate/cunumeric'
70-
name: Get AWS credentials for sccache bucket
71-
uses: aws-actions/configure-aws-credentials@v2
72-
with:
73-
aws-region: us-east-2
74-
role-duration-seconds: 28800 # 8 hours
75-
role-to-assume: arn:aws:iam::279114543810:role/gha-oidc-nv-legate
76-
77-
- name: Create conda env
78-
shell: su coder {0}
79-
run: cd ~/; exec entrypoint make-conda-env;
80-
81-
- name: Build legate.core C++ library
82-
shell: su coder {0}
83-
run: cd ~/; exec entrypoint build-legate-cpp;
84-
85-
- name: Build legate.core Python Wheel
86-
shell: su coder {0}
87-
run: cd ~/; exec entrypoint build-legate-wheel;
88-
89-
- name: Build legate.core Conda Package
90-
shell: su coder {0}
91-
run: cd ~/; exec entrypoint build-legate-conda;
92-
93-
- name: Build cunumeric C++ library
94-
shell: su coder {0}
95-
run: cd ~/; exec entrypoint build-cunumeric-cpp;
96-
97-
- name: Build cunumeric Python Wheel
98-
shell: su coder {0}
99-
run: cd ~/; exec entrypoint build-cunumeric-wheel;
100-
101-
- name: Build cunumeric Conda Package
102-
shell: su coder {0}
103-
run: cd ~/; exec entrypoint build-cunumeric-conda;
104-
105-
- name: Upload build output
106-
uses: actions/upload-artifact@v3
107-
with:
108-
name: "cunumeric-${{ github.sha }}"
109-
path: ./out/*
14+
build-and-test:
15+
strategy:
16+
fail-fast: false
17+
matrix:
18+
include:
19+
- {build-target: cpu}
20+
- {build-target: gpu}
21+
uses:
22+
./.github/workflows/gh-build-and-test.yml
23+
with:
24+
build-target: ${{ matrix.build-target }}
25+
sha: ${{ github.sha }}
+32
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
on:
2+
workflow_call:
3+
inputs:
4+
build-target:
5+
required: true
6+
type: string
7+
sha:
8+
required: true
9+
type: string
10+
11+
jobs:
12+
build:
13+
name: "Build cunumeric (with ${{ inputs.build-target }} legate) on GH"
14+
uses:
15+
./.github/workflows/gh-build.yml
16+
with:
17+
build-target: ${{ inputs.build-target }}
18+
# Ref: https://docs.rapids.ai/resources/github-actions/#cpu-labels for `linux-amd64-cpu4`
19+
runs-on: ${{ github.repository_owner == 'nv-legate' && 'linux-amd64-cpu4' || 'ubuntu-latest' }}
20+
sha: ${{ inputs.sha }}
21+
22+
cleanup:
23+
needs:
24+
- build
25+
26+
# This ensures the cleanup job runs even if previous jobs fail or the workflow is cancelled.
27+
if: always()
28+
uses:
29+
./.github/workflows/gh-cleanup.yml
30+
with:
31+
build-target: ${{ inputs.build-target }}
32+
sha: ${{ inputs.sha }}

.github/workflows/gh-build.yml

+123
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,123 @@
1+
name: Build cunumeric on GH
2+
3+
on:
4+
workflow_call:
5+
inputs:
6+
build-target:
7+
required: true
8+
type: string
9+
runs-on:
10+
required: true
11+
type: string
12+
sha:
13+
required: true
14+
type: string
15+
16+
env:
17+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
18+
BASE_IMAGE: rapidsai/devcontainers:23.06-cpp-cuda11.8-mambaforge-ubuntu22.04
19+
IMAGE_NAME_LEGATE: legate.core-${{ inputs.build-target }}
20+
IMAGE_NAME_CUNUMERIC: cunumeric-${{ inputs.build-target }}
21+
USE_CUDA: ${{ (inputs.build-target == 'cpu' && 'OFF') || 'ON' }}
22+
23+
jobs:
24+
build:
25+
name: build-${{ inputs.build-target }}-sub-workflow
26+
27+
permissions:
28+
id-token: write # This is required for configure-aws-credentials
29+
contents: read # This is required for actions/checkout
30+
packages: write # This is required to push docker image to ghcr.io
31+
32+
runs-on: ${{ inputs.runs-on }}
33+
34+
steps:
35+
- name: Checkout legate.core
36+
uses: actions/checkout@v3
37+
with:
38+
repository: nv-legate/legate.core
39+
fetch-depth: 0
40+
path: legate
41+
42+
- name: Checkout cunumeric (= this repo)
43+
uses: actions/checkout@v3
44+
with:
45+
fetch-depth: 0
46+
path: cunumeric
47+
48+
- if: github.repository_owner == 'nv-legate'
49+
name: Get AWS credentials for sccache bucket
50+
uses: aws-actions/configure-aws-credentials@v2
51+
with:
52+
aws-region: us-east-2
53+
role-duration-seconds: 28800 # 8 hours
54+
role-to-assume: arn:aws:iam::279114543810:role/gha-oidc-nv-legate
55+
56+
- name: Docker system prune
57+
run: |
58+
docker version
59+
docker system prune --all --force
60+
61+
- name: Build legate.core using docker build
62+
run: |
63+
echo BUILD_TARGET: ${{ inputs.build-target }}
64+
echo USE_CUDA: ${{ env.USE_CUDA }}
65+
66+
export LEGATE_SHA=$(cat cunumeric/cmake/versions.json | jq -r '.packages.legate_core.git_tag')
67+
echo "Checking out LEGATE_SHA: ${LEGATE_SHA}"
68+
git -C legate checkout $LEGATE_SHA
69+
70+
IMAGE_TAG_LEGATE=${{ env.IMAGE_NAME_LEGATE }}:${{ inputs.sha }}
71+
72+
chmod +x legate/continuous_integration/build-docker-image
73+
legate/continuous_integration/build-docker-image \
74+
--base-image "$BASE_IMAGE" \
75+
--image-tag "$IMAGE_TAG_LEGATE" \
76+
--source-dir legate
77+
78+
- name: Build cunumeric using docker build
79+
run: |
80+
IMAGE_TAG_CUNUMERIC=${{ env.IMAGE_NAME_CUNUMERIC }}:${{ inputs.sha }}
81+
IMAGE_TAG_LEGATE=${{ env.IMAGE_NAME_LEGATE }}:${{ inputs.sha }}
82+
83+
legate/continuous_integration/build-docker-image \
84+
--base-image "$IMAGE_TAG_LEGATE" \
85+
--image-tag "$IMAGE_TAG_CUNUMERIC" \
86+
--source-dir cunumeric
87+
88+
- name: Dump docker history of image before upload
89+
run: |
90+
IMAGE_TAG=${{ env.IMAGE_NAME_CUNUMERIC }}:${{ inputs.sha }}
91+
docker history $IMAGE_TAG
92+
93+
- name: Log in to container image registry
94+
run: echo "${{ secrets.GITHUB_TOKEN }}" | docker login ghcr.io -u $ --password-stdin
95+
96+
- name: Push cunumeric image
97+
run: |
98+
IMAGE_TAG=${{ env.IMAGE_NAME_CUNUMERIC }}:${{ inputs.sha }}
99+
100+
IMAGE_ID=ghcr.io/${{ github.repository_owner }}
101+
102+
# Change all uppercase to lowercase
103+
IMAGE_ID=$(echo $IMAGE_ID | tr '[A-Z]' '[a-z]')
104+
105+
IMAGE_ID=$IMAGE_ID/$IMAGE_TAG
106+
107+
docker tag $IMAGE_TAG $IMAGE_ID
108+
docker push $IMAGE_ID
109+
110+
- name: Copy artifacts back to the host
111+
run: |
112+
IMAGE_TAG=${{ env.IMAGE_NAME_CUNUMERIC }}:${{ inputs.sha }}
113+
mkdir -p artifacts
114+
docker run -v "$(pwd)/artifacts:/home/coder/.artifacts" --rm -t $IMAGE_TAG copy-artifacts
115+
116+
- name: Display structure of workdir
117+
run: ls -R
118+
119+
- name: Upload build artifacts
120+
uses: actions/upload-artifact@v3
121+
with:
122+
name: "cunumeric-${{ inputs.build-target }}-${{ inputs.sha }}"
123+
path: artifacts

.github/workflows/gh-cleanup.yml

+43
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
name: Clean up
2+
3+
on:
4+
workflow_call:
5+
inputs:
6+
build-target:
7+
required: true
8+
type: string
9+
sha:
10+
required: true
11+
type: string
12+
13+
env:
14+
IMAGE_NAME: cunumeric-${{ inputs.build-target }}
15+
16+
jobs:
17+
cleanup:
18+
permissions:
19+
packages: write
20+
21+
runs-on: ubuntu-latest
22+
23+
steps:
24+
- name: Delete docker image
25+
run: |
26+
set -xeuo pipefail
27+
28+
PACKAGE_NAME=${{ env.IMAGE_NAME }}
29+
PACKAGE_VERSION_ID=$(
30+
curl -L \
31+
-H "Accept: application/vnd.github+json" \
32+
-H "Authorization: Bearer ${{ github.token }}"\
33+
-H "X-GitHub-Api-Version: 2022-11-28" \
34+
https://api.github.com/orgs/${{ github.repository_owner }}/packages/container/$PACKAGE_NAME/versions |
35+
jq '.[] | select(.metadata.container.tags[] == "${{ inputs.sha }}") | .id' -
36+
)
37+
38+
curl -L \
39+
-X DELETE \
40+
-H "Accept: application/vnd.github+json" \
41+
-H "Authorization: Bearer ${{ github.token }}"\
42+
-H "X-GitHub-Api-Version: 2022-11-28" \
43+
https://api.github.com/orgs/${{ github.repository_owner }}/packages/container/$PACKAGE_NAME/versions/$PACKAGE_VERSION_ID

.gitignore

+1
Original file line numberDiff line numberDiff line change
@@ -41,3 +41,4 @@ cunumeric/install_info.py
4141
/_skbuild
4242
/_cmake_test_compile
4343
.ipynb_checkpoints
44+
.legate-test-last-failed

.pre-commit-config.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
repos:
22
- repo: https://github.com/pre-commit/mirrors-mypy
3-
rev: 'v1.4.1'
3+
rev: 'v1.5.1'
44
hooks:
55
- id: mypy
66
language: system

CMakeLists.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ include(rapids-cuda)
5555
include(rapids-export)
5656
include(rapids-find)
5757

58-
set(cunumeric_version 23.07.00)
58+
set(cunumeric_version 23.09.00)
5959

6060
# For now we want the optimization flags to match on both normal make and cmake
6161
# builds so we override the cmake defaults here for release, this changes

cmake/versions.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
{
22
"packages" : {
33
"legate_core" : {
4-
"version": "23.07.00",
4+
"version": "23.09.00",
55
"git_url" : "https://github.com/nv-legate/legate.core.git",
66
"git_shallow": false,
77
"always_download": false,
8-
"git_tag" : "ac75ac05a9056f49729797415ee489b45686a528"
8+
"git_tag" : "14cca04834095553e4d88f503dc4cd35e4072212"
99
}
1010
}
1111
}

0 commit comments

Comments
 (0)