Uploaded image for project: 'Apache Arrow'
  1. Apache Arrow
  2. ARROW-10989

[Rust] Use slices for iterating primitive arrays

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • None
    • 3.0.0
    • Rust

    Description

      Iterating slices instead of indexes seems to improve performance of non-simd arithmetic operations.

      This adds a new method raw_values_slice to PrimitiveArray (so named to pun off of the raw_values function which returns a pointer). A few of the functions in PrimitiveArray rely on the caller for safety guarantees (bounds-checks for value_slice, value), so should probably be unsafe? But they are used widely, so I thought it simpler to start by adding a safer alternative...

      Attachments

        Issue Links

          Activity

            People

              tyrelr Tyrel Rink
              tyrelr Tyrel Rink
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 3h 40m
                  3h 40m