-
Notifications
You must be signed in to change notification settings - Fork 585
Expand file tree
/
Copy path.gitlab-ci.yml
More file actions
1335 lines (1254 loc) · 45.4 KB
/
Copy path.gitlab-ci.yml
File metadata and controls
1335 lines (1254 loc) · 45.4 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
# SPDX-FileCopyrightText: Copyright (c) 2023 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
# SPDX-License-Identifier: Apache-2.0
# ==============================================================================
# CI/CD Pipeline Configuration
# ==============================================================================
include:
- /.gitlab/ci/common.yml
- project: "omniverse/warp-gitlab-ci"
ref: "main"
file: "/.gitlab-ci.yml"
# Validates and signs outbound NVCARPS content under skills/ (see NVCARPS onboarding)
- project: "nvcarps/ci-group/nvcarps-ci"
ref: "main"
file: "/.gitlab/nvcarps-upstream-ci.yml"
workflow:
rules:
- if: $CI_PROJECT_ROOT_NAMESPACE != "omniverse" # Prevent pipelines that can't access the runners
when: never
# Product releases only. The repository also carries llvm-sdk-* tags for the prebuilt
# Clang/LLVM SDKs, which are build inputs rather than Warp releases. Without this filter
# they would start a full pipeline, and the deploy jobs keyed on $CI_COMMIT_TAG would
# `gh release upload` Warp wheels onto the SDK release.
- if: $CI_COMMIT_TAG && $CI_COMMIT_TAG !~ /^v/
when: never
- if: $CI_PIPELINE_SOURCE == 'merge_request_event'
- if: $CI_MERGE_REQUEST_TARGET_BRANCH_SHA
- if: $CI_PIPELINE_SOURCE == "schedule" || $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH
auto_cancel:
on_new_commit: none
on_job_failure: none
- if: $CI_COMMIT_TAG =~ /^v/
- if: $CI_COMMIT_BRANCH =~ /^release-.*/
- if: $CI_PIPELINE_SOURCE == "web" # Run if triggered from the UI
variables:
PM_PACKAGES_ROOT: "$CI_PROJECT_DIR/packman-repo"
PIP_CACHE_DIR: "$CI_PROJECT_DIR/.cache/pip"
WARP_CACHE_PATH: "$CI_PROJECT_DIR/.cache/warp" # Used by the parallel test runner
GIT_DEPTH: 1
PYTHONFAULTHANDLER: "1" # Dump tracebacks on fatal signals (SIGSEGV, SIGABRT, etc.)
UV_LINK_MODE: copy
UV_HTTP_TIMEOUT: 120
UV_PYTHON_PREFERENCE: only-managed
# Standard container images (pinned with SHA256 for supply chain security)
UV_TRIXIE_IMAGE: "ghcr.io/astral-sh/uv:0.11.16-trixie@sha256:3a10099599f370305314be6af0cf18fdbc65ea5ddadb3731561dd920f1d185b8"
UV_TRIXIE_SLIM_IMAGE: "ghcr.io/astral-sh/uv:0.11.16-trixie-slim@sha256:bf3ae2823f0399092f2e47ec7bae6a8e0b389d2310a9bc7f0741f0fa1629040f"
UV_TRIXIE_SLIM_ARM_IMAGE: "ghcr.io/astral-sh/uv:0.11.16-trixie-slim@sha256:e4e5baeeb366609825aadbe4387686c39dab036b0cc68d938fcb9a61aa05bf75"
MINIFORGE_IMAGE: "condaforge/miniforge3:25.11.0-0@sha256:d2fadb08950045962fd1cfb1eeb6224442027f03095862e725f4c1c7b17a3caf"
# Stale pin, and harmless. These tags name older images that still bake in LLVM 21,
# from before the builder image stopped shipping Clang/LLVM at all. Nothing links
# that LLVM: these jobs run build_lib.py without --llvm-path, so the SDK always
# comes from Packman via deps/llvm-deps.packman.xml no matter what the image holds.
#
# Once images built from the current Dockerfile are published to this registry,
# move these to the LLVM-free tag scheme: warp-builder:cuda12.9.1-latest and
# warp-builder:cuda13.0.2-latest.
WARP_BUILDER_IMAGE_CU12: "${CI_REGISTRY_IMAGE}/warp-builder:cuda12.9.1-llvm21-latest"
WARP_BUILDER_IMAGE_CU13: "${CI_REGISTRY_IMAGE}/warp-builder:cuda13.0.2-llvm21-latest"
UV_PYTHON:
value: "3.12"
options:
- "3.14"
- "3.13"
- "3.12"
- "3.11"
- "3.10"
description: "The default UV Python version used in the main testing jobs."
# NVCARPS skill validation and signing
NVCARPS_CI_TRIGGER_BRANCH: "main"
NVCARPS_CI_UPSTREAM_PROFILE: "external"
NVCARPS_CI_AUTO_SIGN: "true"
stages:
- build
- quality
- test
- child pipelines
- package
- deploy
- nvskills-pipeline
# ==============================================================================
# Build Jobs
#
# Compiles Warp binaries for all platforms (Linux, Windows, macOS) using CUDA 12
# by default. Also includes CUDA 13 build for compatibility testing.
# ==============================================================================
linux-aarch64 build:
stage: build
image: $WARP_BUILDER_IMAGE_CU12
extends:
- .lnx-aarch64-cpu-medium
- .save_warp_bin_artifact
before_script:
- gcc --version
script:
- uv run build_lib.py --cuda-path=/usr/local/cuda
- mkdir -p warp/bin/linux-aarch64
- mv warp/bin/warp.so warp/bin/linux-aarch64
- mv warp/bin/warp-clang.so warp/bin/linux-aarch64
linux-x86_64 build:
stage: build
image: $WARP_BUILDER_IMAGE_CU12
variables:
IPP_RUNNER_EXECUTION_DURATION: "3600"
extends:
- .save_warp_bin_artifact
- .ipp_lnx_x86_64_cpu_medium
before_script:
- gcc --version
script:
- uv run build_lib.py --cuda-path=/usr/local/cuda
- mkdir -p warp/bin/linux-x86_64
- mv warp/bin/warp.so warp/bin/linux-x86_64
- mv warp/bin/warp-clang.so warp/bin/linux-x86_64
windows-x86_64 build:
stage: build
variables:
IPP_RUNNER_EXECUTION_DURATION: "3600"
extends:
- .save_warp_bin_artifact
- .runner-build-windows-x86_64
before_script:
- !reference [.snippets, install-uv-windows]
- !reference [.snippets, setup-packman-config-windows]
- tools\packman\packman pull --platform windows-x86_64 deps\cuda-toolkit-deps.packman.xml --verbose --include-tag "cuda-12"
- tools\packman\packman install -l _build\host-deps\winsdk winsdk 10.17763
- tools\packman\packman install -l _build\host-deps\msvc msvc 2019-16.11.24
script:
- |
$env:PATH = "$env:CI_PROJECT_DIR\_uv;$env:PATH"
uv run build_lib.py --msvc-path=_build\host-deps\msvc\VC\Tools\MSVC\14.29.30133 --sdk-path=_build\host-deps\winsdk --cuda-path=_build\target-deps\cuda
mac-aarch64 build:
stage: build
extends:
- .save_warp_bin_artifact
- .runner-build-macos-universal
- .macos_warp_tags
before_script:
- df -h
- curl -LsSf https://astral.sh/uv/install.sh | env UV_UNMANAGED_INSTALL="$CI_PROJECT_DIR/_uv" sh
- export PATH="$CI_PROJECT_DIR/_uv/bin:$PATH"
script:
- uv run build_lib.py
linux-x86_64 cuda 13 build:
stage: build
image: $WARP_BUILDER_IMAGE_CU13
variables:
IPP_RUNNER_EXECUTION_DURATION: "3600"
extends:
- .save_warp_bin_artifact
- .ipp_lnx_x86_64_cpu_medium
script:
- uv run build_lib.py --cuda-path=/usr/local/cuda
- mkdir -p warp/bin/linux-x86_64
- mv warp/bin/warp.so warp/bin/linux-x86_64
- mv warp/bin/warp-clang.so warp/bin/linux-x86_64
linux-x86_64 python free-threaded build:
stage: build
image: $WARP_BUILDER_IMAGE_CU13
variables:
IPP_RUNNER_EXECUTION_DURATION: "3600"
UV_PYTHON: "3.14t"
extends:
- .save_warp_bin_artifact
- .ipp_lnx_x86_64_cpu_medium
script:
- uv python install 3.14t
- uv run --python 3.14t build_lib.py --cuda-path=/usr/local/cuda
- mkdir -p warp/bin/linux-x86_64
- mv warp/bin/warp.so warp/bin/linux-x86_64
- mv warp/bin/warp-clang.so warp/bin/linux-x86_64
linux-aarch64 cuda 13 build:
stage: build
image: $WARP_BUILDER_IMAGE_CU13
extends:
- .lnx-aarch64-cpu-medium
- .save_warp_bin_artifact
before_script:
- gcc --version
script:
- uv run build_lib.py --cuda-path=/usr/local/cuda
- mkdir -p warp/bin/linux-aarch64
- mv warp/bin/warp.so warp/bin/linux-aarch64
- mv warp/bin/warp-clang.so warp/bin/linux-aarch64
windows-x86_64 cuda 13 build:
stage: build
variables:
IPP_RUNNER_EXECUTION_DURATION: "3600"
extends:
- .save_warp_bin_artifact
- .runner-build-windows-x86_64
before_script:
- !reference [.snippets, install-uv-windows]
- !reference [.snippets, setup-packman-config-windows]
- tools\packman\packman pull --platform windows-x86_64 deps\cuda-toolkit-deps.packman.xml --verbose --include-tag "cuda-13"
- tools\packman\packman install -l _build\host-deps\winsdk winsdk 10.17763
- tools\packman\packman install -l _build\host-deps\msvc msvc 2019-16.11.24
script:
- |
$env:PATH = "$env:CI_PROJECT_DIR\_uv;$env:PATH"
uv run build_lib.py --msvc-path=_build\host-deps\msvc\VC\Tools\MSVC\14.29.30133 --sdk-path=_build\host-deps\winsdk --cuda-path=_build\target-deps\cuda
linux-x86_64 debug build:
stage: build
image: $WARP_BUILDER_IMAGE_CU12
variables:
IPP_RUNNER_EXECUTION_DURATION: "3600"
extends:
- .save_warp_bin_artifact
- .ipp_lnx_x86_64_cpu_large
before_script:
- gcc --version
script:
- uv run build_lib.py --cuda-path=/usr/local/cuda --mode=debug
- mkdir -p warp/bin/linux-x86_64
- mv warp/bin/warp.so warp/bin/linux-x86_64
- mv warp/bin/warp-clang.so warp/bin/linux-x86_64
# ==============================================================================
# Code Quality and Documentation Checks
#
# Linting, static analysis, documentation testing, and symbol validation.
# Most jobs run independently without waiting for builds (except those that
# need compiled binaries for testing or validation).
# ==============================================================================
pre-commit checks:
stage: quality
image: $UV_TRIXIE_IMAGE
needs: []
variables:
IPP_RUNNER_EXECUTION_DURATION: "3600"
extends:
- .ipp_lnx_x86_64_cpu_micro
script:
- uvx pre-commit run --all-files --show-diff-on-failure
validate fragments:
stage: quality
image: $UV_TRIXIE_IMAGE
needs: []
variables:
IPP_RUNNER_EXECUTION_DURATION: "900"
extends:
- .ipp_lnx_x86_64_cpu_micro
rules:
- if: $CI_PIPELINE_SOURCE == 'merge_request_event'
changes:
- CHANGELOG.md
- changelog/**/*
- pyproject.toml
script:
- uvx --from towncrier==25.8.0 towncrier build --draft --version Unreleased
type-check stubs:
stage: quality
image: $UV_TRIXIE_IMAGE
needs: []
variables:
IPP_RUNNER_EXECUTION_DURATION: "900"
GIT_LFS_SKIP_SMUDGE: "1"
GIT_DEPTH: "1"
extends:
- .ipp_lnx_x86_64_cpu_micro
script:
- uvx pyright warp/__init__.pyi
- uvx mypy warp/__init__.pyi --follow-imports=silent
# This job tests code snippets in the documentation
doctest:
stage: quality
image: $UV_TRIXIE_IMAGE
needs: [linux-x86_64 build]
variables:
IPP_RUNNER_EXECUTION_DURATION: "3600"
extends:
- .ipp_lnx_x86_64_gpu
before_script:
- df -h
- !reference [.snippets, move-linux-x86_64-binaries]
script:
- uv run --extra docs build_docs.py --doctest --no-html --warnings-as-errors
# The only purpose of this job is to make sure documentation can be built on Windows.
# The output does not get published anywhere, but the website can be viewed in the
# artifacts.
windows-x86_64 docs:
stage: quality
needs: [windows-x86_64 build]
variables:
IPP_RUNNER_EXECUTION_DURATION: "3600"
extends:
- .runner-utility-windows-x86_64
artifacts:
paths:
- public
before_script:
- !reference [.snippets, define-powershell-GetTime]
- !reference [.snippets, powershell-section-start-install-deps]
- !reference [.snippets, install-uv-windows]
- !reference [.snippets, powershell-section-end-install-deps]
script:
- |
$env:PATH = "$env:CI_PROJECT_DIR\_uv;$env:PATH"
uv run --extra docs build_docs.py --warnings-as-errors
- mv docs/_build/html/ ./public/
after_script:
- echo "View the website at https://$CI_PROJECT_ROOT_NAMESPACE.$CI_PAGES_DOMAIN/-/$CI_PROJECT_NAME/-/jobs/$CI_JOB_ID/artifacts/public/index.html"
.check_un_namespaced_symbols_linux_x86_64:
stage: quality
image: python:3.12-bullseye
variables:
IPP_RUNNER_EXECUTION_DURATION: "3600"
extends:
- .ipp_lnx_x86_64_cpu_micro
script:
- |
echo "Checking for un-namespaced symbols..."
LIBRARIES_TO_CHECK="warp/bin/linux-x86_64/warp.so warp/bin/linux-x86_64/warp-clang.so"
found_symbols=""
for lib in $LIBRARIES_TO_CHECK; do
echo "--> Checking $lib"
if [ ! -f "$lib" ]; then
echo "ERROR: $lib not found"
found_symbols="true"
continue
fi
output=$(readelf -Ws "$lib" | awk '$7 ~ /^[0-9]+$/ && $8 !~ /^(_?wp_|PyInit__warp_)/ {print $8}' | grep -Ev '^(_Z|__|\.)' || true)
if [ -n "$output" ]; then
echo "ERROR: Found un-namespaced symbols in $lib:"
echo "$output"
found_symbols="true"
fi
done
if [ -n "$found_symbols" ]; then
echo "FAIL: Un-namespaced symbols detected. Please prefix them with 'wp_' or '_wp_'."
exit 1
fi
echo "SUCCESS: All symbols are correctly namespaced."
check un-namespaced symbols linux-x86_64:
needs: [linux-x86_64 build]
extends:
- .check_un_namespaced_symbols_linux_x86_64
check un-namespaced symbols linux-x86_64 cuda 13:
needs: [linux-x86_64 cuda 13 build]
extends:
- .check_un_namespaced_symbols_linux_x86_64
cppcheck:
stage: quality
image: $MINIFORGE_IMAGE
needs: []
variables:
IPP_RUNNER_EXECUTION_DURATION: "3600"
extends:
- .ipp_lnx_x86_64_cpu_medium
before_script:
- echo -e "\\e[0Ksection_start:`date +%s`:install_dependencies[collapsed=true]\\r\\e[0KInstalling dependencies"
- df -h
- conda install cppcheck --channel conda-forge
- python -m pip install -U cppcheck-codequality
- mkdir -p _build/.cppcheck
- cppcheck --version
- echo -e "\\e[0Ksection_end:`date +%s`:install_dependencies\\r\\e[0K"
script:
# Pass 1: For the CI log and job failure.
- cppcheck_exit_code=0
- >-
cppcheck
--inline-suppr
--cppcheck-build-dir=_build/.cppcheck
--enable=warning
--quiet
--error-exitcode=1
-j $(nproc)
--suppress=*:warp/native/nanovdb/*
--suppress=*:warp/native/cuBQL/*
--suppress=normalCheckLevelMaxBranches
warp
|| cppcheck_exit_code=$?
# Pass 2: For the Code Quality report.
- >-
cppcheck
--inline-suppr
--cppcheck-build-dir=_build/.cppcheck
--enable=warning
--quiet
--xml
--xml-version=2
-j $(nproc)
--suppress=*:warp/native/nanovdb/*
--suppress=*:warp/native/cuBQL/*
--suppress=normalCheckLevelMaxBranches
warp
2> cppcheck-report.xml
- cppcheck-codequality --input-file=cppcheck-report.xml --output-file=gl-code-quality-report.json
- exit $cppcheck_exit_code
artifacts:
when: always
reports:
codequality: gl-code-quality-report.json
paths:
- cppcheck-report.xml
# ==============================================================================
# Unit Testing Jobs
#
# Comprehensive test suite across multiple platforms (Linux x86_64/aarch64,
# Windows, specialized hardware like Orin/Thor/Blackwell), Python versions
# (3.10-3.14), and optional integrations (MuJoCo, JAX, PyTorch). Some jobs
# compute code coverage, others focus on compatibility and performance (ASV).
# ==============================================================================
.test_common_with_coverage:
stage: test
extends:
- .basic_test_changes_rules
coverage: '/(?i)total.*? (100(?:\.0+)?\%|[1-9]?\d(?:\.\d+)?\%)$/'
artifacts:
when: always
paths:
- rspec.xml
- coverage.xml
reports:
junit: rspec.xml
coverage_report:
coverage_format: cobertura
path: coverage.xml
linux-aarch64 test:
image: $UV_TRIXIE_SLIM_ARM_IMAGE
needs: [linux-aarch64 build]
extends:
- .omni_rtx_gpu_arm
- .test_common_with_coverage
before_script:
- df -h
- !reference [.snippets, move-linux-aarch64-binaries]
script:
- uv run --extra dev --with "jax[cuda12]>=0.5" --with rmm-cu12 -m warp.tests --junit-report-xml rspec.xml --coverage --coverage-xml coverage.xml -s autodetect --failfast
linux-aarch64 cuda 13 test:
image: $UV_TRIXIE_SLIM_ARM_IMAGE
needs: [linux-aarch64 cuda 13 build]
extends:
- .omni_rtx_gpu_arm
- .test_common_with_coverage
before_script:
- df -h
- !reference [.snippets, move-linux-aarch64-binaries]
script:
- uv run --extra dev --with "jax[cuda13]>=0.5" --with rmm-cu13 -m warp.tests --junit-report-xml rspec.xml --coverage --coverage-xml coverage.xml -s autodetect --failfast
linux-aarch64 test orin:
needs: [linux-aarch64 build]
image: $UV_TRIXIE_SLIM_ARM_IMAGE
extends:
- .save_test_report_artifact
rules:
- if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH
- if: $CI_PIPELINE_SOURCE == "schedule"
- if: $CI_COMMIT_TAG
- if: $CI_COMMIT_BRANCH =~ /^release-.*/
- if: $CI_PIPELINE_SOURCE == "web"
- when: manual # Can be triggered in all other scenarios
allow_failure: true
before_script:
- !reference [.snippets, section-start-install-deps]
- df -h
- !reference [.snippets, move-linux-aarch64-binaries]
- uv sync --extra dev --no-install-package psutil
- !reference [.snippets, section-end-install-deps]
script:
- uv run --with rmm-cu12 -m warp.tests --maxjobs 4 --junit-report-xml rspec.xml -s autodetect --failfast
tags:
- gpu/orin
linux-aarch64 test thor:
needs: [linux-aarch64 build]
image: $UV_TRIXIE_SLIM_ARM_IMAGE
extends:
- .save_test_report_artifact
- .basic_test_changes_rules
before_script:
- !reference [.snippets, section-start-install-deps]
- df -h
- !reference [.snippets, move-linux-aarch64-binaries]
- uv sync --extra dev
- !reference [.snippets, section-end-install-deps]
script:
- uv run --extra dev --with rmm-cu12 -m warp.tests --junit-report-xml rspec.xml -s autodetect --failfast
tags:
- gpu/thor
linux-aarch64 test dgx spark:
needs: [linux-aarch64 build]
image: $UV_TRIXIE_SLIM_ARM_IMAGE
extends:
- .save_test_report_artifact
- .basic_test_changes_rules
before_script:
- !reference [.snippets, section-start-install-deps]
- df -h
- !reference [.snippets, move-linux-aarch64-binaries]
- uv sync --extra dev
- !reference [.snippets, section-end-install-deps]
script:
- uv run --extra dev --with rmm-cu12 -m warp.tests --junit-report-xml rspec.xml -s autodetect --failfast
tags:
- os/linux
- arch/arm
- gpu/GB10
linux-aarch64 test dgx spark cuda 13:
needs: [linux-aarch64 cuda 13 build]
image: $UV_TRIXIE_SLIM_ARM_IMAGE
extends:
- .save_test_report_artifact
- .basic_test_changes_rules
before_script:
- !reference [.snippets, section-start-install-deps]
- df -h
- !reference [.snippets, move-linux-aarch64-binaries]
- uv sync --extra dev
- !reference [.snippets, section-end-install-deps]
script:
- uv run --extra dev -m warp.tests --junit-report-xml rspec.xml -s autodetect --failfast
tags:
- os/linux
- arch/arm
- gpu/GB10
linux-x86_64 test:
needs: [linux-x86_64 build]
image: $UV_TRIXIE_IMAGE
variables:
IPP_RUNNER_EXECUTION_DURATION: "3600"
extends:
- .ipp_lnx_x86_64_gpu_2x
- .test_common_with_coverage
before_script:
- df -h
- !reference [.snippets, move-linux-x86_64-binaries]
# HACK: disable P2P tests due to misbehaving agents
- export WARP_DISABLE_P2P_TESTS=1
script:
- uv run --extra dev --extra torch-cu12 --with "jax[cuda12]>=0.5" --with rmm-cu12 -m warp.tests --junit-report-xml rspec.xml --coverage --coverage-xml coverage.xml -s autodetect --failfast
linux-x86_64 cuda 13 test:
needs: [linux-x86_64 cuda 13 build]
image: $UV_TRIXIE_IMAGE
variables:
IPP_RUNNER_EXECUTION_DURATION: "3600"
extends:
- .ipp_lnx_x86_64_gpu_2x
- .test_common_with_coverage
before_script:
- df -h
- !reference [.snippets, move-linux-x86_64-binaries]
# HACK: disable P2P tests due to misbehaving agents
- export WARP_DISABLE_P2P_TESTS=1
script:
- uv run --extra dev --extra torch-cu13 --with "jax[cuda13]>=0.5" --with rmm-cu13 -m warp.tests --junit-report-xml rspec.xml --coverage --coverage-xml coverage.xml -s autodetect --failfast
# A temporary job for testing on Blackwell until more runners are available
linux-x86_64-blackwell test:
needs: [linux-x86_64 build]
image: $UV_TRIXIE_SLIM_IMAGE
extends:
- .test_common_with_coverage
before_script:
- df -h
- !reference [.snippets, move-linux-x86_64-binaries]
script:
- uv run --extra dev --extra torch-cu13 --with "jax[cuda13]>=0.5" --with rmm-cu13 -m warp.tests --junit-report-xml rspec.xml --coverage --coverage-xml coverage.xml -s autodetect --failfast
tags:
- arch/x86_64
- gpu/B40
- os/linux
- platform/horde
linux-x86_64 python free-threaded test:
stage: test
needs: [linux-x86_64 python free-threaded build]
image: $UV_TRIXIE_SLIM_IMAGE
variables:
IPP_RUNNER_EXECUTION_DURATION: "3600"
UV_PYTHON: "3.14t"
extends:
- .ipp_lnx_x86_64_gpu
- .save_test_report_artifact
- .basic_test_changes_rules
before_script:
- !reference [.snippets, section-start-install-deps]
- df -h
- apt-get update && apt-get install build-essential --no-install-recommends -y
- uv python install 3.14t
- !reference [.snippets, move-linux-x86_64-binaries]
# usd-core wheels use ABI tag "none" but are built against the regular
# (GIL) CPython ABI, so importing pxr on a free-threaded interpreter
# segfaults. Blosc also does not support free-threaded Python and importing
# its extension re-enables the GIL. Keep both packages out of this environment.
- uv sync --python 3.14t --extra dev --no-install-package usd-core --no-install-package blosc
- !reference [.snippets, section-end-install-deps]
script:
- uv run --python 3.14t --no-sync -m warp.tests --junit-report-xml rspec.xml -s autodetect --failfast
linux-x86_64 test debug mode:
stage: test
needs: [linux-x86_64 build]
image: $UV_TRIXIE_SLIM_IMAGE
variables:
IPP_RUNNER_EXECUTION_DURATION: "2700"
extends:
- .ipp_lnx_x86_64_gpu
- .save_test_report_artifact
- .basic_test_changes_rules
before_script:
- df -h
- !reference [.snippets, move-linux-x86_64-binaries]
script:
- uv run --extra dev -m warp.tests --junit-report-xml rspec.xml --suite debug --warp-debug --failfast
# Note that for throughput reasons this runs on a single-GPU runner
windows-x86_64 test:
stage: test
needs: [windows-x86_64 build]
variables:
IPP_RUNNER_EXECUTION_DURATION: "4500"
extends:
- .runner-test-windows-x86_64-gpu
- .test_common_with_coverage
before_script:
- !reference [.snippets, define-powershell-GetTime]
- !reference [.snippets, powershell-section-start-install-deps]
- !reference [.snippets, install-uv-windows]
- !reference [.snippets, powershell-section-end-install-deps]
script:
# Locking usd-core to 25.5.1 to work around a frequent loading crash
- |
$env:PATH = "$env:CI_PROJECT_DIR\_uv;$env:PATH"
uv run --extra dev --extra torch-cu12 --with "jax>=0.5" --with usd-core==25.5.1 -m warp.tests --junit-report-xml rspec.xml --coverage --coverage-xml coverage.xml -s autodetect --failfast
windows-x86_64 cuda 13 test:
stage: test
needs: [windows-x86_64 cuda 13 build]
variables:
IPP_RUNNER_EXECUTION_DURATION: "4500"
extends:
- .runner-test-windows-x86_64-gpu
- .test_common_with_coverage
before_script:
- !reference [.snippets, define-powershell-GetTime]
- !reference [.snippets, powershell-section-start-install-deps]
- !reference [.snippets, install-uv-windows]
- !reference [.snippets, powershell-section-end-install-deps]
script:
# Locking usd-core to 25.5.1 to work around a frequent loading crash
- |
$env:PATH = "$env:CI_PROJECT_DIR\_uv;$env:PATH"
uv run --extra dev --extra torch-cu13 --with "jax>=0.5" --with usd-core==25.5.1 -m warp.tests --junit-report-xml rspec.xml --coverage --coverage-xml coverage.xml -s autodetect --failfast
# Only one Windows Blackwell runner currently serves the whole organization, so
# this job is opt-in on merge requests to avoid saturating it. It still runs
# automatically on the default branch, schedules, tags, and release branches.
windows-x86_64-blackwell test:
stage: test
needs: [windows-x86_64 build]
variables:
IPP_RUNNER_EXECUTION_DURATION: "4500"
extends:
- .test_common_with_coverage
rules:
- if: $CI_PIPELINE_SOURCE == "schedule" || $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH
- if: $CI_COMMIT_TAG
- if: $CI_COMMIT_BRANCH =~ /^release-.*/
- if: $CI_PIPELINE_SOURCE == "web"
- when: manual # Merge request pipelines: run only on demand
allow_failure: true
before_script:
- !reference [.snippets, define-powershell-GetTime]
- !reference [.snippets, powershell-section-start-install-deps]
- !reference [.snippets, install-uv-windows]
- !reference [.snippets, powershell-section-end-install-deps]
script:
# Locking usd-core to 25.5.1 to work around a frequent loading crash
- |
$env:PATH = "$env:CI_PROJECT_DIR\_uv;$env:PATH"
uv run --extra dev --extra torch-cu13 --with usd-core==25.5.1 -m warp.tests --junit-report-xml rspec.xml --coverage --coverage-xml coverage.xml -s autodetect --failfast
tags:
- win-x86_64-gpu-1x-595.97-blackwell
- gpu/blackwell
- os/windows
# Optional multi-GPU Windows job (likely longer queue time)
windows-x86_64 test mgpu:
stage: test
needs: [windows-x86_64 build]
variables:
IPP_RUNNER_EXECUTION_DURATION: "4500"
extends:
- .save_test_report_artifact
rules:
- if: $CI_PIPELINE_SOURCE == "schedule"
- if: $CI_COMMIT_TAG
- when: manual # Can be triggered in all other scenarios
allow_failure: true
allow_failure: true # GitLab runners are too unstable to run this job
before_script:
- !reference [.snippets, define-powershell-GetTime]
- !reference [.snippets, powershell-section-start-install-deps]
- !reference [.snippets, install-uv-windows]
- !reference [.snippets, powershell-section-end-install-deps]
script:
# Locking usd-core to 25.5.1 to work around a frequent loading crash
- |
$env:PATH = "$env:CI_PROJECT_DIR\_uv;$env:PATH"
uv run --extra dev --extra torch-cu12 --with usd-core==25.5.1 -m warp.tests --junit-report-xml rspec.xml -s autodetect --failfast
tags:
- win-x86_64-gpu-2x-595.97
# Note: This will no longer be needed once Warp auto-initializes upon import
linux-x86_64 test warp-init:
stage: test
image: $UV_TRIXIE_SLIM_IMAGE
needs: [linux-x86_64 build]
variables:
IPP_RUNNER_EXECUTION_DURATION: "900"
extends:
- .ipp_lnx_x86_64_gpu
- .save_test_report_artifact
- .basic_test_changes_rules
before_script:
- df -h
- !reference [.snippets, move-linux-x86_64-binaries]
script:
# Keep exactly one test per class: class-level isolation must give every test
# a fresh process without Warp runtime state inherited from an earlier test.
- uv run --python 3.12 --extra dev -m warp.tests --junit-report-xml rspec.xml -s autodetect --isolate-test-processes --level class -p 'test_implicit_init.py'
# Optional job to test MuJoCo Warp
linux-x86_64 test mujoco warp:
stage: test
needs: [linux-x86_64 build]
image: $UV_TRIXIE_IMAGE
extends:
- .ipp_lnx_x86_64_gpu
- .save_test_report_artifact
variables:
IPP_RUNNER_EXECUTION_DURATION: "3600"
UV_PYTHON: "3.12"
rules:
- if: $CI_PIPELINE_SOURCE == "schedule" || $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH
- if: $CI_COMMIT_TAG
- if: $CI_COMMIT_BRANCH =~ /^release-.*/
- if: $CI_PIPELINE_SOURCE == "web"
- if: $CI_PIPELINE_SOURCE == 'merge_request_event'
changes:
- .gitlab-ci.yml
- .gitlab/ci/*
- warp/**/*
- pyproject.toml
- tools/**/*
- deps/*
- build_lib.py
- build_llvm.py
allow_failure: true # Don't want to block MRs
- when: manual # If not auto-triggered, allow any pipeline to run this job manually
allow_failure: true # Don't want to block MRs
before_script:
- !reference [.snippets, move-linux-x86_64-binaries]
# Python environment
- uv venv
- uv pip install -e .
- uv pip install mujoco
- uv pip install "git+https://github.com/google-deepmind/mujoco_warp@main"
- uv pip install pytest pytest-xdist "jax[cuda12]"
- source .venv/bin/activate
- echo -e "\\e[0Ksection_end:`date +%s`:install_dependencies\\r\\e[0K"
script:
- pytest -n 4 --pyargs mujoco_warp --junit-xml=rspec.xml
# Serial counterpart to help diagnose multi-process failures
linux-x86_64 test mujoco warp serial:
stage: test
needs: [linux-x86_64 build]
image: $UV_TRIXIE_IMAGE
extends:
- .ipp_lnx_x86_64_gpu
- .save_test_report_artifact
variables:
IPP_RUNNER_EXECUTION_DURATION: "3600"
UV_PYTHON: "3.12"
rules:
- if: $CI_PIPELINE_SOURCE == "schedule"
- when: manual
allow_failure: true
before_script:
- !reference [.snippets, move-linux-x86_64-binaries]
# Python environment
- uv venv
- uv pip install -e .
- uv pip install mujoco
- uv pip install "git+https://github.com/google-deepmind/mujoco_warp@main"
- uv pip install pytest
- source .venv/bin/activate
- echo -e "\\e[0Ksection_end:`date +%s`:install_dependencies\\r\\e[0K"
script:
- pytest --pyargs mujoco_warp --junit-xml=rspec.xml
# Optional job to test Newton (https://pypi.org/project/newton/)
linux-x86_64 test newton:
stage: test
needs: [linux-x86_64 build]
image: $UV_TRIXIE_IMAGE
extends:
- .ipp_lnx_x86_64_gpu
- .save_test_report_artifact
variables:
IPP_RUNNER_EXECUTION_DURATION: "3600"
UV_PYTHON: "3.12"
rules:
- when: manual
allow_failure: true
before_script:
- !reference [.snippets, move-linux-x86_64-binaries]
# Python environment
- uv venv
- uv pip install -e .
- uv pip install --prerelease allow "newton[dev]"
- source .venv/bin/activate
- echo -e "\\e[0Ksection_end:`date +%s`:install_dependencies\\r\\e[0K"
script:
- python -m newton.tests --junit-report-xml rspec.xml
# Ensure minimum and maximum Python versions are supported
linux-x86_64 python matrix test:
stage: test
image: $UV_TRIXIE_SLIM_IMAGE
needs: [linux-x86_64 build]
variables:
IPP_RUNNER_EXECUTION_DURATION: "3600"
extends:
- .ipp_lnx_x86_64_gpu
- .save_test_report_artifact
- .basic_test_changes_rules
parallel:
matrix:
- UV_PYTHON: "3.10"
- UV_PYTHON: "3.13"
- UV_PYTHON: "3.14"
before_script:
- !reference [.snippets, section-start-install-deps]
- df -h
# Python 3.14 requires a C compiler for some dependencies
- if [ "$UV_PYTHON" = "3.14" ]; then apt-get update && apt-get install build-essential --no-install-recommends -y; fi
- !reference [.snippets, move-linux-x86_64-binaries]
- !reference [.snippets, section-end-install-deps]
script:
- uv run --extra dev --with rmm-cu12 -m warp.tests --junit-report-xml rspec.xml -s autodetect --failfast
# Ensure cpp examples compile and run
linux-x86_64 cpp examples test:
stage: test
image: ${CI_REGISTRY_IMAGE}/warp-cpp-test-env:12.9.1-ubuntu24.04
needs: [linux-x86_64 build]
variables:
IPP_RUNNER_EXECUTION_DURATION: "3600"
extends:
- .ipp_lnx_x86_64_gpu
- .basic_test_changes_rules
before_script:
- df -h
- !reference [.snippets, move-linux-x86_64-binaries]
- ls -lh warp/bin/*.so # Verify binaries exist
script:
- cd warp/examples/cpp
- bash test_examples.sh
# ==============================================================================
# Child Pipeline Triggers
#
# Triggers for specialized debug, Clang, and ASV configurations. These run
# conditionally based on changed files, schedules, tags, or manual triggers.
# ==============================================================================
# Trigger debug build and test (no code coverage) pipelines
# Workaround from https://gitlab.com/gitlab-org/gitlab/-/issues/284086
trigger debug build and test pipeline:
stage: test
image: busybox
extends:
- .ipp_lnx_x86_64_cpu_micro
needs: [linux-x86_64 debug build]
rules:
- if: $CI_PIPELINE_SOURCE == "schedule"
- if: $CI_COMMIT_TAG
- if: $CI_COMMIT_BRANCH =~ /^release-.*/
- when: manual # Can be triggered in all other scenarios
allow_failure: true
variables:
IPP_RUNNER_EXECUTION_DURATION: "3600"
GIT_STRATEGY: none
script:
- echo "Run this job to test Warp compiled in debug mode."
# Uses the same Python version as the main pipeline.
debug build and test:
stage: child pipelines
needs: [trigger debug build and test pipeline]
trigger:
include: /.gitlab/ci/debug-build-and-test.yml
extends:
- .trigger_common
# Test Warp compilation with Clang instead of GCC and NVCC
clang compilation:
stage: child pipelines
trigger:
include: /.gitlab/ci/clang-build-and-test.yml
needs: []
extends:
- .basic_test_changes_rules
- .trigger_common
# Run the airspeed velocity (ASV) benchmark suite. Auto-triggers on MR
# pipelines whose diff touches any path that could affect a benchmark
# result; the child pipeline itself further gates the heavy tile suite
# on tile-relevant paths. `needs: []` so the trigger fires at pipeline
# start and the child's build job is not blocked behind the parent's
# test stage.
asv benchmarks:
stage: child pipelines
trigger:
include: /.gitlab/ci/asv.yml
needs: []
extends:
- .trigger_common
rules:
- if: $CI_PIPELINE_SOURCE == 'merge_request_event'
changes:
- .gitlab-ci.yml
- .gitlab/ci/asv.yml
- asv/**/*
- asv.conf.json
- warp/*.py
- warp/*.pyi
- warp/py.typed
- warp/_src/**/*
- warp/examples/assets/**/*
- warp/examples/fem/utils.py
- warp/fem/**/*
- warp/jax_experimental/**/*
- warp/native/**/*
- warp/optim/**/*
- warp/render/**/*
- pyproject.toml
- setup.py
- deps/*
- build_lib.py
- build_llvm.py
# Manual fallback: any MR whose diff doesn't match the path filter
# above can still opt in to bench via a play button (e.g. tooling
# changes that affect codegen but live outside warp/**).
- if: $CI_PIPELINE_SOURCE == 'merge_request_event'
when: manual
allow_failure: true
# ==============================================================================
# Packaging Jobs
#
# Creates Python wheels for PyPI distribution across all platforms. Produces both
# release wheels (with CUDA variants) and nightly development builds. Typically
# runs on schedules, tags, or manual trigger rather than every merge request.
# ==============================================================================
# Creates wheel files for PyPI