| Age | Commit message (Collapse) | Author |
|
Commit 981ee02c7c ("Fix performance problem with /k/i and /s/i") was
merged for Ruby 4.0 to enable partial Boyer-Moore optimization for
patterns containing 's' or 'k' by using the prefix before those
characters.
However, when 's' or 'k' appears at the start of a pattern (no usable
prefix), set_bm_skip() returns 0 and the code returned early without
setting any optimization mode, leaving reg->optimize at
ONIG_OPTIMIZE_NONE. This caused up to 30x slowdown for patterns like
/slackware/i when matched against strings with non-ASCII characters.
This patch keeps the improvement from 981ee02c7c for patterns with
3+ char prefix, while fixing the regression by falling back to
ONIG_OPTIMIZE_EXACT_IC with the full pattern when the usable prefix
is less than 3 characters.
Before: /\bslackware\b/i with non-ASCII string: 2.24 us/op
After: /\bslackware\b/i with non-ASCII string: 0.70 us/op (3.2x faster)
[Bug #21824]
|
|
https://github.com/k-takata/Onigmo/commit/ced209d5e9
|
|
When onig_reg_init() returns an error, onig_free_body() which is called
via onig_new() may crash because some members are not properly
initialized. Fix it.
https://github.com/k-takata/Onigmo/commit/d2a090a57e
|
|
* Update our copyright information.
* Import the latest information from oniguruma.
Related: #95
https://github.com/k-takata/Onigmo/commit/0d8662b500
|
|
https://github.com/k-takata/Onigmo/commit/6875da50f7
|
|
The code has not been used for long.
(Oniguruma also removed this code.)
https://github.com/k-takata/Onigmo/commit/8796781fdd
|
|
https://github.com/k-takata/Onigmo/commit/6c58de82d2
|
|
Remove the code for Boyer-Moore-Horspool search.
Now we are using Sunday's quick search.
https://github.com/k-takata/Onigmo/commit/3d9072419a1578b742a422412d004fd8a54209fd
|
|
This fixes k-takata/Onigmo#120.
The commit k-takata/Onigmo@9c13de8d0684ebde97e3709d7693997c81ca374b was insufficient.
https://github.com/k-takata/Onigmo/commit/1de602ddff140d91419e3f86dd35c81d7bd2d8e7
|
|
* Multiplication result may overflow 'int' before it is converted to
'OnigDistance'.
* Comparison is always true because code <= 122.
* This statement makes ExprStmt unreachable.
* Empty block without comment
https://github.com/k-takata/Onigmo/commit/387ad616c3cb9370f99d2b11198c2135fa07030f
|
|
Fixes k-takata/Onigmo#92.
This fix was ported from oniguruma:
https://github.com/kkos/oniguruma/commit/257082dac8c6019198b56324012f0bd1830ff4ba
https://github.com/k-takata/Onigmo/commit/b1a5445fbeba97b3e94a733c2ce11c033453af73
|
|
This reverts commit 282338f88a8bf0807a7a1d21b06f78abe9de8fac.
It seems that the commit didn't improve the performance.
Revert it to fix k-takata/Onigmo#100.
https://github.com/k-takata/Onigmo/commit/cef834cb3a6e278fa252f52b704c65175a970ac0
|
|
E.g.
For the pattern `/----k/i`, optimization was totally turned off.
Make it possible to use the characters before `k` (i.e. `----`) for
optimization.
https://github.com/k-takata/Onigmo/commit/9c13de8d0684ebde97e3709d7693997c81ca374b
|
|
|
|
|
|
xfree can handle null values, so we don't need to check it.
|
|
Co-authored-by: Adam Hess <HParker@github.com>
|
|
|
|
|
|
According to the C99 specification section 7.20.3.2 paragraph 2:
> If ptr is a null pointer, no action occurs.
So we do not need to check that the pointer is a null pointer.
Notes:
Merged: https://github.com/ruby/ruby/pull/8004
|
|
When copying from another regexp, copy already built `regex_t` instead
of re-compiling its source.
Notes:
Merged: https://github.com/ruby/ruby/pull/7922
|
|
|
|
https://hackerone.com/reports/1220911
Notes:
Merged: https://github.com/ruby/ruby/pull/5793
|
|
[Feature #17837]
Notes:
Merged: https://github.com/ruby/ruby/pull/5703
|
|
Notes:
Merged: https://github.com/ruby/ruby/pull/4968
|
|
|
|
|
|
Notes:
Merged: https://github.com/ruby/ruby/pull/2696
|
|
* Fix leaked storage in addr2line.c.
* Fix for "top_root" leaking the resource.
[Fix GH-1956]
From: Jun Aruga <jaruga@redhat.com>
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64750 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
* rememberd -> remembered
* refered -> referred
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61933 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
* Support absent operator https://github.com/k-takata/Onigmo/issues/82
* https://github.com/k-takata/Onigmo/blob/Onigmo-6.1.1/HISTORY
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57603 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
* regcomp.c (print_indent_tree): make a function for debug static.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57420 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
* regcomp.c (get_min_match_length): Fix compile error with old version
of fcc (Fujitsu C Compiler) on Solaris 10. [Bug #13059][ruby-dev:49909]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57143 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
* https://github.com/k-takata/Onigmo/blob/Onigmo-6.0.0/HISTORY
* fix for ruby 2.4: https://github.com/k-takata/Onigmo/pull/78
* suppress warning: https://github.com/k-takata/Onigmo/pull/79
* include/ruby/oniguruma.h: include onigmo.h.
* template/encdb.h.tmpl: ignore duplicated definition of EUC-CN in
enc/euc_kr.c. It is defined in enc/gb2313.c with CRuby macro.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57045 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
* meta character \X matches Unicode 9.0.0 characters with some workarounds
for UTR #51 Unicode Emoji, Version 4.0 emoji zwj sequences.
[Feature #12831] [ruby-core:77586]
The term "character" can have many meanings bytes, codepoints, combined
characters, and so on. "grapheme cluster" is highest one of such words,
which means user-perceived characters.
Unicode Standard Annex #29 UNICODE TEXT SEGMENTATION specifies how to
handle grapheme clusters (extended grapheme cluster).
But some specs aren't updated to current situation because Unicode Emoji
is rapidly extended without well definition.
It breaks the precondition of UTR#29 "Grapheme cluster boundaries can be
easily tested by looking at immediately adjacent characters". (the
sentence will be removed in the next version)
Though some of its detail are described in Unicode Technical Report #51
UNICODE EMOJI but it is not merged into UTR#29 yet.
http://unicode.org/reports/tr29/
http://unicode.org/reports/tr51/
http://unicode.org/Public/emoji/4.0/
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@56949 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
look relative.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@56333 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
Ruby's Regexp doesn't allow normal numbered groups if the regexp
has named groups. On such case it optimizes out related NT_ENCLOSE.
But even on the case it can use \g<0>.
This fix not to remove NT_ENCLOSE whose regnum is 0.
[ruby-core:75828] [Bug #12454]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@55562 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@55157 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
doesn't use regexp now.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@55155 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
if compile_length_tree raised error [Bug #12418]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@55154 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
revert slow atomic operations.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52997 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
* regcomp.c (onig_chain_link_add): use atomic operation instead of
mutex.
* regint.h (ONIG_STATE_{INC,DEC}_THREAD): ditto.
* regparse.c (PopFreeNode, node_recycle): ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52995 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
Merge Onigmo 58fa099ed1a34367de67fb3d06dd48d076839692
+ https://github.com/k-takata/Onigmo/pull/52
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52756 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47598 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
this includes Support for Unicode 7.0 [Bug #9092].
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46831 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
https://bugs.ruby-lang.org/issues/8583
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@41764 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
[bug] fix problem with optimization of \z (Issue #16) [Bug #8210]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@40276 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
v5.13.3 [Bug#7972] [Bug#7974]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@39547 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@34905 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|
|
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@34684 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
|