summaryrefslogtreecommitdiff
path: root/gcc/genoutput.c
diff options
context:
space:
mode:
authorrsandifo <rsandifo@138bc75d-0d04-0410-961f-82ee72b054a4>2014-06-03 07:27:13 +0000
committerrsandifo <rsandifo@138bc75d-0d04-0410-961f-82ee72b054a4>2014-06-03 07:27:13 +0000
commitdd41ed5916255a0b666d3a7a5cb2fb7afcb33049 (patch)
tree9491259b0d05c2a1d5ac9632e9d177ebbae81e81 /gcc/genoutput.c
parentebcc7e92dfdfee12c34282c36b82a463f9b5003d (diff)
downloadgcc-dd41ed5916255a0b666d3a7a5cb2fb7afcb33049.tar.gz
gcc/
* defaults.h (USE_MD_CONSTRAINTS, EXTRA_MEMORY_CONSTRAINT) (EXTRA_ADDRESS_CONSTRAINT, DEFAULT_CONSTRAINT_LEN, CONSTRAINT_LEN) (CONST_OK_FOR_CONSTRAINT_P, CONST_DOUBLE_OK_FOR_LETTER_P) (REG_CLASS_FROM_CONSTRAINT, EXTRA_CONSTRAINT_STR): Delete definitions in this file. (REG_CLASS_FROM_LETTER, CONST_OK_FOR_LETTER_P) (CONST_DOUBLE_OK_FOR_LETTER_P, EXTRA_CONSTRAINT): Move poising to... * system.h: ...here and make it unconditional. * target.def (conditional_register_usage): Mention define_register_constraint instead of old-style constraint macros. * doc/tm.texi.in: Remove documentation for old-style constraint macros. * doc/tm.texi: Regenerate. * genoutput.c: Remove USE_MD_CONSTRAINTS conditions and all code protected by !USE_MD_CONSTRAINTS. * config/frv/frv.md: Remove quote from old version of documentation. * config/frv/frv.c (frv_conditional_register_usage): Likewise. * config/m32r/m32r.c (easy_di_const, easy_df_const): Avoid mentioning CONST_DOUBLE_OK_FOR_LETTER. * config/sh/constraints.md: Likewise EXTRA_CONSTRAINT. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@211161 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/genoutput.c')
-rw-r--r--gcc/genoutput.c66
1 files changed, 0 insertions, 66 deletions
diff --git a/gcc/genoutput.c b/gcc/genoutput.c
index b3ce120f33a..cdd722d43aa 100644
--- a/gcc/genoutput.c
+++ b/gcc/genoutput.c
@@ -197,8 +197,6 @@ static void gen_peephole (rtx, int);
static void gen_expand (rtx, int);
static void gen_split (rtx, int);
-#ifdef USE_MD_CONSTRAINTS
-
struct constraint_data
{
struct constraint_data *next_this_letter;
@@ -217,14 +215,6 @@ constraints_by_letter_table[1 << CHAR_BIT];
static int mdep_constraint_len (const char *, int, int);
static void note_constraint (rtx, int);
-
-#else /* !USE_MD_CONSTRAINTS */
-
-static void check_constraint_len (void);
-static int constraint_len (const char *, int);
-
-#endif /* !USE_MD_CONSTRAINTS */
-
static void
output_prologue (void)
@@ -786,7 +776,6 @@ validate_insn_alternatives (struct data *d)
error_with_line (d->lineno,
"character '%c' can only be used at the"
" beginning of a constraint string", c);
-#ifdef USE_MD_CONSTRAINTS
if (ISSPACE (c) || strchr (indep_constraints, c))
len = 1;
else if (ISDIGIT (c))
@@ -799,18 +788,6 @@ validate_insn_alternatives (struct data *d)
}
else
len = mdep_constraint_len (p, d->lineno, start);
-#else
- len = CONSTRAINT_LEN (c, p);
-
- if (len < 1 || (len > 1 && strchr (",#*+=&%!0123456789", c)))
- {
- error_with_line (d->lineno,
- "invalid length %d for char '%c' in"
- " alternative %d of operand %d",
- len, c, which_alternative, start);
- len = 1;
- }
-#endif
if (c == ',')
{
@@ -914,9 +891,6 @@ gen_insn (rtx insn, int lineno)
d->n_operands = stats.num_insn_operands;
d->n_dups = stats.num_dups;
-#ifndef USE_MD_CONSTRAINTS
- check_constraint_len ();
-#endif
validate_insn_operands (d);
validate_insn_alternatives (d);
validate_optab_operands (d);
@@ -1106,14 +1080,12 @@ main (int argc, char **argv)
gen_split (desc, line_no);
break;
-#ifdef USE_MD_CONSTRAINTS
case DEFINE_CONSTRAINT:
case DEFINE_REGISTER_CONSTRAINT:
case DEFINE_ADDRESS_CONSTRAINT:
case DEFINE_MEMORY_CONSTRAINT:
note_constraint (desc, line_no);
break;
-#endif
default:
break;
@@ -1169,8 +1141,6 @@ strip_whitespace (const char *s)
return q;
}
-#ifdef USE_MD_CONSTRAINTS
-
/* Record just enough information about a constraint to allow checking
of operand constraint strings above, in validate_insn_alternatives.
Does not validate most properties of the constraint itself; does
@@ -1261,39 +1231,3 @@ mdep_constraint_len (const char *s, int lineno, int opno)
message_with_line (lineno, "note: in operand %d", opno);
return 1; /* safe */
}
-
-#else
-/* Verify that DEFAULT_CONSTRAINT_LEN is used properly and not
- tampered with. This isn't bullet-proof, but it should catch
- most genuine mistakes. */
-static void
-check_constraint_len (void)
-{
- const char *p;
- int d;
-
- for (p = ",#*+=&%!1234567890"; *p; p++)
- for (d = -9; d < 9; d++)
- gcc_assert (constraint_len (p, d) == d);
-}
-
-static int
-constraint_len (const char *p, int genoutput_default_constraint_len)
-{
- /* Check that we still match defaults.h . First we do a generation-time
- check that fails if the value is not the expected one... */
- gcc_assert (DEFAULT_CONSTRAINT_LEN (*p, p) == 1);
- /* And now a compile-time check that should give a diagnostic if the
- definition doesn't exactly match. */
-#define DEFAULT_CONSTRAINT_LEN(C,STR) 1
- /* Now re-define DEFAULT_CONSTRAINT_LEN so that we can verify it is
- being used. */
-#undef DEFAULT_CONSTRAINT_LEN
-#define DEFAULT_CONSTRAINT_LEN(C,STR) \
- ((C) != *p || STR != p ? -1 : genoutput_default_constraint_len)
- return CONSTRAINT_LEN (*p, p);
- /* And set it back. */
-#undef DEFAULT_CONSTRAINT_LEN
-#define DEFAULT_CONSTRAINT_LEN(C,STR) 1
-}
-#endif