Repository navigation
docs(cuda-device): the re-export table lists 10 of the 13 macros re-exported - #1056
Merged
nihalpasham merged 2 commits intoAug 20, 2026
Merged
Conversation
…xported
`src/lib.rs` re-exports thirteen macros from `cuda-macros`:
pub use cuda_macros::{
cluster_launch, constant, convergent, cooperative_launch, cuda_module,
device, gpu_printf, kernel, launch_bounds, launch_contract, ptx_asm,
pure, readonly,
};
The README's "Proc-Macro Re-exports" table lists ten of them. Missing are
`#[cuda_module]`, `#[launch_contract]` and `#[constant]` -- which is to say,
the entry point for typed module loading, the attribute that unlocks a safe
launch, and the one that puts a static in constant memory. Not obscure corners:
this same README already relies on `#[launch_contract(domain = 1, ...)]` in its
`DisjointSlice` section and documents the `constant` module in its module
table, so the crate's own README uses two of the three it does not list.
Add the three rows, and tie the table's lead-in to the `pub use` list it
mirrors so the next macro added there has an obvious place to land.
Descriptions are taken verbatim from the book's API quick reference, which
already carries all three, so the two documents now say the same thing rather
than two things.
Verified: the thirteen names in the `pub use` and the thirteen backticked rows
in the table are the same set, with nothing in the table that is not
re-exported.
Signed-off-by: Vyncint Ng <[email protected]>
Collaborator
|
nihalpasham
approved these changes
Aug 20, 2026
nihalpasham
added a commit
that referenced
this pull request
Aug 21, 2026
* docs(ptx-schedule): the one published crate with no README `ptx-schedule` arrived with #1065 and is the only publishable crate in the workspace with neither a `readme` key nor a README.md on disk. Checked across `cargo metadata`: every other publishable member has both. crates.io renders that file as the package page, so this one would publish with an empty body. This is the same gap #981 closed for `ptx-parse`, and the README follows that one's shape. Content is taken from the crate rather than from the commit that added it: - The purpose and the "owns neither CUDA execution nor an input generator" boundary come from `lib.rs`'s module header. - The seven `SiteKind` variants and the eight campaign `RunKind` verdicts are each enumerated in full, since a partial list of a closed enum is the thing that rots (#978, #1045, #1056). - `InjectionOptions`' four fields, `DEFAULT_MAX_SLEEP_NS` (64 µs), the `nanosleep.u32` insertion, and the `confirm_runs` re-run before a finding is reported are all as implemented. - `cargo oxide fuzz-schedule` is named as the user-facing entry point, with the crate's own binary shown for single-file work; the flags in the example come from `main.rs`'s usage string. One detail carried over from #981's review: the License link is absolute rather than `../../LICENSE`, because crates.io rewrites relative README links against the repository root and the relative form 404s there. Verified: `cargo metadata` now reports `readme: README.md` for the crate and the file resolves; all seven `SiteKind` and eight `RunKind` names appear; `check-crate-inventory.sh`, `check-spdx-headers.sh` and `check-book-api-names.sh` pass; no relative `../` links remain. Signed-off-by: Vyncint Ng <[email protected]> * docs(ptx-schedule): align the README with the code it describes Six statements did not match the crate as it stands: - the execution disclaimer claimed the whole crate owns no CUDA execution while campaign.rs two sections down builds, launches, watchdogs and assigns verdicts; the section now scopes the claim to analyze_ptx/perturb_ptx and points at the campaign layer; - intensity is a probability dial (0.75 x intensity per site, and it scales the drawn sleep lengths), not a fraction of sites touched; - focus re-weights selection by substring over each site's opcode and instruction text (0.95x hits, 0.15x misses); it never restricts the sweep to one callable; - Skipped is assigned only when the example prints a skip marker; a zero-injection seed still runs and reports like the baseline; - findings are reported with their confirmation counts attached, not gated on confirmation; - a seed pins the rewrite, not the schedule the GPU then picks. Smaller table fixes from the same read of classify_instruction: the Barrier row now names mbarrier.*, OrderedMemory names the ordering qualifiers it actually matches (a scope alone never classifies), the Backedge row describes the conservative same-or-earlier-block test (no dominance is computed), and the block-index field is called out as back-edge-only. The injection knobs move into a bulleted list so each one can state its own semantics. --------- Signed-off-by: Vyncint Ng <[email protected]> Co-authored-by: nihalpasham <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
src/lib.rsre-exports thirteen macros fromcuda-macros:The README's "Proc-Macro Re-exports" table lists ten. Missing are
#[cuda_module],#[launch_contract]and#[constant]— the entry point for typed module loading, the attribute that unlocks a safe launch, and the one that puts a static in constant memory.Not obscure corners: this same README already relies on two of the three. Its
DisjointSlicesection uses#[launch_contract(domain = 1, ...)]in prose, and its module table documents theconstantmodule. So the crate's own README uses macros it does not list.Add the three rows, and tie the table's lead-in to the
pub uselist it mirrors so the next macro added there has an obvious place to land.Descriptions are taken verbatim from the book's API quick reference, which already carries all three — so the two documents now say the same thing rather than two things.
Verified: the thirteen names in the
pub useand the thirteen backticked rows in the table are the same set, with nothing in the table that is not re-exported.