From 2db572514cd9f5cc8957ab8f35f39650bb243ea7 Mon Sep 17 00:00:00 2001 From: mame Date: Thu, 17 Jun 2010 14:32:20 +0000 Subject: * load.c (rb_load_internal): remove call to rb_realpath_internal within rb_load_internal which caused big performance degradation. Instead, call rb_realpath_internal in the caller of rb_load_internal. [ruby-dev:41502] [ruby-dev:41610] * vm.c (rb_vm_call_cfunc): ditto. * eval_intern.h (rb_vm_call_cfunc): ditto. * ruby.c (process_options): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@28351 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- iseq.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'iseq.c') diff --git a/iseq.c b/iseq.c index 48d0cdfcb9..ae45884578 100644 --- a/iseq.c +++ b/iseq.c @@ -228,7 +228,7 @@ prepare_iseq_build(rb_iseq_t *iseq, iseq->name = name; iseq->filename = filename; - iseq->filepath = filepath == Qnil ? Qnil : rb_realpath_internal(Qnil, filepath, 1); + iseq->filepath = filepath; iseq->line_no = (unsigned short)line_no; /* TODO: really enough? */ iseq->defined_method_id = 0; iseq->mark_ary = rb_ary_tmp_new(3); @@ -606,7 +606,8 @@ iseq_s_compile_file(int argc, VALUE *argv, VALUE self) parser = rb_parser_new(); node = rb_parser_compile_file(parser, fname, f, NUM2INT(line)); make_compile_option(&option, opt); - return rb_iseq_new_with_opt(node, rb_str_new2("
"), file, file, line, Qfalse, + return rb_iseq_new_with_opt(node, rb_str_new2("
"), file, + rb_realpath_internal(Qnil, file, 1), line, Qfalse, ISEQ_TYPE_TOP, &option); } -- cgit v1.2.1