diff options
author | Reid Barton <rwbarton@gmail.com> | 2016-02-01 14:32:38 +0100 |
---|---|---|
committer | Ben Gamari <ben@smart-cactus.org> | 2016-02-01 14:32:50 +0100 |
commit | ba88aab0d1223cd5066a66500360df4bddb159d1 (patch) | |
tree | 6aafd65e8efecea1aad6f82d6a3d2643e036b042 /rts | |
parent | 86897e1fe23cb26fa2278e86542b34c33301606a (diff) | |
download | haskell-ba88aab0d1223cd5066a66500360df4bddb159d1.tar.gz |
Fix LOOKS_LIKE_PTR for 64-bit platforms
I'm not sure what this is used for. But it won't correctly
detect RTS-filled slop on 64-bit platforms.
Test Plan:
Untested. But I did verify that
unsigned long x = (unsigned long)0xaaaaaaaaaaaaaaaaULL;
compiles warning-free and produces the expected output using both
gcc and clang, with -Wall -Wextra -O, and with and without -m32.
Reviewers: simonmar, austin, bgamari
Reviewed By: bgamari
Subscribers: thomie
Differential Revision: https://phabricator.haskell.org/D1860
Diffstat (limited to 'rts')
-rw-r--r-- | rts/RetainerProfile.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/rts/RetainerProfile.c b/rts/RetainerProfile.c index 7a1a66185f..6a6a542041 100644 --- a/rts/RetainerProfile.c +++ b/rts/RetainerProfile.c @@ -2063,7 +2063,7 @@ retainerProfile(void) #define LOOKS_LIKE_PTR(r) ((LOOKS_LIKE_STATIC_CLOSURE(r) || \ ((HEAP_ALLOCED(r) && ((Bdescr((P_)r)->flags & BF_FREE) == 0)))) && \ - ((StgWord)(*(StgPtr)r)!=0xaaaaaaaa)) + ((StgWord)(*(StgPtr)r)!=(StgWord)0xaaaaaaaaaaaaaaaaULL)) static nat sanityCheckHeapClosure( StgClosure *c ) |