From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 28059 invoked by alias); 30 Jun 2006 19:01:35 -0000 Received: (qmail 27750 invoked by uid 48); 30 Jun 2006 19:01:22 -0000 Date: Fri, 30 Jun 2006 19:04:00 -0000 Message-ID: <20060630190122.27749.qmail@sourceware.org> X-Bugzilla-Reason: CC References: Subject: [Bug java/22299] Even length strings (not odd) placed in .section .rodata.jutf8.# at -O1 or above. In-Reply-To: Reply-To: gcc-bugzilla@gcc.gnu.org To: gcc-bugs@gcc.gnu.org From: "mckinlay at redhat dot com" Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org X-SW-Source: 2006-06/txt/msg02624.txt.bz2 List-Id: ------- Comment #1 from mckinlay at redhat dot com 2006-06-30 19:01 ------- The sizes of the constant-merging sections must be a multiple of the alignment of their contents. UtfConsts have 2-byte alignment, so odd-sized strings are rounded up and go in the next-sized bucket. So, it is correct for "ODD" and "XXXX" to both go in .rodata.jutf8.8, which is what is happening here. Constant merging is not performed below -O1. -- mckinlay at redhat dot com changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |mckinlay at redhat dot com Status|UNCONFIRMED |RESOLVED Resolution| |WORKSFORME http://gcc.gnu.org/bugzilla/show_bug.cgi?id=22299