ruby-changes:22332
From: nobu <ko1@a...>
Date: Fri, 27 Jan 2012 16:32:03 +0900 (JST)
Subject: [ruby-changes:22332] nobu:r34381 (trunk): * gc.c (HEAP_ALIGN, HEAP_ALIGN_MASK): DRY, let compiler calculate
nobu 2012-01-27 16:31:50 +0900 (Fri, 27 Jan 2012) New Revision: 34381 http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=34381 Log: * gc.c (HEAP_ALIGN, HEAP_ALIGN_MASK): DRY, let compiler calculate from HEAP_ALIGN_LOG. Modified files: trunk/ChangeLog trunk/gc.c Index: ChangeLog =================================================================== --- ChangeLog (revision 34380) +++ ChangeLog (revision 34381) @@ -1,3 +1,8 @@ +Fri Jan 27 16:31:45 2012 Nobuyoshi Nakada <nobu@r...> + + * gc.c (HEAP_ALIGN, HEAP_ALIGN_MASK): DRY, let compiler calculate + from HEAP_ALIGN_LOG. + Thu Jan 26 11:03:37 2012 Eric Hodel <drbrain@s...> * lib/matrix.rb: Clean up extra whitespace in output documentation. Index: gc.c =================================================================== --- gc.c (revision 34380) +++ gc.c (revision 34381) @@ -538,8 +538,8 @@ /* tiny heap size: 16KB */ #define HEAP_ALIGN_LOG 14 -#define HEAP_ALIGN 0x4000 -#define HEAP_ALIGN_MASK 0x3fff +#define HEAP_ALIGN (1UL << HEAP_ALIGN_LOG) +#define HEAP_ALIGN_MASK (~(~0UL << HEAP_ALIGN_LOG)) #define REQUIRED_SIZE_BY_MALLOC (sizeof(size_t) * 5) #define HEAP_SIZE (HEAP_ALIGN - REQUIRED_SIZE_BY_MALLOC) -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/