From cbb79f0472c4d5fa663033a46c34c6102cbb0e23 Mon Sep 17 00:00:00 2001 From: normal Date: Tue, 28 Oct 2014 18:39:45 +0000 Subject: signal.c: avoid repeated disable/enable interrupt We only install system-level signal handlers during init (before any threads or user code is running), so there's no need to repeatedly enable/disable the interrupts at that time. We also do not change system-level sig handlers once user-level code is running. This saves about 20 syscalls at startup and makes the executable smaller (numbers from 32-bit x86): text data bss dec hex filename before: 2815726 12100 30552 2858378 2b9d8a ruby after: 2815022 12100 30552 2857674 2b9aca ruby * signal.c (install_sighandler): remove rb_disable_interrupt and rb_enable_interrupt calls (init_sigchld): ditto (Init_signal): disable and enable interrupt once around all install_sighandler and init_sigchld to reduce syscalls at start [Feature #9345] [ruby-core:59480] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48178 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- ChangeLog | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'ChangeLog') diff --git a/ChangeLog b/ChangeLog index 5c2e2ab23a..86b66cf0cb 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,12 @@ +Tue Oct 28 16:52:07 2014 Eric Wong + + * signal.c (install_sighandler): remove rb_disable_interrupt and + rb_enable_interrupt calls + (init_sigchld): ditto + (Init_signal): disable and enable interrupt once around all + install_sighandler and init_sigchld to reduce syscalls at start + [Feature #9345] [ruby-core:59480] + Tue Oct 28 16:22:41 2014 Nobuyoshi Nakada * ruby.c (process_options, load_file_internal2): should not -- cgit v1.2.3