aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Update source code URI in bundled_gems [ci skip]nobu2018-11-301-4/+4
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66102 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test/testunit/test_parallel.rb: respect subprocess timeout scalenormal2018-11-301-1/+2
| | | | | | MJIT tests take longer than 100s on my VM :< git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66101 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* vm_trace.c: workqueue as thread-safe version of postponed_jobnormal2018-11-305-20/+67
| | | | | | | | | | postponed_job is safe to use in signal handlers, but is not thread-safe for MJIT. Implement a workqueue for MJIT thread-safety. [Bug #15316] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66100 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* io.c: fix clang -Werror,-Wshorten-64-to-32 on Linux sendfilenormal2018-11-291-1/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66099 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* io.c: fix clang -Werror,-Wshorten-64-to-32 errorsnormal2018-11-291-5/+5
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66098 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * expand tabs.svn2018-11-291-3/+3
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66097 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* io.c: favor comparisons against zero rather than -1normal2018-11-291-99/+102
| | | | | | | | | | On my 32-bit x86 userspace, I get the following .text savings: text data bss dec hex filename 152971 56 252 153279 256bf io.o.before 152863 56 252 153171 25653 io.o.after git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66096 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Use a shared array for the `duparray` instructiontenderlove2018-11-291-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In this example code: ```ruby def foo [1, 2, 3, 4] end ``` The array literal uses a `duparray` instruction. Before this patch, `rb_ary_resurrect` would malloc and memcpy a new array buffer. This patch changes `rb_ary_resurrect` to use `ary_make_partial` so that the new array object shares the underlying buffer with the array stored in the instruction sequences. Before this patch, the new array object is not shared: ``` $ ruby -r objspace -e'p ObjectSpace.dump([1, 2, 3, 4])' "{\"address\":\"0x7fa2718372d0\", \"type\":\"ARRAY\", \"class\":\"0x7fa26f8b0010\", \"length\":4, \"memsize\":72, \"flags\":{\"wb_protected\":true}}\n" ``` After this patch: ``` $ ./ruby -r objspace -e'p ObjectSpace.dump([1, 2, 3, 4])' "{\"address\":\"0x7f9a76883638\", \"type\":\"ARRAY\", \"class\":\"0x7f9a758af900\", \"length\":4, \"shared\":true, \"references\":[\"0x7f9a768837c8\"], \"memsize\":40, \"flags\":{\"wb_protected\":true}}\n" ``` [Feature #15289] [ruby-core:90097] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66095 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * 2018-11-30svn2018-11-291-1/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66094 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* disable non-blocking pipes and sockets by defaultnormal2018-11-295-8/+10
| | | | | | | | | | | | There seems to be a compatibility problems with Rails + Rack::Deflater; so we revert this incompatibility. This effectively reverts r65922; but keeps the bugfixes to better support non-blocking sockets and pipes for future use. [Bug #15356] [Bug #14968] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66093 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Remove unused variable in example code [ci skip]kazu2018-11-291-1/+0
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66092 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* clear dst Hash on Hash#replace. [Bug #15358]ko12018-11-292-10/+29
| | | | | | | | | | | | * hash.c (linear_copy): solve two issues on `Hash#replace`. (1) fix memory leak (1-1) don't allocate memory if destination already has a memory area. (1-2) free destination memory if src is NULL. (2) clear transient heap flag if src is NULL. [Bug #15358] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66091 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Create empty revision.h when srcdir is write-only [ci skip]nobu2018-11-291-1/+2
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66090 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Always try to update revision.h with GNU makenobu2018-11-292-1/+5
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66089 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Revert "using_spec.rb: skip broken test for MinGW for now"k0kubun2018-11-291-9/+7
| | | | | | | | This reverts commit 110273c53461a9a7ecdcca705346be21f25f50c6. Try this with r66087 git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66088 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* use __builtin_setjmp on mingw64 [Bug #15348].ko12018-11-291-1/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66087 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Remove HEAP_ALIGN_LOG setting in configure.ac for OpenBSD/MirOSshyouhei2018-11-292-30/+0
| | | | | | | | | | | | | | | | The ruby setting was renamed to HEAP_PAGE_ALIGN_LOG, but the configure.in (now configure.ac) file was not updated, so the setting had no effect. The configure setting is unnecessary after OpenBSD 5.2 and MirOS has been discontinued (with the last release being over 10 years ago), so it is better to just remove the related configure setting. Fix [Bug #13438] From: Jeremy Evans <code@jeremyevans.net> git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66086 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* .travis.yml: cache unicode.org filesshyouhei2018-11-292-5/+9
| | | | | | | | | | | | | Before this changeset (since r58071) we did not download files from unicode.org but just touch some files. This is a kind of hack that people normally don't do at home. We are caching other files between builds now. Why not also save those files downloaded from elsewhere. This covers more realistic workload, I guess. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66085 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* .travis.yml: fix YAML parse errorshyouhei2018-11-291-1/+3
| | | | | | | | `[` is a meta character in YAML. `- [` starts an array, so it should end with `]`; but it was not. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66084 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * 2018-11-29svn2018-11-291-1/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66083 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* time.rb: Move documents and stop othersnobu2018-11-291-73/+101
| | | | | | | | | * lib/time.rb: Move method documents to each methods. And stop documentation of the abstract and others, which were confusingly placed at the top of generated documents prior to the abstract in time.c. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66082 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Executable scripts have been moved to libexec [ci skip]nobu2018-11-281-2/+2
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66081 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* time.c: rescue find_timezone when loadingnobu2018-11-282-3/+52
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66080 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Try with TZInfo and Timezone gemsnobu2018-11-283-1/+45
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66079 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Time.at in: tznobu2018-11-282-8/+14
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66078 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Timezone at Time.atnobu2018-11-282-2/+29
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66077 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Try Time.find_timezone to convert name to timezonenobu2018-11-282-28/+74
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66076 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Try Time.find_timezone to loadnobu2018-11-282-2/+18
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66075 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* remove two unnecessary variables (np2 and np3)duerst2018-11-281-4/+0
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66072 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* eliminate intermediate variable in very short block (3 times)duerst2018-11-281-12/+3
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66071 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* use create_sequence_node() four more timesduerst2018-11-281-78/+59
| | | | | | | Four more use of create_sequence_node() in node_extended_grapheme_cluster (a few more to come). git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66070 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Get rid of block-less Proc.newnobu2018-11-281-1/+2
| | | | | | | * lib/optparse.rb (OptionParser::Switch#initialize): get rid of `Proc.new` without a block, which may be deprecated in the future. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66069 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Remove useless backslashnobu2018-11-281-1/+1
| | | | | | | * lib/optparse.rb (OptionParser::Switch#compsys): remove useless backslash which just confuse ruby-mode.el. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66068 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test_settracefunc (test_tracepoint_enable_with_target_line): less fragilenormal2018-11-281-1/+2
| | | | | | | Allow us to make other changes to the file and move the method around without affecting this test. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66067 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Regenerated binstubs of bundler, rdoc and irb.hsbt2018-11-285-25/+25
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66066 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Merge rubygems upstream from ↵hsbt2018-11-2811-78/+119
| | | | | | | | https://github.com/rubygems/rubygems/commit/2c499655f29070c809dfea9f5fda6fac6850e62e https://github.com/rubygems/rubygems/pull/2493 git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66065 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Merge stringio.gemspec from github repository.hsbt2018-11-281-3/+4
| | | | | | Temporary ignored configuration of certificate sign. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66064 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* use create_sequence_node() once moreduerst2018-11-281-19/+9
| | | | | | | One more use of create_sequence_node() in node_extended_grapheme_cluster (several more to come). git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66063 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* using_spec.rb: skip broken test for MinGW for nowk0kubun2018-11-281-7/+9
| | | | | | ko1 is fixing this and he suggested to skip it for now git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66062 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* lib/monitor.rb: avoid race conditions by Thread.handle_interruptshugo2018-11-282-7/+33
| | | | | | Suggested by Benoit Daloze. [ruby-core:88502] [Bug #14998] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66061 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* io.c (rb_update_max_fd): use F_GETFL if possiblenormal2018-11-281-2/+10
| | | | | | | | | | | | On 64-bit Linux, fstat() needs to fill out a 144 byte struct while F_GETFL only needs to return 8 bytes. Fwiw, F_GETFD requires an additional rcu_read_lock and bitmap check; so it's obviously more expensive than F_GETFL on Linux. Reduce stack usage of rb_update_max_fd from 184 to 24 bytes. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66060 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Fix for coroutine/win32/Context.objnobu2018-11-282-2/+3
| | | | | | | | | | | * coroutine/win32/Context.asm: old ml version 9 needs CPU directive before `.model` directive. * win32/Makefile.sub: specify object directories to separate Win32 and Win64 targets. Win32 rule was overridden by Win64 rule and just ignored. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66059 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* win32/Makefile.sub: add flags for ASnobu2018-11-282-4/+6
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66058 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* introduce macro R_ERR to reduce repetitive codeduerst2018-11-281-85/+46
| | | | | | | | Introduce a new preprocessor macro R_ERR to visually reduce repetitive code checking for return values and going to the err: label at the end of the function node_extended_grapheme_cluster(). git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66057 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* .travis.yaml: unquoteshyouhei2018-11-281-73/+76
| | | | | | | | | | | | It was probably me, 7 years ago, in r33844, who started overly quoting YAML strings. But now, this file grown up 50+ times from 6 lines to more than 300. It is more annoying than convenient to quote everything to add backslashes here and there. Just use quotes only when necessary. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66056 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Removed redundant empty line.hsbt2018-11-281-1/+0
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66055 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * expand tabs.svn2018-11-281-2/+2
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66054 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* io.c: reduce IO.copy_stream stack usage on Linuxnormal2018-11-281-15/+17
| | | | | | | | | | | | | | | | nogvl_copy_file_range and nogvl_copy_stream_sendfile each used 344 bytes of stack before this change. Now, they are inlined into nogvl_copy_stream_func which only uses 200 bytes of stack. "struct stat" is 144 bytes on my 64-bit Linux. Note: this doesn't affect GC (yet) since GVL is released; but increases safety if called from deep machine stacks. It will affect GC if Thread::Light is merged. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66053 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* reduce number of arguments on quantify_property_node()duerst2018-11-281-20/+38
| | | | | | | | | There are only four patterns of the last two arguments to quantify_property_node(). By replacing the lower/upper arguments with a single char, we get more expressive calls, the last argument directly corresponding to the quantifier that we want to use (except for '2', which means exactly two). git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66052 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Add Float::INFINITY or nil to call-seq of Enumerator::Chain#size [ci skip]kazu2018-11-271-1/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66051 b2dd03c8-39d4-4d8f-98ff-823fe69b080e