Struct EncodingGroup
pub struct EncodingGroup {
pub encodings_per_arch: Vec<Vec<EncodingId>>,
}
Expand description
For each architecture, a group of overlapping encodings.
Fields§
§encodings_per_arch: Vec<Vec<EncodingId>>
The encodings per architecture.
Implementations§
§impl EncodingGroup
impl EncodingGroup
pub fn compute_from_arches<A: Arch, C: Computation + Send + Sync>(
encodings: &IndexedEncodings<A, C>,
arches: Vec<Vec<EncodingId>>,
) -> Vec<EncodingGroup>
pub fn compute_from_arches<A: Arch, C: Computation + Send + Sync>( encodings: &IndexedEncodings<A, C>, arches: Vec<Vec<EncodingId>>, ) -> Vec<EncodingGroup>
Computes a set of EncodingGroup
s that cover all encodings provided in arches
.
pub fn num_encodings(&self) -> usize
pub fn num_encodings(&self) -> usize
The total number of encodings in the group, accross all architectures.
pub fn all_identical_bitpatterns<A: Arch, C: Computation>(
&self,
encodings: &IndexedEncodings<A, C>,
) -> bool
pub fn all_identical_bitpatterns<A: Arch, C: Computation>( &self, encodings: &IndexedEncodings<A, C>, ) -> bool
Checks whether the bitpatterns for the encodings are equivalent between all groups.
pub fn byte_len<A: Arch, C: Computation>(
&self,
encodings: &IndexedEncodings<A, C>,
) -> usize
pub fn byte_len<A: Arch, C: Computation>( &self, encodings: &IndexedEncodings<A, C>, ) -> usize
Returns the byte length of the instructions in this group.
pub fn only_matching<A: Arch, C: Computation>(
&self,
encodings: &IndexedEncodings<A, C>,
filter: &InstructionFilter,
) -> EncodingGroup
pub fn only_matching<A: Arch, C: Computation>( &self, encodings: &IndexedEncodings<A, C>, filter: &InstructionFilter, ) -> EncodingGroup
Filters the encodings by filter
and only returns encodings for which match filter
at least partially.
pub fn compare<A: Arch>(
&self,
encodings: &IndexedEncodings<A, SynthesizedComputation>,
filter: &InstructionFilter,
solver: &impl SolverProvider,
) -> ComparisonMatrix
pub fn compare<A: Arch>( &self, encodings: &IndexedEncodings<A, SynthesizedComputation>, filter: &InstructionFilter, solver: &impl SolverProvider, ) -> ComparisonMatrix
Compares the encodings in the groups and builds a ComparisonMatrix
with the comparison results.
pub fn split_exact<A: Arch, C: Computation>(
&self,
encodings: &IndexedEncodings<A, C>,
) -> Vec<(EncodingGroup, InstructionFilter)>
pub fn split_exact<A: Arch, C: Computation>( &self, encodings: &IndexedEncodings<A, C>, ) -> Vec<(EncodingGroup, InstructionFilter)>
Splits the group into exact, non-overlapping, subgroups.
pub fn has_encodings_overlapping_filter<A: Arch>(
&self,
encodings: &IndexedEncodings<A, SynthesizedComputation>,
restrict: &InstructionFilter,
) -> bool
pub fn has_encodings_overlapping_filter<A: Arch>( &self, encodings: &IndexedEncodings<A, SynthesizedComputation>, restrict: &InstructionFilter, ) -> bool
Checks whether any encodings overlap the filter restrict
.
pub fn all_encodings_have_computations<A: Arch, C: Computation>(
&self,
encodings: &IndexedEncodings<A, C>,
) -> bool
pub fn all_encodings_have_computations<A: Arch, C: Computation>( &self, encodings: &IndexedEncodings<A, C>, ) -> bool
Checks whether all encodings for all architectures have successfully synthesized computations.
Trait Implementations§
§impl Clone for EncodingGroup
impl Clone for EncodingGroup
§fn clone(&self) -> EncodingGroup
fn clone(&self) -> EncodingGroup
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more§impl Debug for EncodingGroup
impl Debug for EncodingGroup
§impl<'de> Deserialize<'de> for EncodingGroup
impl<'de> Deserialize<'de> for EncodingGroup
§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
§impl Serialize for EncodingGroup
impl Serialize for EncodingGroup
Auto Trait Implementations§
impl Freeze for EncodingGroup
impl RefUnwindSafe for EncodingGroup
impl Send for EncodingGroup
impl Sync for EncodingGroup
impl Unpin for EncodingGroup
impl UnwindSafe for EncodingGroup
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
clone_to_uninit
)§impl<T> Identity for Twhere
T: ?Sized,
impl<T> Identity for Twhere
T: ?Sized,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more