mirror of
https://sourceware.org/git/binutils-gdb.git
synced 2024-11-21 01:12:32 +08:00
Add support for IA-64 specific elf header flags.
bfd/ 2000-08-14 Jim Wilson <wilson@cygnus.com> * elf64-ia64.c (elf64_ia64_merge_private_bfd_data): Handle EF_IA_64_REDUCEDFP, EF_IA_64_CONS_GP, and EF_IA_64_NOFUNCDESC_CONS_GP. (elf64_ia64_print_private_bfd_data): Likewise. Also handle EF_IA_64_ABSOLUTE. gas/ 2000-08-14 Jim Wilson <wilson@cygnus.com> * config/tc-ia64.c (md_longopts): Add -mconstant-gp and -mauto-pic. (md_parse_option): Add OPTION_MCONSTANT_GP and OPTION_MAUTO_PIC. (md_begin): Change assignment to md.flag to OR in the new bit. include/elf/ 2000-08-14 Jim Wilson <wilson@cygnus.com> * elf/ia64.h (EF_IA_64_REDUCEDFP, EF_IA_64_CONS_GP, EF_IA_64_NOFUNCDESC_CONS_GP, EF_IA_64_ABSOLUTE): Define.
This commit is contained in:
parent
db4f683116
commit
c43c2cc5fa
@ -1,3 +1,10 @@
|
|||||||
|
2000-08-14 Jim Wilson <wilson@cygnus.com>
|
||||||
|
|
||||||
|
* elf64-ia64.c (elf64_ia64_merge_private_bfd_data): Handle
|
||||||
|
EF_IA_64_REDUCEDFP, EF_IA_64_CONS_GP, and EF_IA_64_NOFUNCDESC_CONS_GP.
|
||||||
|
(elf64_ia64_print_private_bfd_data): Likewise. Also handle
|
||||||
|
EF_IA_64_ABSOLUTE.
|
||||||
|
|
||||||
2000-08-11 Alexandre Oliva <aoliva@redhat.com>
|
2000-08-11 Alexandre Oliva <aoliva@redhat.com>
|
||||||
|
|
||||||
* elf32-sh.c (sh_elf_set_mach_from_flags): Make it static.
|
* elf32-sh.c (sh_elf_set_mach_from_flags): Make it static.
|
||||||
|
@ -3974,6 +3974,10 @@ elf64_ia64_merge_private_bfd_data (ibfd, obfd)
|
|||||||
if (in_flags == out_flags)
|
if (in_flags == out_flags)
|
||||||
return true;
|
return true;
|
||||||
|
|
||||||
|
/* Output has EF_IA_64_REDUCEDFP set only if all inputs have it set. */
|
||||||
|
if (!(in_flags & EF_IA_64_REDUCEDFP) && (out_flags & EF_IA_64_REDUCEDFP))
|
||||||
|
elf_elfheader (obfd)->e_flags &= ~EF_IA_64_REDUCEDFP;
|
||||||
|
|
||||||
if ((in_flags & EF_IA_64_TRAPNIL) != (out_flags & EF_IA_64_TRAPNIL))
|
if ((in_flags & EF_IA_64_TRAPNIL) != (out_flags & EF_IA_64_TRAPNIL))
|
||||||
{
|
{
|
||||||
(*_bfd_error_handler)
|
(*_bfd_error_handler)
|
||||||
@ -4001,6 +4005,25 @@ elf64_ia64_merge_private_bfd_data (ibfd, obfd)
|
|||||||
bfd_set_error (bfd_error_bad_value);
|
bfd_set_error (bfd_error_bad_value);
|
||||||
ok = false;
|
ok = false;
|
||||||
}
|
}
|
||||||
|
if ((in_flags & EF_IA_64_CONS_GP) != (out_flags & EF_IA_64_CONS_GP))
|
||||||
|
{
|
||||||
|
(*_bfd_error_handler)
|
||||||
|
(_("%s: linking constant-gp files with non-constant-gp files"),
|
||||||
|
bfd_get_filename (ibfd));
|
||||||
|
|
||||||
|
bfd_set_error (bfd_error_bad_value);
|
||||||
|
ok = false;
|
||||||
|
}
|
||||||
|
if ((in_flags & EF_IA_64_NOFUNCDESC_CONS_GP)
|
||||||
|
!= (out_flags & EF_IA_64_NOFUNCDESC_CONS_GP))
|
||||||
|
{
|
||||||
|
(*_bfd_error_handler)
|
||||||
|
(_("%s: linking auto-pic files with non-auto-pic files"),
|
||||||
|
bfd_get_filename (ibfd));
|
||||||
|
|
||||||
|
bfd_set_error (bfd_error_bad_value);
|
||||||
|
ok = false;
|
||||||
|
}
|
||||||
|
|
||||||
return ok;
|
return ok;
|
||||||
}
|
}
|
||||||
@ -4015,11 +4038,16 @@ elf64_ia64_print_private_bfd_data (abfd, ptr)
|
|||||||
|
|
||||||
BFD_ASSERT (abfd != NULL && ptr != NULL);
|
BFD_ASSERT (abfd != NULL && ptr != NULL);
|
||||||
|
|
||||||
fprintf (file, "private flags = %s%s%s%s\n",
|
fprintf (file, "private flags = %s%s%s%s%s%s%s%s\n",
|
||||||
(flags & EF_IA_64_TRAPNIL) ? "TRAPNIL, " : "",
|
(flags & EF_IA_64_TRAPNIL) ? "TRAPNIL, " : "",
|
||||||
(flags & EF_IA_64_EXT) ? "EXT, " : "",
|
(flags & EF_IA_64_EXT) ? "EXT, " : "",
|
||||||
(flags & EF_IA_64_BE) ? "BE, " : "LE, ",
|
(flags & EF_IA_64_BE) ? "BE, " : "LE, ",
|
||||||
|
(flags & EF_IA_64_REDUCEDFP) ? "REDUCEDFP, " : "",
|
||||||
|
(flags & EF_IA_64_CONS_GP) ? "CONS_GP, " : "",
|
||||||
|
(flags & EF_IA_64_NOFUNCDESC_CONS_GP) ? "NOFUNCDESC_CONS_GP, " : "",
|
||||||
|
(flags & EF_IA_64_ABSOLUTE) ? "ABSOLUTE, " : "",
|
||||||
(flags & EF_IA_64_ABI64) ? "ABI64" : "ABI32");
|
(flags & EF_IA_64_ABI64) ? "ABI64" : "ABI32");
|
||||||
|
|
||||||
_bfd_elf_print_private_bfd_data (abfd, ptr);
|
_bfd_elf_print_private_bfd_data (abfd, ptr);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
@ -1,3 +1,9 @@
|
|||||||
|
2000-08-14 Jim Wilson <wilson@cygnus.com>
|
||||||
|
|
||||||
|
* config/tc-ia64.c (md_longopts): Add -mconstant-gp and -mauto-pic.
|
||||||
|
(md_parse_option): Add OPTION_MCONSTANT_GP and OPTION_MAUTO_PIC.
|
||||||
|
(md_begin): Change assignment to md.flag to OR in the new bit.
|
||||||
|
|
||||||
2000-08-14 Mark Elbrecht <snowball3@bigfoot.com>
|
2000-08-14 Mark Elbrecht <snowball3@bigfoot.com>
|
||||||
|
|
||||||
* config/obj-coff.c (obj_coff_endef) [BFD_ASSEMBLER]: Set the debug
|
* config/obj-coff.c (obj_coff_endef) [BFD_ASSEMBLER]: Set the debug
|
||||||
|
@ -160,7 +160,10 @@ const char *md_shortopts = "M:N:x::";
|
|||||||
|
|
||||||
struct option md_longopts[] =
|
struct option md_longopts[] =
|
||||||
{
|
{
|
||||||
{ NULL, no_argument, NULL, 0}
|
#define OPTION_MCONSTANT_GP (OPTION_MD_BASE + 1)
|
||||||
|
{"mconstant-gp", no_argument, NULL, OPTION_MCONSTANT_GP},
|
||||||
|
#define OPTION_MAUTO_PIC (OPTION_MD_BASE + 2)
|
||||||
|
{"mauto-pic", no_argument, NULL, OPTION_MAUTO_PIC}
|
||||||
};
|
};
|
||||||
|
|
||||||
size_t md_longopts_size = sizeof (md_longopts);
|
size_t md_longopts_size = sizeof (md_longopts);
|
||||||
@ -5534,9 +5537,9 @@ md_parse_option (c, arg)
|
|||||||
int c;
|
int c;
|
||||||
char *arg;
|
char *arg;
|
||||||
{
|
{
|
||||||
/* Switches from the Intel assembler. */
|
|
||||||
switch (c)
|
switch (c)
|
||||||
{
|
{
|
||||||
|
/* Switches from the Intel assembler. */
|
||||||
case 'M':
|
case 'M':
|
||||||
if (strcmp (arg, "ilp64") == 0
|
if (strcmp (arg, "ilp64") == 0
|
||||||
|| strcmp (arg, "lp64") == 0
|
|| strcmp (arg, "lp64") == 0
|
||||||
@ -5629,6 +5632,15 @@ md_parse_option (c, arg)
|
|||||||
/* nops Print nops statistics. */
|
/* nops Print nops statistics. */
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
/* GNU specific switches for gcc. */
|
||||||
|
case OPTION_MCONSTANT_GP:
|
||||||
|
md.flags |= EF_IA_64_CONS_GP;
|
||||||
|
break;
|
||||||
|
|
||||||
|
case OPTION_MAUTO_PIC:
|
||||||
|
md.flags |= EF_IA_64_NOFUNCDESC_CONS_GP;
|
||||||
|
break;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
@ -5880,7 +5892,8 @@ md_begin ()
|
|||||||
}
|
}
|
||||||
|
|
||||||
/* Default to 64-bit mode. */
|
/* Default to 64-bit mode. */
|
||||||
md.flags = EF_IA_64_ABI64;
|
/* ??? This overrides the -M options, but they aren't working anyways. */
|
||||||
|
md.flags |= EF_IA_64_ABI64;
|
||||||
|
|
||||||
md.mem_offset.hint = 0;
|
md.mem_offset.hint = 0;
|
||||||
md.path = 0;
|
md.path = 0;
|
||||||
|
@ -1,3 +1,8 @@
|
|||||||
|
2000-08-14 Jim Wilson <wilson@cygnus.com>
|
||||||
|
|
||||||
|
* elf/ia64.h (EF_IA_64_REDUCEDFP, EF_IA_64_CONS_GP,
|
||||||
|
EF_IA_64_NOFUNCDESC_CONS_GP, EF_IA_64_ABSOLUTE): Define.
|
||||||
|
|
||||||
2000-08-07 Nick Clifton <nickc@cygnus.com>
|
2000-08-07 Nick Clifton <nickc@cygnus.com>
|
||||||
|
|
||||||
* ppc.h: Remove spurious CYGNUS LOCAL comments.
|
* ppc.h: Remove spurious CYGNUS LOCAL comments.
|
||||||
|
@ -25,7 +25,6 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
|
|||||||
/* Bits in the e_flags field of the Elf64_Ehdr: */
|
/* Bits in the e_flags field of the Elf64_Ehdr: */
|
||||||
|
|
||||||
#define EF_IA_64_MASKOS 0x0000000f /* os-specific flags */
|
#define EF_IA_64_MASKOS 0x0000000f /* os-specific flags */
|
||||||
#define EF_IA_64_ABI64 (1 << 4) /* 64-bit ABI */
|
|
||||||
#define EF_IA_64_ARCH 0xff000000 /* arch. version mask */
|
#define EF_IA_64_ARCH 0xff000000 /* arch. version mask */
|
||||||
|
|
||||||
/* ??? These four definitions are not part of the SVR4 ABI.
|
/* ??? These four definitions are not part of the SVR4 ABI.
|
||||||
@ -36,6 +35,14 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
|
|||||||
#define EF_IA_64_BE (1 << 3) /* PSR BE bit set (big-endian) */
|
#define EF_IA_64_BE (1 << 3) /* PSR BE bit set (big-endian) */
|
||||||
#define EFA_IA_64_EAS2_3 0x23000000 /* ia64 EAS 2.3 */
|
#define EFA_IA_64_EAS2_3 0x23000000 /* ia64 EAS 2.3 */
|
||||||
|
|
||||||
|
#define EF_IA_64_ABI64 (1 << 4) /* 64-bit ABI */
|
||||||
|
/* Not used yet. */
|
||||||
|
#define EF_IA_64_REDUCEDFP (1 << 5) /* Only FP6-FP11 used. */
|
||||||
|
#define EF_IA_64_CONS_GP (1 << 6) /* gp as program wide constant. */
|
||||||
|
#define EF_IA_64_NOFUNCDESC_CONS_GP (1 << 7) /* And no function descriptors. */
|
||||||
|
/* Not used yet. */
|
||||||
|
#define EF_IA_64_ABSOLUTE (1 << 8) /* Load at absolute addresses. */
|
||||||
|
|
||||||
#define ELF_STRING_ia64_archext ".IA_64.archext"
|
#define ELF_STRING_ia64_archext ".IA_64.archext"
|
||||||
#define ELF_STRING_ia64_pltoff ".IA_64.pltoff"
|
#define ELF_STRING_ia64_pltoff ".IA_64.pltoff"
|
||||||
#define ELF_STRING_ia64_unwind ".IA_64.unwind"
|
#define ELF_STRING_ia64_unwind ".IA_64.unwind"
|
||||||
|
Loading…
Reference in New Issue
Block a user