From patchwork Sun May 13 17:16:19 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Uros Bizjak X-Patchwork-Id: 158846 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]) by ozlabs.org (Postfix) with SMTP id D3D14B700A for ; Mon, 14 May 2012 03:16:40 +1000 (EST) Comment: DKIM? See http://www.dkim.org DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d=gcc.gnu.org; s=default; x=1337534201; h=Comment: DomainKey-Signature:Received:Received:Received:Received: MIME-Version:Received:Received:In-Reply-To:References:Date: Message-ID:Subject:From:To:Content-Type:Mailing-List:Precedence: List-Id:List-Unsubscribe:List-Archive:List-Post:List-Help:Sender: Delivered-To; bh=rSUbG3u/H8wRPeLQCrTP03u2fnM=; b=WXEoklHzXSXlv8+ 6ODaD3oVC2UtsSEoIp5TVusXQj2d9hpnUtk0DbvDTWLSaNT5ia+jGWUXsBXvczDG miX2+hbTVJuKNW+pIFM8Vm1F/OcNQ/jEb23m9h4qefznmcx+oqA/cuJLjSiIIRf7 LLHYkflh/aF20ya2zBTysQaYGH+4= Comment: DomainKeys? See http://antispam.yahoo.com/domainkeys DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=default; d=gcc.gnu.org; h=Received:Received:X-SWARE-Spam-Status:X-Spam-Check-By:Received:Received:MIME-Version:Received:Received:In-Reply-To:References:Date:Message-ID:Subject:From:To:Content-Type:Mailing-List:Precedence:List-Id:List-Unsubscribe:List-Archive:List-Post:List-Help:Sender:Delivered-To; b=MkX6cNq+/dNMlU/GHfl2a4YXUoN/q3s6VH0+VPfyFr0NttvxdzTUm+Xz6W1g3S SvAGxGz/bITatF+So0KO+Yms8ORkpp0fMdsKXKyujsxRuJDaHVTY00YA8vvUVWJj VINOP81dWlDBNnARVDkF01+zWOaXi0ycaIhVRdrg3xoVI=; Received: (qmail 29324 invoked by alias); 13 May 2012 17:16:36 -0000 Received: (qmail 29297 invoked by uid 22791); 13 May 2012 17:16:33 -0000 X-SWARE-Spam-Status: No, hits=-4.9 required=5.0 tests=AWL, BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, FREEMAIL_FROM, KHOP_RCVD_TRUST, KHOP_THREADED, RCVD_IN_DNSWL_LOW, RCVD_IN_HOSTKARMA_YE, TW_ZJ X-Spam-Check-By: sourceware.org Received: from mail-yw0-f47.google.com (HELO mail-yw0-f47.google.com) (209.85.213.47) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Sun, 13 May 2012 17:16:19 +0000 Received: by yhjj56 with SMTP id j56so4106390yhj.20 for ; Sun, 13 May 2012 10:16:19 -0700 (PDT) MIME-Version: 1.0 Received: by 10.236.76.38 with SMTP id a26mr5109997yhe.98.1336929379316; Sun, 13 May 2012 10:16:19 -0700 (PDT) Received: by 10.146.124.5 with HTTP; Sun, 13 May 2012 10:16:19 -0700 (PDT) In-Reply-To: References: Date: Sun, 13 May 2012 19:16:19 +0200 Message-ID: Subject: Re: [PATCH, i386]: Handle TARGET_SSE_PACKED_SINGLE_INSN_OPTIMAL in SSE bitops From: Uros Bizjak To: gcc-patches@gcc.gnu.org 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 On Sun, May 13, 2012 at 5:16 PM, Uros Bizjak wrote: > 2012-05-13  Uros Bizjak   > >        * config/i386/sse.md (_andnot3): Handle >        TARGET_SSE_PACKED_SINGLE_INSN_OPTIMAL. >        (3): Ditto. >        (*andnot3): Ditto. >        (*andnottf3): Ditto. >        (*3): Ditto. >        (tf3): Ditto. > > Tested on x86_64-pc-linux-gnu {,-m32}, committed to mainline SVN. For some reason, the attached part was left out of my previous mail and commit. Uros. Index: config/i386/sse.md =================================================================== --- config/i386/sse.md (revision 187438) +++ config/i386/sse.md (working copy) @@ -6729,13 +6729,20 @@ (const_string "*"))) (set_attr "prefix" "orig,vex") (set (attr "mode") - (cond [(and (not (match_test "TARGET_AVX2")) - (match_test "GET_MODE_SIZE (mode) > 16")) - (const_string "V8SF") - (not (match_test "TARGET_SSE2")) - (const_string "V4SF") - ] - (const_string "")))]) + (cond [(match_test "TARGET_SSE_PACKED_SINGLE_INSN_OPTIMAL") + (const_string "") + (match_test "TARGET_AVX2") + (const_string "") + (match_test "TARGET_AVX") + (if_then_else + (match_test "GET_MODE_SIZE (mode) > 16") + (const_string "V8SF") + (const_string "")) + (ior (not (match_test "TARGET_SSE2")) + (match_test "optimize_function_for_size_p (cfun)")) + (const_string "V4SF") + ] + (const_string "")))]) (define_expand "3" [(set (match_operand:VI 0 "register_operand") @@ -6804,13 +6811,20 @@ (const_string "*"))) (set_attr "prefix" "orig,vex") (set (attr "mode") - (cond [(and (not (match_test "TARGET_AVX2")) - (match_test "GET_MODE_SIZE (mode) > 16")) - (const_string "V8SF") - (not (match_test "TARGET_SSE2")) - (const_string "V4SF") - ] - (const_string "")))]) + (cond [(match_test "TARGET_SSE_PACKED_SINGLE_INSN_OPTIMAL") + (const_string "") + (match_test "TARGET_AVX2") + (const_string "") + (match_test "TARGET_AVX") + (if_then_else + (match_test "GET_MODE_SIZE (mode) > 16") + (const_string "V8SF") + (const_string "")) + (ior (not (match_test "TARGET_SSE2")) + (match_test "optimize_function_for_size_p (cfun)")) + (const_string "V4SF") + ] + (const_string "")))]) ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;