From: normalperson@... Date: 2014-01-22T20:53:25+00:00 Subject: [ruby-core:59993] [ruby-trunk - Feature #9441] [Open] [PATCH] method.h: save 8 bytes in rb_method_definition_t on x86-64 Issue #9441 has been reported by Eric Wong. ---------------------------------------- Feature #9441: [PATCH] method.h: save 8 bytes in rb_method_definition_t on x86-64 https://bugs.ruby-lang.org/issues/9441 * Author: Eric Wong * Status: Open * Priority: Normal * Assignee: * Category: core * Target version: current: 2.2.0 ---------------------------------------- Rearranging the struct to have two 32-bit values next to each other allows the struct to be one word smaller on 64-bit. This lowers overall memory use as we have many methods out-of-the box: $ /usr/bin/time ./ruby -e exit 0.06user 0.00system 0:00.07elapsed 98%CPU (0avgtext+0avgdata 7420maxresident)k 0inputs+0outputs (0major+1930minor)pagefaults 0swaps $ /usr/bin/time ./ruby -e exit 0.06user 0.00system 0:00.07elapsed 98%CPU (0avgtext+0avgdata 7372maxresident)k 0inputs+0outputs (0major+1918minor)pagefaults 0swaps ---------------------------------------------------------------- The following changes since commit 06d2e8aaf7fe60a09245963f2f69feb5685db8f0: thread/thread.c: no dup (2014-01-22 06:59:41 +0000) are available in the git repository at: git://80x24.org/ruby.git mdefsize for you to fetch changes up to 3fcf1bf57d99482e9882fc8d5b3348da799c41c5: method.h: save 8 bytes in rb_method_definition_t on x86-64 (2014-01-22 20:41:17 +0000) ---------------------------------------------------------------- Eric Wong (1): method.h: save 8 bytes in rb_method_definition_t on x86-64 method.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) ---Files-------------------------------- 0001-method.h-save-8-bytes-in-rb_method_definition_t-on-x.patch (1.36 KB) -- http://bugs.ruby-lang.org/