Граф коммитов

50638 Коммитов

Автор SHA1 Сообщение Дата
k0kubun 6090206275 test_rubyoptions.rb: let all tests work with --jit
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63288 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-28 09:11:25 +00:00
k0kubun acacd7a1d3 test_bug_reporter.rb: make it work with --jit
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
2018-04-28 09:02:56 +00:00
k0kubun 0b01776d43 test_rubyoptions.rb: let test_verbose work w/ --jit
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63286 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-28 08:52:24 +00:00
k0kubun 9aab4b6bc7 test_parallel.rb: extend timeout for --jit-wait
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
2018-04-28 08:41:19 +00:00
k0kubun ada4198478 test_ftp.rb: extend read_timeout for --jit-wait
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
2018-04-28 08:24:44 +00:00
nobu d07861fb2f range.c: each on endless range
* range.c (range_each): endless range begins with string-like
  object should iterate from the converted result string, as well
  as `#each` on a string-end range or `#step` method on an endless
  range, i.e., `begin.succ` should not be called.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63283 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-28 07:31:32 +00:00
normal b6e2851431 thread_sync.c: remove "volatile" qualifiers
I may store ->ec in rb_mutex_t instead of ->th to support green
thread.  For now, "volatile" is useless for thread-safety
anyways and we're not dealing with *jmp or signals with mutex.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63282 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-28 06:23:43 +00:00
normal 0d77b73db7 thread_sync.c: remove unused list_heads
I forgot to clean these up in r63215

* thread_sync.c (szqueue_list, queue_list, condvar_list): remove

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63281 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-28 06:00:39 +00:00
hsbt f114089585 Merge Pysch 3.0.3.pre1.
I added the following additional commits from 3.0.3.pre1:
    * https://github.com/ruby/psych/pull/356
    * https://github.com/ruby/psych/pull/357
    * https://github.com/ruby/psych/pull/359

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63280 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-28 01:47:58 +00:00
nobu 13dc8e4ef0 mjit_config.h: expand min header name
* Makefile.in, win32/Makefile.sub (mjit_config.h): expand min
  header name, including the version number and the suffix.

* mjit.c (init_header_filename): the version number and the suffix
  are now included in the header name.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63279 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-28 01:45:52 +00:00
kou 1d67b9de28 rexml: disable XPath 1.0 compatible "#{ELEMENT_NAME}" processing by default
It breaks backward compatibility than I thought. So it's disabled by
default. It means that REXML's XPath processor isn't compatible with
XPath 1.0. But it will be acceptable for users.

We can enable it by specifying "strict: true" to
REXML::XPathParser.new explicitly.

* lib/rexml/xpath.rb,
  lib/rexml/xpath_parser.rb: Accept "strict: true" option.

* test/rexml/test_contrib.rb,
  test/rexml/xpath/test_base.rb: Use not XPath 1.0 compatible behavior.

* test/rexml/test_jaxen.rb: Use XPath 1.0 compatible behavior.

* test/rss/test_1.0.rb,
  test/rss/test_dublincore.rb,
  spec/ruby/library/rexml/element/namespace_spec.rb,
  spec/ruby/library/rexml/element/namespaces_spec.rb,
  spec/ruby/library/rexml/element/prefixes_spec.rb: Enable again.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63278 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-28 01:36:18 +00:00
svn 75f4f699fd * 2018-04-28
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63277 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-27 20:25:50 +00:00
stomar 743c6edd32 NEWS: fix typos
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63276 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-27 20:25:49 +00:00
nobu 0dd9f7cc5c iseq.c: consistent rb_bug messages
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63275 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-27 13:14:09 +00:00
nobu e858f8655a mjit.c: remove undef
* mjit.c (clean_so_file): removed unnecessary undef of `Sleep`
  which is redfined as rb_w32_sleep.  eventually, retry loop with
  sleep has been removed.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63274 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-27 13:14:08 +00:00
nobu fa7fa92870 mjit.c: clean so file on Windows
* mjit.c (dlclose): use FreeLibrary to manage the reference count
  on the loaded module properly.

