comp.lang.ada
 help / color / mirror / Atom feed
From: Magnus Ericson <emwmei@kiemw.ericsson.se>
Cc: emwmei
Subject: Re: Record rep-clauses
Date: 1996/01/09
Date: 1996-01-09T00:00:00+00:00	[thread overview]
Message-ID: <30F2C048.5935@kiemw.ericsson.se> (raw)
In-Reply-To: dewar.821114082@schonberg

Robert Dewar wrote:
> This is too vague, these endian questions can be very confusing, and there
> are at least three quite different problems that the above question might
> be referring to. Magnus, can you be very precise in exactly what you are
> trying to do, and we will try to help!

I am working in a project where we need to define a protocol on two
machines, one of them is a Motorola 68040 and the other is a Pentium PC. We
have started to write rep-clauses for the Motorola machine and realized how
difficult it will be to make and maintain a parallell package with
declarations and rep-specs with all bits reversed etc for the Intel 
machine. The questions are what coding-techniques that can be used to make
this as "painles" as possible. 

Can you please elaborate on what "three" problems that you are thinking about?
Since the protocol is packed tightly (possibly crossing storage unit
boundaries) I (unfortunatly) suspect that all of them might apply...

One posibility for us (that I actually like a lot) is to describe the messages
of the protocol in for instance a relational data base and then write a piece 
of code that auto-generate the record declarations and rep-specs for both the
Intel and Motorola machine from this description.
In this case no measures need to be taken to simplify the maintanence of
the two parallell packages but other language issues might still apply!

Hope this is specific enough, I am trying to learn a bit more about this
issue before finding the problems "the hard way"...

When it comes to Ada 95 I am not sure if all of the new pragmas about 
bit-ordering are informational only or if it actually is possible to select
what bit-numbering scheme that is used by the copmiler when interpreting
rep-clauses? 

Regards
Magnus Ericson  
-- 
Magnus Ericson M.Sc, Ericsson Microwave Systems
Torshamnsgatan 32C, S-164 84 STOCKHOLM
Tel: +46 8 757 35 38 Fax: +46 8 750 74 42
Disclaimer: "The opinions expressed here are my own,
             and not those of my employer."




      reply	other threads:[~1996-01-09  0:00 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <30F1418B.33CB@kiemw.ericsson.se>
1996-01-08  0:00 ` Record rep-clauses Robert A Duff
1996-01-08  0:00   ` Robert Dewar
1996-01-09  0:00     ` Magnus Ericson [this message]
replies disabled

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