From 8724ef75281d2011a5a7603d21bbd72840c7264b Mon Sep 17 00:00:00 2001 From: Weston Pace Date: Fri, 17 Oct 2025 10:46:51 -0700 Subject: [PATCH] Clarify the encoding of the fp16 substrait literal --- format/substrait/extension_types.yaml | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/format/substrait/extension_types.yaml b/format/substrait/extension_types.yaml index 0073da1acc1..febcfaf5a3e 100644 --- a/format/substrait/extension_types.yaml +++ b/format/substrait/extension_types.yaml @@ -107,8 +107,11 @@ types: - name: u64 structure: {} # fp16 literals are encoded as user defined literals with - # a google.protobuf.UInt32Value message where the lower 16 bits are - # the fp16 value. + # a google.protobuf.UInt32Value message where the least significant + # 16 bits are the fp16 value encoded with little-endian encoding. + # + # In other words, the least significant 8 bits of the u32 will contain + # the most significant 8 bits of the fp16 value. - name: fp16 structure: {} # 64-bit integers are big. Even though date64 stores ms and not days it