From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 6115 invoked by alias); 9 Mar 2008 17:50:52 -0000 Received: (qmail 6099 invoked by uid 22791); 9 Mar 2008 17:50:50 -0000 X-Spam-Check-By: sourceware.org Received: from cantor2.suse.de (HELO mx2.suse.de) (195.135.220.15) by sourceware.org (qpsmtpd/0.31) with ESMTP; Sun, 09 Mar 2008 17:50:27 +0000 Received: from Relay2.suse.de (relay-ext.suse.de [195.135.221.8]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mx2.suse.de (Postfix) with ESMTP id 05DAF3B08E for ; Sun, 9 Mar 2008 18:50:23 +0100 (CET) Date: Sun, 09 Mar 2008 17:50:00 -0000 From: Richard Guenther To: gcc-patches@gcc.gnu.org Subject: [PATCH][mem-ref] Adjust some testsuite patterns Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org X-SW-Source: 2008-03/txt/msg00589.txt.bz2 These are just false-positive fails. Richard. 2008-03-09 Richard Guenther * gcc.dg/tree-ssa/20030530-2.c: Adjust patterns. * gcc.dg/tree-ssa/20030703-2.c: Likewise. * gcc.dg/tree-ssa/20030709-2.c: Likewise. * gcc.dg/tree-ssa/20030709-3.c: Likewise. * gcc.dg/tree-ssa/20030710-1.c: Likewise. * gcc.dg/tree-ssa/20030711-2.c: Likewise. * gcc.dg/tree-ssa/20030711-3.c: Likewise. * gcc.dg/tree-ssa/20030729-1.c: Likewise. * gcc.dg/tree-ssa/20030807-5.c: Likewise. * gcc.dg/tree-ssa/20030814-1.c: Likewise. * gcc.dg/tree-ssa/20030814-4.c: Likewise. * gcc.dg/tree-ssa/20030814-5.c: Likewise. * gcc.dg/tree-ssa/20031021-1.c: Likewise. * gcc.dg/tree-ssa/20031022-1.c: Likewise. * gcc.dg/tree-ssa/20040729-1.c: Likewise. * gcc.dg/tree-ssa/20050314-1.c: Likewise. * gcc.dg/tree-ssa/alias-6.c: Likewise. * gcc.dg/tree-ssa/complex-3.c: Likewise. * gcc.dg/tree-ssa/foldaddr-2.c: Likewise. * gcc.dg/tree-ssa/foldaddr-3.c: Likewise. Index: mem-ref/gcc/testsuite/gcc.dg/tree-ssa/20030530-2.c =================================================================== *** mem-ref.orig/gcc/testsuite/gcc.dg/tree-ssa/20030530-2.c 2008-03-09 15:09:19.000000000 +0100 --- mem-ref/gcc/testsuite/gcc.dg/tree-ssa/20030530-2.c 2008-03-09 15:17:43.000000000 +0100 *************** rs6000_emit_prologue (int i, rs6000_stac *** 16,26 **** /* There should be precisely one load of first_gp_reg_save. If there is more than one, then the dominator optimizations failed. */ ! /* { dg-final { scan-tree-dump-times "first_gp_reg_save" 1 "dom3"} } */ /* There should be precisely one addition. If there is more than one, then the dominator optimizations failed, most likely due to not handling commutative operands correctly. */ /* { dg-final { scan-tree-dump-times "\\+" 1 "dom3"} } */ /* { dg-final { cleanup-tree-dump "dom3" } } */ --- 16,31 ---- /* There should be precisely one load of first_gp_reg_save. If there is more than one, then the dominator optimizations failed. */ ! /* { dg-final { scan-tree-dump-times "MEM ; + D.1190_6 = MEM ; + and preserve IDX even for stride == 1 case. */ /* { dg-final { scan-tree-dump-times "\\+" 1 "dom3"} } */ /* { dg-final { cleanup-tree-dump "dom3" } } */ Index: mem-ref/gcc/testsuite/gcc.dg/tree-ssa/20030703-2.c =================================================================== *** mem-ref.orig/gcc/testsuite/gcc.dg/tree-ssa/20030703-2.c 2008-03-09 15:18:10.000000000 +0100 --- mem-ref/gcc/testsuite/gcc.dg/tree-ssa/20030703-2.c 2008-03-09 15:20:37.000000000 +0100 *************** get_alias_set (t) *** 29,35 **** /* There should be precisely one load of {t,__t}->code. If there is more than one, then the dominator optimizations failed. */ ! /* { dg-final { scan-tree-dump-times "->code" 1 "dom3"} } */ /* There should be precisely one load of tree_code_type. If there is more than one, then the dominator optimizations failed. */ --- 29,35 ---- /* There should be precisely one load of {t,__t}->code. If there is more than one, then the dominator optimizations failed. */ ! /* { dg-final { scan-tree-dump-times "MEM decl.rtl. If there is more than, then the dominator optimizations failed. */ ! /* { dg-final { scan-tree-dump-times "->decl\\.rtl" 1 "cddce"} } */ ! ! /* There should be no loads of .rtmem since the complex return statement ! is just "return 0". */ ! /* { dg-final { scan-tree-dump-times ".rtmem" 0 "cddce"} } */ ! /* There should be one IF statement (the complex return statement should collapse down to a simple return 0 without any conditionals). */ /* { dg-final { scan-tree-dump-times "if " 1 "cddce"} } */ --- 41,48 ---- /* There should be precisely one load of ->decl.rtl. If there is more than, then the dominator optimizations failed. */ ! /* { dg-final { scan-tree-dump-times "MEM" 1 "cddce"} } */ ! /* There should be one IF statement (the complex return statement should collapse down to a simple return 0 without any conditionals). */ /* { dg-final { scan-tree-dump-times "if " 1 "cddce"} } */ Index: mem-ref/gcc/testsuite/gcc.dg/tree-ssa/20030709-3.c =================================================================== *** mem-ref.orig/gcc/testsuite/gcc.dg/tree-ssa/20030709-3.c 2008-03-09 15:22:54.000000000 +0100 --- mem-ref/gcc/testsuite/gcc.dg/tree-ssa/20030709-3.c 2008-03-09 15:23:46.000000000 +0100 *************** record_component_aliases (type) *** 36,46 **** /* There should be precisely one load of type.binfo. If there is more than one, then the dominator optimizations failed. */ ! /* { dg-final { scan-tree-dump-times "type\\.binfo" 1 "dom3"} } */ /* There should be precisely one load of common.code. If there is more than one, then the dominator optimizations failed. */ ! /* { dg-final { scan-tree-dump-times "common\\.code" 1 "dom3"} } */ /* There should be one IF conditional. */ /* { dg-final { scan-tree-dump-times "if " 1 "dom3"} } */ --- 36,46 ---- /* There should be precisely one load of type.binfo. If there is more than one, then the dominator optimizations failed. */ ! /* { dg-final { scan-tree-dump-times "MEM vec.a[4]. */ ! /* { dg-final { scan-tree-dump-times "MEM alias" 1 "dom3"} } */ /* { dg-final { cleanup-tree-dump "dom3" } } */ --- 55,66 ---- /* { dg-final { scan-tree-dump-times "if " 3 "dom3"} } */ /* There should be one loads of decl.rtl. */ ! /* { dg-final { scan-tree-dump-times "MEM alias" 1 "dom3"} } */ /* { dg-final { cleanup-tree-dump "dom3" } } */ --- 50,61 ---- /* { dg-final { scan-tree-dump-times "if " 2 "dom3"} } */ /* There should be one load of decl.rtl. */ ! /* { dg-final { scan-tree-dump-times "MEM common.code. We currently fail this ! because we load from ->common.code using different types. */ ! /* { dg-final { scan-tree-dump-times "common\.code" 1 "dom3"} } */ /* { dg-final { cleanup-tree-dump "dom3" } } */ --- 45,53 ---- /* A good optimizer would realize that the cast to (unsigned int) is useless as the earlier cast of the same value of (unsigned char) will always produce the same result. */ ! /* { dg-final { scan-tree-dump-times "\\(unsigned int\\)" 0 "dom3" } } */ ! /* There should be one load of ->common.code, two loads in total. */ ! /* { dg-final { scan-tree-dump-times "MEM" 2 "dom3" } } */ /* { dg-final { cleanup-tree-dump "dom3" } } */ Index: mem-ref/gcc/testsuite/gcc.dg/tree-ssa/20030807-5.c =================================================================== *** mem-ref.orig/gcc/testsuite/gcc.dg/tree-ssa/20030807-5.c 2008-03-09 15:46:34.000000000 +0100 --- mem-ref/gcc/testsuite/gcc.dg/tree-ssa/20030807-5.c 2008-03-09 16:13:26.000000000 +0100 *************** foo () *** 29,36 **** } /* There should be precisely one load of ->code. If there is ! more than, then the dominator optimizations failed. */ ! /* { dg-final { scan-tree-dump-times "->code" 1 "dom3"} } */ /* There should be two IF statements. One for 'current_sym_addr->code == 42'. The other one for '(EXPR)->unchanging'. */ --- 29,37 ---- } /* There should be precisely one load of ->code. If there is ! more than, then the dominator optimizations failed. ! There are two loads in total, one for unchanging as well. */ ! /* { dg-final { scan-tree-dump-times "MEM <" 2 "dom3"} } */ /* There should be two IF statements. One for 'current_sym_addr->code == 42'. The other one for '(EXPR)->unchanging'. */ Index: mem-ref/gcc/testsuite/gcc.dg/tree-ssa/20030814-1.c =================================================================== *** mem-ref.orig/gcc/testsuite/gcc.dg/tree-ssa/20030814-1.c 2008-03-09 15:48:08.000000000 +0100 --- mem-ref/gcc/testsuite/gcc.dg/tree-ssa/20030814-1.c 2008-03-09 15:49:09.000000000 +0100 *************** com(int *blah) *** 16,21 **** /* There should be precisely one load of blah. If there is more than one, then the dominator optimizations failed. */ ! /* { dg-final { scan-tree-dump-times "\\*blah" 1 "dom3"} } */ /* { dg-final { cleanup-tree-dump "dom3" } } */ --- 16,21 ---- /* There should be precisely one load of blah. If there is more than one, then the dominator optimizations failed. */ ! /* { dg-final { scan-tree-dump-times "MEM" 1 "dom3" } } */ /* { dg-final { cleanup-tree-dump "dom3" } } */ Index: mem-ref/gcc/testsuite/gcc.dg/tree-ssa/20030814-4.c =================================================================== *** mem-ref.orig/gcc/testsuite/gcc.dg/tree-ssa/20030814-4.c 2008-03-09 15:49:25.000000000 +0100 --- mem-ref/gcc/testsuite/gcc.dg/tree-ssa/20030814-4.c 2008-03-09 15:51:45.000000000 +0100 *************** blah (decl, set) *** 34,40 **** /* There should be precisely one reference to pointer_alias_set. If there is more than one, then the dominator optimizations failed. */ ! /* { dg-final { scan-tree-dump-times "pointer_alias_set" 1 "dom3"} } */ /* { dg-final { cleanup-tree-dump "dom3" } } */ /* The assignment set = -1 in the ELSE clause of the last IF --- 34,40 ---- /* There should be precisely one reference to pointer_alias_set. If there is more than one, then the dominator optimizations failed. */ ! /* { dg-final { scan-tree-dump-times "MEM > \\\+ MEM ;" "optimized" } } */ /* { dg-final { cleanup-tree-dump "optimized" } } */ Index: mem-ref/gcc/testsuite/gcc.dg/tree-ssa/complex-3.c =================================================================== *** mem-ref.orig/gcc/testsuite/gcc.dg/tree-ssa/complex-3.c 2008-03-09 16:08:20.000000000 +0100 --- mem-ref/gcc/testsuite/gcc.dg/tree-ssa/complex-3.c 2008-03-09 16:17:52.000000000 +0100 *************** float imag_part(COMPLEX_FLOAT a) *** 18,27 **** return ((float*)(&a))[1]; } ! /* Test that the above gets optimized to REALPART_EXPR and IMAGPART_EXPR ! respectively. */ ! /* { dg-final { scan-tree-dump-times "REALPART_EXPR" 2 "optimized" } } */ ! /* { dg-final { scan-tree-dump-times "IMAGPART_EXPR" 1 "optimized" } } */ /* { dg-final { cleanup-tree-dump "optimized" } } */ --- 18,26 ---- return ((float*)(&a))[1]; } ! /* Test that the above gets optimized to proper float loads. */ ! /* { dg-final { scan-tree-dump-times "MEM