Skip to main content

ptx_parser/type/instruction/
isspacep.rs

1//! Original PTX specification:
2//!
3//! isspacep.space  p, a;    // result is .pred
4//! .space = { .const, .global, .local, .shared, .shared::cta, .shared::cluster, .param, .param::entry };
5
6#![allow(unused)]
7use crate::r#type::common::*;
8
9pub mod section_0 {
10    use crate::Spanned;
11    use crate::parser::Span;
12    use crate::r#type::common::*;
13
14    use serde::Serialize;
15
16    #[derive(Debug, Clone, PartialEq, Serialize)]
17    pub enum Space {
18        SharedCluster, // .shared::cluster
19        ParamEntry,    // .param::entry
20        SharedCta,     // .shared::cta
21        Global,        // .global
22        Shared,        // .shared
23        Const,         // .const
24        Local,         // .local
25        Param,         // .param
26    }
27
28    #[derive(Debug, Clone, PartialEq, Spanned, Serialize)]
29    pub struct IsspacepSpace {
30        pub space: Space,      // .space
31        pub p: GeneralOperand, // p
32        pub a: GeneralOperand, // a
33        pub span: Span,
34    }
35}
36
37// Re-export types with section suffixes to avoid naming conflicts
38// e.g., Type0 for section_0::Type, Type1 for section_1::Type
39pub use section_0::IsspacepSpace;
40pub use section_0::Space as Space0;