mirror of
https://github.com/MariaDB/server.git
synced 2025-01-17 12:32:27 +01:00
Fixed compiler optimization problem with doubleget()
(Casused problems in GIS functions in 4.1) include/global.h: Fixed compiler optimization problem with doubleget()
This commit is contained in:
parent
cd554e9ed6
commit
b5965dbded
1 changed files with 5 additions and 2 deletions
|
@ -795,8 +795,11 @@ typedef union {
|
|||
double v;
|
||||
long m[2];
|
||||
} doubleget_union;
|
||||
#define doubleget(V,M) { ((doubleget_union *)&V)->m[0] = *((long*) M); \
|
||||
((doubleget_union *)&V)->m[1] = *(((long*) M)+1); }
|
||||
#define doubleget(V,M) \
|
||||
{ doubleget_union _tmp; \
|
||||
_tmp.m[0] = *((long*)(M)); \
|
||||
_tmp.m[1] = *(((long*) (M))+1); \
|
||||
(V) = _tmp.v; }
|
||||
#define doublestore(T,V) { *((long *) T) = ((doubleget_union *)&V)->m[0]; \
|
||||
*(((long *) T)+1) = ((doubleget_union *)&V)->m[1]; }
|
||||
#define float4get(V,M) { *((long *) &(V)) = *((long*) (M)); }
|
||||
|
|
Loading…
Reference in a new issue