Patchwork Committed: Fix xtensa --enable-werror-always build

login
register
mail settings
Submitter Joern Rennecke
Date Nov. 12, 2010, 8:11 p.m.
Message ID <20101112151114.m1erp71q80ckk4gs-nzlynne@webmail.spamcop.net>
Download mbox | patch
Permalink /patch/71011/
State New
Headers show

Comments

Joern Rennecke - Nov. 12, 2010, 8:11 p.m.
Built on i686-pc-linux-gnu with gcc (GCC) 4.6.0 20101111 (experimental) .

Committed as obvious.
2010-11-12  Joern Rennecke  <amylaar@spamcop.net>

	PR target/46438
	* config/xtensa/xtensa.c (xtensa_expand_nonlocal_goto): Use LCT_NORMAL.
	(xtensa_setup_frame_addresses, xtensa_trampoline_init): Likewise.
	(xtensa_function_arg_1): De-constify cum.
	(xtensa_expand_prologue): Use add_reg_note.

Patch

Index: config/xtensa/xtensa.c
===================================================================
--- config/xtensa/xtensa.c	(revision 166609)
+++ config/xtensa/xtensa.c	(working copy)
@@ -1305,7 +1305,7 @@  xtensa_expand_nonlocal_goto (rtx *operan
     containing_fp = force_reg (Pmode, containing_fp);
 
   emit_library_call (gen_rtx_SYMBOL_REF (Pmode, "__xtensa_nonlocal_goto"),
-		     0, VOIDmode, 2,
+		     LCT_NORMAL, VOIDmode, 2,
 		     containing_fp, Pmode,
 		     goto_handler, Pmode);
 }
@@ -1583,7 +1583,7 @@  xtensa_setup_frame_addresses (void)
 
   emit_library_call
     (gen_rtx_SYMBOL_REF (Pmode, "__xtensa_libgcc_window_spill"),
-     0, VOIDmode, 0);
+     LCT_NORMAL, VOIDmode, 0);
 }
 
 
@@ -2043,7 +2043,7 @@  xtensa_function_arg_advance (CUMULATIVE_
    if this is an incoming argument to the current function.  */
 
 static rtx
-xtensa_function_arg_1 (const CUMULATIVE_ARGS *cum, enum machine_mode mode,
+xtensa_function_arg_1 (CUMULATIVE_ARGS *cum, enum machine_mode mode,
 		       const_tree type, bool incoming_p)
 {
   int regbase, words, max;
@@ -2637,8 +2637,7 @@  xtensa_expand_prologue (void)
 				     : stack_pointer_rtx),
 			  plus_constant (stack_pointer_rtx, -total_size));
   RTX_FRAME_RELATED_P (insn) = 1;
-  REG_NOTES (insn) = gen_rtx_EXPR_LIST (REG_FRAME_RELATED_EXPR,
-					note_rtx, REG_NOTES (insn));
+  add_reg_note (insn, REG_FRAME_RELATED_EXPR, note_rtx);
 }
 
 
@@ -3590,7 +3589,7 @@  xtensa_trampoline_init (rtx m_tramp, tre
   emit_move_insn (adjust_address (m_tramp, SImode, chain_off), chain);
   emit_move_insn (adjust_address (m_tramp, SImode, func_off), func);
   emit_library_call (gen_rtx_SYMBOL_REF (Pmode, "__xtensa_sync_caches"),
-		     0, VOIDmode, 1, XEXP (m_tramp, 0), Pmode);
+		     LCT_NORMAL, VOIDmode, 1, XEXP (m_tramp, 0), Pmode);
 }