* mjit.c (clean_so_file): clean shared object file after unloaded,
  in-use files cannot be removed on Windows.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63273 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-27 07:39:00 +00:00
nobu ea631cc184 mjit.c: fix cc arguments
* mjit.c (CC_LIBS): MJIT_LIBS is used only on Windows.

* mjit.c (compile_c_to_so): moved source and shared object files
  to simplify indexes.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63272 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-27 05:20:40 +00:00
nobu 6dafb4c910 ruby.c: moved libdir
* ruby.c (ruby_init_loadpath_safe): moved libdir name inside
  LOAD_RELATIVE.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63271 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-27 05:20:40 +00:00
nobu 4eb2c1e121 ruby.c: fix compilation error
* ruby.c (ruby_init_loadpath_safe): fix compilation error when
  ENABLE_MULTIARCH but not universal binary.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63270 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-27 04:36:34 +00:00
nobu 67800ea9c7 mjit.c: prefix and archdir in init
* ruby.c (ruby_init_loadpath_safe): store prefix and archlibdir
  paths.

* mjit.c (compile_c_to_so, init_header_filename): use just one
  library path on Windows.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63269 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-27 02:02:29 +00:00
nobu 9ce0a84640 rbinstall.rb: fix timing to read stub
* tool/rbinstall.rb ($script_installer.stub): read stub file on
  demand.  as `$cmdtype` is set to "exe" in parse_args, it is not
  set yet when `$script_installer` is defined.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63268 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-27 01:58:29 +00:00
tenderlove c03f86b389 Revert "Fix use of `rb_profile_frames` start parameter"
This reverts commit r63265.

ko1 said I should not have committed this! I'm sorry!

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63267 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-27 00:13:51 +00:00
svn 707cbe6f99 * 2018-04-27
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63266 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-26 22:49:01 +00:00
tenderlove d676ad1050 Fix use of `rb_profile_frames` start parameter
rb_profile_frames was always behaving as if the value given for the
start parameter was 0.

