[aarch64-port-dev ] printf format conflict

Andy Johnson andy.johnson at linaro.org
Tue Oct 29 17:04:46 PDT 2013


I got an error while doing a sim_compile.  It complained about a type
conflict between the argument and the corresponding format.  The following
patch solves the problem:

# HG changeset patch
# User andy johnson andy.johnson at linaro.org
# Date 1383091105 0
# Node ID 88d8843ae27ffb6f66baf16dfc9b3b34775b91c9
# Parent  2c9491db660f51559026478f7053a0e1054cb277
Fixed conflicting types in printf format argument.

diff -r 2c9491db660f -r 88d8843ae27f src/cpu/aarch64/vm/frame_aarch64.cpp
--- a/src/cpu/aarch64/vm/frame_aarch64.cpp    Tue Oct 29 16:06:56 2013 +0000
+++ b/src/cpu/aarch64/vm/frame_aarch64.cpp    Tue Oct 29 23:58:25 2013 +0000
@@ -713,7 +713,7 @@
 #define DESCRIBE_FP_OFFSET(name)                \
   {                                \
     unsigned long *p = (unsigned long *)fp;            \
-    printf("0x%016lx 0x%016lx %s\n", p + frame::name##_offset,    \
+    printf("0x%016lx 0x%016lx %s\n", (unsigned long)(p +
frame::name##_offset),\
        p[frame::name##_offset], #name);            \
   }



More information about the aarch64-port-dev mailing list