Commit b4018aaa authored by Simon Marlow's avatar Simon Marlow

Fix alignment in the CostCentre struct (#5710)

parent 24b31376
......@@ -178,8 +178,8 @@ emitCostCentreDecl cc = do
label, -- char *label,
modl, -- char *module,
loc, -- char *srcloc,
zero64, -- StgWord64 mem_alloc
zero, -- StgWord time_ticks
zero64, -- StgWord64 mem_alloc
is_caf, -- StgInt is_caf
zero -- struct _CostCentre *link
]
......
......@@ -223,14 +223,14 @@ emitCostCentreDecl cc = do
-- All cost centres will be in the main package, since we
-- don't normally use -auto-all or add SCCs to other packages.
-- Hence don't emit the package name in the module here.
; let lits = [ zero, -- StgInt ccID,
label, -- char *label,
modl, -- char *module,
loc, -- char *srcloc,
zero, -- StgWord time_ticks
zero64, -- StgWord64 mem_alloc
is_caf, -- StgInt is_caf
zero -- struct _CostCentre *link
; let lits = [ zero, -- StgInt ccID,
label, -- char *label,
modl, -- char *module,
loc, -- char *srcloc,
zero64, -- StgWord64 mem_alloc
zero, -- StgWord time_ticks
is_caf, -- StgInt is_caf
zero -- struct _CostCentre *link
]
; emitDataLits (mkCCLabel cc) lits
}
......
......@@ -37,8 +37,8 @@ typedef struct _CostCentre {
char * srcloc;
// used for accumulating costs at the end of the run...
StgWord time_ticks;
StgWord64 mem_alloc; // align 8 (Note [struct alignment])
StgWord time_ticks;
StgInt is_caf; // non-zero for a CAF cost centre
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment