This is the mail archive of the
binutils@sourceware.cygnus.com
mailing list for the binutils project.
more binutils fixes for alpha
- To: binutils@sourceware.cygnus.com
- Subject: more binutils fixes for alpha
- From: Brad Lucier <lucier@math.purdue.edu>
- Date: Thu, 9 Sep 1999 10:19:02 -0500 (EST)
- Cc: lucier@math.purdue.edu, staff@math.purdue.edu, wilker@math.purdue.edu, hosking@cs.purdue.edu
In binutils-2.9.5.0.7 compiled with gcc-2.95.1, gprof was dumping core.
I decided to fix the 64-bit uncleanliness of the code. Now gprof works;
I don't know what fixed it, or why this should fix it, but here are the
diffs.
Brad Lucier lucier@math.purdue.edu
===================================================================
RCS file: RCS/readelf.c,v
retrieving revision 1.1
diff -c -r1.1 readelf.c
*** /tmp/T0a0064B Thu Sep 9 10:14:14 1999
--- readelf.c Thu Sep 9 09:55:03 1999
***************
*** 3249,3256 ****
nn += printf ("(%s%-*s",
strtab + ivna.vna_name,
! 12 - strlen (strtab
! + ivna.vna_name),
")");
break;
}
--- 3249,3256 ----
nn += printf ("(%s%-*s",
strtab + ivna.vna_name,
! (int) (12 - strlen (strtab
! + ivna.vna_name)),
")");
break;
}
***************
*** 3296,3304 ****
nn +=
printf ("(%s%-*s",
strtab + ivda.vda_name,
! 12
- strlen (strtab
! + ivda.vda_name),
")");
}
}
--- 3296,3304 ----
nn +=
printf ("(%s%-*s",
strtab + ivda.vda_name,
! (int) (12
- strlen (strtab
! + ivda.vda_name)),
")");
}
}
***************
*** 3351,3358 ****
nn += printf ("(%s%-*s",
strtab + ivna.vna_name,
! 12 - strlen (strtab
! + ivna.vna_name),
")");
break;
}
--- 3351,3358 ----
nn += printf ("(%s%-*s",
strtab + ivna.vna_name,
! (int)(12 - strlen (strtab
! + ivna.vna_name)),
")");
break;
}
***************
*** 3396,3403 ****
nn += printf ("(%s%-*s",
strtab + ivda.vda_name,
! 12 - strlen (strtab
! + ivda.vda_name),
")");
}
}
--- 3396,3403 ----
nn += printf ("(%s%-*s",
strtab + ivda.vda_name,
! (int) (12 - strlen (strtab
! + ivda.vda_name)),
")");
}
}
***************
*** 5959,5965 ****
GET_DATA_ALLOC (liblist_offset, liblistno * sizeof (Elf32_External_Lib),
elib, Elf32_External_Lib *, "liblist");
! printf ("\nSection '.liblist' contains %d entries:\n", liblistno);
fputs (" Library Time Stamp Checksum Version Flags\n",
stdout);
--- 5959,5965 ----
GET_DATA_ALLOC (liblist_offset, liblistno * sizeof (Elf32_External_Lib),
elib, Elf32_External_Lib *, "liblist");
! printf ("\nSection '.liblist' contains %d entries:\n", (int) liblistno);
fputs (" Library Time Stamp Checksum Version Flags\n",
stdout);
***************
*** 5977,5983 ****
strftime (timebuf, 20, "%Y-%m-%dT%H:%M:%S", gmtime (&time));
! printf ("%3d: %-20s %s %#10lx %-7ld", cnt,
dynamic_strings + liblist.l_name, timebuf,
liblist.l_checksum, liblist.l_version);
--- 5977,5983 ----
strftime (timebuf, 20, "%Y-%m-%dT%H:%M:%S", gmtime (&time));
! printf ("%3d: %-20s %s %#10lx %-7ld", (int) cnt,
dynamic_strings + liblist.l_name, timebuf,
liblist.l_checksum, liblist.l_version);
***************
*** 6258,6264 ****
Elf_Internal_Sym * psym = &dynamic_symbols[iconf[cnt]];
printf ("%5u: %8lu %#10lx %s\n",
! cnt, iconf[cnt], (unsigned long) psym->st_value,
dynamic_strings + psym->st_name);
}
--- 6258,6264 ----
Elf_Internal_Sym * psym = &dynamic_symbols[iconf[cnt]];
printf ("%5u: %8lu %#10lx %s\n",
! (unsigned int) cnt, iconf[cnt], (unsigned long) psym->st_value,
dynamic_strings + psym->st_name);
}
===================================================================
RCS file: RCS/corefile.c,v
retrieving revision 1.1
diff -c -r1.1 corefile.c
No differences encountered
===================================================================
RCS file: RCS/i386.c,v
retrieving revision 1.1
diff -c -r1.1 i386.c
*** /tmp/T0a0064F Thu Sep 9 10:14:32 1999
--- i386.c Thu Sep 9 10:12:03 1999
***************
*** 67,73 ****
if (i386_iscall (instructp))
{
DBG (CALLDEBUG,
! printf ("[findcall]\t0x%x:call",
instructp - (unsigned char *) delta));
/*
* regular pc relative addressing
--- 67,73 ----
if (i386_iscall (instructp))
{
DBG (CALLDEBUG,
! printf ("[findcall]\t0x%lx:call",
instructp - (unsigned char *) delta));
/*
* regular pc relative addressing
===================================================================
RCS file: RCS/tahoe.c,v
retrieving revision 1.1
diff -c -r1.1 tahoe.c
*** /tmp/T0a0064F Thu Sep 9 10:14:32 1999
--- tahoe.c Thu Sep 9 10:03:54 1999
***************
*** 260,266 ****
* maybe a callf, better check it out.
* skip the count of the number of arguments.
*/
! DBG (CALLDEBUG, printf ("[findcall]\t0x%x:callf",
instructp - (unsigned char *) core_text_space));
firstmode = tahoe_operandmode (instructp + length);
switch (firstmode)
--- 260,266 ----
* maybe a callf, better check it out.
* skip the count of the number of arguments.
*/
! DBG (CALLDEBUG, printf ("[findcall]\t0x%lx:callf",
instructp - (unsigned char *) core_text_space));
firstmode = tahoe_operandmode (instructp + length);
switch (firstmode)
===================================================================
RCS file: RCS/vax.c,v
retrieving revision 1.1
diff -c -r1.1 vax.c
*** /tmp/T0a0064F Thu Sep 9 10:14:33 1999
--- vax.c Thu Sep 9 10:03:21 1999
***************
*** 264,270 ****
* skip the count of the number of arguments.
*/
DBG (CALLDEBUG,
! printf ("[findcall]\t0x%x:calls",
instructp - (unsigned char *) core_text_space));
firstmode = vax_operandmode ((struct modebyte *) (instructp + length));
switch (firstmode)
--- 264,270 ----
* skip the count of the number of arguments.
*/
DBG (CALLDEBUG,
! printf ("[findcall]\t0x%lx:calls",
instructp - (unsigned char *) core_text_space));
firstmode = vax_operandmode ((struct modebyte *) (instructp + length));
switch (firstmode)
===================================================================
RCS file: RCS/dwarf2dbg.c,v
retrieving revision 1.1
diff -c -r1.1 dwarf2dbg.c
*** /tmp/T0a0064O Thu Sep 9 10:14:41 1999
--- dwarf2dbg.c Thu Sep 9 09:59:41 1999
***************
*** 618,624 ****
{
j = SPECIAL_LINE (i);
if (j == DWARF2_LINE_BASE)
! fprintf (stderr, "\n%4u: ",
DWARF2_LINE_MIN_INSN_LENGTH*SPECIAL_ADDR (i));
fprintf (stderr, " %2u", ls.opcode_hist[i]);
}
--- 618,624 ----
{
j = SPECIAL_LINE (i);
if (j == DWARF2_LINE_BASE)
! fprintf (stderr, "\n%4lu: ",
DWARF2_LINE_MIN_INSN_LENGTH*SPECIAL_ADDR (i));
fprintf (stderr, " %2u", ls.opcode_hist[i]);
}