[Git][ghc/ghc][master] eventlog: Ensure that IPE output contains actual info table pointers
Marge Bot (@marge-bot)
gitlab at gitlab.haskell.org
Mon Nov 14 14:37:16 UTC 2022
Marge Bot pushed to branch master at Glasgow Haskell Compiler / GHC
Commits:
268a3ce9 by Ben Gamari at 2022-11-14T09:36:57-05:00
eventlog: Ensure that IPE output contains actual info table pointers
The refactoring in 866c736e introduced a rather subtle change in the
semantics of the IPE eventlog output, changing the eventlog field from
encoding info table pointers to "TNTC pointers" (which point to entry
code when tables-next-to-code is enabled). Fix this.
Fixes #22452.
- - - - -
2 changed files:
- rts/eventlog/EventLog.c
- rts/include/rts/IPE.h
Changes:
=====================================
rts/eventlog/EventLog.c
=====================================
@@ -1429,7 +1429,7 @@ void postIPE(const InfoProvEnt *ipe)
ensureRoomForVariableEvent(&eventBuf, len);
postEventHeader(&eventBuf, EVENT_IPE);
postPayloadSize(&eventBuf, len);
- postWord64(&eventBuf, (StgWord) ipe->info);
+ postWord64(&eventBuf, (StgWord) INFO_PTR_TO_STRUCT(ipe->info));
postString(&eventBuf, ipe->prov.table_name);
postString(&eventBuf, ipe->prov.closure_desc);
postString(&eventBuf, ipe->prov.ty_desc);
=====================================
rts/include/rts/IPE.h
=====================================
@@ -24,6 +24,8 @@ typedef struct InfoProv_ {
} InfoProv;
typedef struct InfoProvEnt_ {
+ // When TNTC is enabled this will point to the entry code
+ // not the info table itself.
const StgInfoTable *info;
InfoProv prov;
} InfoProvEnt;
@@ -50,6 +52,8 @@ typedef uint32_t StringIdx;
// The size of this must be a multiple of the word size
// to ensure correct packing.
typedef struct {
+ // When TNTC is enabled this will point to the entry code
+ // not the info table itself.
const StgInfoTable *info;
StringIdx table_name;
StringIdx closure_desc;
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/268a3ce952f6be00a1dd164dc4d7acb346045e90
--
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/268a3ce952f6be00a1dd164dc4d7acb346045e90
You're receiving this email because of your account on gitlab.haskell.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/ghc-commits/attachments/20221114/c07e683d/attachment-0001.html>
More information about the ghc-commits
mailing list