Commit | Line | Data |
---|---|---|
7f918cf1 CE |
1 | diff -Naur gdtoa.0/arithchk.c gdtoa.1/arithchk.c |
2 | --- gdtoa.0/arithchk.c 2016-02-18 20:37:07.000000000 +0000 | |
3 | +++ gdtoa.1/arithchk.c 2018-01-25 20:47:16.000000000 +0000 | |
4 | @@ -46,7 +46,7 @@ | |
5 | union { | |
6 | double d; | |
7 | long L[2]; | |
8 | - } u; | |
9 | + } __attribute__((__may_alias__)) u; | |
10 | struct { | |
11 | double d; | |
12 | long L; | |
13 | @@ -73,7 +73,7 @@ | |
14 | union { | |
15 | double d; | |
16 | int L[2]; | |
17 | - } u; | |
18 | + } __attribute__((__may_alias__)) u; | |
19 | struct { | |
20 | double d; | |
21 | int L; | |
22 | @@ -100,7 +100,7 @@ | |
23 | union { | |
24 | double d; | |
25 | long L; | |
26 | - } u; | |
27 | + } __attribute__((__may_alias__)) u; | |
28 | long Cray1; | |
29 | ||
30 | /* Cray1 = 4617762693716115456 -- without overflow on non-Crays */ | |
31 | diff -Naur gdtoa.0/gdtoaimp.h gdtoa.1/gdtoaimp.h | |
32 | --- gdtoa.0/gdtoaimp.h 2016-02-19 18:37:41.000000000 +0000 | |
33 | +++ gdtoa.1/gdtoaimp.h 2018-01-25 20:47:16.000000000 +0000 | |
34 | @@ -299,7 +299,7 @@ | |
35 | Exactly one of IEEE_8087, IEEE_MC68k, VAX, or IBM should be defined. | |
36 | #endif | |
37 | ||
38 | -typedef union { double d; ULong L[2]; } U; | |
39 | +typedef union { double d; ULong L[2]; } __attribute__((__may_alias__)) U; | |
40 | ||
41 | #ifdef IEEE_8087 | |
42 | #define word0(x) (x)->L[1] | |
43 | diff -Naur gdtoa.0/qnan.c gdtoa.1/qnan.c | |
44 | --- gdtoa.0/qnan.c 2016-02-19 04:23:34.000000000 +0000 | |
45 | +++ gdtoa.1/qnan.c 2018-01-25 20:47:16.000000000 +0000 | |
46 | @@ -89,7 +89,7 @@ | |
47 | unsigned short u[5]; | |
48 | long double D; | |
49 | #endif | |
50 | - } U; | |
51 | + } __attribute__((__may_alias__)) U; | |
52 | U a, b, c; | |
53 | #ifdef Gen_ld_QNAN | |
54 | int i; | |
55 | diff -Naur gdtoa.0/strtodnrp.c gdtoa.1/strtodnrp.c | |
56 | --- gdtoa.0/strtodnrp.c 2016-02-19 04:38:18.000000000 +0000 | |
57 | +++ gdtoa.1/strtodnrp.c 2018-01-25 20:47:16.000000000 +0000 | |
58 | @@ -48,7 +48,7 @@ | |
59 | ULong bits[2]; | |
60 | Long exp; | |
61 | int k; | |
62 | - union { ULong L[2]; double d; } u; | |
63 | + union { ULong L[2]; double d; } __attribute__((__may_alias__)) u; | |
64 | ||
65 | k = strtodg(s, sp, &fpi, &exp, bits); | |
66 | switch(k & STRTOG_Retmask) { | |
67 | diff -Naur gdtoa.0/strtof.c gdtoa.1/strtof.c | |
68 | --- gdtoa.0/strtof.c 2016-02-19 05:05:40.000000000 +0000 | |
69 | +++ gdtoa.1/strtof.c 2018-01-25 20:47:16.000000000 +0000 | |
70 | @@ -42,7 +42,7 @@ | |
71 | ULong bits[1]; | |
72 | Long exp; | |
73 | int k; | |
74 | - union { ULong L[1]; float f; } u; | |
75 | + union { ULong L[1]; float f; } __attribute__((__may_alias__)) u; | |
76 | #ifdef Honor_FLT_ROUNDS | |
77 | #include "gdtoa_fltrnds.h" | |
78 | #else | |
79 | diff -Naur gdtoa.0/strtopdd.c gdtoa.1/strtopdd.c | |
80 | --- gdtoa.0/strtopdd.c 2016-02-19 04:40:59.000000000 +0000 | |
81 | +++ gdtoa.1/strtopdd.c 2018-01-25 20:47:16.000000000 +0000 | |
82 | @@ -49,7 +49,7 @@ | |
83 | typedef union { | |
84 | double d[2]; | |
85 | ULong L[4]; | |
86 | - } U; | |
87 | + } __attribute__((__may_alias__)) U; | |
88 | U *u; | |
89 | #ifdef Honor_FLT_ROUNDS | |
90 | #include "gdtoa_fltrnds.h" |