Mercurial > hg > CbC > CbC_gcc
comparison gcc/config/xtensa/xtensa.c @ 63:b7f97abdc517 gcc-4.6-20100522
update gcc from gcc-4.5.0 to gcc-4.6
author | ryoma <e075725@ie.u-ryukyu.ac.jp> |
---|---|
date | Mon, 24 May 2010 12:47:05 +0900 |
parents | 77e2b8dfacca |
children | f6334be47118 |
comparison
equal
deleted
inserted
replaced
56:3c8a44c06a95 | 63:b7f97abdc517 |
---|---|
25 #include "tm.h" | 25 #include "tm.h" |
26 #include "rtl.h" | 26 #include "rtl.h" |
27 #include "regs.h" | 27 #include "regs.h" |
28 #include "hard-reg-set.h" | 28 #include "hard-reg-set.h" |
29 #include "basic-block.h" | 29 #include "basic-block.h" |
30 #include "real.h" | |
31 #include "insn-config.h" | 30 #include "insn-config.h" |
32 #include "conditions.h" | 31 #include "conditions.h" |
33 #include "insn-flags.h" | 32 #include "insn-flags.h" |
34 #include "insn-attr.h" | 33 #include "insn-attr.h" |
35 #include "insn-codes.h" | 34 #include "insn-codes.h" |
140 static bool xtensa_return_in_memory (const_tree, const_tree); | 139 static bool xtensa_return_in_memory (const_tree, const_tree); |
141 static tree xtensa_gimplify_va_arg_expr (tree, tree, gimple_seq *, | 140 static tree xtensa_gimplify_va_arg_expr (tree, tree, gimple_seq *, |
142 gimple_seq *); | 141 gimple_seq *); |
143 static rtx xtensa_function_value (const_tree, const_tree, bool); | 142 static rtx xtensa_function_value (const_tree, const_tree, bool); |
144 static void xtensa_init_builtins (void); | 143 static void xtensa_init_builtins (void); |
145 static tree xtensa_fold_builtin (tree, tree, bool); | 144 static tree xtensa_fold_builtin (tree, int, tree *, bool); |
146 static rtx xtensa_expand_builtin (tree, rtx, rtx, enum machine_mode, int); | 145 static rtx xtensa_expand_builtin (tree, rtx, rtx, enum machine_mode, int); |
147 static void xtensa_va_start (tree, rtx); | 146 static void xtensa_va_start (tree, rtx); |
148 static bool xtensa_frame_pointer_required (void); | 147 static bool xtensa_frame_pointer_required (void); |
149 static rtx xtensa_static_chain (const_tree, bool); | 148 static rtx xtensa_static_chain (const_tree, bool); |
150 static void xtensa_asm_trampoline_template (FILE *); | 149 static void xtensa_asm_trampoline_template (FILE *); |
2998 } | 2997 } |
2999 } | 2998 } |
3000 | 2999 |
3001 | 3000 |
3002 static tree | 3001 static tree |
3003 xtensa_fold_builtin (tree fndecl, tree arglist, bool ignore ATTRIBUTE_UNUSED) | 3002 xtensa_fold_builtin (tree fndecl, int n_args ATTRIBUTE_UNUSED, tree *args, |
3003 bool ignore ATTRIBUTE_UNUSED) | |
3004 { | 3004 { |
3005 unsigned int fcode = DECL_FUNCTION_CODE (fndecl); | 3005 unsigned int fcode = DECL_FUNCTION_CODE (fndecl); |
3006 tree arg0, arg1; | 3006 tree arg0, arg1; |
3007 | 3007 |
3008 switch (fcode) | 3008 switch (fcode) |
3009 { | 3009 { |
3010 case XTENSA_BUILTIN_UMULSIDI3: | 3010 case XTENSA_BUILTIN_UMULSIDI3: |
3011 arg0 = TREE_VALUE (arglist); | 3011 arg0 = args[0]; |
3012 arg1 = TREE_VALUE (TREE_CHAIN (arglist)); | 3012 arg1 = args[1]; |
3013 if ((TREE_CODE (arg0) == INTEGER_CST && TREE_CODE (arg1) == INTEGER_CST) | 3013 if ((TREE_CODE (arg0) == INTEGER_CST && TREE_CODE (arg1) == INTEGER_CST) |
3014 || TARGET_MUL32_HIGH) | 3014 || TARGET_MUL32_HIGH) |
3015 return fold_build2 (MULT_EXPR, unsigned_intDI_type_node, | 3015 return fold_build2 (MULT_EXPR, unsigned_intDI_type_node, |
3016 fold_convert (unsigned_intDI_type_node, arg0), | 3016 fold_convert (unsigned_intDI_type_node, arg0), |
3017 fold_convert (unsigned_intDI_type_node, arg1)); | 3017 fold_convert (unsigned_intDI_type_node, arg1)); |