The reason for this was that it would check if (start > 0) { then
continue without updating the control frame pointer or anything other
than decrementing start.

[ruby-core:86147] [Bug #14607]

Co-authored-by: Dylan Thacker-Smith <Dylan.Smith@shopify.com>

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63265 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-26 22:49:00 +00:00
nobu 81f02142b8 win32/Makefile.sub: LIBDIR_BASENAME
* mjit.c (init_header_filename): support LIBDIR_BASENAME.

* win32/Makefile.sub (config.h): ditto.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63264 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-26 12:36:27 +00:00
nobu 8036af48a5 ruby.c (ruby_init_loadpath_safe): constify
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63263 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-26 12:36:26 +00:00
svn 4ac7702814 * 2018-04-26
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63262 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-26 00:12:36 +00:00
nobu b7d260f185 test_numeric.rb: loose precision assertion
* test/ruby/test_numeric.rb (TestNumeric#test_step): remove a
  loose precision assertion, as Float cannot keep complete
  precision.  [ruby-core:86684] [Bug #14712]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63261 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-26 00:12:35 +00:00
kazu 6509c1781c [DOC] Fix capitallizing [ci skip]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63260 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-25 14:00:47 +00:00
nobu 27e972854c common.rb: unused constant
* lib/uri/common.rb (URI::HTML5ASCIIINCOMPAT): remove the constant
  which has been unused since r40460, and wrong since r49069 due
  to the operator precedence.  [ruby-core:86678] [Bug #14711]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63259 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-25 11:56:58 +00:00
eregon 512041bf62 Avoid "should_not raise_error" in Thread#raise spec
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63258 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-25 08:16:09 +00:00
eregon 9498d66c5d Fix style in Thread#raise spec
* Add space after { and before }.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63257 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-25 08:15:58 +00:00
eregon 66058dd546 Use Thread.pass in loop{} to check interrupts more often
* The spec now runs in ~5ms vs ~100ms before.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63256 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-25 08:11:01 +00:00
nobu 067066fc9b compile.c: fix unconditional branch optimization
* compile.c (iseq_peephole_optimize): add dummy `putnil` after a
  `jump` replacing an unconditional branch, to adjust removed
  `dup`.  [ruby-core:86666] [Bug #14708]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63255 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-25 06:45:05 +00:00
svn b768dc2207 * 2018-04-25
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63254 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-24 20:32:00 +00:00
normal acbbf8b0ca eval.c (ruby_setup): disable THP on Linux
Transparent Huge Pages (THP) decrease the effectiveness of
CoW-friendly GC because it decreases page granularity.  That is,
a forked process dirtying one bit of CoW-shared memory can
trigger a copy of a huge page (2MB on x86-64) instead of a smaller,
standard page (4K).

* eval.c (ruby_setup): disable THP on Linux
  [ruby-core:86651] [Feature #14705]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63253 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-24 20:31:59 +00:00
nobu 2c8f16e6c0 string.c: fix scanned substring with `\K`
* string.c (scan_once): fix the matched substring with `\K`, the
  beginning of that string may differ from the matched position.
  [ruby-core:86663] [Bug #14707]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63252 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-24 12:25:46 +00:00
nobu 3471d0f6d6 rescue Errno::EPROTOTYPE
* test/webrick/test_httpserver.rb (test_gigantic_request_header):
  Errno::EPROTOTYPE is sometimes raised on Mac OS X 10.10.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63251 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-23 23:46:26 +00:00
svn 6c4cab00cd * 2018-04-24
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63250 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-23 16:20:46 +00:00
k0kubun f84efbaa0f revert r63212
except test_jit.rb.

In some situations, this generates a wrong code. I'll add a test for it
later but let me revert this to make it work for now.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63249 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-23 16:20:45 +00:00
nobu 4cae5353c0 compile.c: copy a short insn with leave
* compile.c (iseq_peephole_optimize): copy not only `leave`, with
  a non-operand instruction, which are not longer than `jump`.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63248 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-23 12:51:18 +00:00
kazu 425118b898 [DOC] URI::Generic#port returns Integer [ci skip]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63247 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-23 12:09:21 +00:00
nobu c6ad7a6272 compile.c: insn before pop
* compile.c (iseq_peephole_optimize): more eliminatable
  instructions before `pop` without side effects.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63246 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-23 09:52:23 +00:00
normal 87ca4f3065 test/ruby/test_io.rb: add extra Thread#join to delay close
Maybe this fixes some CI failures.  Also, use different timeouts
for each item for hopefully easier diagnosis.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63245 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-23 05:54:06 +00:00
nobu 1222560ad1 thread_pthread.c: fallback to CLOCK_REALTIME
* thread_pthread.c (Init_native_thread): fallback to the default
  CLOCK_REALTIME when failed to set to CLOCK_MONOTONIC, e.g. on
  Solaris.  [Misc #14497]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63244 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-23 02:07:11 +00:00
normal c4056a4a70 net/imap: set SO_KEEPALIVE on TCP sockets
Otherwise connections (commonly on IDLE, but it could be any
command) may never receive notifications of link errors.

[ruby-core:86628] [Feature #14703]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63243 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-22 21:21:06 +00:00
stomar 75e5a91e92 sprintf.c: fix typo
* sprintf.c: [DOC] fix typo.
  Patch by Lazarus Lazaridis (iridakos).  [Fix GH-1789]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63242 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-22 19:41:06 +00:00
ko1 532464d178 Same as the last commit (comment out tests for CI).
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63241 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-22 16:33:49 +00:00
svn fdf2764e2a * 2018-04-23
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63240 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-22 16:03:10 +00:00
ko1 dd45691dbc Skip some tests to make CI healthy.
r63236 (or r63237) introduces test failures and CI shows errors.
This commit makes skipping these tests.  Please revert this commit
after tests (and rubyspec) work fine.

Failure log example:
https://gist.github.com/ko1/8456cf25fe35a696bd33ac86135092e4


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63239 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-22 16:03:09 +00:00