tree-ssa-pre.c (my_rev_post_order_compute): Remove set but not used count variable.

* 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.

From-SVN: r158084
This commit is contained in:
Jakub Jelinek 2010-04-07 22:27:37 +02:00 committed by Jakub Jelinek
parent b51e84c954
commit 60d3aec487
26 changed files with 118 additions and 83 deletions

View file

@ -1,3 +1,18 @@
2010-04-07 Jakub Jelinek <jakub@redhat.com>
* 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.
2010-04-07 Simon Baldwin <simonb@google.com> 2010-04-07 Simon Baldwin <simonb@google.com>
* diagnostic.h (diagnostic_override_option_index): New macro to * diagnostic.h (diagnostic_override_option_index): New macro to

View file

@ -1,3 +1,8 @@
2010-04-07 Jakub Jelinek <jakub@redhat.com>
* parse.c (parse_derived, parse_enum): Avoid set but not used
warning.
2010-04-07 Janne Blomqvist <jb@gcc.gnu.org> 2010-04-07 Janne Blomqvist <jb@gcc.gnu.org>
PR fortran/40539 PR fortran/40539

View file

@ -1968,14 +1968,12 @@ parse_derived_contains (void)
static void static void
parse_derived (void) parse_derived (void)
{ {
int compiling_type, seen_private, seen_sequence, seen_component, error_flag; int compiling_type, seen_private, seen_sequence, seen_component;
gfc_statement st; gfc_statement st;
gfc_state_data s; gfc_state_data s;
gfc_symbol *sym; gfc_symbol *sym;
gfc_component *c; gfc_component *c;
error_flag = 0;
accept_statement (ST_DERIVED_DECL); accept_statement (ST_DERIVED_DECL);
push_state (&s, COMP_DERIVED, gfc_new_block); push_state (&s, COMP_DERIVED, gfc_new_block);
@ -2002,18 +2000,15 @@ parse_derived (void)
case ST_FINAL: case ST_FINAL:
gfc_error ("FINAL declaration at %C must be inside CONTAINS"); gfc_error ("FINAL declaration at %C must be inside CONTAINS");
error_flag = 1;
break; break;
case ST_END_TYPE: case ST_END_TYPE:
endType: endType:
compiling_type = 0; compiling_type = 0;
if (!seen_component if (!seen_component)
&& (gfc_notify_std (GFC_STD_F2003, "Fortran 2003: Derived type " gfc_notify_std (GFC_STD_F2003, "Fortran 2003: Derived type "
"definition at %C without components") "definition at %C without components");
== FAILURE))
error_flag = 1;
accept_statement (ST_END_TYPE); accept_statement (ST_END_TYPE);
break; break;
@ -2023,7 +2018,6 @@ endType:
{ {
gfc_error ("PRIVATE statement in TYPE at %C must be inside " gfc_error ("PRIVATE statement in TYPE at %C must be inside "
"a MODULE"); "a MODULE");
error_flag = 1;
break; break;
} }
@ -2031,15 +2025,11 @@ endType:
{ {
gfc_error ("PRIVATE statement at %C must precede " gfc_error ("PRIVATE statement at %C must precede "
"structure components"); "structure components");
error_flag = 1;
break; break;
} }
if (seen_private) if (seen_private)
{ gfc_error ("Duplicate PRIVATE statement at %C");
gfc_error ("Duplicate PRIVATE statement at %C");
error_flag = 1;
}
s.sym->component_access = ACCESS_PRIVATE; s.sym->component_access = ACCESS_PRIVATE;
@ -2052,7 +2042,6 @@ endType:
{ {
gfc_error ("SEQUENCE statement at %C must precede " gfc_error ("SEQUENCE statement at %C must precede "
"structure components"); "structure components");
error_flag = 1;
break; break;
} }
@ -2063,7 +2052,6 @@ endType:
if (seen_sequence) if (seen_sequence)
{ {
gfc_error ("Duplicate SEQUENCE statement at %C"); gfc_error ("Duplicate SEQUENCE statement at %C");
error_flag = 1;
} }
seen_sequence = 1; seen_sequence = 1;
@ -2072,14 +2060,12 @@ endType:
break; break;
case ST_CONTAINS: case ST_CONTAINS:
if (gfc_notify_std (GFC_STD_F2003, gfc_notify_std (GFC_STD_F2003,
"Fortran 2003: CONTAINS block in derived type" "Fortran 2003: CONTAINS block in derived type"
" definition at %C") == FAILURE) " definition at %C");
error_flag = 1;
accept_statement (ST_CONTAINS); accept_statement (ST_CONTAINS);
if (parse_derived_contains ()) parse_derived_contains ();
error_flag = 1;
goto endType; goto endType;
default: default:
@ -2138,14 +2124,11 @@ endType:
static void static void
parse_enum (void) parse_enum (void)
{ {
int error_flag;
gfc_statement st; gfc_statement st;
int compiling_enum; int compiling_enum;
gfc_state_data s; gfc_state_data s;
int seen_enumerator = 0; int seen_enumerator = 0;
error_flag = 0;
push_state (&s, COMP_ENUM, gfc_new_block); push_state (&s, COMP_ENUM, gfc_new_block);
compiling_enum = 1; compiling_enum = 1;
@ -2167,10 +2150,7 @@ parse_enum (void)
case ST_END_ENUM: case ST_END_ENUM:
compiling_enum = 0; compiling_enum = 0;
if (!seen_enumerator) if (!seen_enumerator)
{ gfc_error ("ENUM declaration at %C has no ENUMERATORS");
gfc_error ("ENUM declaration at %C has no ENUMERATORS");
error_flag = 1;
}
accept_statement (st); accept_statement (st);
break; break;

View file

@ -1,6 +1,6 @@
/* Generate code from machine description to emit insns as rtl. /* Generate code from machine description to emit insns as rtl.
Copyright (C) 1987, 1988, 1991, 1994, 1995, 1997, 1998, 1999, 2000, 2001, 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. This file is part of GCC.
@ -520,12 +520,13 @@ gen_expand (rtx expand)
(unless we aren't going to use them at all). */ (unless we aren't going to use them at all). */
if (XVEC (expand, 1) != 0) if (XVEC (expand, 1) != 0)
{ {
for (i = 0; i < operands; i++) for (i = 0;
printf (" operand%d = operands[%d];\n", i, i); i < MAX (operands, MAX (max_scratch_opno, max_dup_opno) + 1);
for (; i <= max_dup_opno; i++) i++)
printf (" operand%d = operands[%d];\n", i, i); {
for (; i <= max_scratch_opno; i++) printf (" operand%d = operands[%d];\n", i, i);
printf (" operand%d = operands[%d];\n", i, i); printf (" (void) operand%d;\n", i);
}
} }
printf (" }\n"); printf (" }\n");
} }
@ -647,7 +648,10 @@ gen_split (rtx split)
/* Output code to copy the arguments back out of `operands' */ /* Output code to copy the arguments back out of `operands' */
for (i = 0; i < operands; i++) 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. /* Output code to construct the rtl for the instruction bodies.
Use emit_insn to add them to the sequence being accumulated. Use emit_insn to add them to the sequence being accumulated.

View file

@ -1,3 +1,9 @@
2010-04-07 Jakub Jelinek <jakub@redhat.com>
* 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.
2010-01-20 Joern Rennecke <amylaar@spamcop.net> 2010-01-20 Joern Rennecke <amylaar@spamcop.net>
* lang.c (java_post_options): Constify variable "dot". * lang.c (java_post_options): Constify variable "dot".

View file

@ -1,5 +1,5 @@
/* Built-in and inline functions for gcj /* Built-in and inline functions for gcj
Copyright (C) 2001, 2003, 2004, 2005, 2006, 2007, 2009 Copyright (C) 2001, 2003, 2004, 2005, 2006, 2007, 2009, 2010
Free Software Foundation, Inc. Free Software Foundation, Inc.
This file is part of GCC. This file is part of GCC.
@ -323,6 +323,7 @@ compareAndSwapInt_builtin (tree method_return_type ATTRIBUTE_UNUSED,
{ {
tree addr, stmt; tree addr, stmt;
UNMARSHAL5 (orig_call); UNMARSHAL5 (orig_call);
(void) value_type; /* Avoid set but not used warning. */
addr = build_addr_sum (int_type_node, obj_arg, offset_arg); addr = build_addr_sum (int_type_node, obj_arg, offset_arg);
stmt = build_call_expr (built_in_decls[BUILT_IN_BOOL_COMPARE_AND_SWAP_4], stmt = build_call_expr (built_in_decls[BUILT_IN_BOOL_COMPARE_AND_SWAP_4],
@ -347,6 +348,7 @@ compareAndSwapLong_builtin (tree method_return_type ATTRIBUTE_UNUSED,
{ {
tree addr, stmt; tree addr, stmt;
UNMARSHAL5 (orig_call); UNMARSHAL5 (orig_call);
(void) value_type; /* Avoid set but not used warning. */
addr = build_addr_sum (long_type_node, obj_arg, offset_arg); addr = build_addr_sum (long_type_node, obj_arg, offset_arg);
stmt = build_call_expr (built_in_decls[BUILT_IN_BOOL_COMPARE_AND_SWAP_8], stmt = build_call_expr (built_in_decls[BUILT_IN_BOOL_COMPARE_AND_SWAP_8],
@ -410,7 +412,8 @@ getVolatile_builtin (tree method_return_type ATTRIBUTE_UNUSED,
{ {
tree addr, stmt, modify_stmt, tmp; tree addr, stmt, modify_stmt, tmp;
UNMARSHAL3 (orig_call); UNMARSHAL3 (orig_call);
(void) this_arg; /* Avoid set but not used warning. */
addr = build_addr_sum (method_return_type, obj_arg, offset_arg); addr = build_addr_sum (method_return_type, obj_arg, offset_arg);
addr addr
= fold_convert (build_pointer_type (build_type_variant = fold_convert (build_pointer_type (build_type_variant

View file

@ -1,6 +1,6 @@
/* Process expressions for the GNU compiler for the Java(TM) language. /* Process expressions for the GNU compiler for the Java(TM) language.
Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
2005, 2006, 2007, 2008 Free Software Foundation, Inc. 2005, 2006, 2007, 2008, 2010 Free Software Foundation, Inc.
This file is part of GCC. This file is part of GCC.
@ -3329,6 +3329,7 @@ process_jvm_instruction (int PC, const unsigned char* byte_ops,
{ \ { \
int saw_index = 0; \ int saw_index = 0; \
int index = OPERAND_VALUE; \ int index = OPERAND_VALUE; \
(void) saw_index; /* Avoid set but not used warning. */ \
build_java_ret \ build_java_ret \
(find_local_variable (index, return_address_type_node, oldpc)); \ (find_local_variable (index, return_address_type_node, oldpc)); \
} }

View file

@ -1,3 +1,10 @@
2010-04-07 Jakub Jelinek <jakub@redhat.com>
* 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.
2010-04-07 Iain Sandoe <iains@gcc.gnu.org> 2010-04-07 Iain Sandoe <iains@gcc.gnu.org>
PR objc/35996 PR objc/35996

View file

@ -29,6 +29,8 @@
t1 = t1b; \ t1 = t1b; \
t2 = t2a; \ t2 = t2a; \
t2 = t2b; \ t2 = t2b; \
(void) t1; \
(void) t2; \
} while (0) } while (0)

View file

@ -30,18 +30,19 @@ do \
d##TYPE = f2_##TYPE(h1_##TYPE); \ d##TYPE = f2_##TYPE(h1_##TYPE); \
d##TYPE = f2_##TYPE(h2_##TYPE); \ d##TYPE = f2_##TYPE(h2_##TYPE); \
d##TYPE = f2_##TYPE(h3_##TYPE); \ d##TYPE = f2_##TYPE(h3_##TYPE); \
(void) d##TYPE; \
} while(0) } while(0)
DECIMAL_COMPOSITE_DECL(32); /* { dg-error "incompatible types when assigning to type '\[^\n\]*' from type '\[^\n\]*'" } */ DECIMAL_COMPOSITE_DECL(32); /* { dg-error "incompatible types when assigning to type '\[^\n\]*' from type '\[^\n\]*'" } */
/* { dg-message "note: expected '\[^'\n\]*' but argument is of type '\[^'\n\]*'" "note: expected" { target *-*-* } 35 } */ /* { dg-message "note: expected '\[^'\n\]*' but argument is of type '\[^'\n\]*'" "note: expected" { target *-*-* } 36 } */
DECIMAL_COMPOSITE_DECL(64); /* { dg-error "incompatible types when assigning to type '\[^\n\]*' from type '\[^\n\]*'" } */ DECIMAL_COMPOSITE_DECL(64); /* { dg-error "incompatible types when assigning to type '\[^\n\]*' from type '\[^\n\]*'" } */
/* { dg-message "note: expected '\[^'\n\]*' but argument is of type '\[^'\n\]*'" "note: expected" { target *-*-* } 39 } */ /* { dg-message "note: expected '\[^'\n\]*' but argument is of type '\[^'\n\]*'" "note: expected" { target *-*-* } 40 } */
DECIMAL_COMPOSITE_DECL(128); /* { dg-error "incompatible types when assigning to type '\[^\n\]*' from type '\[^\n\]*'" } */ DECIMAL_COMPOSITE_DECL(128); /* { dg-error "incompatible types when assigning to type '\[^\n\]*' from type '\[^\n\]*'" } */
/* { dg-message "note: expected '\[^'\n\]*' but argument is of type '\[^'\n\]*'" "note: expected" { target *-*-* } 43 } */ /* { dg-message "note: expected '\[^'\n\]*' but argument is of type '\[^'\n\]*'" "note: expected" { target *-*-* } 44 } */
int main() int main()

View file

@ -11,5 +11,5 @@ main (void)
len = ~(sizeof (size_t) - 1); /* { dg-bogus "truncated" "bogus truncation warning" } */ len = ~(sizeof (size_t) - 1); /* { dg-bogus "truncated" "bogus truncation warning" } */
return 0; return len - len;
} }

View file

@ -6,4 +6,5 @@ void f(__SIZE_TYPE__ d)
{ {
typedef int t[d]; typedef int t[d];
t *g = (__typeof (g)) d; t *g = (__typeof (g)) d;
(void) g;
} }

View file

@ -252,17 +252,17 @@ typedef struct immediate_use_iterator_d
/* Use this iterator when simply looking at stmts. Adding, deleting or /* Use this iterator when simply looking at stmts. Adding, deleting or
modifying stmts will cause this iterator to malfunction. */ modifying stmts will cause this iterator to malfunction. */
#define FOR_EACH_IMM_USE_FAST(DEST, ITER, SSAVAR) \ #define FOR_EACH_IMM_USE_FAST(DEST, ITER, SSAVAR) \
for ((DEST) = first_readonly_imm_use (&(ITER), (SSAVAR)); \ for ((DEST) = first_readonly_imm_use (&(ITER), (SSAVAR)); \
!end_readonly_imm_use_p (&(ITER)); \ !end_readonly_imm_use_p (&(ITER)); \
(DEST) = next_readonly_imm_use (&(ITER))) (void) ((DEST) = next_readonly_imm_use (&(ITER))))
/* Use this iterator to visit each stmt which has a use of SSAVAR. */ /* Use this iterator to visit each stmt which has a use of SSAVAR. */
#define FOR_EACH_IMM_USE_STMT(STMT, ITER, SSAVAR) \ #define FOR_EACH_IMM_USE_STMT(STMT, ITER, SSAVAR) \
for ((STMT) = first_imm_use_stmt (&(ITER), (SSAVAR)); \ for ((STMT) = first_imm_use_stmt (&(ITER), (SSAVAR)); \
!end_imm_use_stmt_p (&(ITER)); \ !end_imm_use_stmt_p (&(ITER)); \
(STMT) = next_imm_use_stmt (&(ITER))) (void) ((STMT) = next_imm_use_stmt (&(ITER))))
/* Use this to terminate the FOR_EACH_IMM_USE_STMT loop early. Failure to /* Use this to terminate the FOR_EACH_IMM_USE_STMT loop early. Failure to
do so will result in leaving a iterator marker node in the immediate do so will result in leaving a iterator marker node in the immediate
@ -290,7 +290,7 @@ typedef struct immediate_use_iterator_d
#define FOR_EACH_IMM_USE_ON_STMT(DEST, ITER) \ #define FOR_EACH_IMM_USE_ON_STMT(DEST, ITER) \
for ((DEST) = first_imm_use_on_stmt (&(ITER)); \ for ((DEST) = first_imm_use_on_stmt (&(ITER)); \
!end_imm_use_on_stmt_p (&(ITER)); \ !end_imm_use_on_stmt_p (&(ITER)); \
(DEST) = next_imm_use_on_stmt (&(ITER))) (void) ((DEST) = next_imm_use_on_stmt (&(ITER))))

View file

@ -452,8 +452,9 @@ do { \
y_ = VEC_index (int, (GRAPH)->edge_list, x_); \ y_ = VEC_index (int, (GRAPH)->edge_list, x_); \
if (y_ != (NODE)) \ if (y_ != (NODE)) \
continue; \ continue; \
(VAR) = VEC_index (int, (GRAPH)->edge_list, x_ + 1); \ (void) ((VAR) = VEC_index (int, (GRAPH)->edge_list, x_ + 1)); \
(LOCUS) = VEC_index (source_location, (GRAPH)->edge_locus, x_ / 2); \ (void) ((LOCUS) = VEC_index (source_location, \
(GRAPH)->edge_locus, x_ / 2)); \
CODE; \ CODE; \
} \ } \
} while (0) } while (0)
@ -472,8 +473,9 @@ do { \
y_ = VEC_index (int, (GRAPH)->edge_list, x_ + 1); \ y_ = VEC_index (int, (GRAPH)->edge_list, x_ + 1); \
if (y_ != (NODE)) \ if (y_ != (NODE)) \
continue; \ continue; \
(VAR) = VEC_index (int, (GRAPH)->edge_list, x_); \ (void) ((VAR) = VEC_index (int, (GRAPH)->edge_list, x_)); \
(LOCUS) = VEC_index (source_location, (GRAPH)->edge_locus, x_ / 2); \ (void) ((LOCUS) = VEC_index (source_location, \
(GRAPH)->edge_locus, x_ / 2)); \
CODE; \ CODE; \
} \ } \
} while (0) } while (0)

View file

@ -1,5 +1,6 @@
/* SSA operand management for trees. /* SSA operand management for trees.
Copyright (C) 2003, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. Copyright (C) 2003, 2005, 2006, 2007, 2008, 2010
Free Software Foundation, Inc.
This file is part of GCC. This file is part of GCC.
@ -160,7 +161,7 @@ typedef struct ssa_operand_iterator_d
#define FOR_EACH_SSA_TREE_OPERAND(TREEVAR, STMT, ITER, FLAGS) \ #define FOR_EACH_SSA_TREE_OPERAND(TREEVAR, STMT, ITER, FLAGS) \
for (TREEVAR = op_iter_init_tree (&(ITER), STMT, FLAGS); \ for (TREEVAR = op_iter_init_tree (&(ITER), STMT, FLAGS); \
!op_iter_done (&(ITER)); \ !op_iter_done (&(ITER)); \
TREEVAR = op_iter_next_tree (&(ITER))) (void) (TREEVAR = op_iter_next_tree (&(ITER))))
/* This macro executes a loop over the operands of STMT specified in FLAG, /* This macro executes a loop over the operands of STMT specified in FLAG,
returning each operand as a 'use_operand_p' in the variable USEVAR. returning each operand as a 'use_operand_p' in the variable USEVAR.

View file

@ -4498,7 +4498,6 @@ my_rev_post_order_compute (int *post_order, bool include_entry_exit)
int sp; int sp;
int post_order_num = 0; int post_order_num = 0;
sbitmap visited; sbitmap visited;
int count;
if (include_entry_exit) if (include_entry_exit)
post_order[post_order_num++] = EXIT_BLOCK; post_order[post_order_num++] = EXIT_BLOCK;
@ -4553,12 +4552,7 @@ my_rev_post_order_compute (int *post_order, bool include_entry_exit)
} }
if (include_entry_exit) if (include_entry_exit)
{ post_order[post_order_num++] = ENTRY_BLOCK;
post_order[post_order_num++] = ENTRY_BLOCK;
count = post_order_num;
}
else
count = post_order_num + 2;
free (stack); free (stack);
sbitmap_free (visited); sbitmap_free (visited);

View file

@ -3652,9 +3652,9 @@ build1_stat (enum tree_code code, tree type, tree node MEM_STAT_DECL)
side_effects = 1; \ side_effects = 1; \
if (!TREE_READONLY (arg##N) \ if (!TREE_READONLY (arg##N) \
&& !CONSTANT_CLASS_P (arg##N)) \ && !CONSTANT_CLASS_P (arg##N)) \
read_only = 0; \ (void) (read_only = 0); \
if (!TREE_CONSTANT (arg##N)) \ if (!TREE_CONSTANT (arg##N)) \
constant = 0; \ (void) (constant = 0); \
} \ } \
} while (0) } while (0)

View file

@ -1507,9 +1507,9 @@ struct GTY(()) tree_vec {
#define FOR_EACH_CONSTRUCTOR_ELT(V, IX, INDEX, VAL) \ #define FOR_EACH_CONSTRUCTOR_ELT(V, IX, INDEX, VAL) \
for (IX = 0; (IX >= VEC_length (constructor_elt, V)) \ for (IX = 0; (IX >= VEC_length (constructor_elt, V)) \
? false \ ? false \
: ((VAL = VEC_index (constructor_elt, V, IX)->value), \ : (((void) (VAL = VEC_index (constructor_elt, V, IX)->value)), \
(INDEX = VEC_index (constructor_elt, V, IX)->index), \ (INDEX = VEC_index (constructor_elt, V, IX)->index), \
true); \ true); \
(IX)++) (IX)++)
/* Append a new constructor element to V, with the specified INDEX and VAL. */ /* Append a new constructor element to V, with the specified INDEX and VAL. */

View file

@ -1,3 +1,8 @@
2010-04-07 Jakub Jelinek <jakub@redhat.com>
* regex.c (byte_re_match_2_internal): Avoid set but not used
warning.
2010-04-02 Ralf Wildenhues <Ralf.Wildenhues@gmx.de> 2010-04-02 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
* Makefile.in: Regenerate. * Makefile.in: Regenerate.

View file

@ -17,11 +17,9 @@ int main (void)
ffi_cif cif; ffi_cif cif;
void *code; void *code;
ffi_closure *pcl = ffi_closure_alloc(sizeof(ffi_closure), &code); ffi_closure *pcl = ffi_closure_alloc(sizeof(ffi_closure), &code);
void* args[1];
ffi_type* arg_types[1]; ffi_type* arg_types[1];
arg_types[0] = NULL; arg_types[0] = NULL;
args[0] = NULL;
CHECK(ffi_prep_cif(&cif, 255, 0, &ffi_type_void, CHECK(ffi_prep_cif(&cif, 255, 0, &ffi_type_void,
arg_types) == FFI_BAD_ABI); arg_types) == FFI_BAD_ABI);

View file

@ -4,7 +4,7 @@
internationalization features.) internationalization features.)
Copyright (C) 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, Copyright (C) 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001,
2002, 2005 Free Software Foundation, Inc. 2002, 2005, 2010 Free Software Foundation, Inc.
This file is part of the GNU C Library. This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or The GNU C Library is free software; you can redistribute it and/or
@ -7140,8 +7140,8 @@ byte_re_match_2_internal (struct re_pattern_buffer *bufp,
register from the stack, since lowest will == highest in register from the stack, since lowest will == highest in
`pop_failure_point'. */ `pop_failure_point'. */
active_reg_t dummy_low_reg, dummy_high_reg; active_reg_t dummy_low_reg, dummy_high_reg;
UCHAR_T *pdummy = NULL; UCHAR_T *pdummy ATTRIBUTE_UNUSED = NULL;
const CHAR_T *sdummy = NULL; const CHAR_T *sdummy ATTRIBUTE_UNUSED = NULL;
DEBUG_PRINT1 ("EXECUTING pop_failure_jump.\n"); DEBUG_PRINT1 ("EXECUTING pop_failure_jump.\n");
POP_FAILURE_POINT (sdummy, pdummy, POP_FAILURE_POINT (sdummy, pdummy,

View file

@ -1,3 +1,9 @@
2010-04-07 Jakub Jelinek <jakub@redhat.com>
* 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.
2010-04-07 Jason Merrill <jason@redhat.com> 2010-04-07 Jason Merrill <jason@redhat.com>
* gnu/gcj/runtime/natSharedLibLoader.cc (findCore): Move * gnu/gcj/runtime/natSharedLibLoader.cc (findCore): Move

View file

@ -1,3 +1,9 @@
2010-04-07 Jakub Jelinek <jakub@redhat.com>
* 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.
2010-01-09 Jakub Jelinek <jakub@redhat.com> 2010-01-09 Jakub Jelinek <jakub@redhat.com>
* gnu/java/rmi/registry/RegistryImpl.java (version): Update * gnu/java/rmi/registry/RegistryImpl.java (version): Update

View file

@ -1,5 +1,5 @@
/* gnu_javax_sound_midi_alsa_AlsaPortDevice.c - Native support /* gnu_javax_sound_midi_alsa_AlsaPortDevice.c - Native support
Copyright (C) 2005 Copyright (C) 2005, 2010
Free Software Foundation, Inc. Free Software Foundation, Inc.
This file is part of GNU Classpath. This file is part of GNU Classpath.
@ -48,7 +48,6 @@ Java_gnu_javax_sound_midi_alsa_AlsaPortDevice_run_1receiver_1thread_1
(JNIEnv *env, jobject this __attribute__((unused)), (JNIEnv *env, jobject this __attribute__((unused)),
jlong client, jlong port, jobject receiver) jlong client, jlong port, jobject receiver)
{ {
int rc;
snd_seq_port_info_t *pinfo, *sinfo; snd_seq_port_info_t *pinfo, *sinfo;
snd_seq_port_subscribe_t *subs; snd_seq_port_subscribe_t *subs;
snd_seq_addr_t sender, dest; snd_seq_addr_t sender, dest;
@ -58,12 +57,12 @@ Java_gnu_javax_sound_midi_alsa_AlsaPortDevice_run_1receiver_1thread_1
snd_seq_port_info_alloca (&sinfo); snd_seq_port_info_alloca (&sinfo);
snd_seq_port_subscribe_alloca (&subs); snd_seq_port_subscribe_alloca (&subs);
rc = snd_seq_open (&seq, "default", SND_SEQ_OPEN_DUPLEX, SND_SEQ_NONBLOCK); snd_seq_open (&seq, "default", SND_SEQ_OPEN_DUPLEX, SND_SEQ_NONBLOCK);
snd_seq_port_info_set_capability (pinfo, SND_SEQ_PORT_CAP_WRITE); snd_seq_port_info_set_capability (pinfo, SND_SEQ_PORT_CAP_WRITE);
snd_seq_port_info_set_type (pinfo, SND_SEQ_PORT_TYPE_MIDI_GENERIC); snd_seq_port_info_set_type (pinfo, SND_SEQ_PORT_TYPE_MIDI_GENERIC);
rc = snd_seq_create_port (seq, pinfo); snd_seq_create_port (seq, pinfo);
sender.client = (int) client; sender.client = (int) client;
sender.port = (int) port; sender.port = (int) port;
@ -72,7 +71,7 @@ Java_gnu_javax_sound_midi_alsa_AlsaPortDevice_run_1receiver_1thread_1
snd_seq_port_subscribe_set_sender (subs, &sender); snd_seq_port_subscribe_set_sender (subs, &sender);
snd_seq_port_subscribe_set_dest (subs, &dest); snd_seq_port_subscribe_set_dest (subs, &dest);
rc = snd_seq_subscribe_port(seq, subs); snd_seq_subscribe_port(seq, subs);
{ {
int npfd; int npfd;

View file

@ -1,6 +1,6 @@
// Functions for Exception Support for Java. // Functions for Exception Support for Java.
/* Copyright (C) 1998, 1999, 2001, 2002, 2006 Free Software Foundation /* Copyright (C) 1998, 1999, 2001, 2002, 2006, 2010 Free Software Foundation
This file is part of libgcj. This file is part of libgcj.
@ -111,11 +111,10 @@ _Jv_Throw (jthrowable value)
/* We're happy with setjmp/longjmp exceptions or region-based /* We're happy with setjmp/longjmp exceptions or region-based
exception handlers: entry points are provided here for both. */ exception handlers: entry points are provided here for both. */
_Unwind_Reason_Code code;
#ifdef SJLJ_EXCEPTIONS #ifdef SJLJ_EXCEPTIONS
code = _Unwind_SjLj_RaiseException (&xh->unwindHeader); _Unwind_SjLj_RaiseException (&xh->unwindHeader);
#else #else
code = _Unwind_RaiseException (&xh->unwindHeader); _Unwind_RaiseException (&xh->unwindHeader);
#endif #endif
/* If code == _URC_END_OF_STACK, then we reached top of stack without /* If code == _URC_END_OF_STACK, then we reached top of stack without

View file

@ -1,6 +1,6 @@
// java-assert.h - Header file holding assertion definitions. -*- c++ -*- // java-assert.h - Header file holding assertion definitions. -*- c++ -*-
/* Copyright (C) 1998, 1999 Free Software Foundation /* Copyright (C) 1998, 1999, 2010 Free Software Foundation
This file is part of libgcj. This file is part of libgcj.
@ -29,8 +29,8 @@ void _Jv_Abort (const char *, const char *, int, const char *)
#else /* __GCJ_DEBUG */ #else /* __GCJ_DEBUG */
#define _Jv_AssertDoCall(Message) #define _Jv_AssertDoCall(Message)
#define JvAssertMessage(Expr, Message) #define JvAssertMessage(Expr, Message) (void) sizeof (Expr)
#define JvAssert(Expr) #define JvAssert(Expr) (void) sizeof (Expr)
#define JvFail(Message) _Jv_Abort (0, 0, 0, Message) #define JvFail(Message) _Jv_Abort (0, 0, 0, Message)
#endif /* not __GCJ_DEBUG */ #endif /* not __GCJ_DEBUG */