pub struct ProfilingBackend { /* private fields */ }Expand description
Profiling backend for ZKBoo circuits.
Implementations§
Source§impl ProfilingBackend
impl ProfilingBackend
Sourcepub fn into_profiler(self) -> Frontend<Self>
pub fn into_profiler(self) -> Frontend<Self>
Wraps this profiling backend into a Frontend.
Alias of Backend::into_frontend.
Trait Implementations§
Source§impl Backend for ProfilingBackend
impl Backend for ProfilingBackend
Source§type FinalizeArg = ()
type FinalizeArg = ()
Type for data to be passed to the backend finalizer.
Source§type FinalizeResult = ProfilingData
type FinalizeResult = ProfilingData
Type for the finalization result of the backend.
Source§fn finalize(self, _arg: Self::FinalizeArg) -> Self::FinalizeResult
fn finalize(self, _arg: Self::FinalizeArg) -> Self::FinalizeResult
Finalizes the backend, returning a finalization result.
Source§fn input<W: Word, const N: usize>(
&mut self,
_word: CompositeWord<W, N>,
) -> WordIdx<W, N>
fn input<W: Word, const N: usize>( &mut self, _word: CompositeWord<W, N>, ) -> WordIdx<W, N>
Allocates an input word in the backend, returning the allocated index. Read more
Source§fn alloc<W: Word, const N: usize>(&mut self) -> WordIdx<W, N>
fn alloc<W: Word, const N: usize>(&mut self) -> WordIdx<W, N>
Allocates a word in the backend, returning the allocated index.
⚠️ Warning: the word value is uninitialised.
Source§fn constant<W: Word, const N: usize>(
&mut self,
_word: CompositeWord<W, N>,
_out: WordIdx<W, N>,
)
fn constant<W: Word, const N: usize>( &mut self, _word: CompositeWord<W, N>, _out: WordIdx<W, N>, )
Writes a constant word to the given index.
Source§fn from_le_words<W: Word, const N: usize>(
&mut self,
_ins: [WordIdx<W, 1>; N],
_out: WordIdx<W, N>,
)
fn from_le_words<W: Word, const N: usize>( &mut self, _ins: [WordIdx<W, 1>; N], _out: WordIdx<W, N>, )
Packs a little-endian array of machine words into a single composite word,
storing the result at the given output index.
Source§fn to_le_words<W: Word, const N: usize>(
&mut self,
_in_: WordIdx<W, N>,
_outs: [WordIdx<W, 1>; N],
)
fn to_le_words<W: Word, const N: usize>( &mut self, _in_: WordIdx<W, N>, _outs: [WordIdx<W, 1>; N], )
Unpacks a composite word into a little-endian array of machine words,
storing the result at the given output indices.
Source§fn output<W: Word, const N: usize>(&mut self, _out: WordIdx<W, N>)
fn output<W: Word, const N: usize>(&mut self, _out: WordIdx<W, N>)
Pushes the given word onto the outputs.
Source§fn increase_refcount<W: Word, const N: usize>(&mut self, idx: WordIdx<W, N>)
fn increase_refcount<W: Word, const N: usize>(&mut self, idx: WordIdx<W, N>)
Increases the reference count of the word at the given index.
The token parameter restricts this method from external use.
Source§fn decrease_refcount<W: Word, const N: usize>(&mut self, idx: WordIdx<W, N>)
fn decrease_refcount<W: Word, const N: usize>(&mut self, idx: WordIdx<W, N>)
Decreases the reference count of the word at the given index.
The token parameter restricts this method from external use.
Source§fn not<W: Word, const N: usize>(
&mut self,
_in_: WordIdx<W, N>,
_out: WordIdx<W, N>,
)
fn not<W: Word, const N: usize>( &mut self, _in_: WordIdx<W, N>, _out: WordIdx<W, N>, )
Performs a bitwise NOT operation on the word at the given input index,
storing the result at the given output index.
Source§fn bitxor<W: Word, const N: usize>(
&mut self,
_inl: WordIdx<W, N>,
_inr: WordIdx<W, N>,
_out: WordIdx<W, N>,
)
fn bitxor<W: Word, const N: usize>( &mut self, _inl: WordIdx<W, N>, _inr: WordIdx<W, N>, _out: WordIdx<W, N>, )
Performs a bitwise XOR operation on the words at the given input indices,
storing the result at the given output index.
Source§fn bitand<W: Word, const N: usize>(
&mut self,
_inl: WordIdx<W, N>,
_inr: WordIdx<W, N>,
_out: WordIdx<W, N>,
)
fn bitand<W: Word, const N: usize>( &mut self, _inl: WordIdx<W, N>, _inr: WordIdx<W, N>, _out: WordIdx<W, N>, )
Performs a bitwise AND operation on the words at the given input indices,
storing the result at the given output index.
Source§fn bitxor_const<W: Word, const N: usize>(
&mut self,
_inl: WordIdx<W, N>,
_inr: CompositeWord<W, N>,
_out: WordIdx<W, N>,
)
fn bitxor_const<W: Word, const N: usize>( &mut self, _inl: WordIdx<W, N>, _inr: CompositeWord<W, N>, _out: WordIdx<W, N>, )
Performs a bitwise XOR operation on the word at the given input index with given constant,
storing the result at the given output index.
Source§fn bitand_const<W: Word, const N: usize>(
&mut self,
_inl: WordIdx<W, N>,
_inr: CompositeWord<W, N>,
_out: WordIdx<W, N>,
)
fn bitand_const<W: Word, const N: usize>( &mut self, _inl: WordIdx<W, N>, _inr: CompositeWord<W, N>, _out: WordIdx<W, N>, )
Performs a bitwise AND operation on the word at the given input index with given constant,
storing the result at the given output index.
Source§fn unbounded_shl<W: Word, const N: usize>(
&mut self,
_in_: WordIdx<W, N>,
_shift: usize,
_out: WordIdx<W, N>,
)
fn unbounded_shl<W: Word, const N: usize>( &mut self, _in_: WordIdx<W, N>, _shift: usize, _out: WordIdx<W, N>, )
Performs a left shift operation on the word at the given input index,
storing the result at the given output index.
Source§fn unbounded_shr<W: Word, const N: usize>(
&mut self,
_in_: WordIdx<W, N>,
_shift: usize,
_out: WordIdx<W, N>,
)
fn unbounded_shr<W: Word, const N: usize>( &mut self, _in_: WordIdx<W, N>, _shift: usize, _out: WordIdx<W, N>, )
Performs a right shift operation on the word at the given input index,
storing the result at the given output index.
Source§fn rotate_left<W: Word, const N: usize>(
&mut self,
_in_: WordIdx<W, N>,
_shift: usize,
_out: WordIdx<W, N>,
)
fn rotate_left<W: Word, const N: usize>( &mut self, _in_: WordIdx<W, N>, _shift: usize, _out: WordIdx<W, N>, )
Performs a left rotate operation on the word at the given input index,
storing the result at the given output index.
Source§fn rotate_right<W: Word, const N: usize>(
&mut self,
_in_: WordIdx<W, N>,
_shift: usize,
_out: WordIdx<W, N>,
)
fn rotate_right<W: Word, const N: usize>( &mut self, _in_: WordIdx<W, N>, _shift: usize, _out: WordIdx<W, N>, )
Performs a right rotate operation on the word at the given input index,
storing the result at the given output index.
Source§fn reverse_bits<W: Word, const N: usize>(
&mut self,
_in_: WordIdx<W, N>,
_out: WordIdx<W, N>,
)
fn reverse_bits<W: Word, const N: usize>( &mut self, _in_: WordIdx<W, N>, _out: WordIdx<W, N>, )
Performs a bit-reversal operation on the word at the given input index,
storing the result at the given output index.
Source§fn swap_bytes<W: Word, const N: usize>(
&mut self,
_in_: WordIdx<W, N>,
_out: WordIdx<W, N>,
)
fn swap_bytes<W: Word, const N: usize>( &mut self, _in_: WordIdx<W, N>, _out: WordIdx<W, N>, )
Performs a byte-reversal operation on the word at the given input index,
storing the result at the given output index.
Source§fn cast<W: Word, T: Word>(&mut self, _in_: WordIdx<W, 1>, _out: WordIdx<T, 1>)
fn cast<W: Word, T: Word>(&mut self, _in_: WordIdx<W, 1>, _out: WordIdx<T, 1>)
Casts the word at the given input index to another word type,
storing the result at the given output index.
Source§fn carry<W: Word, const N: usize>(
&mut self,
_p: WordIdx<W, N>,
_g: WordIdx<W, N>,
_carry_in: bool,
_out: WordIdx<W, N>,
)
fn carry<W: Word, const N: usize>( &mut self, _p: WordIdx<W, N>, _g: WordIdx<W, N>, _carry_in: bool, _out: WordIdx<W, N>, )
Computes the carry bits from the given propagate and generate words,
storing the result at the given output index. Read more
Source§fn into_frontend(self) -> Frontend<Self>
fn into_frontend(self) -> Frontend<Self>
Wraps this backend into a Frontend.
Source§fn alloc_constant<W, const N: usize>(
&mut self,
word: CompositeWord<W, N>,
) -> WordIdx<W, N>where
W: Word,
fn alloc_constant<W, const N: usize>(
&mut self,
word: CompositeWord<W, N>,
) -> WordIdx<W, N>where
W: Word,
Allocates a constant work in the backend, returning the allocated index.
Auto Trait Implementations§
impl Freeze for ProfilingBackend
impl RefUnwindSafe for ProfilingBackend
impl Send for ProfilingBackend
impl Sync for ProfilingBackend
impl Unpin for ProfilingBackend
impl UnsafeUnpin for ProfilingBackend
impl UnwindSafe for ProfilingBackend
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