X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=rts%2FHpc.c;h=50730ea70bad4359092bcf43b9619245139335a3;hb=80a766fdb6864eae613962e43ad9eb371e0ce80c;hp=b1b26082946f46529480d4b855624150d5b08170;hpb=0df7dbb1b98d08521f177ade22615861752f8981;p=ghc-hetmet.git diff --git a/rts/Hpc.c b/rts/Hpc.c index b1b2608..50730ea 100644 --- a/rts/Hpc.c +++ b/rts/Hpc.c @@ -32,6 +32,13 @@ typedef struct _Info { struct _Info *next; } Info; +// This is a cruel hack, we should completely redesign the format specifier handling in the RTS. +#if SIZEOF_LONG == 8 +#define PRIuWORD64 "lu" +#else +#define PRIuWORD64 "llu" +#endif + Info *modules = 0; Info *nextModule = 0; StgWord64 *tixBoxes = 0; // local copy of tixBoxes array, from file. @@ -314,7 +321,7 @@ exitHpc(void) { } if (tmpModule->tixArr) { - fprintf(f,"%lld",tmpModule->tixArr[i]); + fprintf(f,"%" PRIuWORD64,tmpModule->tixArr[i]); } else { fprintf(f,"0"); }