Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Populate by column #1424

Merged
merged 1 commit into from
Mar 30, 2023
Merged

Populate by column #1424

merged 1 commit into from
Mar 30, 2023

Conversation

acquamarin
Copy link
Collaborator

@acquamarin acquamarin commented Mar 29, 2023

This PR refactors the logic of populating inMemColumn while loading a node table. Instead of populating a row at a time, we populate a column at a time.

@acquamarin acquamarin requested a review from ray6080 March 29, 2023 12:52
@codecov
Copy link

codecov bot commented Mar 29, 2023

Codecov Report

Patch coverage: 96.66% and no project coverage change.

Comparison is base (e307fbc) 92.64% compared to head (7e0368c) 92.64%.

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #1424   +/-   ##
=======================================
  Coverage   92.64%   92.64%           
=======================================
  Files         651      650    -1     
  Lines       22557    22544   -13     
=======================================
- Hits        20897    20886   -11     
+ Misses       1660     1658    -2     
Impacted Files Coverage Δ
src/include/storage/store/rels_statistics.h 100.00% <ø> (ø)
src/include/storage/store/table_statistics.h 95.23% <ø> (ø)
src/storage/copier/node_copier.cpp 93.91% <91.30%> (-0.01%) ⬇️
src/include/storage/copier/node_copier.h 100.00% <100.00%> (ø)
src/include/storage/copier/table_copier.h 100.00% <100.00%> (ø)
...e/storage/store/nodes_statistics_and_deleted_ids.h 94.54% <100.00%> (ø)
src/storage/copier/rel_copier.cpp 95.60% <100.00%> (-0.01%) ⬇️
src/storage/copier/table_copier.cpp 82.05% <100.00%> (ø)
src/storage/store/rels_statistics.cpp 100.00% <100.00%> (ø)

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

@ray6080 ray6080 force-pushed the copy-by-column branch 2 times, most recently from 66598b8 to 6be982e Compare March 29, 2023 23:11
CopyDescription& copyDescription, PageByteCursor& overflowCursor) {
for (auto i = 0u; i < numLinesInCurBlock; i++) {
auto nodeOffset = startNodeOffset + i;
auto currentToken = arrowArray->GetScalar(i);
if ((*currentToken)->is_valid) {
auto stringToken = currentToken->get()->ToString();
const char* data = stringToken.c_str();
switch (column->getDataType().typeID) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would move the switch case out of the for loop.

@acquamarin acquamarin merged commit 6675cf1 into master Mar 30, 2023
@acquamarin acquamarin deleted the copy-by-column branch March 30, 2023 06:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants