string.c: move frozen_strings table to rb_vm_t

Cleanup in case MVM development proceeds.

* string.c: remove static frozen_strings
* string.c (Init_frozen_strings): new function
* string.c (rb_fstring): remove check for frozen strings,
  use per-VM table
* string.c (rb_str_free): use per-VM table
* string.c (Init_String): use per-VM table
* vm_core.h (rb_vm_t): add frozen_strings table
* internal.h (Init_frozen_strings): new function prototype
* eval.c (ruby_setup): call Init_frozen_strings
  [Feature #10182]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47310 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* 2014-08-29

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47311 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
string.c: remove vm_core.h dependency [ruby-core:64627]

* string.c: revert part of r47311, add rb_vm_fstring_table(),
  remove vm_core.h dependency. [ruby-core:64627]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47312 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test/rinda/test_rinda.rb: removed useless assignment variables.
* test/rss/rss-assertions.rb: ditto.
* test/rss/test_maker_itunes.rb: ditto.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47313 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test/net/imap/test_imap_response_parser.rb: removed needless code.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47314 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* ext/psych/lib/psych/visitors/to_ruby.rb: quoted "<<" strings
  should not be treated as merge keys.
* ext/psych/lib/psych/visitors/yaml_tree.rb: hashes with keys
  containing "<<" should roundtrip.
* test/psych/test_merge_keys.rb: test for change. Fixes GH #203

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47315 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* 2014-08-30

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47316 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* ext/psych/lib/psych/visitors/to_ruby.rb: merge keys with a hash
  should merge the hash in to the parent.
* test/psych/test_merge_keys.rb: test for change. Fixes GH #202

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47317 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* ext/psych/lib/psych/scalar_scanner.rb: fix loading strings that
  look like integers but have a newline. Fixes GH #189
* test/psych/test_string.rb: test for fix

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47318 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* ext/psych/lib/psych/visitors/yaml_tree.rb: fix NameError dumping and
  loading. Fixes GH #85. Thanks @brentdax for the patch!
* test/psych/test_exception.rb: test for fix

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47319 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
benchmark.rb: prefer Process::CLOCK_MONOTONIC_RAW

* lib/benchmark.rb (BENCHMARK_CLOCK): prefer Process::CLOCK_MONOTONIC_RAW
  if available to more accurate measure.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47320 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
test_benchmark.rb: extend sleep time

* test/benchmark/test_benchmark.rb: extend sleep time, as 1ms is
  too short on some environments.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47321 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
symbol.c (rb_sym2id): do not return garbage object

The dynamic sym passed to rb_sym2id may be a garbage object
(as accounted for by dsymbol_check).  This fixes an occasional
segfault in "make test-all" for me.

No need to backport, this is from the new symbol GC feature.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47322 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
internal.h: WARN_UNUSED_RESULT

* internal.h (WARN_UNUSED_RESULT): warn unused result by gcc 3.4
  or later.

* symbol.c: declare some functions with WARN_UNUSED_RESULT.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47323 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
zlib: GzipReader#rewind preserves ZSTREAM_FLAG_GZFILE

* ext/zlib/zlib.c (gzfile_reset): preserve ZSTREAM_FLAG_GZFILE
  [Bug #10101]

* test/zlib/test_zlib.rb (test_rewind): test each_byte

We must preserve the ZSTREAM_FLAG_GZFILE flag to prevent
zstream_detach_buffer from:

a) returning Qnil and breaking out of the `each_byte' loop
b) yielding a large string to each_byte

Note: the test case in bug report takes a long time.  I found this
bug because I noticed the massive time descrepancy between
`each_byte' and `readbyte' loop before this patch.  With this patch,
`each_byte' and `readbyte' both take very long.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47327 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* 2014-08-31

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47328 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
test_benchmark.rb: use assert_in_epsilon

* test/benchmark/test_benchmark.rb (test_realtime_output): use
  assert_in_epsilon which compares in relative range, instead of
  assert_in_delta which compares in absolute range.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47329 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
benchmark.rb: Process::CLOCK_MONOTONIC_RAW may be unavailable

* lib/benchmark.rb (BENCHMARK_CLOCK): Process::CLOCK_MONOTONIC_RAW
  is not supported on old linux.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47330 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* lib/benchmark.rb: Fix a syntax error.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47341 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* ext/win32ole/win32ole.c (rbtime2vtdate): try to convert millisecond
  of Time object to millisecond of VT_DATE VARIANT.
* test/win32ole/test_win32ole_variant.rb
  (test_conversion_time2date_with_msec): ditto.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47343 b2dd03c8-39d4-4d8f-98ff-823fe69b080e