Update ROCm for multi-target support
[deliverable/binutils-gdb.git] / bfd / cpu-amdgcn.c
CommitLineData
5922befa
LM
1/* BFD support for the AMDGCN gpu.
2
4e5106e6
LM
3 Copyright (C) 2019-2020 Free Software Foundation, Inc.
4 Copyright (C) 2019-2020 Advanced Micro Devices, Inc. All rights reserved.
5922befa
LM
5
6 This file is part of GDB.
7
8 This program is free software; you can redistribute it and/or modify
9 it under the terms of the GNU General Public License as published by
10 the Free Software Foundation; either version 3 of the License, or
11 (at your option) any later version.
12
13 This program is distributed in the hope that it will be useful,
14 but WITHOUT ANY WARRANTY; without even the implied warranty of
15 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 GNU General Public License for more details.
17
18 You should have received a copy of the GNU General Public License
19 along with this program. If not, see <http://www.gnu.org/licenses/>. */
20
21#include "sysdep.h"
22#include "bfd.h"
23#include "libbfd.h"
24
25#define N(MACHINE, PRINTABLE_NAME, DEFAULT, NEXT) \
26 { \
27 32, /* 32 bits in a word */ \
28 64, /* 64 bits in an address */ \
29 8, /* 8 bits in a byte */ \
30 bfd_arch_amdgcn, \
31 MACHINE, \
32 "amdgcn", \
33 PRINTABLE_NAME, \
34 3, /* section align power */ \
35 DEFAULT, \
36 bfd_default_compatible, \
37 bfd_default_scan, \
38 bfd_arch_default_fill, \
39 NEXT, \
40 0 \
41 }
42
43#define NN(index) (&arch_info_struct[index])
44
45static const bfd_arch_info_type arch_info_struct[] =
46{
6c81ab16
LM
47 N (bfd_mach_amdgcn_gfx900, "amdgcn:gfx900", FALSE, NN(1)),
48 N (bfd_mach_amdgcn_gfx902, "amdgcn:gfx902", FALSE, NN(2)),
49 N (bfd_mach_amdgcn_gfx904, "amdgcn:gfx904", FALSE, NN(3)),
50 N (bfd_mach_amdgcn_gfx906, "amdgcn:gfx906", FALSE, NN(4)),
51 N (bfd_mach_amdgcn_gfx908, "amdgcn:gfx908", FALSE, 0),
5922befa
LM
52};
53
54const bfd_arch_info_type bfd_amdgcn_arch =
55 N (bfd_mach_amdgcn_unknown, "amdgcn", TRUE, NN(0));
This page took 0.025141 seconds and 4 git commands to generate.