This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[M32R] Remove warning.
- From: Anatoly Sokolov <aesok at post dot ru>
- To: gcc-patches at gcc dot gnu dot org
- Cc: nickc at redhat dot com
- Date: Wed, 15 Sep 2010 20:36:34 +0400
- Subject: [M32R] Remove warning.
Hi.
This patch remove compiler warning from the M32R back end.
../../gcc/gcc/config/m32r/m32r.c: In function 'm32r_function_arg':
../../gcc/gcc/config/m32r/m32r.c:1240: warning: unused parameter 'type'
../../gcc/gcc/config/m32r/m32r.c: At top level:
../../gcc/gcc/config/m32r/m32r.c:1385: warning: 'm32r_memory_move_cost'
defined but not used
Regression tested on m32r-unknown-elf.
OK to install?
* config/m32r/m32r.c (TARGET_MEMORY_MOVE_COSTS): Remove.
(TARGET_MEMORY_MOVE_COST): Define.
(m32r_function_arg): Annotate argument 'type' with ATTRIBUTE_UNUSED.
Index: gcc/config/m32r/m32r.c
===================================================================
--- gcc/config/m32r/m32r.c (revision 164280)
+++ gcc/config/m32r/m32r.c (working copy)
@@ -157,8 +157,8 @@
#define TARGET_IN_SMALL_DATA_P m32r_in_small_data_p
-#undef TARGET_MEMORY_MOVE_COSTS
-#define TARGET_MEMORY_MOVE_COSTS m32r_memory_move_costs
+#undef TARGET_MEMORY_MOVE_COST
+#define TARGET_MEMORY_MOVE_COST m32r_memory_move_cost
#undef TARGET_RTX_COSTS
#define TARGET_RTX_COSTS m32r_rtx_costs
#undef TARGET_ADDRESS_COST
@@ -1237,7 +1237,8 @@
static rtx
m32r_function_arg (CUMULATIVE_ARGS *cum, enum machine_mode mode,
- const_tree type, bool named ATTRIBUTE_UNUSED)
+ const_tree type ATTRIBUTE_UNUSED,
+ bool named ATTRIBUTE_UNUSED)
{
return (PASS_IN_REG_P (*cum, mode, type)
? gen_rtx_REG (mode, ROUND_ADVANCE_CUM (*cum, mode, type))
Anatoly.