diff --git a/ChangeLog b/ChangeLog index afd3d56373..32ed3e9787 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,11 @@ +Sat Jul 26 17:22:14 2014 URABE Shyouhei + + * ext/objspace/objspace_dump.c (dump_append): avoid fflush. + + because dump_append_string_value() iterates over each chars, + fflush()-ing here effectively issues system calls on every single + bytes exist in a ruby process. + Sat Jul 26 16:55:18 2014 Eric Wong * iseq.h (struct iseq_compile_data_storage): reduce overhead diff --git a/ext/objspace/objspace_dump.c b/ext/objspace/objspace_dump.c index 076d4fbaa1..e13cc39a6c 100644 --- a/ext/objspace/objspace_dump.c +++ b/ext/objspace/objspace_dump.c @@ -43,7 +43,6 @@ dump_append(struct dump_config *dc, const char *format, ...) if (dc->stream) { vfprintf(dc->stream, format, vl); - fflush(dc->stream); } else if (dc->string) rb_str_vcatf(dc->string, format, vl);