Skip to content

Commit aedf91c

Browse files
ericyuliufacebook-github-bot
authored andcommitted
fix: Resolve typo in post for simple functions (facebookincubator#11555)
Summary: Pull Request resolved: facebookincubator#11555 Fix: typo in post for simple functions Reviewed By: xiaoxmeng Differential Revision: D63989272 fbshipit-source-id: 7c2f45ccc3a71faf72dc5c361a9dec9877ebbab1
1 parent faf5951 commit aedf91c

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

website/blog/2023-05-01-simple-2.mdx

+2-2
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ The previous representations of input complex types in the simple function inter
2828

2929
The previous approach has two key inefficiencies; **Eager materialization** : For each row, all the data in the input vector is decoded and read before calling the function. And **Double reading**, the data is read twice once when the input is constructed, and again in the function when it's used.
3030

31-
In order to mitigate those regressions, Velox introduced <a href="https://github.com/facebookincubator/velox/blob/main/velox/expression/ComplexViewTypes.h">View types</a>: ArraViews, MapViews ...etc. The goal is to keep the authoring simple but achieve at least the performance of a basic vector implementation that decodes input and applies some logic for every row without any special optimizations.
31+
In order to mitigate those regressions, Velox introduced <a href="https://github.com/facebookincubator/velox/blob/main/velox/expression/ComplexViewTypes.h">View types</a>: ArrayViews, MapViews ...etc. The goal is to keep the authoring simple but achieve at least the performance of a basic vector implementation that decodes input and applies some logic for every row without any special optimizations.
3232

3333
The view types are **Lazy**, very cheap to construct and do not materialize the underlying data unless the code accesses it.For example, the function _array_first_ only needs to read the first element in every array, moreover the _cardinality_ function does not need to read any elements in the array. They view types have interfaces similar to those of std::containers.
3434

@@ -69,7 +69,7 @@ A similar pattern of inefficiency existed for functions with complex output type
6969

7070
We changed the writing path so that the data is written directly into the Velox vector during the function evaluation. By introducing <a href="https://github.com/facebookincubator/velox/blob/main/velox/expression/ComplexWriterTypes.h">writer types</a>: ArrayWriter, MapWriter, RowWriter. This avoids the double materialization and the unnecessary sorting and hashing for maps.
7171

72-
Consider the function below for example that constructs an array [0, n-1).
72+
Consider the function below for example that constructs an array [0, n).
7373

7474
<figure>
7575
<img src="/img/simple1_code1.png"/>

0 commit comments

Comments
 (0)