Linker(ELF): Fix addProddableBlocks usage
authorBen Gamari <bgamari.foss@gmail.com>
Sun, 27 Dec 2015 00:13:39 +0000 (01:13 +0100)
committerBen Gamari <ben@smart-cactus.org>
Sun, 27 Dec 2015 00:43:08 +0000 (01:43 +0100)
The range marked as proddable didn't actually match the range that we
mapped. This fixed `ghc-api/T8628` et al on ARM.

Test Plan: Validate

Reviewers: austin, erikd

Subscribers: thomie

Differential Revision: https://phabricator.haskell.org/D1700

GHC Trac Issues: #11289

rts/Linker.c

index e411e4d..3bd12b3 100644 (file)
@@ -4809,7 +4809,7 @@ ocGetNames_ELF ( ObjectCode* oc )
               if (start == NULL) goto fail;
               alloc = SECTION_MMAP;
           }
-          addProddableBlock(oc, ehdrC + offset, size);
+          addProddableBlock(oc, start, size);
       }
 
       addSection(&sections[i], kind, alloc, start, size,