summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorDave Brolley <brolley@redhat.com>2002-06-18 21:15:57 +0000
committerDave Brolley <brolley@redhat.com>2002-06-18 21:15:57 +0000
commitac547a3d9ab76f95a8d4c73b61e98bcc558b92f4 (patch)
tree38e7f3af5ceefb90c4dab223c6d9fdb22d436f53 /include
parent619d08f24b426bf6f8d8f7496df358c042d81106 (diff)
downloadgdb-ac547a3d9ab76f95a8d4c73b61e98bcc558b92f4.tar.gz
2002-06-18 Dave Brolley <brolley@redhat.com>
From Catherine Moore, Michael Meissner, Dave Brolley: * common.h (EM_CYGNUS_FRV): New macro. * frv.h: New file.
Diffstat (limited to 'include')
-rw-r--r--include/elf/ChangeLog6
-rw-r--r--include/elf/common.h2
-rw-r--r--include/elf/frv.h95
3 files changed, 103 insertions, 0 deletions
diff --git a/include/elf/ChangeLog b/include/elf/ChangeLog
index 2a1f6b41d81..cc8315d5d12 100644
--- a/include/elf/ChangeLog
+++ b/include/elf/ChangeLog
@@ -1,3 +1,9 @@
+2002-06-18 Dave Brolley <brolley@redhat.com>
+
+ From Catherine Moore, Michael Meissner, Dave Brolley:
+ * common.h (EM_CYGNUS_FRV): New macro.
+ * frv.h: New file.
+
2002-06-06 Lars Brinkhoff <lars@nocrew.org>
* common.h: Change registry@sco.com to registry@caldera.com.
diff --git a/include/elf/common.h b/include/elf/common.h
index ce3974eec7a..f4663df2ccb 100644
--- a/include/elf/common.h
+++ b/include/elf/common.h
@@ -244,6 +244,8 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define EM_XSTORMY16 0xad45
+/* FRV magic number - no EABI available??. */
+#define EM_CYGNUS_FRV 0x5441
/* See the above comment before you add a new EM_* value here. */
/* Values for e_version. */
diff --git a/include/elf/frv.h b/include/elf/frv.h
new file mode 100644
index 00000000000..65ce97d1ee3
--- /dev/null
+++ b/include/elf/frv.h
@@ -0,0 +1,95 @@
+/* FRV ELF support for BFD.
+ Copyright (C) 2002 Free Software Foundation, Inc.
+
+This file is part of BFD, the Binary File Descriptor library.
+
+This program is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2 of the License, or
+(at your option) any later version.
+
+This program is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with this program; if not, write to the Free Software Foundation, Inc.,
+59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+
+#ifndef _ELF_FRV_H
+#define _ELF_FRV_H
+
+#include "elf/reloc-macros.h"
+
+/* Relocations. */
+START_RELOC_NUMBERS (elf_frv_reloc_type)
+ RELOC_NUMBER (R_FRV_NONE, 0)
+ RELOC_NUMBER (R_FRV_32, 1)
+ RELOC_NUMBER (R_FRV_LABEL16, 2)
+ RELOC_NUMBER (R_FRV_LABEL24, 3)
+ RELOC_NUMBER (R_FRV_LO16, 4)
+ RELOC_NUMBER (R_FRV_HI16, 5)
+ RELOC_NUMBER (R_FRV_GPREL12, 6)
+ RELOC_NUMBER (R_FRV_GPRELU12, 7)
+ RELOC_NUMBER (R_FRV_GPREL32, 8)
+ RELOC_NUMBER (R_FRV_GPRELHI, 9)
+ RELOC_NUMBER (R_FRV_GPRELLO, 10)
+ RELOC_NUMBER (R_FRV_GNU_VTINHERIT, 200)
+ RELOC_NUMBER (R_FRV_GNU_VTENTRY, 201)
+END_RELOC_NUMBERS(R_FRV_max)
+
+/* Processor specific flags for the ELF header e_flags field. */
+ /* gpr support */
+#define EF_FRV_GPR_MASK 0x00000003 /* mask for # of gprs */
+#define EF_FRV_GPR_32 0x00000001 /* -mgpr-32 */
+#define EF_FRV_GPR_64 0x00000002 /* -mgpr-64 */
+
+ /* fpr support */
+#define EF_FRV_FPR_MASK 0x0000000c /* mask for # of fprs */
+#define EF_FRV_FPR_32 0x00000004 /* -mfpr-32 */
+#define EF_FRV_FPR_64 0x00000008 /* -mfpr-64 */
+#define EF_FRV_FPR_NONE 0x0000000c /* -msoft-float */
+
+ /* double word support */
+#define EF_FRV_DWORD_MASK 0x00000030 /* mask for dword support */
+#define EF_FRV_DWORD_YES 0x00000010 /* use double word insns */
+#define EF_FRV_DWORD_NO 0x00000020 /* don't use double word insn*/
+
+#define EF_FRV_DOUBLE 0x00000040 /* -mdouble */
+#define EF_FRV_MEDIA 0x00000080 /* -mmedia */
+
+#define EF_FRV_PIC 0x00000100 /* -fpic */
+#define EF_FRV_NON_PIC_RELOCS 0x00000200 /* used non pic safe relocs */
+
+#define EF_FRV_MULADD 0x00000400 /* -mmuladd */
+#define EF_FRV_BIGPIC 0x00000800 /* -fPIC */
+#define EF_FRV_LIBPIC 0x00001000 /* -mlibrary-pic */
+#define EF_FRV_G0 0x00002000 /* -G 0, no small data ptr */
+#define EF_FRV_NOPACK 0x00004000 /* -mnopack */
+
+#define EF_FRV_CPU_MASK 0xff000000 /* specific cpu bits */
+#define EF_FRV_CPU_GENERIC 0x00000000 /* generic FRV */
+#define EF_FRV_CPU_FR500 0x01000000 /* FRV500 */
+#define EF_FRV_CPU_FR300 0x02000000 /* FRV300 */
+#define EF_FRV_CPU_SIMPLE 0x03000000 /* SIMPLE */
+#define EF_FRV_CPU_TOMCAT 0x04000000 /* Tomcat, FR500 prototype */
+#define EF_FRV_CPU_FR400 0x05000000 /* FRV400 */
+
+ /* Mask of PIC related bits */
+#define EF_FRV_PIC_FLAGS (EF_FRV_PIC | EF_FRV_LIBPIC | EF_FRV_BIGPIC)
+
+ /* Mask of all flags */
+#define EF_FRV_ALL_FLAGS (EF_FRV_GPR_MASK | \
+ EF_FRV_FPR_MASK | \
+ EF_FRV_DWORD_MASK | \
+ EF_FRV_DOUBLE | \
+ EF_FRV_MEDIA | \
+ EF_FRV_PIC_FLAGS | \
+ EF_FRV_NON_PIC_RELOCS | \
+ EF_FRV_MULADD | \
+ EF_FRV_G0 | \
+ EF_FRV_NOPACK | \
+ EF_FRV_CPU_MASK)
+
+#endif /* _ELF_FRV_H */