pub enum Ring0Predicate {
Eq {
column_index: usize,
value: ScalarValue,
},
NotEq {
column_index: usize,
value: ScalarValue,
},
Gt {
column_index: usize,
value: ScalarValue,
},
GtEq {
column_index: usize,
value: ScalarValue,
},
Lt {
column_index: usize,
value: ScalarValue,
},
LtEq {
column_index: usize,
value: ScalarValue,
},
Between {
column_index: usize,
low: ScalarValue,
high: ScalarValue,
},
IsNull {
column_index: usize,
},
IsNotNull {
column_index: usize,
},
In {
column_index: usize,
values: SmallVec<[ScalarValue; 8]>,
},
}Expand description
Ring 0 predicate (must be zero-allocation, < 50ns).
Supports column-level checks that can be evaluated with no heap allocation. Complex expressions (AND/OR, multi-column, UDFs) are deferred to Ring 1.
Variants§
Eq
Column equals a constant value: column = value
Fields
value: ScalarValueThe constant value to compare against.
NotEq
Column not equal: column != value / column <> value
Fields
value: ScalarValueThe constant value to compare against.
Gt
Column greater than: column > value
Fields
value: ScalarValueThe constant value to compare against.
GtEq
Column greater than or equal: column >= value
Fields
value: ScalarValueThe constant value to compare against.
Lt
Column less than: column < value
Fields
value: ScalarValueThe constant value to compare against.
LtEq
Column less than or equal: column <= value
Fields
value: ScalarValueThe constant value to compare against.
Between
Column is between two values (inclusive): column BETWEEN low AND high
IsNull
Column is null: column IS NULL
IsNotNull
Column is not null: column IS NOT NULL
In
Column value is in a set: column IN (v1, v2, ...)
Limited to 8 values to stay on the stack via SmallVec.
Implementations§
Source§impl Ring0Predicate
impl Ring0Predicate
Sourcepub fn evaluate(
&self,
batch: &RecordBatch,
row: usize,
intern: &StringInternTable,
) -> bool
pub fn evaluate( &self, batch: &RecordBatch, row: usize, intern: &StringInternTable, ) -> bool
Evaluates the predicate against a single row in a RecordBatch.
Returns true if the row matches the predicate.
This runs on the Ring 0 hot path.
Trait Implementations§
Source§impl Clone for Ring0Predicate
impl Clone for Ring0Predicate
Source§fn clone(&self) -> Ring0Predicate
fn clone(&self) -> Ring0Predicate
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreAuto Trait Implementations§
impl Freeze for Ring0Predicate
impl RefUnwindSafe for Ring0Predicate
impl Send for Ring0Predicate
impl Sync for Ring0Predicate
impl Unpin for Ring0Predicate
impl UnwindSafe for Ring0Predicate
Blanket Implementations§
Source§impl<T> ArchivePointee for T
impl<T> ArchivePointee for T
Source§type ArchivedMetadata = ()
type ArchivedMetadata = ()
Source§fn pointer_metadata(
_: &<T as ArchivePointee>::ArchivedMetadata,
) -> <T as Pointee>::Metadata
fn pointer_metadata( _: &<T as ArchivePointee>::ArchivedMetadata, ) -> <T as Pointee>::Metadata
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§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> LayoutRaw for T
impl<T> LayoutRaw for T
Source§fn layout_raw(_: <T as Pointee>::Metadata) -> Result<Layout, LayoutError>
fn layout_raw(_: <T as Pointee>::Metadata) -> Result<Layout, LayoutError>
Source§impl<T, N1, N2> Niching<NichedOption<T, N1>> for N2
impl<T, N1, N2> Niching<NichedOption<T, N1>> for N2
Source§unsafe fn is_niched(niched: *const NichedOption<T, N1>) -> bool
unsafe fn is_niched(niched: *const NichedOption<T, N1>) -> bool
Source§fn resolve_niched(out: Place<NichedOption<T, N1>>)
fn resolve_niched(out: Place<NichedOption<T, N1>>)
out indicating that a T is niched.