Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 21 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,11 @@ on:
- 'deps/build.jl'
- 'deps/buildtools/**'
- 'Project.toml'
- 'lib/legate_jl_wrapper/src/**'
- 'lib/legate_jl_wrapper/include/**'
- 'lib/LegatePreferences/src/**'
- '.github/workflows/ci.yml'
- '.github/workflows/developer.yml'
- 'Dockerfile' # container.yml depends on this
tags:
- 'v*'
Expand All @@ -32,8 +35,11 @@ on:
- 'deps/build.jl'
- 'deps/buildtools/**'
- 'Project.toml'
- 'lib/legate_jl_wrapper/src/**'
- 'lib/legate_jl_wrapper/include/**'
- 'lib/LegatePreferences/src/**'
- '.github/workflows/ci.yml'
- '.github/workflows/developer.yml'
- 'Dockerfile' # container.yml depends on this
jobs:
check_changes:
Expand All @@ -50,10 +56,24 @@ jobs:
wrapper:
- 'lib/legate_jl_wrapper/**'

developer_tests:
name: Developer wrapper tests
needs: check_changes
# Build-from-source (developer) CI only when the wrapper changed, or on/into main
if: ${{ github.ref == 'refs/heads/main' || github.base_ref == 'main' || needs.check_changes.outputs.wrapper_changed == 'true' }}
permissions:
contents: read
packages: write
attestations: write
id-token: write
actions: write
uses: ./.github/workflows/developer.yml

test:
name: Julia ${{ matrix.julia }} - ${{ matrix.os }}
needs: check_changes
if: ${{ github.base_ref == 'main' || needs.check_changes.outputs.wrapper_changed != 'true' }}
# Always run JLL CI on main (push/merge) and on PRs targeting main; otherwise skip when only wrappers changed
if: ${{ github.ref == 'refs/heads/main' || github.base_ref == 'main' || needs.check_changes.outputs.wrapper_changed != 'true' }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
Expand Down
38 changes: 2 additions & 36 deletions .github/workflows/developer.yml
Original file line number Diff line number Diff line change
@@ -1,44 +1,10 @@
# Develeper CI test. This will build the workflow using Jlls and building wrappers from SRC
name: Develeper CI test

# Called by ci.yml (gated on wrapper changes / main); also runnable manually.
on:
workflow_call:
workflow_dispatch:
inputs:
tag:
description: 'Tag to build instead'
required: false
default: ''
mark_as_latest:
description: 'Mark as latest'
type: boolean
required: false
default: false
push:
paths:
- 'src/**'
- 'scripts/**'
- 'deps/build.jl'
- 'deps/buildtools/**'
- 'Project.toml'
- 'lib/legate_jl_wrapper/src/**'
- 'lib/legate_jl_wrapper/include/**'
- 'lib/LegatePreferences/src/**'
- '.github/workflows/developer.yml'
tags:
- 'v*'
branches:
- main
pull_request:
paths:
- 'src/**'
- 'scripts/**'
- 'deps/build.jl'
- 'deps/buildtools/**'
- 'Project.toml'
- 'lib/legate_jl_wrapper/src/**'
- 'lib/legate_jl_wrapper/include/**'
- 'lib/LegatePreferences/src/**'
- '.github/workflows/developer.yml'
jobs:
pkg_resolve:
uses: ./.github/workflows/pkg_resolve.yml
Expand Down
2 changes: 1 addition & 1 deletion Project.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name = "Legate"
uuid = "1238f2cf-6593-4d60-9aca-2f5364e49909"
version = "0.2.4"
version = "0.2.5"

[workspace]
projects = ["test", "dev"]
Expand Down
2 changes: 1 addition & 1 deletion docs/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"devDependencies": {
"@nolebase/vitepress-plugin-enhanced-readabilities": "^2.15.0",
"@nolebase/vitepress-plugin-enhanced-readabilities": "~2.18.1",
"@types/d3-format": "^3.0.4",
"@types/node": "^22.13.9",
"markdown-it": "^14.1.0",
Expand Down
25 changes: 19 additions & 6 deletions src/Legate.jl
Original file line number Diff line number Diff line change
Expand Up @@ -98,8 +98,21 @@ if !isfile(WRAPPER_LIB_PATH)
)
end

#! DO I NEED TO DLOPEN ANYTHING HERE FIRST?
@wrapmodule(() -> WRAPPER_LIB_PATH)
module LegateInternal
using CxxWrap
import ..WRAPPER_LIB_PATH
@wrapmodule(() -> WRAPPER_LIB_PATH)
function init()
@initcxx
end
end

# Expose C++ types to the main Legate namespace for use in other files
using .LegateInternal: Library, Variable, Constraint, LocalTaskID, GlobalTaskID,
AutoTask, ManualTask, StoreTarget, Shape, Scalar, Slice,
StoreTargetOptional, PhysicalStore, PhysicalArray,
LogicalStoreImpl, LogicalArrayImpl, LogicalStorePartitionImpl,
LegateType, Domain, Runtime, Scope

include("utilities/type_map.jl")
#include("ufi.jl")
Expand Down Expand Up @@ -133,10 +146,10 @@ function _finish_runtime()
#Legate.shutdown_ufi() # shutdown UFI
#end

Legate.has_finished() && return nothing
LegateInternal.has_finished() && return nothing

# finish legate runtime
return Legate.legate_finish()
return LegateInternal.legate_finish()
end

function _configure_realm_backtrace!()
Expand All @@ -153,7 +166,7 @@ function _start_runtime()
Libdl.dlopen(LEGATE_LIB_PATH, Libdl.RTLD_GLOBAL | Libdl.RTLD_NOW)
Libdl.dlopen(WRAPPER_LIB_PATH, Libdl.RTLD_GLOBAL | Libdl.RTLD_NOW)

Legate.start_legate()
LegateInternal.start_legate()
LegatePreferences.maybe_warn_prerelease()
#Legate.init_ufi()

Expand Down Expand Up @@ -187,7 +200,7 @@ function __init__()

LegatePreferences.check_unchanged()

@initcxx
LegateInternal.init()

_is_precompiling() && return nothing

Expand Down
Loading
Loading