1/* Architecture and core descriptions for the C-SKY back end.
2   Copyright (C) 2018-2019 Free Software Foundation, Inc.
3   Contributed by C-SKY Microsystems and Mentor Graphics.
4
5   This file is part of GCC.
6
7   GCC is free software; you can redistribute it and/or modify it
8   under the terms of the GNU General Public License as published
9   by the Free Software Foundation; either version 3, or (at your
10   option) any later version.
11
12   GCC is distributed in the hope that it will be useful, but WITHOUT
13   ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
14   or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public
15   License for more details.
16
17   You should have received a copy of the GNU General Public License
18   along with GCC; see the file COPYING3.  If not see
19   <http://www.gnu.org/licenses/>.  */
20
21/* Before using #include to read this file, define a macro:
22
23      CSKY_ARCH(NAME, CORE, ARCH, ISA)
24
25   The NAME is the name of the architecture, represented as a string
26   constant.  The CORE is the identifier for a core representative of
27   this architecture.  ARCH is the architecture revision.  ISA is the
28   detailed architectural capabilities of the core.  */
29
30#ifdef CSKY_ARCH
31CSKY_ARCH ("ck801",  ck801,  CK801,
32	   CSKY_ISA_FEAT (CSKY_ISA_CK801))
33CSKY_ARCH ("ck802",  ck802,  CK802,
34	   CSKY_ISA_FEAT (CSKY_ISA_CK802))
35CSKY_ARCH ("ck803",  ck803,  CK803,
36	   CSKY_ISA_FEAT (CSKY_ISA_CK803))
37CSKY_ARCH ("ck807",  ck807,  CK807,
38	   CSKY_ISA_FEAT (CSKY_ISA_CK807) CSKY_ISA_FEAT (CSKY_ISA_DSP))
39CSKY_ARCH ("ck810",  ck810,  CK810,
40	   CSKY_ISA_FEAT (CSKY_ISA_CK810) CSKY_ISA_FEAT (CSKY_ISA_DSP))
41#endif
42
43
44/* Before using #include to read this file, define a macro:
45
46      CSKY_CORE(CORE_NAME, INTERNAL_IDENT, TUNE_IDENT, ARCH, ISA)
47
48      The isa features of core will inherit the ARCH.
49
50   The CORE_NAME is the name of the core, represented as a string constant.
51   The INTERNAL_IDENT is the name of the core represented as an identifier.
52   This must be unique for each entry in this table.
53   The TUNE_IDENT is the name of the core for which scheduling decisions
54   should be made, represented as an identifier.
55   The ARCH is the architecture revision implemented by the chip.
56   The ISA is the detailed architectural capabilities of the core.  */
57
58#ifdef CSKY_CORE
59/* ck801 Architecture Processors */
60CSKY_CORE ("ck801",    ck801,	 ck801,	   CK801,
61	   CSKY_ISA_FEAT_NONE)
62CSKY_CORE ("ck801t",   ck801t,	 ck801t,   CK801,
63	   CSKY_ISA_FEAT_NONE)
64
65/* ck802 Architecture Processors */
66CSKY_CORE ("ck802",    ck802,	 ck802,	   CK802,
67	   CSKY_ISA_FEAT_NONE)
68CSKY_CORE ("ck802t",   ck802t,	 ck802t,   CK802,
69	   CSKY_ISA_FEAT_NONE)
70CSKY_CORE ("ck802j",   ck802j,	 ck802j,   CK802,
71	   CSKY_ISA_FEAT (isa_bit_java))
72
73/* ck803 Architecture Processors */
74CSKY_CORE ("ck803",    ck803,	 ck803,	   CK803,
75	   CSKY_ISA_FEAT_NONE)
76CSKY_CORE ("ck803h",   ck803h,	 ck803h,   CK803,
77	   CSKY_ISA_FEAT_NONE)
78CSKY_CORE ("ck803t",   ck803t,	 ck803t,   CK803,
79	   CSKY_ISA_FEAT_NONE)
80CSKY_CORE ("ck803ht",  ck803ht,	 ck803ht,  CK803,
81	   CSKY_ISA_FEAT_NONE)
82CSKY_CORE ("ck803f",   ck803f,	 ck803f,   CK803,
83	   CSKY_ISA_FEAT_NONE)
84CSKY_CORE ("ck803fh",  ck803fh,	 ck803fh,  CK803,
85	   CSKY_ISA_FEAT_NONE)
86CSKY_CORE ("ck803e",   ck803e,	 ck803e,   CK803,
87	   CSKY_ISA_FEAT (CSKY_ISA_DSP))
88CSKY_CORE ("ck803eh",  ck803eh,	 ck803eh,  CK803,
89	   CSKY_ISA_FEAT (CSKY_ISA_DSP))
90CSKY_CORE ("ck803et",  ck803et,	 ck803et,  CK803,
91	   CSKY_ISA_FEAT (CSKY_ISA_DSP))
92CSKY_CORE ("ck803eht", ck803eht, ck803eht, CK803,
93	   CSKY_ISA_FEAT (CSKY_ISA_DSP))
94CSKY_CORE ("ck803ef",  ck803ef,	 ck803ef,  CK803,
95	   CSKY_ISA_FEAT (CSKY_ISA_DSP))
96CSKY_CORE ("ck803efh", ck803efh, ck803efh, CK803,
97	   CSKY_ISA_FEAT (CSKY_ISA_DSP))
98CSKY_CORE ("ck803ft",  ck803ft,	 ck803ft,  CK803,
99	   CSKY_ISA_FEAT_NONE)
100CSKY_CORE ("ck803eft", ck803eft, ck803eft, CK803,
101	   CSKY_ISA_FEAT (CSKY_ISA_DSP))
102CSKY_CORE ("ck803efht", ck803efht, ck803efht, CK803,
103	   CSKY_ISA_FEAT (CSKY_ISA_DSP))
104CSKY_CORE ("ck803r1",	 ck803r1,    ck803r1,	 CK803,
105	   CSKY_ISA_FEAT (isa_bit_3E3r1))
106CSKY_CORE ("ck803hr1",	 ck803hr1,   ck803hr1,	 CK803,
107	   CSKY_ISA_FEAT (isa_bit_3E3r1))
108CSKY_CORE ("ck803tr1",	 ck803tr1,   ck803tr1,	 CK803,
109	   CSKY_ISA_FEAT (isa_bit_3E3r1))
110CSKY_CORE ("ck803htr1",	 ck803htr1,  ck803htr1,	 CK803,
111	   CSKY_ISA_FEAT (isa_bit_3E3r1))
112CSKY_CORE ("ck803fr1",	 ck803fr1,   ck803fr1,	 CK803,
113	   CSKY_ISA_FEAT (isa_bit_3E3r1))
114CSKY_CORE ("ck803fhr1",	 ck803fhr1,  ck803fhr1,	 CK803,
115	   CSKY_ISA_FEAT (isa_bit_3E3r1))
116CSKY_CORE ("ck803er1",	 ck803er1,   ck803er1,	 CK803,
117	   CSKY_ISA_FEAT (isa_bit_3E3r1))
118CSKY_CORE ("ck803ehr1",	 ck803ehr1,  ck803ehr1,	 CK803,
119	   CSKY_ISA_FEAT (isa_bit_3E3r1))
120CSKY_CORE ("ck803etr1",	 ck803etr1,  ck803etr1,	 CK803,
121	   CSKY_ISA_FEAT (isa_bit_3E3r1))
122CSKY_CORE ("ck803ehtr1", ck803ehtr1, ck803ehtr1, CK803,
123	   CSKY_ISA_FEAT (isa_bit_3E3r1))
124CSKY_CORE ("ck803efr1",	 ck803efr1,  ck803efr1,	 CK803,
125	   CSKY_ISA_FEAT (isa_bit_3E3r1))
126CSKY_CORE ("ck803efhr1", ck803efhr1, ck803efhr1, CK803,
127	   CSKY_ISA_FEAT (isa_bit_3E3r1))
128CSKY_CORE ("ck803ftr1",	 ck803ftr1,  ck803ftr1,	 CK803,
129	   CSKY_ISA_FEAT (isa_bit_3E3r1))
130CSKY_CORE ("ck803eftr1", ck803eftr1, ck803eftr1, CK803,
131	   CSKY_ISA_FEAT (isa_bit_3E3r1))
132CSKY_CORE ("ck803efhtr1", ck803efhtr1, ck803efhtr1, CK803,
133	   CSKY_ISA_FEAT (isa_bit_3E3r1))
134
135/* ck803s Architecture Processors */
136CSKY_CORE ("ck803s",   ck803s,	 ck803s,   CK803,
137	   CSKY_ISA_FEAT_NONE)
138CSKY_CORE ("ck803st",  ck803st,	 ck803st,  CK803,
139	   CSKY_ISA_FEAT_NONE)
140CSKY_CORE ("ck803se",  ck803se,	 ck803se,  CK803,
141	   CSKY_ISA_FEAT (CSKY_ISA_DSP))
142CSKY_CORE ("ck803sf",  ck803sf,	 ck803sf,  CK803,
143	   CSKY_ISA_FEAT_NONE)
144CSKY_CORE ("ck803sef", ck803sef, ck803sef, CK803,
145	   CSKY_ISA_FEAT (CSKY_ISA_DSP))
146CSKY_CORE ("ck803seft", ck803seft, ck803seft, CK803,
147	   CSKY_ISA_FEAT (CSKY_ISA_DSP))
148
149/* ck807 Architecture Processors */
150CSKY_CORE ("ck807e",   ck807e,	 ck807e,   CK807,
151	   CSKY_ISA_FEAT_NONE)
152CSKY_CORE ("ck807ef",  ck807ef,	 ck807ef,  CK807,
153	   CSKY_ISA_FEAT_NONE)
154CSKY_CORE ("ck807",    ck807,	 ck807,	   CK807,
155	   CSKY_ISA_FEAT_NONE)
156CSKY_CORE ("ck807f",   ck807f,	 ck807f,   CK807,
157	   CSKY_ISA_FEAT_NONE)
158
159/* ck810 Architecture Processors */
160CSKY_CORE ("ck810e",   ck810e,	 ck810e,   CK810,
161	   CSKY_ISA_FEAT_NONE)
162CSKY_CORE ("ck810et",  ck810et,	 ck810et,  CK810,
163	   CSKY_ISA_FEAT_NONE)
164CSKY_CORE ("ck810ef",  ck810ef,	 ck810ef,  CK810,
165	   CSKY_ISA_FEAT_NONE)
166CSKY_CORE ("ck810eft", ck810eft, ck810eft, CK810,
167	   CSKY_ISA_FEAT_NONE)
168CSKY_CORE ("ck810",    ck810,	 ck810,	   CK810,
169	   CSKY_ISA_FEAT_NONE)
170CSKY_CORE ("ck810v",   ck810v,	 ck810v,   CK810,
171	   CSKY_ISA_FEAT_NONE)
172CSKY_CORE ("ck810f",   ck810f,	 ck810f,   CK810,
173	   CSKY_ISA_FEAT_NONE)
174CSKY_CORE ("ck810t",   ck810t,	 ck810t,   CK810,
175	   CSKY_ISA_FEAT_NONE)
176CSKY_CORE ("ck810fv",  ck810fv,	 ck810fv,  CK810,
177	   CSKY_ISA_FEAT_NONE)
178CSKY_CORE ("ck810tv",  ck810tv,	 ck810tv,  CK810,
179	   CSKY_ISA_FEAT_NONE)
180CSKY_CORE ("ck810ft",  ck810ff,	 ck810ft,  CK810,
181	   CSKY_ISA_FEAT_NONE)
182CSKY_CORE ("ck810ftv", ck810ftv, ck810ftv, CK810,
183	   CSKY_ISA_FEAT_NONE)
184#endif
185
186
187/* Before using #include to read this file, define a macro:
188
189      CSKY_FPU(NAME, CNAME, ISA)
190
191   NAME is the publicly visible option name.
192   CNAME is a C-compatible variable name substring.
193   ISA is the list of feature bits that this FPU provides.  */
194
195#ifdef CSKY_FPU
196CSKY_FPU ("fpv2_sf",   fpv2_sf,	  CSKY_ISA_FEAT (CSKY_ISA_FPv2_SF))
197CSKY_FPU ("fpv2",      fpv2,	  CSKY_ISA_FEAT (CSKY_ISA_FPv2))
198CSKY_FPU ("fpv2_divd", fpv2_divd, CSKY_ISA_FEAT (CSKY_ISA_FPv2_DIVD))
199#endif
200