comp.lang.ada
 help / color / mirror / Atom feed
From: Kilgallen@SpamCop.net (Larry Kilgallen)
Subject: Re: Size and pack
Date: 29 Oct 2001 04:29:42 -0600
Date: 2001-10-29T04:29:42-06:00	[thread overview]
Message-ID: <xSlQNRG4wlOM@eisner.encompasserve.org> (raw)
In-Reply-To: slrn9tq9mi.nt.lutz@taranis.iks-jena.de

In article <slrn9tq9mi.nt.lutz@taranis.iks-jena.de>, lutz@iks-jena.de (Lutz Donnerhacke) writes:
> * tmoran@acm.org wrote:
>>> >           Log_Num      at 5 range 0 .. 31;
>>> >           End_Byte     at 9 range 0 .. 7;
>>> >           LRC          at 10 range 0 .. 7;
>>> >        end record;
>>> >     for Rx_Header_Data'size use 8*11;
>>>
>>> The problem was that this rep clause will not work, because Log_Num must
>>> be aligned to a 4-byte boundary.  Some compilers will silently ignore your
>>> rep clause, I believe GNAT will tell you it can't do it.
>>
>>  I tested it on Gnat 3.13p on Windows before posting, and Gnat was
>>perfectly happy with it.  And ARM 13.5.1(23) says that "If component
>>clauses are given for all components, the record representation clause
>>completely specifies the representation of the type and will be obeyed
>>exactly by the implementation."  That seems pretty unambiguous to me.
> 
> Compile on Alpha and get BUS ERROR.

Presumably that is a runtime rather than compilation time error.

You didn't say what model of Alpha, but older chips require
certain instructions be aligned.  VMS deals with this through
alignment fault handlers that fix up such problems at a penalty
of about 100 instructions.  Perhaps you are on Unix or Linux
(you didn't say in the body text).  If so, look at your compiler
instructions for something regarding which Alpha chip you are
targeting.  Specify an older chip and the resulting code should
work on all.



  reply	other threads:[~2001-10-29 10:29 UTC|newest]

Thread overview: 51+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-10-10  8:05 Size and pack Adrian Hoe
2001-10-10  8:59 ` Alfred Hilscher
2001-10-10  9:50   ` John McCabe
2001-10-11  6:36     ` Adrian Hoe
2001-10-11  8:55       ` John McCabe
2001-10-31  1:53         ` Robert Dewar
2001-10-31  1:50     ` Robert Dewar
2001-10-31  9:17       ` John McCabe
2001-10-31 11:58       ` Jeff Creem
2001-11-01  1:58         ` Adrian Hoe
2001-11-01  2:34           ` Jeff Creem
2001-11-01 14:58             ` Marin David Condic
2001-11-01  3:53           ` Matthew Heaney
2001-11-01 18:37             ` Jeff Creem
2001-11-02  3:39               ` Robert Dewar
2001-11-01  3:45         ` Jeffrey Carter
2001-11-01  6:00         ` Robert Dewar
2001-10-10  9:24 ` Pi
2001-10-10  9:27 ` Lutz Donnerhacke
2001-10-11  6:24   ` Adrian Hoe
2001-10-11  8:58     ` John McCabe
2001-10-11 13:20       ` Mark Johnson
2001-10-11 16:23         ` John McCabe
2001-10-11 16:00           ` Pat Rogers
2001-10-12  8:37             ` John McCabe
2001-10-28  1:30         ` Robert Dewar
2001-10-11  9:30     ` Lutz Donnerhacke
2001-10-11 10:12 ` Vincent Smeets
2001-10-11 10:19   ` Lutz Donnerhacke
2001-10-11 11:18     ` David C. Hoos, Sr.
2001-10-11 12:06       ` Lutz Donnerhacke
2001-10-11 13:49 ` Ted Dennison
2001-10-26  4:00 ` Smark
2001-10-26  6:14   ` tmoran
2001-10-26 17:51     ` Smark
2001-10-26 23:21       ` Jeffrey Carter
2001-10-26 23:39       ` tmoran
2001-10-29  1:01         ` Adrian Hoe
2001-10-29  2:21           ` tmoran
2001-10-29 10:42             ` Adrian Hoe
2001-10-29 23:15               ` tmoran
2001-10-29  9:52         ` Lutz Donnerhacke
2001-10-29 10:29           ` Larry Kilgallen [this message]
2001-10-29 10:50             ` Lutz Donnerhacke
2001-10-29 11:12               ` Larry Kilgallen
2001-10-31  2:02                 ` Robert Dewar
2001-10-31  2:00               ` Robert Dewar
2001-10-31  2:51                 ` Larry Kilgallen
2001-10-31  1:59           ` Robert Dewar
2001-10-31  1:57       ` Robert Dewar
2001-10-31  1:55   ` Robert Dewar
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox