summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2018-01-09* properties.svn
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61732 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-09* append newline at EOF.svn
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61731 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-09[ci skip] add comments about file formatshyouhei
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61730 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-09new insns.def formatshyouhei
- Gave up @j comments - Room for sp_inc to be a proper grammer element git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61729 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-09rb_num_t happen to be unsigned; introduce signed variantshyouhei
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61728 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-09parse.y: insane syntax too (class definition in cond)mame
This change partially reverts r61724 and take another approach: exploiting struct local_vars to backup the cond_stack state. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61727 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-09Fix indent [ci skip]kazu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61726 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-09Include ruby/{io,encoding}.h before internal.hkazu
because of r61712 and r61713 git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61725 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-09parse.y: insane syntaxnobu
* parse.y (primary): save/restore COND and CMDARG stacks at method definition, to distinguish do_block and do_cond properly. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61724 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-09insns_info.inc.tmpl: split rb_vm_insn_name_infonobu
* template/insns_info.inc.tmpl (rb_vm_insn_name_info): split instruction names pool not to exceed C90 limit. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61723 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-09thread_pthread.c: round stack sizenobu
* thread_pthread.c (rb_thread_create_timer_thread): round up additional stack size to PTHREAD_STACK_MIN, to get rid of EINVAL at pthread_attr_setstacksize(). git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61722 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-09Rename code_range to code_locationmame
Because the name "code_range" is ambiguous with encoding's. Abbreviations ("crange", and "cr") are also renamed to "loc". The traditional "code_location" (a pair of lineno and column) is renamed to "code_position". Abbreviations are also renamed (first_loc to beg_pos, and last_loc to end_pos). git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61721 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-09thread_pthread: remove checks for pthread_cond*_initnormal
These were added for NaCL support in r36022, and we dropped NaCL in r60374. IMHO, any pthreads implementation without these basic functions is not worth the time to support. [ruby-core:84758] [Misc #14342] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61720 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-09thread_pthread: remove HAVE_PTHREAD_ATTR_INIT ifdefsnormal
ifdefs make code confusing for my easily-confused mind :< These were added for NaCL support in r36022, and we dropped NaCL in r60374. There are more #ifdefs to remove... [ruby-core:84758] [Misc #14342] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61719 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-09bootstraptest/test_fork.rb: Stop too restrict NPROC test temporarilymame
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61718 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-09Fix the position of VM_ASSERT for "pthread_create failed for time"mame
Fix r61706. Thank you, Eric Wong. [ruby-core:84756] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61717 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-09thread_pthread: more diagnostics around timer thread creation failuresnormal
However, I don't think EAGAIN on pthread_create can really be fixed in our code. I suspect test machines are overloaded. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61716 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-09update dependenciesnobu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61715 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-09update-deps: strip -j optionnobu
* update-deps: strip -j option from ENV['GNUMAKEFLAGS'], not dirstack to get confused by intermingled entering/leaveing directory messages. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61714 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-09internal.h: remove dependecy on ruby/encoding.hnobu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61713 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-09internal.h: remove dependecy on ruby/io.hnobu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61712 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-09compile.c (iseq_compile_each0): remove irrelevant tracecoveragemame
This change removes tracecoverage instructions on a line that has any NODE but is non-significant, such as, just one literal. This fixes the following failure that occurs only when coverage is enabled: 1) Failure: TestISeq#test_to_a_lines [.../ruby/test/ruby/test_iseq.rb:56]: <[3, 4, 7, 9]> expected but was <[3, 4, 5, 6, 7, 8, 9]>. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61711 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-09Allow `-> do rescue; end` as well as `proc do rescue; end`mame
https://twitter.com/takiuchi/status/950593389963051008 git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61710 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-09parse.y: Remove redefinition of mallocmame
Because the purpose is now unsure (maybe, to support very old bison?). If an issue occurs, it should be resurrected with explicit comment. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61709 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-09parse.y: PARSER_DEBUG is no longer usedmame
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61708 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-09parse.y: Remove meaningless ifndef guardsmame
Because the part of the code is already within `#ifndef RIPPER`. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61707 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-09Explicit failure in VM_CHECK_MODE when failing to create timer threadmame
"warning: pthread_create failed for timer: Resource temporarily unavailable, scheduling broken" still occurs randomly. This change will allow us to debug the issue. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61706 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-09common.mk (srcs_vpath): renamed for nmakenobu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61705 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-09use predefined ids in a few more placesnormal
Saves a little space on x86: text data bss dec hex filename 3684110 11968 34240 3730318 38eb8e ruby.before 3684086 11968 34240 3730294 38eb76 ruby.after * enumerator.c: include id.h, define aliases (Init_Enumeerator): remove unnecessary rb_intern calls * gc.c (should_be_callable): use idCall * vm.c (Init_VM): ditto git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61704 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-09gmake.mk: update srcdir filesnobu
* defs/gmake.mk (commit): update source files under the sources directory after commit. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61703 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-09parse.y: set ID to yylval ID instead of tokennobu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61702 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-09parse.y: Remove special handling of tOROP and tANDOPmame
The complexity is no longer considered necessary. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61701 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-09.gdbinit (print_lineno): follow up changes in r61534, r61536ktsj
insns_info was refactored. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61700 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-09parse.y: use change_shortcut_operator_idnobu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61699 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-09wrap statement expression with __extension__nobu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61698 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-09parse.y: Remove duplicated nd_line setyui-knk
* parse.y: These nodes are created with `@$` locations. Start position of `@$` is same as start position of `@1`. And NEW_XXX macros set first_loc.lineno of a passed code range to nd_line. So these nd_set_line are not needed. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61697 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-09constifiednobu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61696 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-08vm.c: remove extra ifdefnobu
* vm.c (rb_execution_context_mark): VM_ASSERT works only if VM_CHECK_MODE > 0. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61695 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-08use `getblockparamproxy` to pass blocks.ko1
* compile.c (setup_args): use `getblockparamproxy` (`rb_block_param_proxy`) to represent a block parameter passing. * vm_args.c (vm_caller_setup_arg_block): check `rb_block_param_proxy` instead of using `VM_CALL_ARGS_BLOCKARG_BLOCKPARAM` call flag. * vm_core.h (VM_CALL_ARGS_BLOCKARG_BLOCKPARAM): removed. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61694 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-08fix a bug only on assertion.ko1
* vm.c (rb_execution_context_mark): check escaped directly to skip assertions. Not sure why there is an inconsistency. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61693 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-08* 2018-01-09svn
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61692 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-08fix mark miss of Env (which is pointed by prev_ep).ko1
* vm.c (rb_execution_context_mark): r61624 and r61659 introduce marking miss bug for Env objects as a prev_ep which is contained by Proc objects because Proc objects can be collected when they should be living and Env objects will collected unexpectedly. This patch solves this problem. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61691 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-08parse.y: Make consistent with the terms about code ranges and locationsmame
"loc" was ambiguous; it might refer both a location and a code range. This change uses "loc" for a location, and "crange" or "cr" for a code range. A location (abbr. loc) is a point in a program and consists of line number and column number. A code range (abbr. crange and cr) is a range within a program and consists of a pair of locations which is the first and the last. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61690 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-08parse.y (remove_duplicate_keys): Remove a not used argumentyui-knk
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61689 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-08parse.y: Factor out code fragments that merges two code rangesmame
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61688 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-08parse.y (block_append_gen): Remove a not used argumentyui-knk
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61687 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-08parse.y: Use nd_loc of head and tailyui-knk
* parse.y (block_append_gen): Use nd_loc of head(tail) when create NEW_BLOCK of head(tail). e.g. The locations of the NODE_BLOCK is fixed: ``` BEGIN { :a } BEGIN { :b } ``` * Before ``` NODE_BLOCK (line: 5, code_range: (5,0)-(7,1)) ``` * After ``` NODE_BLOCK (line: 1, code_range: (1,0)-(7,1)) ``` git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61686 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-08parse.y: Fix the lineno of nd_set_lineyui-knk
* parse.y: Follow up of r61676. r61676 removed ruby_sourceline from some actions. When stop to use lineno of "n th" symbol, it's better to use last location's lineno of "n-1 th" symbol. e.g. ``` primary : k_begin {} bodystmt k_end ``` Before r61676 we use lineno of `@2` (ruby_sourceline). In this case, last location's lineno of `k_begin` (`@1`) is suitable. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61685 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-08net/http: clear compressed chunk after decompressionnormal
We no longer need the compressed data once the inflate block is called; so clear it ASAP to reduce memory overhead. This is a small chunk, so it only saves a few hundred kilobytes with the script below. before: RssAnon: 5976 kB after: RssAnon: 5564 kB ------ require 'net/http' require 'zlib' response_gz = ARGV.shift or abort "#$0 TEMPORARY_FILE" # pre-create response since compressing is slower than decompressing unless File.readable?(response_gz) nr = 16384 * 2 buf = ((0..255).map(&:chr).join * 128) File.open(response_gz, 'wb') do |fp| gzip = Zlib::GzipWriter.new(fp) nr.times { gzip.write(buf) } gzip.close end buf.clear end response_gz = File.open(response_gz) s = TCPServer.new('127.0.0.1', 0) pid = fork do c = s.accept c.readpartial(16384).clear c.write("HTTP/1.1 200 OK\r\n" \ "Content-Length: #{response_gz.stat.size}\r\n" \ "Content-Encoding: gzip\r\n" \ "Accept-Ranges: bytes\r\n" \ "\r\n") IO.copy_stream(response_gz, c) c.close end addr = s.addr Net::HTTP.start(addr[3], addr[1]) do |http| http.request_get(-'/') do |res| res.read_body(&:clear) end end puts File.readlines(-'/proc/self/status').grep(/RssAnon/)[0] Process.waitpid2(pid) ------ * lib/net/http/response.rb (inflate_adapter): clear compressed_chunk git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61684 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-08Update minitest-5.11.1hsbt
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61683 b2dd03c8-39d4-4d8f-98ff-823fe69b080e