summaryrefslogtreecommitdiff
path: root/yjit.c
diff options
context:
space:
mode:
authornekoyama32767 <[email protected]>2023-05-20 19:40:27 +0900
committerGitHub <[email protected]>2023-05-20 19:40:27 +0900
commit87217f26f120611d009f1b178d3cc5eaf1b8b515 (patch)
tree076728143f2a038c0e953a85c9c14a3a11a6d7d6 /yjit.c
parent892798cac8d025ad30a99fc2a0efa6b0a7a8dd0e (diff)
[Feature #19643] Direct primitive compare sort for `Array#sort_by`
In most of case `sort_by` works on primitive type. Using `qsort_r` with function pointer is much slower than compare data directly. I implement an intro sort which compare primitive data directly for `sort_by`. We can even afford an O(n) type check before primitive data sort. It still go faster.
Notes
Notes: Merged: https://github.com/ruby/ruby/pull/7805 Merged-By: nobu <[email protected]>
Diffstat (limited to 'yjit.c')
0 files changed, 0 insertions, 0 deletions