Commit 32812a40 by Joseph Myers Committed by Joseph Myers

fold-const.c (fold): When folding a CONJ_EXPR of a COMPLEX_CST...

	* fold-const.c (fold): When folding a CONJ_EXPR of a COMPLEX_CST,
	use TREE_REALPART and TREE_IMAGPART instead of TREE_OPERAND.

testsuite:
	* gcc.c-torture/compile/20001222-1.x: Remove.

From-SVN: r38696
parent eaa7c03f
2001-01-04 Joseph S. Myers <jsm28@cam.ac.uk> 2001-01-04 Joseph S. Myers <jsm28@cam.ac.uk>
* fold-const.c (fold): When folding a CONJ_EXPR of a COMPLEX_CST,
use TREE_REALPART and TREE_IMAGPART instead of TREE_OPERAND.
2001-01-04 Joseph S. Myers <jsm28@cam.ac.uk>
* c-common.c (SIZE_TYPE, WCHAR_TYPE): Define. * c-common.c (SIZE_TYPE, WCHAR_TYPE): Define.
(flag_short_double, flag_short_wchar): Define. (flag_short_double, flag_short_wchar): Define.
(c_common_nodes_and_builtins): Create many tree nodes shared (c_common_nodes_and_builtins): Create many tree nodes shared
......
/* Fold a constant sub-tree into a single node for C-compiler /* Fold a constant sub-tree into a single node for C-compiler
Copyright (C) 1987, 1988, 1992, 1993, 1994, 1995, 1996, 1997, 1998, Copyright (C) 1987, 1988, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
1999, 2000 Free Software Foundation, Inc. 1999, 2000, 2001 Free Software Foundation, Inc.
This file is part of GNU CC. This file is part of GNU CC.
...@@ -5278,8 +5278,8 @@ fold (expr) ...@@ -5278,8 +5278,8 @@ fold (expr)
TREE_OPERAND (arg0, 0), TREE_OPERAND (arg0, 0),
negate_expr (TREE_OPERAND (arg0, 1))); negate_expr (TREE_OPERAND (arg0, 1)));
else if (TREE_CODE (arg0) == COMPLEX_CST) else if (TREE_CODE (arg0) == COMPLEX_CST)
return build_complex (type, TREE_OPERAND (arg0, 0), return build_complex (type, TREE_REALPART (arg0),
negate_expr (TREE_OPERAND (arg0, 1))); negate_expr (TREE_IMAGPART (arg0)));
else if (TREE_CODE (arg0) == PLUS_EXPR || TREE_CODE (arg0) == MINUS_EXPR) else if (TREE_CODE (arg0) == PLUS_EXPR || TREE_CODE (arg0) == MINUS_EXPR)
return fold (build (TREE_CODE (arg0), type, return fold (build (TREE_CODE (arg0), type,
fold (build1 (CONJ_EXPR, type, fold (build1 (CONJ_EXPR, type,
......
2001-01-04 Joseph S. Myers <jsm28@cam.ac.uk>
* gcc.c-torture/compile/20001222-1.x: Remove.
Thu Jan 4 13:54:11 2001 Richard Kenner <kenner@vlsi1.ultra.nyu.edu> Thu Jan 4 13:54:11 2001 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
* gcc.c-torture/execute/built-in-setjmp.c: New. * gcc.c-torture/execute/built-in-setjmp.c: New.
......
set torture_compile_xfail "*-*-*"
return 0
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment