aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* _mjit_compile_send.erb: retry inlining attr_readerk0kubun2018-05-035-15/+76
| | | | | | | | | | | | | | | | | This reverts r63249 (revert r63212) and fixes a bug in it. The test to prevent the bug is added as well. vm_insnhelper.c: add `index` argument to vm_getivar. The argument is created so that MJIT can pass the value of `cc->aux.index` on compilation time. The cache invalidation in _mjit_compile_send_guard.erb is only working for the cache value on compilation time. Note: As `index` is always passed as constant and it's force-inlined, the performance of `vm_getivar` won't be degraded in VM. _mjit_compile_send_guard.erb: New. Used to invalidate inlined values of cc. common.mk: update dependencies for _mjit_compile_send_guard.erb git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63333 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* mjit_compile.c: skip generating unnecessary gotok0kubun2018-05-031-5/+5
| | | | | | | | after return or longjmp. This is mainly for skipping the check of stack size in such cases, which shouldn't be checked because it does never happen. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63332 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* mjit_compile.c: verify stack size agreementk0kubun2018-05-032-9/+24
| | | | | | | | | between branches. mjit_compile.inc.erb: move the compiled_for_pos reference to mjit_compile.c git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63331 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Revert "ext/cgi/escape: preserve String subclass in result"normal2018-05-032-26/+5
| | | | | | | This reverts commit 6afea14043b0c0e603f26c89ae0d043f65852668 r63328 I misread the original bug report and got results flipped. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63330 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* mjit_compile.inc.erb: verify stack consistencyk0kubun2018-05-032-5/+16
| | | | | | | | on JIT compilation. r63092 was risky without this check. mjit_compile.c: update comment about stack consistency check git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63329 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* ext/cgi/escape: preserve String subclass in resultnormal2018-05-022-5/+26
| | | | | | | | | | | * ext/cgi/escape/escape.c (optimized_escape_html): use rb_str_new_with_class (optimized_unescape_html): ditto (optimized_escape): ditto (optimized_unescape): ditto * test/cgi/test_cgi_util.rb (test_escape_string_subclass): new test [ruby-core:86847] [Bug #14732] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63328 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test_jit.rb: test local variablesk0kubun2018-05-021-4/+17
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63327 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test_jit.rb: test opt_aref_with againk0kubun2018-05-021-1/+4
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63326 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test_jit.rb: make it possible to automatically findk0kubun2018-05-021-7/+43
| | | | | | untested insns. Resolved some warnings. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63325 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * 2018-05-03svn2018-05-021-1/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63324 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test_jit.rb: verify tested insnsk0kubun2018-05-021-68/+102
| | | | | | and fix some untested insns git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63323 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* object.c: fix exponent with underscorenobu2018-05-022-1/+7
| | | | | | | | * object.c (rb_cstr_to_dbl_raise): do not ignore exponent part when the input string longer than internal buffer contains underscore(s). [ruby-core:86836] [Bug #14731] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63322 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test_jit.rb: add missing dependencyk0kubun2018-05-021-0/+1
| | | | | | | The test works with make test-all, but I sometimes want to do a thing like: `.ruby-svn/ruby -Itest/lib test/ruby/test_jit.rb -n test_clean_so` git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63321 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* compile.c: mark catch_except_p of iseqk0kubun2018-05-022-10/+19
| | | | | | | | | | which has throw insn, not only ancestor iseqs of it. I think we should remove catch_except_p flag and try to simplify the catch table itself, to prevent similar bugs in the future. test_jit.rb: add test to prevent the bug git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63320 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* common.mk: Update dependencies on tool/ruby_vm scriptsmame2018-05-021-8/+13
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63319 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* tool/ruby_vm/views/_insn_name_info.erb: Auto-detect the longest insn namemame2018-05-022-1/+3
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63318 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* iseq.c (rb_iseq_disasm_insn): Change the width of insn namesmame2018-05-021-2/+2
| | | | | | | Currently "trace_opt_send_without_block" (28 letters) is the longest insn. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63317 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * 2018-05-02svn2018-05-011-1/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63316 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* cont.c: cleanup needless castnormal2018-05-011-3/+3
| | | | | | | | | | | | | | It seems like leftover development step from r59557 ("refactoring Fiber status"). I will make fiber_status use BITFIELD macro in a future commit. * cont.c (struct rb_fiber_struct): drop const from fiber_status (fiber_status_set): remove cast [ruby-core:86788] [Misc #14720] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63315 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* use list_head_init instead of open-coding itnormal2018-05-012-2/+2
| | | | | | | While we cannot use LIST_HEAD since r63312, we can at least use list_head_init to make our code more readable. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63314 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* ast.c: use enum in switch for warningsnobu2018-05-011-3/+3
| | | | | | | | | * ext/-test-/ast/ast.c (node_children): use enum instead of int for not-handled enumeration value in switch warnings. * ext/-test-/ast/ast.c (node_children): fix the rb_bug message. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63313 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* LIST_HEAD as a local variable is a C99ism.shyouhei2018-05-012-2/+4
| | | | | | | | | | | | | | | | | Address of a variable whose storage duration is `auto` is _not_ a compile time constant, according to ISO 9899 section 6.4. LIST_HEAD takes such thing. You can't use it to declare local variables. Interestingly, address of a static variable _is_ a compile time constant. So a declaration like `static LIST_HEAD..` is completely legal even in C90. In C99 and newer, this is not a constraint violation. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63312 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* rexml: Suppress warningskou2018-05-011-5/+5
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63311 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test/thread/test_cv.rb: test CV usability inside forked childnormal2018-04-301-2/+8
| | | | | | | * test/thread/test_cv.rb (def test_condvar_fork): new test [Bug #14725] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63310 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* thread_sync.c (condvar_ptr): reset fork_gen after forkingnormal2018-04-301-0/+1
| | | | | | | | | Otherwise the condition variable waiter list will always be empty, which is wrong :x [Bug #14725] [Bug #14634] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63309 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * 2018-05-01svn2018-04-301-2/+2
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63308 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* thread.c (vm_living_thread_num): constify vm argnormal2018-04-301-1/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63307 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Use `&.` instead of modifier ifkazu2018-04-301-2/+2
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63306 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* NEWS: Add recent REXML changeskou2018-04-301-0/+35
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63305 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* io.c: workaround for EPROTOTYPEnobu2018-04-304-8/+35
| | | | | | | | | | * io.c (internal_write_func, internal_writev_func): retry at unexpected EPROTOTYPE on macOS, to get rid of a kernel bug. [ruby-core:86690] [Bug #14713] * ext/socket/init.c (rsock_{sendto,send,write}_blocking): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63304 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * 2018-04-30svn2018-04-301-1/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63303 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* io.c: reuse internal_write_funcnobu2018-04-301-2/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63302 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * spec/ruby/command_line/dash_upper_i_spec.rb: skip symlink on Windows likeusa2018-04-291-12/+14
| | | | | | | other specs. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63301 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Remove the teeny part from the shared library name on macOSknu2018-04-292-4/+16
| | | | | | | | | | | | | | | | This will prevent macOS users from having to rebuild all extension libraries every time they upgrade ruby to a new teeny release. Before: - libruby.2.6.0.dylib - libruby.2.6.dylib -> libruby.2.6.0.dylib - libruby.dylib -> libruby.2.6.0.dylib After: - libruby.2.6.dylib - libruby.dylib -> libruby.2.6.dylib git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63300 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* range.c: optimize range_each for Bignumnobu2018-04-291-8/+51
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63299 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* _mjit_compile_send.erb: fix pointer conversion warningk0kubun2018-04-291-1/+1
| | | | | | | | | | | | | | | | | | | | | | /var/folders/b0/9hgj_tyx10zgkcbyx3_j2dlr0000gn/T//_ruby_mjit_p72619u0.c:37:58: warning: incompatible integer to pointer conversion passing 'long' to parameter of type 'const struct rb_call_info *' [-Wint-conversion] vm_caller_setup_arg_block(ec, reg_cfp, &calling, 0x7ff6b2e10ca0, 0x7ff6b3847108, FALSE); ^~~~~~~~~~~~~~ /Users/kokubun/.rbenv/versions/ruby-svn/include/ruby-2.6.0/x86_64-darwin16/rb_mjit_min_header-2.6.0.h:15613:66: note: passing argument to parameter 'ci' here struct rb_calling_info *calling, const struct rb_call_info *ci, rb_iseq_t *blockiseq, const int is_super) ^ /var/folders/b0/9hgj_tyx10zgkcbyx3_j2dlr0000gn/T//_ruby_mjit_p72619u0.c:37:74: warning: incompatible integer to pointer conversion passing 'long' to parameter of type 'rb_iseq_t *' (aka 'struct rb_iseq_struct *') [-Wint-conversion] vm_caller_setup_arg_block(ec, reg_cfp, &calling, 0x7ff6b2e10ca0, 0x7ff6b3847108, FALSE); ^~~~~~~~~~~~~~ /Users/kokubun/.rbenv/versions/ruby-svn/include/ruby-2.6.0/x86_64-darwin16/rb_mjit_min_header-2.6.0.h:15613:81: note: passing argument to parameter 'blockiseq' here struct rb_calling_info *calling, const struct rb_call_info *ci, rb_iseq_t *blockiseq, const int is_super) ^ 2 warnings generated. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63298 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* range.c: endless symbol rangenobu2018-04-281-2/+7
| | | | | | | * range.c (range_each): shortcirtuit endless symbol range too, as well as `#step`. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63297 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Generalize the check to MRI in the -I speceregon2018-04-281-1/+1
| | | | | | * The current check seems to fail with AppVeyor. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63296 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Ignore the extension of miniruby on Windows in the -I speceregon2018-04-281-1/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63295 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * properties.svn2018-04-280-0/+0
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63294 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Update to ruby/spec@6f38a82eregon2018-04-28145-2442/+2693
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63293 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * 2018-04-29svn2018-04-281-1/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63292 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* Update to ruby/mspec@b5b13deeregon2018-04-286-12/+21
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63291 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* string.c: adjust to rb_str_upto_eachnobu2018-04-283-47/+36
| | | | | | | | | | * range.c (range_each_func): adjust the signature of the callback function to rb_str_upto_each, and exit the loop if the callback returned non-zero. * string.c (rb_str_upto_endless_each): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63290 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test_open3.rb: let test_popen2 work with --jitk0kubun2018-04-282-1/+10
| | | | | | test/lib/jit_support.rb: add .remove_mjit_logs to normalize stderr git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63289 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test_rubyoptions.rb: let all tests work with --jitk0kubun2018-04-281-4/+9
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63288 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test_bug_reporter.rb: make it work with --jitk0kubun2018-04-282-2/+4
| | | | | | | test_rubyoptions.rb: replace gsub with sub because it's suboptimal for this git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63287 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test_rubyoptions.rb: let test_verbose work w/ --jitk0kubun2018-04-281-1/+3
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63286 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test_parallel.rb: extend timeout for --jit-waitk0kubun2018-04-281-12/+13
| | | | | | testing. 10s was long enough for my machine, but not for travis. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63285 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test_ftp.rb: extend read_timeout for --jit-waitk0kubun2018-04-281-1/+1
| | | | | | | testing. I'm running `make test-all RUN_OPTS='--jit-wait'` and the read_timeout was too slow for it. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63284 b2dd03c8-39d4-4d8f-98ff-823fe69b080e