From: Uncle George <gatgul@voicenet.com>
Subject: axp/gcc the double cast gets trashed on return ( really a GDB BUG )
Date: Tue, 07 Oct 1997 08:53:06 -0400 [thread overview]
Message-ID: <f083f067bf19e4c0fce3c8d16dd48dfd.axp-list@archive.invalid> (raw)
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 2465 bytes --]
--------------5882E66C177C4E5ED3A7EF8D
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Volker Barthelmann wrote:
> On Mon, 6 Oct 1997, Uncle George wrote:
> The code is basically broken. Reading another member of a union than the
> one which was last written causes implementation defined behaviour (IMHO
> it should even be undefined behaviour).
This is not a broken feature, but rather a porting implimentation problem. The
long on alpha is 64 bit, the double on a alpha is 64 bit. a union would make the
space ONE. in reality quite a few people do this for the exact same reasons, so
long as u understand how things are getting stored ( including packed/unpacked
structs!)
BTW. i ran the pgm without gdb, and it prints out the right contents,
I ran GDB without any breakpoints, and the printed values were correct.
BUT
running gdb, using next stepping caused the values to be mixed up. SO I GUESS
its a gdb/ptrace bug! (fudge!!!)
> --
> To unsubscribe: send e-mail to axp-list-request@redhat.com with
> 'unsubscribe' as the subject. Do not send it to axp-list@redhat.com
--------------5882E66C177C4E5ED3A7EF8D
Content-Type: text/html; charset=us-ascii
Content-Transfer-Encoding: 7bit
Volker Barthelmann wrote:
On Mon, 6 Oct 1997, Uncle George wrote:
The code is basically broken. Reading another member of a union than
the
one which was last written causes implementation defined behaviour
(IMHO
it should even be undefined behaviour).
This is not a broken feature, but rather a porting implimentation problem.
The long on alpha is 64 bit, the double on a alpha is 64 bit. a union would
make the space ONE. in reality quite a few people do this for the
exact same reasons, so long as u understand how things are getting stored
( including packed/unpacked structs!)
BTW. i ran the pgm without gdb, and it prints out the right contents,
I ran GDB without any breakpoints, and the printed
values were correct.
BUT
running gdb, using next stepping caused the
values to be mixed up. SO I GUESS its a gdb/ptrace bug! (fudge!!!)
--
To unsubscribe: send e-mail to axp-list-request@redhat.com with
'unsubscribe' as the subject. Do not send it to axp-list@redhat.com
--------------5882E66C177C4E5ED3A7EF8D--
--
To unsubscribe: send e-mail to axp-list-request@redhat.com with
'unsubscribe' as the subject. Do not send it to axp-list@redhat.com
next reply other threads:[~1997-10-07 12:53 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
1997-10-07 12:53 Uncle George [this message]
[not found] <343A30B1.CD60EA8F@voicenet.com>
1997-10-07 12:33 ` axp/gcc the double cast gets trashed on return ( really a GDB BUG ) Volker Barthelmann
read-only archive
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox