File tree Expand file tree Collapse file tree
vortex-btrblocks/src/schemes Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -35,7 +35,7 @@ use vortex_array::session::ArraySessionExt;
3535use vortex_session:: VortexSession ;
3636
3737/// Check if we're using experimental patches deserialization
38- static USE_EXPERIMENTAL_PATCHES : LazyLock < bool > =
38+ pub static USE_EXPERIMENTAL_PATCHES : LazyLock < bool > =
3939 LazyLock :: new ( || env:: var ( "VORTEX_EXPERIMENTAL_PATCHED_ARRAY" ) . is_ok ( ) ) ;
4040
4141/// Initialize fastlanes encodings in the given session.
Original file line number Diff line number Diff line change 33
44//! Integer compression schemes.
55
6- use std:: env;
7- use std:: sync:: LazyLock ;
8-
96use vortex_array:: ArrayRef ;
107use vortex_array:: Canonical ;
118use vortex_array:: IntoArray ;
@@ -29,6 +26,7 @@ use vortex_error::vortex_err;
2926use vortex_fastlanes:: BitPacked ;
3027use vortex_fastlanes:: FoR ;
3128use vortex_fastlanes:: FoRArrayExt ;
29+ use vortex_fastlanes:: USE_EXPERIMENTAL_PATCHES ;
3230use vortex_fastlanes:: bitpack_compress:: bit_width_histogram;
3331use vortex_fastlanes:: bitpack_compress:: bitpack_encode;
3432use vortex_fastlanes:: bitpack_compress:: find_best_bit_width;
@@ -285,10 +283,6 @@ impl Scheme for ZigZagScheme {
285283 }
286284}
287285
288- // replicated from vortex-file
289- static USE_EXPERIMENTAL_PATCHES : LazyLock < bool > =
290- LazyLock :: new ( || env:: var ( "VORTEX_EXPERIMENTAL_PATCHED_ARRAY" ) . is_ok ( ) ) ;
291-
292286impl Scheme for BitPackingScheme {
293287 fn scheme_name ( & self ) -> & ' static str {
294288 "vortex.int.bitpacking"
Original file line number Diff line number Diff line change @@ -21,6 +21,7 @@ use vortex_array::arrays::List;
2121use vortex_array:: arrays:: ListView ;
2222use vortex_array:: arrays:: Masked ;
2323use vortex_array:: arrays:: Null ;
24+ use vortex_array:: arrays:: Patched ;
2425use vortex_array:: arrays:: Primitive ;
2526use vortex_array:: arrays:: Struct ;
2627use vortex_array:: arrays:: VarBin ;
@@ -90,6 +91,10 @@ pub static ALLOWED_ENCODINGS: LazyLock<HashSet<ArrayId>> = LazyLock::new(|| {
9091 allowed. insert ( Masked . id ( ) ) ;
9192 allowed. insert ( Dict . id ( ) ) ;
9293
94+ if * vortex_fastlanes:: USE_EXPERIMENTAL_PATCHES {
95+ allowed. insert ( Patched . id ( ) ) ;
96+ }
97+
9398 // Compressed encodings from encoding crates
9499 allowed. insert ( ALP . id ( ) ) ;
95100 allowed. insert ( ALPRD . id ( ) ) ;
You can’t perform that action at this time.
0 commit comments