* Data Type sizes question
@ 2002-10-29 1:24 John Lu
2002-10-29 7:07 ` Fergus Henderson
0 siblings, 1 reply; 2+ messages in thread
From: John Lu @ 2002-10-29 1:24 UTC (permalink / raw)
To: gcc
Hi,
I'm working on an architecture that supports 16-bit,
32-bit, and 40-bit data. I am trying to support the following data
types on the archtiecture:
int -> QImode, 16-bits
long -> HImode, 32-bits
long long -> SImode, 40-bits ??????
These sizes were set by defining INT_TYPE_SIZE, LONG_TYPE_SIZE
and LONG_LONG_TYPE_SIZE appropriately. Is this feasible with gcc?
I have a compiler with just the 16-bit and 32-bit sizes working fine.
When I try to add the "long long" type, the SImode instructions are
used for 64-bit structures. GCC seems to think that the SImode
supports 64-bit data (which I guess is reasonable). Is there a way
to prevent GCC from doing this?
Thanks,
John Lu
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: Data Type sizes question
2002-10-29 1:24 Data Type sizes question John Lu
@ 2002-10-29 7:07 ` Fergus Henderson
0 siblings, 0 replies; 2+ messages in thread
From: Fergus Henderson @ 2002-10-29 7:07 UTC (permalink / raw)
To: John Lu; +Cc: gcc
On 28-Oct-2002, John Lu <jlu@lsil.com> wrote:
> I'm working on an architecture that supports 16-bit,
> 32-bit, and 40-bit data. I am trying to support the following data
> types on the archtiecture:
>
> int -> QImode, 16-bits
> long -> HImode, 32-bits
> long long -> SImode, 40-bits ??????
This is a bad idea. The ISO C standard guarantees that "long long"
will be at least 64 bits.
--
Fergus Henderson <fjh@cs.mu.oz.au> | "I have always known that the pursuit
The University of Melbourne | of excellence is a lethal habit"
WWW: <http://www.cs.mu.oz.au/~fjh> | -- the last words of T. S. Garp.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2002-10-29 3:05 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-10-29 1:24 Data Type sizes question John Lu
2002-10-29 7:07 ` Fergus Henderson
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).