Mercurial > hg > CbC > CbC_gcc
comparison gcc/gengenrtl.c @ 131:84e7813d76e9
gcc-8.2
author | mir3636 |
---|---|
date | Thu, 25 Oct 2018 07:37:49 +0900 |
parents | 04ced10e8804 |
children | 1830386684a0 |
comparison
equal
deleted
inserted
replaced
111:04ced10e8804 | 131:84e7813d76e9 |
---|---|
1 /* Generate code to allocate RTL structures. | 1 /* Generate code to allocate RTL structures. |
2 Copyright (C) 1997-2017 Free Software Foundation, Inc. | 2 Copyright (C) 1997-2018 Free Software Foundation, Inc. |
3 | 3 |
4 This file is part of GCC. | 4 This file is part of GCC. |
5 | 5 |
6 GCC is free software; you can redistribute it and/or modify it under | 6 GCC is free software; you can redistribute it and/or modify it under |
7 the terms of the GNU General Public License as published by the Free | 7 the terms of the GNU General Public License as published by the Free |
51 case 'i': | 51 case 'i': |
52 return "int "; | 52 return "int "; |
53 | 53 |
54 case 'w': | 54 case 'w': |
55 return "HOST_WIDE_INT "; | 55 return "HOST_WIDE_INT "; |
56 | |
57 case 'p': | |
58 return "poly_uint16 "; | |
56 | 59 |
57 case 's': | 60 case 's': |
58 return "const char *"; | 61 return "const char *"; |
59 | 62 |
60 case 'e': case 'u': | 63 case 'e': case 'u': |
154 excluded_rtx (int idx) | 157 excluded_rtx (int idx) |
155 { | 158 { |
156 return (strcmp (defs[idx].enumname, "VAR_LOCATION") == 0 | 159 return (strcmp (defs[idx].enumname, "VAR_LOCATION") == 0 |
157 || strcmp (defs[idx].enumname, "CONST_DOUBLE") == 0 | 160 || strcmp (defs[idx].enumname, "CONST_DOUBLE") == 0 |
158 || strcmp (defs[idx].enumname, "CONST_WIDE_INT") == 0 | 161 || strcmp (defs[idx].enumname, "CONST_WIDE_INT") == 0 |
162 || strcmp (defs[idx].enumname, "CONST_POLY_INT") == 0 | |
159 || strcmp (defs[idx].enumname, "CONST_FIXED") == 0); | 163 || strcmp (defs[idx].enumname, "CONST_FIXED") == 0); |
160 } | 164 } |
161 | 165 |
162 /* Place a list of all format specifiers we use into the array FORMAT. */ | 166 /* Place a list of all format specifiers we use into the array FORMAT. */ |
163 | 167 |
253 puts (" rt = rtx_alloc (code PASS_MEM_STAT);\n"); | 257 puts (" rt = rtx_alloc (code PASS_MEM_STAT);\n"); |
254 | 258 |
255 puts (" PUT_MODE_RAW (rt, mode);"); | 259 puts (" PUT_MODE_RAW (rt, mode);"); |
256 | 260 |
257 for (p = format, i = j = 0; *p ; ++p, ++i) | 261 for (p = format, i = j = 0; *p ; ++p, ++i) |
258 if (*p != '0') | 262 if (*p == '0') |
263 printf (" X0EXP (rt, %d) = NULL_RTX;\n", i); | |
264 else if (*p == 'p') | |
265 printf (" SUBREG_BYTE (rt) = arg%d;\n", j++); | |
266 else | |
259 printf (" %s (rt, %d) = arg%d;\n", accessor_from_format (*p), i, j++); | 267 printf (" %s (rt, %d) = arg%d;\n", accessor_from_format (*p), i, j++); |
260 else | |
261 printf (" X0EXP (rt, %d) = NULL_RTX;\n", i); | |
262 | 268 |
263 puts ("\n return rt;\n}\n"); | 269 puts ("\n return rt;\n}\n"); |
264 printf ("#define gen_rtx_fmt_%s(c, m", format); | 270 printf ("#define gen_rtx_fmt_%s(c, m", format); |
265 for (p = format, i = 0; *p != 0; p++) | 271 for (p = format, i = 0; *p != 0; p++) |
266 if (*p != '0') | 272 if (*p != '0') |