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
//! GPU comment-strip mask for C source.
//!
//! Phase 17b.5: per-byte mask `0 = code, 1 = drop comment byte,
//! 2 = C-required replacement space`. Composes
//! with `gpu_line_splice_classify` (multiply masks element-wise) and
//! `stream_compact` to produce a comment-and-splice-free byte stream
//! before lexing.
//!
//! ## GPU formulation
//!
//! Comment state is sequential by nature: a `/*` opens until the next
//! `*/`; a `//` opens until the next `\n`. Pure parallel formulations
//! exist (segmented scans, balanced-paren style) but each adds enough
//! complexity and register pressure. The shipped kernel uses exactly
//! one GPU lane per dispatch, byte-at-a-time, so production code stays
//! GPU-resident without launching idle helper lanes or routing comment
//! semantics through a CPU helper.
//!
//! ## Wire layout
//!
//! Inputs:
//! - `bytes_in` - compatibility [`gpu_comment_strip_mask`] expects
//! packed little-endian `DataType::U32` words, four source bytes per
//! word. [`gpu_comment_strip_mask_u8`] expects one `DataType::U8`
//! element per source byte.
//!
//! Outputs:
//! - `comment_mask_out` (U32) - one entry per byte. `0` for ordinary
//! source, `1` for comment bytes to drop, `2` for the first comment
//! byte that must materialize as one replacement space.
use ;
pub use ;
pub use ;
pub use reference_gpu_comment_strip_mask;