xref: /netbsd-src/external/gpl3/gdb.old/dist/gdb/arch/csky.c (revision 6881a4007f077b54e5f51159c52b9b25f57deb0d)
1*6881a400Schristos /* Copyright (C) 2022-2023 Free Software Foundation, Inc.
2*6881a400Schristos 
3*6881a400Schristos    This file is part of GDB.
4*6881a400Schristos 
5*6881a400Schristos    This program is free software; you can redistribute it and/or modify
6*6881a400Schristos    it under the terms of the GNU General Public License as published by
7*6881a400Schristos    the Free Software Foundation; either version 3 of the License, or
8*6881a400Schristos    (at your option) any later version.
9*6881a400Schristos 
10*6881a400Schristos    This program is distributed in the hope that it will be useful,
11*6881a400Schristos    but WITHOUT ANY WARRANTY; without even the implied warranty of
12*6881a400Schristos    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13*6881a400Schristos    GNU General Public License for more details.
14*6881a400Schristos 
15*6881a400Schristos    You should have received a copy of the GNU General Public License
16*6881a400Schristos    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
17*6881a400Schristos 
18*6881a400Schristos #include "gdbsupport/common-defs.h"
19*6881a400Schristos #include "csky.h"
20*6881a400Schristos #include <stdlib.h>
21*6881a400Schristos 
22*6881a400Schristos #include "../features/cskyv2-linux.c"
23*6881a400Schristos 
24*6881a400Schristos target_desc_up
25*6881a400Schristos csky_create_target_description (void)
26*6881a400Schristos {
27*6881a400Schristos   /* Now we should create a new target description.  */
28*6881a400Schristos   target_desc_up tdesc = allocate_target_description ();
29*6881a400Schristos 
30*6881a400Schristos #ifndef IN_PROCESS_AGENT
31*6881a400Schristos   std::string arch_name = "csky";
32*6881a400Schristos   set_tdesc_architecture (tdesc.get (), arch_name.c_str ());
33*6881a400Schristos #endif
34*6881a400Schristos 
35*6881a400Schristos   create_feature_cskyv2_linux (tdesc.get (), 0);
36*6881a400Schristos 
37*6881a400Schristos   return tdesc;
38*6881a400Schristos }
39