summaryrefslogtreecommitdiff
path: root/gcc/genemit.c
diff options
context:
space:
mode:
authorjakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4>2010-04-07 20:27:37 +0000
committerjakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4>2010-04-07 20:27:37 +0000
commit4081d362fba108e17784f385774bfae44e2dcee2 (patch)
tree6753832a3718adf7bc216f0e33a4f7458672d44f /gcc/genemit.c
parent421351fbb102e20c5d53e67099dc7152dec6c00f (diff)
downloadgcc-4081d362fba108e17784f385774bfae44e2dcee2.tar.gz
* tree-ssa-pre.c (my_rev_post_order_compute): Remove set but not
used count variable. * genemit.c (gen_expand, gen_split): Avoid set but not used warnings when operandN variables aren't used in the body of the expander or splitter. * tree-outof-ssa.c (FOR_EACH_ELIM_GRAPH_SUCC, FOR_EACH_ELIM_GRAPH_PRED): Avoid set but not used warnings. * tree-ssa-operands.h (FOR_EACH_SSA_TREE_OPERAND): Likewise. * tree-flow.h (FOR_EACH_IMM_USE_FAST, FOR_EACH_IMM_USE_STMT, FOR_EACH_IMM_USE_ON_STMT): Likewise. * tree.h (FOR_EACH_CONSTRUCTOR_ELT): Likewise. * tree.c (PROCESS_ARG): Likewise. fortran/ * parse.c (parse_derived, parse_enum): Avoid set but not used warning. java/ * expr.c (process_jvm_instruction): Avoid set but not used warning. * builtins.c (compareAndSwapInt_builtin, compareAndSwapLong_builtin, getVolatile_builtin): Likewise. libjava/ * exception.cc (_Jv_Throw): Avoid set but not used warning. * include/java-assert.h (JvAssertMessage, JvAssert): Use argument in sizeof to avoid set but not used warnings. libjava/classpath/ * native/jni/midi-alsa/gnu_javax_sound_midi_alsa_AlsaPortDevice.c (Java_gnu_javax_sound_midi_alsa_AlsaPortDevice_run_1receiver_1thread_1): Avoid set but not used warning. libiberty/ * regex.c (byte_re_match_2_internal): Avoid set but not used warning. gcc/testsuite/ * gcc.dg/builtin-choose-expr.c: Avoid set but not used warnings. * gcc.dg/trunc-1.c: Likewise. * gcc.dg/vla-9.c: Likewise. * gcc.dg/dfp/composite-type.c: Likewise. libffi/ * testsuite/libffi.call/err_bad_abi.c: Remove unused args variable. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@158084 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/genemit.c')
-rw-r--r--gcc/genemit.c20
1 files changed, 12 insertions, 8 deletions
diff --git a/gcc/genemit.c b/gcc/genemit.c
index 7ac3c917067..1a6502585db 100644
--- a/gcc/genemit.c
+++ b/gcc/genemit.c
@@ -1,6 +1,6 @@
/* Generate code from machine description to emit insns as rtl.
Copyright (C) 1987, 1988, 1991, 1994, 1995, 1997, 1998, 1999, 2000, 2001,
- 2003, 2004, 2005, 2007, 2008, 2009 Free Software Foundation, Inc.
+ 2003, 2004, 2005, 2007, 2008, 2009, 2010 Free Software Foundation, Inc.
This file is part of GCC.
@@ -520,12 +520,13 @@ gen_expand (rtx expand)
(unless we aren't going to use them at all). */
if (XVEC (expand, 1) != 0)
{
- for (i = 0; i < operands; i++)
- printf (" operand%d = operands[%d];\n", i, i);
- for (; i <= max_dup_opno; i++)
- printf (" operand%d = operands[%d];\n", i, i);
- for (; i <= max_scratch_opno; i++)
- printf (" operand%d = operands[%d];\n", i, i);
+ for (i = 0;
+ i < MAX (operands, MAX (max_scratch_opno, max_dup_opno) + 1);
+ i++)
+ {
+ printf (" operand%d = operands[%d];\n", i, i);
+ printf (" (void) operand%d;\n", i);
+ }
}
printf (" }\n");
}
@@ -647,7 +648,10 @@ gen_split (rtx split)
/* Output code to copy the arguments back out of `operands' */
for (i = 0; i < operands; i++)
- printf (" operand%d = operands[%d];\n", i, i);
+ {
+ printf (" operand%d = operands[%d];\n", i, i);
+ printf (" (void) operand%d;\n", i);
+ }
/* Output code to construct the rtl for the instruction bodies.
Use emit_insn to add them to the sequence being accumulated.