traverso-commit
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Traverso-commit] traverso/src/common fpu.cc


From: Remon Sijrier
Subject: [Traverso-commit] traverso/src/common fpu.cc
Date: Tue, 11 Dec 2007 17:34:27 +0000

CVSROOT:        /sources/traverso
Module name:    traverso
Changes by:     Remon Sijrier <r_sijrier>       07/12/11 17:34:27

Modified files:
        src/common     : fpu.cc 

Log message:
        * fix compile warning:  dereferencing type-punned pointer will break 
strict-aliasing, patch from Alexis.

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/traverso/src/common/fpu.cc?cvsroot=traverso&r1=1.2&r2=1.3

Patches:
Index: fpu.cc
===================================================================
RCS file: /sources/traverso/traverso/src/common/fpu.cc,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -b -r1.2 -r1.3
--- fpu.cc      8 Nov 2007 21:32:09 -0000       1.2
+++ fpu.cc      11 Dec 2007 17:34:27 -0000      1.3
@@ -75,11 +75,12 @@
        if (cpuflags & (1 << 24)) {
                
                char* fxbuf = 0;
+               char** temp = &fxbuf;
                
 #ifdef NO_POSIX_MEMALIGN
                if ((fxbuf = (char *) malloc(512)) == 0)
 #else
-               if (posix_memalign ((void**)&fxbuf, 16, 512)) 
+               if (posix_memalign ((void**)temp, 16, 512))
 #endif                 
                {
                        printf("FPU() ERROR: cannot allocate 16 byte aligned 
buffer for h/w feature detection");




reply via email to

[Prev in Thread] Current Thread [Next in Thread]