(__monstartup): Round kcountsize to multiples of the froms[] array so the
authordrepper <drepper>
Sat, 17 Apr 2004 22:50:29 +0000 (22:50 +0000)
committerdrepper <drepper>
Sat, 17 Apr 2004 22:50:29 +0000 (22:50 +0000)
array is properly aligned.

gmon/gmon.c

index 407993d..dd4ee3a 100644 (file)
@@ -114,7 +114,7 @@ __monstartup (lowpc, highpc)
   p->lowpc = ROUNDDOWN(lowpc, HISTFRACTION * sizeof(HISTCOUNTER));
   p->highpc = ROUNDUP(highpc, HISTFRACTION * sizeof(HISTCOUNTER));
   p->textsize = p->highpc - p->lowpc;
-  p->kcountsize = p->textsize / HISTFRACTION;
+  p->kcountsize = ROUNDUP(p->textsize / HISTFRACTION, sizeof(*p->froms));
   p->hashfraction = HASHFRACTION;
   p->log_hashfraction = -1;
   /* The following test must be kept in sync with the corresponding