From patchwork Sat Mar 23 11:31:17 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Eric Botcazou X-Patchwork-Id: 230327 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client CN "localhost", Issuer "www.qmailtoaster.com" (not verified)) by ozlabs.org (Postfix) with ESMTPS id 207ED2C00AA for ; Sat, 23 Mar 2013 22:33:07 +1100 (EST) DomainKey-Signature: a=rsa-sha1; c=nofws; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:from :to:subject:date:message-id:mime-version:content-type :content-transfer-encoding; q=dns; s=default; b=E8IMtROmwDUFLk9a T6OxCiVzUtXWdRg54QUANGGCkfRKDDpfPmDALJ3i/yWW0Tfp+AknXRh2FTvKvd/v Rl0i0BVdCrbpWP3Jz9MGGfsTKP5vHVQ4tBZskLXd2XrSAxVylofPsyxCfGzPq2wa Av2ZXQnK26YWySPKpH2MfiPlJTQ= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:from :to:subject:date:message-id:mime-version:content-type :content-transfer-encoding; s=default; bh=bxR/TFNKfk0RK8HtBGEerh aNQCI=; b=fAgQ40CJPXSnKo+UvvxOvQt9l/z3Wn7rKplnVjg0t4dYp45a4w4DQT ltkGNs6rkUaxaIS0E6OfAz4jXjIkvIDugFq3waHolOgEEfp6gxdiy408C7v06fM1 +3uPhPV78FRsPc3MiT1HmGMjXVWWlmyMDAVyils5px+n7u+XGEOqc= Received: (qmail 14234 invoked by alias); 23 Mar 2013 11:32:58 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org Received: (qmail 14221 invoked by uid 89); 23 Mar 2013 11:32:51 -0000 X-Spam-SWARE-Status: No, score=-2.2 required=5.0 tests=AWL, BAYES_00 autolearn=ham version=3.3.1 Received: from mel.act-europe.fr (HELO mel.act-europe.fr) (194.98.77.210) by sourceware.org (qpsmtpd/0.84/v0.84-167-ge50287c) with ESMTP; Sat, 23 Mar 2013 11:32:48 +0000 Received: from localhost (localhost [127.0.0.1]) by filtered-smtp.eu.adacore.com (Postfix) with ESMTP id 9477F290036 for ; Sat, 23 Mar 2013 12:32:46 +0100 (CET) Received: from mel.act-europe.fr ([127.0.0.1]) by localhost (smtp.eu.adacore.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id EIZ4AMrAZbJZ for ; Sat, 23 Mar 2013 12:32:46 +0100 (CET) Received: from polaris.localnet (bon31-6-88-161-99-133.fbx.proxad.net [88.161.99.133]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mel.act-europe.fr (Postfix) with ESMTP id 6B0AF29000A for ; Sat, 23 Mar 2013 12:32:46 +0100 (CET) From: Eric Botcazou To: gcc-patches@gcc.gnu.org Subject: [SPARC] Minor tweaks Date: Sat, 23 Mar 2013 12:31:17 +0100 Message-ID: <1438600.zm6KTiKpQZ@polaris> User-Agent: KMail/4.7.2 (Linux/3.1.10-1.19-desktop; KDE/4.7.2; x86_64; ; ) MIME-Version: 1.0 X-Virus-Found: No The correct test for the pointer size in sparc_emit_probe_stack_range is TARGET_ARCH64 instead of TARGET_64BIT. The patch also adds predicates to the 3rd argument of ctrapsi4 and ctrapdi4. Tested on SPARC/Solaris, applied on the mainline. 2013-03-23 Eric Botcazou * config/sparc/sparc.c (sparc_emit_probe_stack_range): Fix small inaccuracy in the probing code. * config/sparc/sparc.md (ctrapsi4): Add predicate for operand #3. (ctrapdi4): Likewise. Index: config/sparc/sparc.md =================================================================== --- config/sparc/sparc.md (revision 196816) +++ config/sparc/sparc.md (working copy) @@ -7217,7 +7217,7 @@ (define_expand "ctrapsi4" [(trap_if (match_operator 0 "noov_compare_operator" [(match_operand:SI 1 "compare_operand" "") (match_operand:SI 2 "arith_operand" "")]) - (match_operand 3 ""))] + (match_operand 3 "arith_operand"))] "" "operands[1] = gen_compare_reg (operands[0]); if (GET_MODE (operands[1]) != CCmode && GET_MODE (operands[1]) != CCXmode) @@ -7228,7 +7228,7 @@ (define_expand "ctrapdi4" [(trap_if (match_operator 0 "noov_compare_operator" [(match_operand:DI 1 "compare_operand" "") (match_operand:DI 2 "arith_operand" "")]) - (match_operand 3 ""))] + (match_operand 3 "arith_operand"))] "TARGET_ARCH64" "operands[1] = gen_compare_reg (operands[0]); if (GET_MODE (operands[1]) != CCmode && GET_MODE (operands[1]) != CCXmode) Index: config/sparc/sparc.c =================================================================== --- config/sparc/sparc.c (revision 196816) +++ config/sparc/sparc.c (working copy) @@ -4777,7 +4777,7 @@ sparc_emit_probe_stack_range (HOST_WIDE_ probes at FIRST + N * PROBE_INTERVAL for values of N from 1 until it is equal to ROUNDED_SIZE. */ - if (TARGET_64BIT) + if (TARGET_ARCH64) emit_insn (gen_probe_stack_rangedi (g1, g1, g4)); else emit_insn (gen_probe_stack_rangesi (g1, g1, g4));