[ruby-cvs:60820] normal:r53659 (trunk): fstring early for internal iseq

normal at ruby-lang.org normal at ruby-lang.org
Tue Jan 26 15:23:47 JST 2016

normal	2016-01-26 15:23:47 +0900 (Tue, 26 Jan 2016)

  New Revision: 53659


    fstring early for internal iseq
    All of the strings created here eventually get converted to
    fstrings when they are frozen into the iseq.  Prepare the
    fstring early so we may reduce a one or two objects.
    This is a very minor change, mainly for the '<main>' dedupe.
    * compile.c (caller_location): use rb_fstring_cstr for "<compiled>"
      (it is converted to fstring anyways inside rb_iseq_new_with_opt)
    * iseq.c (iseqw_s_compile): ditto
    * iseq.c (rb_iseq_new_main): use rb_fstring_cstr for "<main>"
    * vm.c (Init_VM): ditto, share with with above
    * iseq.c (iseqw_s_compile_file): rb_fstring before rb_io_t->pathv
      share "<main>" with above
    * vm.c (rb_binding_add_dynavars): fstring "<temp>" immediately

  Modified files:

More information about the ruby-cvs mailing list