Revision 9b605b9e

b/hw/ppc_oldworld.c
93 93
        /* R6 = x, R7 = y, R8 = visible, R9 = data */
94 94
        break;
95 95
    default:
96
        fprintf(stderr, "unsupported OSI call R5=" REGX "\n", env->gpr[5]);
96
        fprintf(stderr, "unsupported OSI call R5=" REGX "\n",
97
                (target_ulong)env->gpr[5]);
97 98
        break;
98 99
    }
99 100

  
b/target-ppc/cpu.h
30 30
typedef uint64_t ppc_gpr_t;
31 31
#define TARGET_GPR_BITS  64
32 32
#define TARGET_LONG_BITS 64
33
#define REGX "%016" PRIx64
34 33
#define TARGET_PAGE_BITS 12
35 34

  
36 35
#else /* defined (TARGET_PPC64) */
......
43 42
 */
44 43
typedef uint64_t ppc_gpr_t;
45 44
#define TARGET_GPR_BITS  64
46
#define REGX "%08" PRIx64
47 45
#else /* (HOST_LONG_BITS >= 64) */
48 46
typedef uint32_t ppc_gpr_t;
49 47
#define TARGET_GPR_BITS  32
50
#define REGX "%08" PRIx32
51 48
#endif /* (HOST_LONG_BITS >= 64) */
52 49

  
53 50
#define TARGET_LONG_BITS 32
......
72 69

  
73 70
#endif /* defined (TARGET_PPC64) */
74 71

  
72
/* A ppc_gpr_t should not be printed directly as the high bits may be
73
   garbage.  It should always be cast to a target_ulong first.  */
74
#define REGX TARGET_FMT_lx
75

  
75 76
#include "cpu-defs.h"
76 77

  
77 78
#define ADDRX TARGET_FMT_lx
b/target-ppc/helper.c
2169 2169
{
2170 2170
    fprintf(logfile, "syscall r0=0x" REGX " r3=0x" REGX " r4=0x" REGX
2171 2171
            " r5=0x" REGX " r6=0x" REGX " nip=0x" ADDRX "\n",
2172
            env->gpr[0], env->gpr[3], env->gpr[4],
2173
            env->gpr[5], env->gpr[6], env->nip);
2172
            (target_ulong)env->gpr[0], (target_ulong)env->gpr[3],
2173
            (target_ulong)env->gpr[4], (target_ulong)env->gpr[5],
2174
            (target_ulong)env->gpr[6], env->nip);
2174 2175
}
2175 2176

  
2176 2177
/* Note that this function should be greatly optimized
b/target-ppc/op_helper.c
2920 2920

  
2921 2921
#if defined (DEBUG_SOFTWARE_TLB)
2922 2922
    if (loglevel != 0) {
2923
        fprintf(logfile, "%s T0 " REGX " T1 " REGX "\n", __func__, T0, T1);
2923
        fprintf(logfile, "%s T0 " REGX " T1 " REGX "\n", __func__,
2924
                (target_ulong)T0, (target_ulong)T1);
2924 2925
    }
2925 2926
#endif
2926 2927
    T0 &= 0x3F;
......
2989 2990

  
2990 2991
#if defined (DEBUG_SOFTWARE_TLB)
2991 2992
    if (loglevel != 0) {
2992
        fprintf(logfile, "%s T0 " REGX " T1 " REGX "\n", __func__, T0, T1);
2993
        fprintf(logfile, "%s T0 " REGX " T1 " REGX "\n", __func__,
2994
                (targt_ulong)T0, (target_ulong)T1);
2993 2995
    }
2994 2996
#endif
2995 2997
    T0 &= 0x3F;
......
3023 3025
#if defined (DEBUG_SOFTWARE_TLB)
3024 3026
    if (loglevel != 0) {
3025 3027
        fprintf(logfile, "%s word %d T0 " REGX " T1 " REGX "\n",
3026
                __func__, word, T0, T1);
3028
                __func__, word, (target_ulong)T0, (target_ulong)T1);
3027 3029
    }
3028 3030
#endif
3029 3031
    do_flush_tlbs = 0;

Also available in: Unified diff