Skip to content

dt_na: hoist COMPLEX_RO() out of the loop - #7930

Merged
ben-schwen merged 2 commits into
masterfrom
frank-hoist-complex-ro
Nov 15, 2026
Merged

ben-schwen merged 2 commits into
masterfrom
frank-hoist-complex-ro

Conversation

@m-muecke

Copy link
Copy Markdown
Contributor

follows the rest of the file, about 1.5x faster

@codecov

codecov Bot commented Oct 20, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 99.08%. Comparing base (f0de60b) to head (378c87c).
⚠️ Report is 1 commits behind head on master.

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #7930   +/-   ##
=======================================
  Coverage   99.08%   99.08%           
=======================================
  Files          88       88           
  Lines       17428    17429    +1     
=======================================
+ Hits        17269    17270    +1     
  Misses        159      159           

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@ben-schwen

Copy link
Copy Markdown
Member

Basically yes, but can we write a linter or coccinelle for this, so we avoid this construct in the future?

@m-muecke

m-muecke commented Oct 21, 2026 •

Copy link
Copy Markdown
Contributor Author

Not a problem, but I don't believe it can be auto-fixed. Should this be a follow-up PR, since the linter rule would flag 117 cases across 12 files, and most of them aren't hot paths.

@aitap

aitap commented Oct 21, 2026 via email

Copy link
Copy Markdown
Member

@MichaelChirico

Copy link
Copy Markdown
Member

most of them aren't hot paths.

IIUC the change is not bad to make on "slow paths", just that the benefit is small. In that case, I would still make the changes in one clean-up and then guard with a linter -- it's good to be in the habit of making the right choice.

@ben-schwen
ben-schwen merged commit b7a12d8 into master Nov 15, 2026
8 checks passed
@ben-schwen
ben-schwen deleted the frank-hoist-complex-ro branch November 15, 2026 18:27
@github-actions

Copy link
Copy Markdown
  • HEAD=frank-hoist-complex-ro much faster for as.data.table.array improved in #7019
  • HEAD=frank-hoist-complex-ro much faster for transform improved in #5493
  • HEAD=frank-hoist-complex-ro slower P<0.001 for Date-IDate regression in #7213

(Plot image upload to picrd.com failed; download the artifact below to view plots)

Generated via commit 378c87c

Download link for the artifact containing the test results: ↓ atime-results.zip

Task Duration
R setup and installing dependencies 1 minutes and 28 seconds
Installing different package versions 14 minutes and 8 seconds
Running and plotting the test cases 6 minutes and 24 seconds

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.

4 participants