Coverage Report

Created: 2025-06-24 06:45

/src/binutils-gdb/include/elf/z80.h
Line
Count
Source (jump to first uncovered line)
1
/* Z80 ELF support for BFD.
2
   Copyright (C) 1999-2025 Free Software Foundation, Inc.
3
   Contributed by Sergey Belyashov <sergey.belyashov@gmail.com>
4
5
   This file is part of BFD, the Binary File Descriptor library.
6
7
   This program is free software; you can redistribute it and/or modify
8
   it under the terms of the GNU General Public License as published by
9
   the Free Software Foundation; either version 3 of the License, or
10
   (at your option) any later version.
11
12
   This program is distributed in the hope that it will be useful,
13
   but WITHOUT ANY WARRANTY; without even the implied warranty of
14
   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
15
   GNU General Public License for more details.
16
17
   You should have received a copy of the GNU General Public License
18
   along with this program; if not, write to the Free Software Foundation,
19
   Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA.  */
20
21
#ifndef _ELF_Z80_H
22
#define _ELF_Z80_H
23
24
#include "elf/reloc-macros.h"
25
26
/* Processor specific flags for the ELF header e_flags field.  */
27
3.40k
#define EF_Z80_MACH_Z80      0x01
28
673
#define EF_Z80_MACH_Z180     0x02
29
673
#define EF_Z80_MACH_R800     0x03
30
1.20k
#define EF_Z80_MACH_EZ80_Z80 0x04
31
489
#define EF_Z80_MACH_EZ80_ADL 0x84
32
1.20k
#define EF_Z80_MACH_GBZ80    0x05
33
771
#define EF_Z80_MACH_Z80N     0x06
34
8.53k
#define EF_Z80_MACH_MSK      0xff
35
36
/* Relocations.  */
37
1.31k
START_RELOC_NUMBERS (elf_z80_reloc_type)
38
1.31k
     RELOC_NUMBER (R_Z80_NONE,   0)
39
24
     RELOC_NUMBER (R_Z80_8,    1)
40
50
     RELOC_NUMBER (R_Z80_8_DIS,    2)
41
9
     RELOC_NUMBER (R_Z80_8_PCREL,  3)
42
13
     RELOC_NUMBER (R_Z80_16,     4)
43
7
     RELOC_NUMBER (R_Z80_24,     5)
44
8
     RELOC_NUMBER (R_Z80_32,     6)
45
25
     RELOC_NUMBER (R_Z80_BYTE0,    7)
46
17
     RELOC_NUMBER (R_Z80_BYTE1,    8)
47
56
     RELOC_NUMBER (R_Z80_BYTE2,    9)
48
7
     RELOC_NUMBER (R_Z80_BYTE3,    10)
49
6
     RELOC_NUMBER (R_Z80_WORD0,    11)
50
17
     RELOC_NUMBER (R_Z80_WORD1,    12)
51
7
     RELOC_NUMBER (R_Z80_16_BE,    13)
52
667
END_RELOC_NUMBERS (R_Z80_max)
53
54
#endif /* _ELF_Z80_H */