Skip to content

Commit 49a9dae

Browse files
authored
chore(dataset/array): Add Bitpacked encoding (#21807)
1 parent a78c390 commit 49a9dae

7 files changed

Lines changed: 1004 additions & 13 deletions

File tree

pkg/dataset/array/codec.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,8 @@ func NewWriter(alloc *memory.Allocator, spec Spec, typ types.Type) (Writer, erro
4545
return newPlainWriter(alloc, spec, typ)
4646
case EncodingKindBinary:
4747
return newBinaryWriter(alloc, spec, typ)
48+
case EncodingKindBitpacked:
49+
return newBitpackedWriter(alloc, spec, typ)
4850

4951
default:
5052
return nil, fmt.Errorf("unsupported encoding kind %q", spec.Kind())
@@ -95,6 +97,8 @@ func NewReader(alloc *memory.Allocator, arr Array, source buffer.Source) (Reader
9597
return newPlainReader(alloc, arr, source)
9698
case EncodingKindBinary:
9799
return newBinaryReader(alloc, arr, source)
100+
case EncodingKindBitpacked:
101+
return newBitpackedReader(alloc, arr, source)
98102

99103
default:
100104
return nil, fmt.Errorf("unsupported encoding kind %q", arr.Encoding.Kind())

0 commit comments

Comments
 (0)