qemu-devel
[Top][All Lists]
Advanced

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

[Qemu-devel] Arm host float endian fix


From: Paul Brook
Subject: [Qemu-devel] Arm host float endian fix
Date: Sun, 6 Feb 2005 01:03:29 +0000
User-agent: KMail/1.7.2

The newer arm VFP floating point units store double values with natural 
word-ordering, unlike the old FPA unit which always used big-endian.

Patch below updates host conditionals to reflect this.

Paul

Index: cpu-all.h
===================================================================
RCS file: /cvsroot/qemu/qemu/cpu-all.h,v
retrieving revision 1.39
diff -u -p -r1.39 cpu-all.h
--- cpu-all.h 28 Jan 2005 22:37:22 -0000 1.39
+++ cpu-all.h 6 Feb 2005 00:57:27 -0000
@@ -114,10 +114,11 @@ static inline void tswap64s(uint64_t *s)
 #define tswapls(s) tswap64s((uint64_t *)(s))
 #endif
 
-/* NOTE: arm is horrible as double 32 bit words are stored in big endian ! */
+/* NOTE: arm FPA is horrible as double 32 bit words are stored in big endian!
+ */
 typedef union {
     double d;
-#if !defined(WORDS_BIGENDIAN) && !defined(__arm__)
+#if !defined(WORDS_BIGENDIAN) && !defined(__arm__) && !defined (__VFP_FP__)
     struct {
         uint32_t lower;
         uint32_t upper;




reply via email to

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