Possibly faster fread via fast_float

Open
#4,882 2 comments 4 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
28/100
Issue type
Feature
Clarity
Needs clarification
Activity status
Stale
Tech stack
cpp, r
Domain
data, performance

Research direction

Start by locating fread's ASCII-to-float conversion and reviewing the linked fast_float paper and library. Compare the approaches and benchmark whether fast_float provides a meaningful improvement; done means establishing whether it is faster and whether its Apache license permits vendoring.

Written by the indexing model from the issue text.

Description

fread

Daniel @Lemire has another paper (https://arxiv.org/abs/2101.11408) and library (https://github.com/fastfloat/fast_float) out which speeds up conversion from ascii to float ("4x over strtod"):

image

Apparently Arrow already uses it, as does ClickHouse (which is also a performance hound):

image

It is C++, but Apache license so you could possibly vendor it if it turns that it offers a leg up over your code in fread. Feel free to close this if it is old news to you.

Dominant language
R
Stars
3.9k
Forks
1.1k
Avg merge
14h 4m
Merged PRs (30d)
4

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from Rdatatable/data.table

All issues in Rdatatable/data.table

Similar issues

More R issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.