Files
metal2vulkan/crates/metal2vulkan-runtime/Cargo.toml
T
Anees Iqbal ddd339e2a3 Count released objects by kind and shadow keeps by planner, for the residency churn
The steps this packet landed as, in order:
- Count no-copy imports a live import already holds
- Recycle a texture's image and memory for the next texture of the same making
- Add a control build that turns the image recycler off (--cfg m2v_no_recycle)
- Count image, buffer and memory releases by the place that released them
- Recycle the runtime's buffers and their memory for the next buffer of the same size

Content: the tree of `development` at db877e7a50, unchanged.
2026-10-26 13:19:03 +02:00

87 lines
3.1 KiB
TOML

[package]
name = "metal2vulkan-runtime"
version = "0.2.0"
edition.workspace = true
rust-version.workspace = true
license.workspace = true
authors.workspace = true
description = "The Metal API on Vulkan: Metal's objects and calls run on a Vulkan device through ash"
readme = "README.md"
repository.workspace = true
homepage.workspace = true
documentation = "https://docs.rs/metal2vulkan-runtime"
keywords = ["metal", "vulkan", "gpu", "graphics"]
categories = ["graphics", "api-bindings"]
# No crate root can appear unannounced, so validation's product fingerprint follows exactly the
# runtime's module tree (build_support.rs). Each example is listed below.
autobins = false
autoexamples = false
# The runtime's tests read the repository's profiles, fixtures and guide beside this directory.
exclude = ["/target/", "**/*.air", "**/*.metallib", "**/*.spv"]
[lib]
name = "metal2vulkan_runtime"
path = "src/lib.rs"
# Runnable examples for consumers (README.md, "Examples"): each runs the owned fixture
# validation/fixtures/public/examples/runtime_examples.metal on the system default device, from the
# workspace checkout (its committed LLVM text, assembled by `llvm-as`), or a metallib passed as the
# first argument.
[[example]]
name = "compute_dispatch"
path = "examples/compute_dispatch.rs"
[[example]]
name = "render_to_texture"
path = "examples/render_to_texture.rs"
[[example]]
name = "indirect_command_buffer"
path = "examples/indirect_command_buffer.rs"
[[example]]
name = "heap_placement"
path = "examples/heap_placement.rs"
[[example]]
name = "adopted_buffer"
path = "examples/adopted_buffer.rs"
# Not a consumer's example: the host A/B benchmark, the same Metal workloads natively on Metal
# and through the runtime, with a table of the two (examples/host_ab/main.rs).
[[example]]
name = "host_ab"
path = "examples/host_ab/main.rs"
[dependencies]
# The translator, through its public API only: the compiler checks that the runtime
# reaches nothing else. `ash` gives `ash_interop`'s conversions and `DeviceDescription::query`.
metal2vulkan = { version = "0.2.0", path = "../metal2vulkan", features = ["ash"] }
# `ash/loaded` opens the Vulkan loader with `dlopen` when a device is created; nothing is linked at
# build time.
ash = { workspace = true, features = ["std", "loaded"] }
# No-copy buffers take the host's page size on unix; elsewhere they are
# refused typed. It also registers the exit guard's exit handler on unix.
libc.workspace = true
# The shader cache's entry names and the binary archive's keys.
sha2.workspace = true
[dev-dependencies]
serde_json.workspace = true
# `llvm-as` for the device tests' owned fixture (`tests/pipeline_wait_order.rs`).
metal2vulkan-devtools = { path = "../metal2vulkan-devtools" }
# The host A/B benchmark's native side (examples/host_ab): Metal itself, on macOS.
[target.'cfg(target_os = "macos")'.dev-dependencies]
block2 = "0.6"
objc2 = "0.6"
objc2-foundation = "0.3"
objc2-metal = "0.3"
# The device tests compile only under the validation crate's GPU safety cfgs (`tests/mod.rs`).
[lints.rust]
unexpected_cfgs = { level = "warn", check-cfg = ["cfg(m2v_gpu)", "cfg(m2v_cpu_icd)", "cfg(m2v_no_recycle)"] }
[build-dependencies]
sha2.workspace = true