xref: /netbsd-src/external/gpl3/binutils.old/dist/include/elf/vax.h (revision e992f068c547fd6e84b3f104dc2340adcc955732)
175fd0b74Schristos /* VAX ELF support for BFD.
2*e992f068Schristos    Copyright (C) 2002-2022 Free Software Foundation, Inc.
375fd0b74Schristos    Contributed by Matt Thomas <matt@3am-software.com>.
475fd0b74Schristos 
575fd0b74Schristos    This file is part of BFD, the Binary File Descriptor library.
675fd0b74Schristos 
775fd0b74Schristos    This program is free software; you can redistribute it and/or modify
875fd0b74Schristos    it under the terms of the GNU General Public License as published by
975fd0b74Schristos    the Free Software Foundation; either version 3 of the License, or
1075fd0b74Schristos    (at your option) any later version.
1175fd0b74Schristos 
1275fd0b74Schristos    This program is distributed in the hope that it will be useful,
1375fd0b74Schristos    but WITHOUT ANY WARRANTY; without even the implied warranty of
1475fd0b74Schristos    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
1575fd0b74Schristos    GNU General Public License for more details.
1675fd0b74Schristos 
1775fd0b74Schristos    You should have received a copy of the GNU General Public License
1875fd0b74Schristos    along with this program; if not, write to the Free Software Foundation,
1975fd0b74Schristos    Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA.  */
2075fd0b74Schristos 
2175fd0b74Schristos #ifndef _ELF_VAX_H
2275fd0b74Schristos #define _ELF_VAX_H
2375fd0b74Schristos 
2475fd0b74Schristos #include "elf/reloc-macros.h"
2575fd0b74Schristos 
2675fd0b74Schristos /* Relocation types.  */
2775fd0b74Schristos START_RELOC_NUMBERS (elf_vax_reloc_type)
2875fd0b74Schristos   RELOC_NUMBER (R_VAX_NONE, 0)		/* No reloc */
2975fd0b74Schristos   RELOC_NUMBER (R_VAX_32, 1)		/* Direct 32 bit  */
3075fd0b74Schristos   RELOC_NUMBER (R_VAX_16, 2)		/* Direct 16 bit  */
3175fd0b74Schristos   RELOC_NUMBER (R_VAX_8, 3)		/* Direct 8 bit  */
3275fd0b74Schristos   RELOC_NUMBER (R_VAX_PC32, 4)		/* PC relative 32 bit */
3375fd0b74Schristos   RELOC_NUMBER (R_VAX_PC16, 5)		/* PC relative 16 bit */
3475fd0b74Schristos   RELOC_NUMBER (R_VAX_PC8, 6)		/* PC relative 8 bit */
3575fd0b74Schristos   RELOC_NUMBER (R_VAX_GOT32, 7)		/* 32 bit PC relative GOT entry */
3675fd0b74Schristos   RELOC_NUMBER (R_VAX_PLT32, 13)	/* 32 bit PC relative PLT address */
3775fd0b74Schristos   RELOC_NUMBER (R_VAX_COPY, 19)		/* Copy symbol at runtime */
3875fd0b74Schristos   RELOC_NUMBER (R_VAX_GLOB_DAT, 20)	/* Create GOT entry */
3975fd0b74Schristos   RELOC_NUMBER (R_VAX_JMP_SLOT, 21)	/* Create PLT entry */
4075fd0b74Schristos   RELOC_NUMBER (R_VAX_RELATIVE, 22)	/* Adjust by program base */
4175fd0b74Schristos   /* These are GNU extensions to enable C++ vtable garbage collection.  */
4275fd0b74Schristos   RELOC_NUMBER (R_VAX_GNU_VTINHERIT, 23)
4375fd0b74Schristos   RELOC_NUMBER (R_VAX_GNU_VTENTRY, 24)
4475fd0b74Schristos END_RELOC_NUMBERS (R_VAX_max)
4575fd0b74Schristos 
4675fd0b74Schristos /* Processor specific flags for the ELF header e_flags field.  */
4775fd0b74Schristos #define EF_VAX_NONPIC		0x0001	/* Object contains non-PIC code */
4875fd0b74Schristos #define EF_VAX_DFLOAT		0x0100	/* Object contains D-Float insn.  */
4975fd0b74Schristos #define EF_VAX_GFLOAT		0x0200	/* Object contains G-Float insn.  */
5075fd0b74Schristos 
5175fd0b74Schristos #endif
52