aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Revert r65800nobu2019-01-161-1/+0
| | | | | | | "Makefile.in: reconfig with the original warnflags" It would be unnecessary since r65803 and r65805. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66835 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * 2019-01-16svn2019-01-161-1/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66834 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Fixed a typo, missing `$`nobu2019-01-161-1/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66833 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* st.c (rb_hash_bulk_insert_into_st_table): avoid out-of-bounds writemame2019-01-152-1/+19
| | | | | | | | | | | | | | "hash_bulk_insert" first expands the table, but the target size was wrong: it was calculated by "num_entries + (size to buld insert)", but it was wrong when "num_entries < entries_bound", i.e., it has a deleted entry. "hash_bulk_insert" adds the given entries from entries_bound, which led to out-of-bounds write access. [Bug #15536] As a simple fix, this commit changes the calculation to "entries_bound + size". I'm afraid if this might be inefficient, but I think it is safe anyway. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66832 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Clarify Array#- and Array#difference documentationnobu2019-01-151-6/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Currently we are not explicit enough regarding the potentially confusing behavior of `Array#-` and `Array#difference` when it comes to duplicate items within receiver arrays. Although the original documentation for these methods does use an array with multiple instance of the same integers, the explanation for the behavior is actually imprecise. > removing any items that also appear in +other_ary+ Not only does `Array#-` remove any items that also appear in `other_ary` but it also remove any instance of any item in `other_ary`. One may expect `Array#-` to behave like mathematical subtraction or difference when it doesn't. One could be forgiven to expect the following behavior: ```ruby [1,1,2,2,3,3,4,4] - [1,2,3,4] => [1,2,3,4] ``` In reality this is the result: ```ruby [1,1,2,2,3,3,4,4] - [1,2,3,4] => [] ``` I hope that I've prevented this potential confusion with the clarifications in this change. I can offer this as evidence of likeliness for confusion: https://twitter.com/olivierlacan/status/1084930269533085696 I'll freely admit I was surprised by this behavior myself since I needed to obtain an Array with only one instance of each item in the argument array removed. [Fix GH-2068] [ci skip] From: Olivier Lacan <hi@olivierlacan.com> git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66831 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Use `&` instead of `modulo`nobu2019-01-152-6/+6
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66830 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* setbyte / ungetbyte allow out-of-range integersshyouhei2019-01-156-59/+53
| | | | | | | | | | | | * string.c: String#setbyte to accept arbitrary integers [Bug #15460] * io.c: ditto for IO#ungetbyte * ext/strringio/stringio.c: ditto for StringIO#ungetbyte git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66824 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Revert "mjit_worker.c: try passing -nostdlib to AIX"k0kubun2019-01-151-2/+2
| | | | | | | | This reverts commit b32fb23083912c37a2601c66531ed786a7c9f3e5. This didn't work on AIX. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66823 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * 2019-01-15svn2019-01-151-1/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66822 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Suppress warning: ambiguous first argument; put parentheses or a space even ↵naruse2019-01-151-15/+15
| | | | | | after `/' operator git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66821 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* update redmine-backporter to catch up Redmine 4.0. [ci skip]nagachika2019-01-141-2/+3
| | | | | | tool/redmine-backporter.rb: change revision resource URL. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66820 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* ast.c: fix missing head part in dynamic literalnobu2019-01-142-1/+15
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66819 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* mjit_worker.c: pass -nostdlib when making pch as wellk0kubun2019-01-141-4/+12
| | | | | | [Bug #15513] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66817 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* mjit_worker.c: try passing -nostdlib to AIXk0kubun2019-01-141-1/+1
| | | | | | r66812 might have allowed this. Testing. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66816 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* mjit_worker.c: pass -lgcc to GCC platformsk0kubun2019-01-141-7/+7
| | | | | | | | | | | | | | | | | | | | | | | | | using `-nodefaultlibs -nostdlib`. I assume libgcc is needed when we use -nostdlib, and it's linked on some platforms but not linked on some platforms (like aarch64, and possibly AIX as well) as said in https://wiki.osdev.org/Libgcc : > You can link with libgcc by passing -lgcc when linking your kernel with your compiler. You don't need to do this unless you pass the -nodefaultlibs option (implied by -nostdlib) Also note that -nostdlib is not strictly needed (rather implied -nodefaultlibs is problematic for Gentoo like Bug#15513, which will be approached later) but helpful for performance. So I want to keep it for now. [Bug #15522] I'm not trying to add `-nodefaultlibs -nostdlib` for AIX in this commit because AIX RubyCI is dead right now, but I'll try to add them again once RubyCI is fixed. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66812 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* mjit_worker.c: untangle CC_LIBS nestingk0kubun2019-01-141-5/+5
| | | | | | | | | | This should have no impact. The CC_LIBS was too hard to read for human. I don't remember whether the order of -lmsvcrt and -lgcc matters or not, but I kept that for the best safety. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66811 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * 2019-01-14svn2019-01-141-1/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66810 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* vm_insnhelper.c: make VM helpers inlinek0kubun2019-01-141-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In r66597, both VM and JIT seem to be made slower: ``` $ benchmark-driver benchmark.yml --rbenv 'r66596::before --disable-gems;r66597::after --disable-gems;r66596+JIT::before --disable-gems --jit;r66597+JIT::after --disable-gems --jit' -v --repeat-count 24 r66596: ruby 2.7.0dev (2018-12-28 trunk 66596) [x86_64-linux] r66597: ruby 2.7.0dev (2018-12-28 trunk 66597) [x86_64-linux] r66596+JIT: ruby 2.7.0dev (2018-12-28 trunk 66596) +JIT [x86_64-linux] r66597+JIT: ruby 2.7.0dev (2018-12-28 trunk 66597) +JIT [x86_64-linux] Calculating ------------------------------------- r66596 r66597 r66596+JIT r66597+JIT Optcarrot Lan_Master.nes 55.174 54.620 88.011 85.326 fps Comparison: Optcarrot Lan_Master.nes r66596+JIT: 88.0 fps r66597+JIT: 85.3 fps - 1.03x slower r66596: 55.2 fps - 1.60x slower r66597: 54.6 fps - 1.61x slower ``` This commit makes JIT's situation a little better. But in 2.7 we seem to have some other regressions after that, and this can't still resurrect the 2.6.0's performance. ``` $ benchmark-driver benchmark.yml --rbenv 'before::before --disable-gems;after::after --disable-gems;before+JIT::before --disable-gems --jit;after+JIT::after --disable-gems --jit' -v --repeat-count 24 before: ruby 2.7.0dev (2019-01-13 trunk 66808) [x86_64-linux] after: ruby 2.7.0dev (2019-01-13 trunk 66808) [x86_64-linux] last_commit=vm_insnhelper.c: make VM helpers inline before+JIT: ruby 2.7.0dev (2019-01-13 trunk 66808) +JIT [x86_64-linux] after+JIT: ruby 2.7.0dev (2019-01-13 trunk 66808) +JIT [x86_64-linux] last_commit=vm_insnhelper.c: make VM helpers inline Calculating ------------------------------------- before after before+JIT after+JIT Optcarrot Lan_Master.nes 51.710 51.535 83.629 85.486 fps Comparison: Optcarrot Lan_Master.nes after+JIT: 85.5 fps before+JIT: 83.6 fps - 1.02x slower before: 51.7 fps - 1.65x slower after: 51.5 fps - 1.66x slower ``` git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66809 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* rdoc: ignore gemspec filesnobu2019-01-132-1/+2
| | | | | | [ruby-core:91067] [Bug #15531] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66808 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* rdoc: fixup the test for r66806nobu2019-01-131-1/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66807 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* rdoc: ignore garbage filesnobu2019-01-131-1/+3
| | | | | | | * lib/rdoc/options.rb (RDoc::Options#init_ivars): exclude backup files by default. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66806 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* common.mk: common rdoc variablesnobu2019-01-131-3/+5
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66805 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* time.c: separate sign argumentnobu2019-01-131-8/+4
| | | | | | | * time.c (vtm_add_offset): separate sign argument to get rid of repeated negations. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66804 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* time.c: do not set utc_offset in vtm_add_offsetnobu2019-01-131-2/+0
| | | | | | | | * time.c (vtm_add_offset): just add offset to other components only. removed subtraction of utc_offset as it is overwritten always immediately in callers. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66803 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * 2019-01-13svn2019-01-131-1/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66802 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Fix remaining syntax errors in Binding#irb docsnobu2019-01-131-3/+3
| | | | | | | | | | Apologies for catching those so late. [Fix GH-2067] [ci skip] From: Olivier Lacan <hi@olivierlacan.com> git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66801 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* trivial fix r66778 [ci skip]kazu2019-01-121-2/+2
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66798 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* No FloatDomainError at non-finitive number if exception: falsenobu2019-01-122-0/+10
| | | | | | [ruby-core:91021] [Bug #15525] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66797 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* No TypeError at nil if exception: falsenobu2019-01-124-2/+18
| | | | | | [ruby-core:91021] [Bug #15525] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66796 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * 2019-01-12svn2019-01-121-1/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66795 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* RbConfig::CONFIG never had "exeext"nobu2019-01-121-2/+2
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66794 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Drop whole examplesnobu2019-01-111-5/+2
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66793 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Fix r66791nobu2019-01-111-1/+0
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66792 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Fix r66772nobu2019-01-111-17/+6
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66791 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Fix make-snapshot for trunkkazu2019-01-112-0/+27
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66790 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Ensure to terminate the childnobu2019-01-112-31/+42
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66789 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Update refinements docstenderlove2019-01-101-4/+2
| | | | | | Co-Authored-By: Vladimir Dementyev <dementiev.vm@gmail.com> git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66788 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* addr2line.c: fix -Wextra-semik0kubun2019-01-101-1/+2
| | | | | | | and ignore only -Wgnu-empty-initializer. https://travis-ci.org/ruby/ruby/jobs/477867392 git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66787 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* addr2line.c: do not suppress -Wpedantick0kubun2019-01-101-3/+0
| | | | | | | because it was for "-assi -Wpedantic" on Travis, but we changed the Travis build to "-std=c99 -Wpedantic". git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66786 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * 2019-01-11svn2019-01-101-1/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66783 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* revert r66768 for Ruby 2.7 due to Misc#15347k0kubun2019-01-101-6/+3
| | | | | | | It's safer to backport r66768 to 2.6 branch, but for 2.7 it's not needed anymore. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66782 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test_jit.rb: change format of test error outputk0kubun2019-01-102-2/+2
| | | | | | | to avoid breaking redmine quote like https://bugs.ruby-lang.org/issues/15522 git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66781 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* configure: refuse to build with jemalloc when header is missingnobu2019-01-101-1/+2
| | | | | | | | [ruby-core:90964] [Bug #15520] Freom: Misty De Meo <mistydemeo@github.com> git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66779 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* mjit.c: use boolean type for boolean variablesk0kubun2019-01-109-115/+112
| | | | | | | | | | and functions to clarify the intention and make sure it's not used in a surprising way (like using 2, 3, ... other than 0, 1 even while it seems to be a boolean). This is a retry of r66775. It included some typos... git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66778 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Revert "mjit.c: use boolean type for boolean variables"k0kubun2019-01-108-91/+94
| | | | | | | | This reverts commit bb1a1aeab0f2a5fe437c89b841a887ba56653453. We hit something on ci.rvm.jp, reverting until investigation is done. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66776 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* mjit.c: use boolean type for boolean variablesk0kubun2019-01-108-94/+91
| | | | | | | | and functions to clarify the intention and make sure it's not used in a surprising way (like using 2, 3, ... other than 0, 1 even while it seems to be a boolean). git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66775 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test/ruby/test_method.rb: Remove unreachable callkazu2019-01-101-2/+2
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66774 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* NEWS: announce C99 requirement [ci skip]k0kubun2019-01-101-0/+3
| | | | | | [Misc #15347] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66773 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* proc.c: proc without blocknobu2019-01-1010-66/+144
| | | | | | | * proc.c (proc_new): promoted lambda/proc/Proc.new with no block in a method called with a block to a warning/error. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66772 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* configure.ac: Require C99k0kubun2019-01-101-2/+0
| | | | | | | | | We already added AC_PROG_CC_C99 in r66605. This commit stops warning C99 features. [Misc #15347] [close https://github.com/ruby/ruby/pull/2064] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66771 b2dd03c8-39d4-4d8f-98ff-823fe69b080e