diff options
author | Corinna Vinschen <corinna@vinschen.de> | 2003-10-23 09:43:20 +0000 |
---|---|---|
committer | Corinna Vinschen <corinna@vinschen.de> | 2003-10-23 09:43:20 +0000 |
commit | a9178a2f3855dae2cc0341e82dc16307b73a3aaa (patch) | |
tree | d057805c64f813244e5bb9244f28d0f25adca646 /include | |
parent | 5aa04fdff8518bdf9e0d5517ad66213407fef9ab (diff) | |
download | gdb-a9178a2f3855dae2cc0341e82dc16307b73a3aaa.zip gdb-a9178a2f3855dae2cc0341e82dc16307b73a3aaa.tar.gz gdb-a9178a2f3855dae2cc0341e82dc16307b73a3aaa.tar.bz2 |
* sh.h (EF_SH4A, EF_SH4AL_DSP, EF_SH4_NOFPU, EF_SH4A_NOFPU): New.
(EF_SH_MERGE_MACH): Combine them.
Diffstat (limited to 'include')
-rw-r--r-- | include/elf/ChangeLog | 6 | ||||
-rw-r--r-- | include/elf/sh.h | 21 |
2 files changed, 26 insertions, 1 deletions
diff --git a/include/elf/ChangeLog b/include/elf/ChangeLog index dbf3297..724ac71 100644 --- a/include/elf/ChangeLog +++ b/include/elf/ChangeLog @@ -1,3 +1,9 @@ +2003-10-22 Alexandre Oliva <aoliva@redhat.com>, + Michael Snyder <msnyder@redhat.com> + + * sh.h (EF_SH4A, EF_SH4AL_DSP, EF_SH4_NOFPU, EF_SH4A_NOFPU): New. + (EF_SH_MERGE_MACH): Combine them. + 2003-10-18 Hans-Peter Nilsson <hp@bitrange.com> * mmix.h (R_MMIX_PUSHJ_STUBBABLE): New reloc number. diff --git a/include/elf/sh.h b/include/elf/sh.h index 4286235..15d460d 100644 --- a/include/elf/sh.h +++ b/include/elf/sh.h @@ -27,13 +27,18 @@ #define EF_SH1 1 #define EF_SH2 2 #define EF_SH3 3 -#define EF_SH_HAS_DSP(flags) ((flags) & 4) +#define EF_SH_HAS_DSP(flags) (((flags) & EF_SH_MACH_MASK & ~3) == 4) #define EF_SH_DSP 4 #define EF_SH3_DSP 5 +#define EF_SH4AL_DSP 6 #define EF_SH_HAS_FP(flags) ((flags) & 8) #define EF_SH3E 8 #define EF_SH4 9 #define EF_SH2E 11 +#define EF_SH4A 12 + +#define EF_SH4_NOFPU 0x10 +#define EF_SH4A_NOFPU 0x11 /* This one can only mix in objects from other EF_SH5 objects. */ #define EF_SH5 10 @@ -56,6 +61,20 @@ : (((mach1) == EF_SH3E && (mach2) == EF_SH_UNKNOWN) \ || ((mach2) == EF_SH3E && (mach1) == EF_SH_UNKNOWN)) \ ? EF_SH4 \ + /* ??? SH4? Why not SH3E? */ \ + : ((((mach1) == EF_SH4_NOFPU || (mach1) == EF_SH4A_NOFPU) \ + && EF_SH_HAS_DSP (mach2)) \ + || (((mach2) == EF_SH4_NOFPU || (mach2) == EF_SH4A_NOFPU) \ + && EF_SH_HAS_DSP (mach1))) \ + ? EF_SH4AL_DSP \ + : ((mach1) == EF_SH4_NOFPU && EF_SH_HAS_FP (mach2)) \ + ? ((mach2) < EF_SH4A) ? EF_SH4 : (mach2) \ + : ((mach2) == EF_SH4_NOFPU && EF_SH_HAS_FP (mach1)) \ + ? ((mach1) < EF_SH4A) ? EF_SH4 : (mach1) \ + : ((mach1) == EF_SH4A_NOFPU && EF_SH_HAS_FP (mach2)) \ + ? ((mach2) <= EF_SH4A) ? EF_SH4A : (mach2) \ + : ((mach2) == EF_SH4A_NOFPU && EF_SH_HAS_FP (mach1)) \ + ? ((mach1) <= EF_SH4A) ? EF_SH4A : (mach1) \ : (((mach1) == EF_SH2E ? 7 : (mach1)) > ((mach2) == EF_SH2E ? 7 : (mach2)) \ ? (mach1) : (mach2))) |