Struct melior::dialect::ods::sparse_tensor::OutOperation
source · pub struct OutOperation<'c> { /* private fields */ }
Expand description
An out
operation. Outputs a sparse tensor to the given destination.
Outputs the contents of a sparse tensor to the destination defined by an
opaque pointer provided by dest
. For targets that have access to a file
system, for example, this pointer may specify a filename (or file) for output.
The form of the operation is kept deliberately very general to allow for
alternative implementations in the future, such as sending the contents to
a buffer defined by a pointer.
Note that this operation is “impure” in the sense that its behavior is solely defined by side-effects and not SSA values.
Example:
sparse_tensor.out %t, %dest : tensor<1024x1024xf64, #CSR>, !Dest
Implementations§
source§impl<'c> OutOperation<'c>
impl<'c> OutOperation<'c>
sourcepub fn as_operation(&self) -> &Operation<'c>
pub fn as_operation(&self) -> &Operation<'c>
Returns a generic operation.
sourcepub fn builder(
context: &'c Context,
location: Location<'c>
) -> OutOperationBuilder<'c, Unset, Unset>
pub fn builder( context: &'c Context, location: Location<'c> ) -> OutOperationBuilder<'c, Unset, Unset>
Creates a builder.
pub fn tensor(&self) -> Result<Value<'c, '_>, Error>
pub fn dest(&self) -> Result<Value<'c, '_>, Error>
Trait Implementations§
source§impl<'c> From<OutOperation<'c>> for Operation<'c>
impl<'c> From<OutOperation<'c>> for Operation<'c>
source§fn from(operation: OutOperation<'c>) -> Self
fn from(operation: OutOperation<'c>) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl<'c> RefUnwindSafe for OutOperation<'c>
impl<'c> !Send for OutOperation<'c>
impl<'c> !Sync for OutOperation<'c>
impl<'c> Unpin for OutOperation<'c>
impl<'c> UnwindSafe for OutOperation<'c>
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