Project

General

Profile

Actions

Misc #16487

open

Potential for SIMD usage in ruby-core

Added by byroot (Jean Boussier) about 4 years ago. Updated about 4 years ago.

Status:
Open
Assignee:
-
[ruby-core:96708]

Description

Context

There are several ruby core methods that could be optimized with the use of SIMD instructions.

I experimented a bit on coderange_scan https://github.com/Shopify/ruby/pull/2, and Pavel Rosický experimented on String#strip https://github.com/ruby/ruby/pull/2815.

Problem

The downside of SIMD instructions is that they are not universally available.
So it means maintaining several versions of the same code, and switching them either statically or dynamically.

And since most Ruby users use precompiled binaries from repositories and such, it would need to be dynamic if we want most users to benefit from it.

So it's not exactly "free speed", as it means a complexified codebase.

Question

So the question is to know wether ruby-core is open to patches using SIMD instructions ? And if so under which conditions.

cc @shyouhei (Shyouhei Urabe)


Related issues 1 (1 open0 closed)

Related to Ruby master - Feature #14328: SIMD vectorizationOpenActions
Actions

Also available in: Atom PDF

Like0
Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0