re PR middle-end/13696 (enum not useable as array index?)
PR middle-end/13696 * fold-const.c (fold_convert): New function to provide type conversion to the middle-end without using convert. (negate_expr, associate_trees, size_diffop, omit_one_operand, operand_equal_for_comparison_p, pedantic_omit_one_operand, invert_truthvalue, optimize_bit_field_compare, range_binop, decode_field_reference, make_range, build_range_check, unextend, fold_truthop, extract_muldiv_1, fold_mathfn_compare, fold_binary_op_with_conditional_arg, fold_inf_compare, fold_single_bit_test, fold, multiple_of_p): Replace all calls to convert with calls to fold_convert. * g++.dg/opt/fold1.C: New test case. From-SVN: r77464
This commit is contained in:
parent
076963eb57
commit
088414c122
|
@ -1,3 +1,17 @@
|
|||
2004-02-07 Roger Sayle <roger@eyesopen.com>
|
||||
|
||||
PR middle-end/13696
|
||||
* fold-const.c (fold_convert): New function to provide type
|
||||
conversion to the middle-end without using convert.
|
||||
(negate_expr, associate_trees, size_diffop, omit_one_operand,
|
||||
operand_equal_for_comparison_p, pedantic_omit_one_operand,
|
||||
invert_truthvalue, optimize_bit_field_compare, range_binop,
|
||||
decode_field_reference, make_range, build_range_check, unextend,
|
||||
fold_truthop, extract_muldiv_1, fold_mathfn_compare,
|
||||
fold_binary_op_with_conditional_arg, fold_inf_compare,
|
||||
fold_single_bit_test, fold, multiple_of_p): Replace all calls to
|
||||
convert with calls to fold_convert.
|
||||
|
||||
2004-02-07 Jan Hubicka <jh@suse.cz>
|
||||
|
||||
* genrecog.c (find_operand): add extra argument stop.
|
||||
|
|
691
gcc/fold-const.c
691
gcc/fold-const.c
File diff suppressed because it is too large
Load Diff
|
@ -1,3 +1,8 @@
|
|||
2004-02-07 Roger Sayle <roger@eyesopen.com>
|
||||
|
||||
PR middle-end/13696
|
||||
* g++.dg/opt/fold1.C: New test case.
|
||||
|
||||
2003-02-06 Giovanni Bajo <giovannibajo@gcc.gnu.org>
|
||||
|
||||
PR c++/14033
|
||||
|
|
|
@ -0,0 +1,17 @@
|
|||
// PR middle-end/13696
|
||||
// { dg-do compile }
|
||||
// { dg-options "-O2" }
|
||||
|
||||
extern void x(unsigned long*);
|
||||
|
||||
enum e { red, blue, green };
|
||||
|
||||
struct s {
|
||||
unsigned long l;
|
||||
};
|
||||
struct s map[1][256];
|
||||
|
||||
void
|
||||
f(int i,e j) {
|
||||
x(&(map[i][j].l));
|
||||
}
|
Loading…
Reference in New Issue