Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 16 additions & 5 deletions vortex-btrblocks/src/builder.rs
Original file line number Diff line number Diff line change
Expand Up @@ -63,10 +63,12 @@ impl CompressionMode {
excluded.push(binary::ZstdBuffersScheme.id());
}
Self::Cuda => {
// Keep FSST, which has a CUDA decoder and direct Arrow offset-based export. Other
// string fragmentation and dictionary schemes still require unsupported decode
// paths. Delta has a CUDA decode kernel, but stays excluded until GPU delta
// decode is benchmarked against the schemes it would displace.
// Keep FSST, which has a CUDA decoder and direct Arrow offset-based export, and
// string dictionaries, which the CUDA dictionary gather decodes into views over
// the decoded values. Other string fragmentation schemes and binary dictionaries
// still require unsupported decode paths. Delta has a CUDA decode kernel, but
// stays excluded until GPU delta decode is benchmarked against the schemes it
// would displace.
excluded.extend([
integer::DeltaScheme::default().id(),
integer::SparseScheme.id(),
Expand All @@ -76,7 +78,6 @@ impl CompressionMode {
float::NullDominatedSparseScheme.id(),
string::NullDominatedSparseScheme.id(),
fixed_size_list::FixedSizeListSparseScheme.id(),
string::StringDictScheme.id(),
binary::BinaryDictScheme.id(),
]);
// Both binary Zstd schemes are kept. Buffer-level compression preserves binary
Expand Down Expand Up @@ -321,4 +322,14 @@ mod tests {
assert!(has_delta(builder.clone().with_compact()));
assert!(!has_delta(builder.only_cuda_compatible()));
}

#[test]
fn cuda_keeps_string_dictionaries_but_not_binary_ones() {
let cuda = BtrBlocksCompressorBuilder::from_session(&SESSION)
.unrestricted()
.only_cuda_compatible();
let has = |id: SchemeId| cuda.allowed_schemes().iter().any(|s| s.id() == id);
assert!(has(string::StringDictScheme.id()));
assert!(!has(binary::BinaryDictScheme.id()));
}
}
Loading