While searching for more information on GCC on armel, I came across
#580334, which sounds very much like our case: gcc 4.3 is fine, gcc 4.4
breaks on armel. Following their approach, I've disabled optimizations
on the ZigZagDecode64 function, and suprise! unittests pass without any
error.

Until the discussion with upstream regarding int types and sizes and
what-not is clarified, I'm going to upload a patched version that has
this diff:

--- a/src/google/protobuf/wire_format_lite.h
+++ b/src/google/protobuf/wire_format_lite.h
@@ -222,7 +222,11 @@
   static uint32 ZigZagEncode32(int32 n);
   static int32  ZigZagDecode32(uint32 n);
   static uint64 ZigZagEncode64(int64 n);
-  static int64  ZigZagDecode64(uint64 n);
+  static int64  ZigZagDecode64(uint64 n)
+#ifdef __arm__
+    __attribute__((__optimize__(0)))
+#endif
+  ;
 
   // =================================================================
   // Methods for reading/writing individual field.  The implementations

regards,
iustin



-- 
To UNSUBSCRIBE, email to debian-bugs-rc-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org

Reply via email to