pub struct TinyXgcfDevice {
pub num_nodes: usize,
pub num_vars: usize,
pub root: u32,
/* private fields */
}Expand description
Device-resident XGCF circuit + reusable buffers.
This is used by certification categories that validate transfer efficiency and circuit reuse. The key property: circuit structure is uploaded once; repeated evaluations reuse device buffers.
Fields§
§num_nodes: usize§num_vars: usize§root: u32Implementations§
Source§impl TinyXgcfDevice
impl TinyXgcfDevice
pub fn upload(ctx: &TestContext, spec: &TinyXgcfSpec) -> Result<Self>
pub fn set_weights( &mut self, ctx: &TestContext, log_true: &[f64], log_false: &[f64], ) -> Result<()>
Sourcepub fn forward_launch(&mut self, _ctx: &TestContext) -> Result<()>
pub fn forward_launch(&mut self, _ctx: &TestContext) -> Result<()>
Launch forward kernels (no sync, no host transfers).
pub fn forward_download_values(&mut self, ctx: &TestContext) -> Result<Vec<f64>>
pub fn forward_download_root(&mut self, ctx: &TestContext) -> Result<f64>
Sourcepub fn backward_only_launch(&mut self, ctx: &TestContext) -> Result<()>
pub fn backward_only_launch(&mut self, ctx: &TestContext) -> Result<()>
Launch backward kernels using existing d_values (no sync, no host transfers).
Sourcepub fn forward_then_backward_launch(&mut self, ctx: &TestContext) -> Result<()>
pub fn forward_then_backward_launch(&mut self, ctx: &TestContext) -> Result<()>
Convenience helper: forward + backward in one launch sequence (no sync, no host transfers).
Auto Trait Implementations§
impl Freeze for TinyXgcfDevice
impl RefUnwindSafe for TinyXgcfDevice
impl !Send for TinyXgcfDevice
impl !Sync for TinyXgcfDevice
impl Unpin for TinyXgcfDevice
impl UnsafeUnpin for TinyXgcfDevice
impl UnwindSafe for TinyXgcfDevice
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more