From: Tom Tromey Date: Tue, 15 Apr 2003 02:17:12 +0000 (+0000) Subject: resolve.cc (_Jv_PrepareClass): Round up class size to multiple of alignment. X-Git-Tag: releases/gcc-3.4.0~7287 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=355d89939212294d4b0d1cf9bc3cd806eb6d7a84;p=thirdparty%2Fgcc.git resolve.cc (_Jv_PrepareClass): Round up class size to multiple of alignment. * resolve.cc (_Jv_PrepareClass): Round up class size to multiple of alignment. From-SVN: r65617 --- diff --git a/libjava/ChangeLog b/libjava/ChangeLog index d4403ef6ad4e..8d9944d4c85f 100644 --- a/libjava/ChangeLog +++ b/libjava/ChangeLog @@ -1,3 +1,8 @@ +2003-04-14 Tom Tromey + + * resolve.cc (_Jv_PrepareClass): Round up class size to multiple + of alignment. + 2003-04-10 Tom Tromey * verify.cc (pop64): Removed. diff --git a/libjava/resolve.cc b/libjava/resolve.cc index ea506452d583..fbdc284945f9 100644 --- a/libjava/resolve.cc +++ b/libjava/resolve.cc @@ -513,7 +513,10 @@ _Jv_PrepareClass(jclass klass) } } - // set the instance size for the class + // Set the instance size for the class. Note that first we round it + // to the alignment required for Object; this keeps us in sync with + // our current ABI. + instance_size = ROUND (instance_size, __alignof__ (java::lang::Object)); clz->size_in_bytes = instance_size; // allocate static memory