This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug ada/41675] GNAT rejects type with 64 bits, claiming it has 65 bits
- From: "dirk dot herrmann-privat at gmx dot de" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 5 Dec 2009 11:25:03 -0000
- Subject: [Bug ada/41675] GNAT rejects type with 64 bits, claiming it has 65 bits
- References: <bug-41675-18212@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #2 from dirk dot herrmann-privat at gmx dot de 2009-12-05 11:25 -------
Hello,
thanks for considering the bug.
I checked that the maximum value that could be stored in scalars of type T
would be 0xFF80000000000000. Thus, a representation within 64 bits is
possible.
I have also taken a look at the AARM, where in section 13.3 "Operational and
Representation Attributes"
(http://www.adaic.com/standards/1zaarm/html/AA-13-3.html) paragraphs 54 and 55
it says:
54 {recommended level of support (Size attribute) [partial]} The recommended
level of support for the Size attribute of subtypes is:
55 * The Size (if not specified) of a static discrete or fixed point subtype
should be the number of bits needed to represent each value belonging to the
subtype using an unbiased representation, leaving space for a sign bit only if
the subtype contains negative values. If such a subtype is a first subtype,
then an implementation should support a specified Size for it that reflects
this representation.
So, it may not be a bug, but as I understand it, it would at least be against
the recommendation from the AARM.
Best regards,
Dirk
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=41675