From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 20244 invoked by alias); 19 May 2011 17:10:23 -0000 Received: (qmail 20226 invoked by uid 22791); 19 May 2011 17:10:20 -0000 X-SWARE-Spam-Status: No, hits=-6.9 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_HI,SPF_HELO_PASS,T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Thu, 19 May 2011 17:09:58 +0000 Received: from int-mx12.intmail.prod.int.phx2.redhat.com (int-mx12.intmail.prod.int.phx2.redhat.com [10.5.11.25]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id p4JH9nfR019232 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Thu, 19 May 2011 13:09:49 -0400 Received: from ns3.rdu.redhat.com (ns3.rdu.redhat.com [10.11.255.199]) by int-mx12.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id p4JH9nQR006948; Thu, 19 May 2011 13:09:49 -0400 Received: from opsy.redhat.com (ovpn01.gateway.prod.ext.phx2.redhat.com [10.5.9.1]) by ns3.rdu.redhat.com (8.13.8/8.13.8) with ESMTP id p4JH9mVJ031984; Thu, 19 May 2011 13:09:48 -0400 Received: by opsy.redhat.com (Postfix, from userid 500) id DCBA237918A; Thu, 19 May 2011 11:09:47 -0600 (MDT) From: Tom Tromey To: Yao Qi Cc: "Joseph S. Myers" , Mark Kettenis , gdb-patches@sourceware.org Subject: Re: [_Complex test 1/4] support_complex_tests in gdb.exp and pass _Complex args to func References: <4DC401D0.1050500@codesourcery.com> <4DC75036.4040806@codesourcery.com> <4DD49BE7.80206@codesourcery.com> <201105190814.p4J8EMYF020774@glazunov.sibelius.xs4all.nl> <4DD51A55.9000209@codesourcery.com> Date: Thu, 19 May 2011 17:10:00 -0000 In-Reply-To: <4DD51A55.9000209@codesourcery.com> (Yao Qi's message of "Thu, 19 May 2011 21:25:41 +0800") Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.2 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2011-05/txt/msg00446.txt.bz2 >>>>> "Yao" == Yao Qi writes: Yao> This is a good idea. Done this in new patch. Thanks for doing this. Yao> +#ifdef PROTOTYPES Yao> +void callca (float _Complex f1, float _Complex f2, float _Complex f3) Yao> +#else Yao> +callca (f1, f2, f3) Yao> +float _Complex f1; float _Complex f2; float _Complex f3; Yao> +#endif I would not worry about the no PROTOTYPES case. You can leave this in if you want though. Yao> +set compile_flags {debug nowarnings quiet} Yao> +if [support_complex_tests] { Yao> + set compile_flags "$compile_flags additional_flags=-DTEST_COMPLEX" I think it is better to use lappend here. Yao> + gdb_breakpoint callca; Yao> + gdb_breakpoint callcb; Yao> + gdb_breakpoint callcc; Yao> + gdb_breakpoint callcd; Yao> + gdb_breakpoint callce; Yao> + gdb_breakpoint callcf; These ";"s are not needed. There are a few instances of this. Yao> +# Return a 1 if we should run tests to _Complex types, otherwise, skip it. Just "Return 1 if...", and then ", otherwise 0.". I am curious if you tested this in some situation where the complex tests are skipped. Tom