delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2002/05/05/20:14:58

Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com
To: "Billinghurst, David (CRTS)" <David DOT Billinghurst AT riotinto DOT com>
Cc: <java AT gcc DOT gnu DOT org>, <cygwin AT cygwin DOT com>
Subject: Re: Object alignment, was: cygwin failures - assertion "!(addr & FLAGS)" failed:
References: <FAC87D7C874EAB46A847604DA4FD5A6403470E AT crtsmail DOT corp DOT riotinto DOT org>
From: Tom Tromey <tromey AT redhat DOT com>
Reply-To: tromey AT redhat DOT com
X-Attribution: Tom
X-Zippy: What I want to find out is -- do parrots know much about Astro-Turf?
Date: 05 May 2002 18:23:43 -0600
In-Reply-To: "Billinghurst, David's message of "Mon, 6 May 2002 09:49:31 +1000"
Message-ID: <87n0vedsz4.fsf@creche.redhat.com>
Lines: 27

>>>>> "David" == Billinghurst, David (CRTS) <David DOT Billinghurst AT riotinto DOT com> writes:

David> So we need objects to be 8-byte aligned so that the low three
David> bits of the address are 0?  Are there any ways around this, as
David> I don't think that this is the default on cygwin.

For libgcj this decision is made either by the GC (for dynamically
allocated objects) or the compiler (for statically allocated objects).

The GC should already be doing this.

The compiler might not, but that is something that, in theory, we can
fix entirely in gcj by setting the required alignment correctly.
Unless...

David>  - it is necessary to rebuild ld to ensure 8-byte alignment

... there is some problem getting ld to do this even when gcj sets the
alignment correctly on the type.

It looks like the alignment is in fact set correctly in gcj:

  /* Hash synchronization requires at least 64-bit alignment. */
  if (flag_hash_synchronization && POINTER_SIZE < 64)
    DECL_ALIGN (decl) = 64; 

Tom

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019