Skip to content

Commit 5148199

Browse files
committed
Mention columnation
1 parent 97b45ff commit 5148199

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

doc/developer/design/20230110_window_functions.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,7 @@ Also, we will want to entirely transform away certain window function patterns;
145145
146146
### Prefix Sum
147147
148-
This section defines prefix sum, then discusses various properties/caveats/limitations of DD's prefix sum implementation from the caller's point of view, and then discusses the implementation itself.
148+
This section defines prefix sum, then discusses various properties/caveats/limitations of DD's prefix sum implementation from the caller's point of view, and then discusses the implementation itself. The implementation will need to be generalized and extended in various ways, therefore we'll copy it into the Materialize codebase, and make improvements there.
149149
150150
#### Definition
151151
@@ -181,6 +181,8 @@ We’ll use the word **index** in this document to mean the values of the ORDER
181181
182182
As mentioned above, DD's prefix sum needs the index type to be `usize`. It is actually a fundamental limitation of the algorithm that it only works with integer indexes, and therefore we will have to map other types to integers. We discuss this in the ["ORDER BY types" section](#order-by-types).
183183
184+
A technical detail is that we will need to [control the container types of prefix sum's internal arrangements](https://github.com/MaterializeInc/materialize/issues/16549) to make them columnation-backed. We should check every DD operator call in prefix sum when copying over the prefix sum code from DD to the Materialize codebase.
185+
184186
#### Implementation details of DD's prefix sum
185187
186188
(The reader might skip this section on a first read, and refer back to it later when delving into performance considerations, or extensions/generalizations of prefix sum needed for framed window functions and LAG/LEAD with an offset >1.)

0 commit comments

Comments
 (0)