From patchwork Tue Sep 26 10:37:44 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Krebbel X-Patchwork-Id: 818513 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=gcc.gnu.org (client-ip=209.132.180.131; helo=sourceware.org; envelope-from=gcc-patches-return-462946-incoming=patchwork.ozlabs.org@gcc.gnu.org; receiver=) Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=gcc.gnu.org header.i=@gcc.gnu.org header.b="pe9HtT34"; dkim-atps=neutral Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3y1cqf5YNhz9t6C for ; Tue, 26 Sep 2017 20:38:22 +1000 (AEST) 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:in-reply-to:references:message-id; q=dns; s= default; b=duE3DrumKy80U0Xo6CO/CJSgJHSSGw4b5hWI3zxnWCVWcpdQsiaFU zitUo7QiXrhnOeTWRek88PB+HzrC/GCQLxS8XPqR32mcZjEH6pcQ0vitd5EauDej eoTl2wDppaYRC6mHDjxQSWhIWR2TbJ++ZA7dsLbgSJhlfR0Jtnyhfc= 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:in-reply-to:references:message-id; s=default; bh=mgFhBREryM4fOlLNauYZk/f19Cs=; b=pe9HtT346cef+ofoLBGRkyigWekY NWIzsYhwRd7dpAdz9Z8ASiItzcdI6VEbyjhPS9brGiDilllIwehafGhlCwTXQt/s UME9G69ZPiTHyDfZO0aLJOYrgeW22WzdZMHURaiJcmHU8i6+3cPWGxsEp2EEGcfI aTApMWnpxTA7p90= Received: (qmail 101008 invoked by alias); 26 Sep 2017 10:38:02 -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 100815 invoked by uid 89); 26 Sep 2017 10:38:01 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-24.6 required=5.0 tests=AWL, BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, KAM_LAZY_DOMAIN_SECURITY, RCVD_IN_DNSWL_LOW autolearn=ham version=3.3.2 spammy= X-HELO: mx0a-001b2d01.pphosted.com Received: from mx0b-001b2d01.pphosted.com (HELO mx0a-001b2d01.pphosted.com) (148.163.158.5) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Tue, 26 Sep 2017 10:37:59 +0000 Received: from pps.filterd (m0098414.ppops.net [127.0.0.1]) by mx0b-001b2d01.pphosted.com (8.16.0.21/8.16.0.21) with SMTP id v8QAZN3S133994 for ; Tue, 26 Sep 2017 06:37:57 -0400 Received: from e06smtp14.uk.ibm.com (e06smtp14.uk.ibm.com [195.75.94.110]) by mx0b-001b2d01.pphosted.com with ESMTP id 2d7n99g5ty-1 (version=TLSv1.2 cipher=AES256-SHA bits=256 verify=NOT) for ; Tue, 26 Sep 2017 06:37:57 -0400 Received: from localhost by e06smtp14.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Tue, 26 Sep 2017 11:37:55 +0100 Received: from b06cxnps4075.portsmouth.uk.ibm.com (9.149.109.197) by e06smtp14.uk.ibm.com (192.168.101.144) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; Tue, 26 Sep 2017 11:37:53 +0100 Received: from d06av21.portsmouth.uk.ibm.com (d06av21.portsmouth.uk.ibm.com [9.149.105.232]) by b06cxnps4075.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id v8QAbrEY20709538 for ; Tue, 26 Sep 2017 10:37:53 GMT Received: from d06av21.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 4D31C52041 for ; Tue, 26 Sep 2017 10:32:43 +0100 (BST) Received: from maggie.boeblingen.de.ibm.com (unknown [9.152.212.134]) by d06av21.portsmouth.uk.ibm.com (Postfix) with ESMTPS id 304AB5203F for ; Tue, 26 Sep 2017 10:32:43 +0100 (BST) From: Andreas Krebbel To: gcc-patches@gcc.gnu.org Subject: [PATCH 1/8] Enable vect testcases on S/390. Date: Tue, 26 Sep 2017 12:37:44 +0200 In-Reply-To: <20170926103751.21907-1-krebbel@linux.vnet.ibm.com> References: <20170926103751.21907-1-krebbel@linux.vnet.ibm.com> X-TM-AS-GCONF: 00 x-cbid: 17092610-0016-0000-0000-000004F02822 X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 17092610-0017-0000-0000-0000282A7424 Message-Id: <20170926103751.21907-2-krebbel@linux.vnet.ibm.com> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:, , definitions=2017-09-26_03:, , signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 spamscore=0 suspectscore=1 malwarescore=0 phishscore=0 adultscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1707230000 definitions=main-1709260158 X-IsSubscribed: yes Add s390 platform checks where appropriate. gcc/testsuite/ChangeLog: 2017-09-26 Andreas Krebbel * lib/target-supports.exp: Enable tests for S/390. --- gcc/testsuite/ChangeLog | 4 ++ gcc/testsuite/lib/target-supports.exp | 131 ++++++++++++++++++++++++++-------- 2 files changed, 106 insertions(+), 29 deletions(-) diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 6401706..72cf8c3 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,7 @@ +2017-09-26 Andreas Krebbel + + * lib/target-supports.exp: Enable tests for S/390. + 2017-09-26 Richard Biener PR tree-optimization/82320 diff --git a/gcc/testsuite/lib/target-supports.exp b/gcc/testsuite/lib/target-supports.exp index 7834c30..8b25797 100644 --- a/gcc/testsuite/lib/target-supports.exp +++ b/gcc/testsuite/lib/target-supports.exp @@ -3066,7 +3066,9 @@ proc check_effective_target_vect_int { } { || [is-effective-target arm_neon] || ([istarget mips*-*-*] && ([et-is-effective-target mips_loongson] - || [et-is-effective-target mips_msa])) } { + || [et-is-effective-target mips_msa])) + || ([istarget s390*-*-*] + && [check_effective_target_s390_vx]) } { set et_vect_int_saved($et_index) 1 } } @@ -5069,7 +5071,9 @@ proc check_effective_target_vect_shift { } { || [is-effective-target arm_neon] || ([istarget mips*-*-*] && ([et-is-effective-target mips_msa] - || [et-is-effective-target mips_loongson])) } { + || [et-is-effective-target mips_loongson])) + || ([istarget s390*-*-*] + && [check_effective_target_s390_vx]) } { set et_vect_shift_saved($et_index) 1 } } @@ -5087,7 +5091,9 @@ proc check_effective_target_whole_vector_shift { } { || ([is-effective-target arm_neon] && [check_effective_target_arm_little_endian]) || ([istarget mips*-*-*] - && [et-is-effective-target mips_loongson]) } { + && [et-is-effective-target mips_loongson]) + || ([istarget s390*-*-*] + && [check_effective_target_s390_vx]) } { set answer 1 } else { set answer 0 @@ -5133,7 +5139,9 @@ proc check_effective_target_vect_shift_char { } { && ![istarget powerpc-*-linux*paired*]) || [is-effective-target arm_neon] || ([istarget mips*-*-*] - && [et-is-effective-target mips_msa]) } { + && [et-is-effective-target mips_msa]) + || ([istarget s390*-*-*] + && [check_effective_target_s390_vx]) } { set et_vect_shift_char_saved($et_index) 1 } } @@ -5156,7 +5164,9 @@ proc check_effective_target_vect_long { } { || ([istarget sparc*-*-*] && [check_effective_target_ilp32]) || [istarget aarch64*-*-*] || ([istarget mips*-*-*] - && [et-is-effective-target mips_msa]) } { + && [et-is-effective-target mips_msa]) + || ([istarget s390*-*-*] + && [check_effective_target_s390_vx]) } { set answer 1 } else { set answer 0 @@ -5219,7 +5229,9 @@ proc check_effective_target_vect_double { } { || [istarget spu-*-*] || ([istarget powerpc*-*-*] && [check_vsx_hw_available]) || ([istarget mips*-*-*] - && [et-is-effective-target mips_msa]) } { + && [et-is-effective-target mips_msa]) + || ([istarget s390*-*-*] + && [check_effective_target_s390_vx]) } { set et_vect_double_saved($et_index) 1 } } @@ -5243,7 +5255,9 @@ proc check_effective_target_vect_long_long { } { set et_vect_long_long_saved($et_index) 0 if { [istarget i?86-*-*] || [istarget x86_64-*-*] || ([istarget mips*-*-*] - && [et-is-effective-target mips_msa]) } { + && [et-is-effective-target mips_msa]) + || ([istarget s390*-*-*] + && [check_effective_target_s390_vx]) } { set et_vect_long_long_saved($et_index) 1 } } @@ -5343,7 +5357,9 @@ proc check_effective_target_vect_perm { } { || [istarget i?86-*-*] || [istarget x86_64-*-*] || ([istarget mips*-*-*] && ([et-is-effective-target mpaired_single] - || [et-is-effective-target mips_msa])) } { + || [et-is-effective-target mips_msa])) + || ([istarget s390*-*-*] + && [check_effective_target_s390_vx]) } { set et_vect_perm_saved($et_index) 1 } } @@ -5372,7 +5388,9 @@ proc check_effective_target_vect_perm_byte { } { || [istarget powerpc*-*-*] || [istarget spu-*-*] || ([istarget mips-*.*] - && [et-is-effective-target mips_msa]) } { + && [et-is-effective-target mips_msa]) + || ([istarget s390*-*-*] + && [check_effective_target_s390_vx]) } { set et_vect_perm_byte_saved($et_index) 1 } } @@ -5401,7 +5419,9 @@ proc check_effective_target_vect_perm_short { } { || [istarget powerpc*-*-*] || [istarget spu-*-*] || ([istarget mips*-*-*] - && [et-is-effective-target mips_msa]) } { + && [et-is-effective-target mips_msa]) + || ([istarget s390*-*-*] + && [check_effective_target_s390_vx]) } { set et_vect_perm_short_saved($et_index) 1 } } @@ -5560,7 +5580,9 @@ proc check_effective_target_vect_widen_mult_qi_to_hi { } { } if { [istarget powerpc*-*-*] || [istarget aarch64*-*-*] - || [is-effective-target arm_neon] } { + || [is-effective-target arm_neon] + || ([istarget s390*-*-*] + && [check_effective_target_s390_vx]) } { set et_vect_widen_mult_qi_to_hi_saved($et_index) 1 } } @@ -5597,7 +5619,9 @@ proc check_effective_target_vect_widen_mult_hi_to_si { } { || [istarget ia64-*-*] || [istarget aarch64*-*-*] || [istarget i?86-*-*] || [istarget x86_64-*-*] - || [is-effective-target arm_neon] } { + || [is-effective-target arm_neon] + || ([istarget s390*-*-*] + && [check_effective_target_s390_vx]) } { set et_vect_widen_mult_hi_to_si_saved($et_index) 1 } } @@ -5622,7 +5646,9 @@ proc check_effective_target_vect_widen_mult_qi_to_hi_pattern { } { set et_vect_widen_mult_qi_to_hi_pattern_saved($et_index) 0 if { [istarget powerpc*-*-*] || ([is-effective-target arm_neon] - && [check_effective_target_arm_little_endian]) } { + && [check_effective_target_arm_little_endian]) + || ([istarget s390*-*-*] + && [check_effective_target_s390_vx]) } { set et_vect_widen_mult_qi_to_hi_pattern_saved($et_index) 1 } } @@ -5650,7 +5676,9 @@ proc check_effective_target_vect_widen_mult_hi_to_si_pattern { } { || [istarget ia64-*-*] || [istarget i?86-*-*] || [istarget x86_64-*-*] || ([is-effective-target arm_neon] - && [check_effective_target_arm_little_endian]) } { + && [check_effective_target_arm_little_endian]) + || ([istarget s390*-*-*] + && [check_effective_target_s390_vx]) } { set et_vect_widen_mult_hi_to_si_pattern_saved($et_index) 1 } } @@ -5674,7 +5702,9 @@ proc check_effective_target_vect_widen_mult_si_to_di_pattern { } { } else { set et_vect_widen_mult_si_to_di_pattern_saved($et_index) 0 if {[istarget ia64-*-*] - || [istarget i?86-*-*] || [istarget x86_64-*-*] } { + || [istarget i?86-*-*] || [istarget x86_64-*-*] + || ([istarget s390*-*-*] + && [check_effective_target_s390_vx]) } { set et_vect_widen_mult_si_to_di_pattern_saved($et_index) 1 } } @@ -5847,7 +5877,9 @@ proc check_effective_target_vect_pack_trunc { } { || ([istarget arm*-*-*] && [check_effective_target_arm_neon_ok] && [check_effective_target_arm_little_endian]) || ([istarget mips*-*-*] - && [et-is-effective-target mips_msa]) } { + && [et-is-effective-target mips_msa]) + || ([istarget s390*-*-*] + && [check_effective_target_s390_vx]) } { set et_vect_pack_trunc_saved($et_index) 1 } } @@ -5877,7 +5909,9 @@ proc check_effective_target_vect_unpack { } { || ([istarget mips*-*-*] && [et-is-effective-target mips_msa]) || ([istarget arm*-*-*] && [check_effective_target_arm_neon_ok] - && [check_effective_target_arm_little_endian]) } { + && [check_effective_target_arm_little_endian]) + || ([istarget s390*-*-*] + && [check_effective_target_s390_vx]) } { set et_vect_unpack_saved($et_index) 1 } } @@ -5947,7 +5981,9 @@ proc check_effective_target_vect_hw_misalign { } { if { [istarget i?86-*-*] || [istarget x86_64-*-*] || ([istarget powerpc*-*-*] && [check_p8vector_hw_available]) || [istarget aarch64*-*-*] - || ([istarget mips*-*-*] && [et-is-effective-target mips_msa]) } { + || ([istarget mips*-*-*] && [et-is-effective-target mips_msa]) + || ([istarget s390*-*-*] + && [check_effective_target_s390_vx]) } { set et_vect_hw_misalign_saved($et_index) 1 } if { [istarget arm*-*-*] } { @@ -6121,7 +6157,9 @@ proc check_effective_target_vect_condition { } { || ([istarget mips*-*-*] && [et-is-effective-target mips_msa]) || ([istarget arm*-*-*] - && [check_effective_target_arm_neon_ok]) } { + && [check_effective_target_arm_neon_ok]) + || ([istarget s390*-*-*] + && [check_effective_target_s390_vx]) } { set et_vect_cond_saved($et_index) 1 } } @@ -6146,7 +6184,9 @@ proc check_effective_target_vect_cond_mixed { } { || [istarget aarch64*-*-*] || [istarget powerpc*-*-*] || ([istarget mips*-*-*] - && [et-is-effective-target mips_msa]) } { + && [et-is-effective-target mips_msa]) + || ([istarget s390*-*-*] + && [check_effective_target_s390_vx]) } { set et_vect_cond_mixed_saved($et_index) 1 } } @@ -6172,7 +6212,9 @@ proc check_effective_target_vect_char_mult { } { || [check_effective_target_arm32] || [check_effective_target_powerpc_altivec] || ([istarget mips*-*-*] - && [et-is-effective-target mips_msa]) } { + && [et-is-effective-target mips_msa]) + || ([istarget s390*-*-*] + && [check_effective_target_s390_vx]) } { set et_vect_char_mult_saved($et_index) 1 } } @@ -6200,7 +6242,9 @@ proc check_effective_target_vect_short_mult { } { || [check_effective_target_arm32] || ([istarget mips*-*-*] && ([et-is-effective-target mips_msa] - || [et-is-effective-target mips_loongson])) } { + || [et-is-effective-target mips_loongson])) + || ([istarget s390*-*-*] + && [check_effective_target_s390_vx]) } { set et_vect_short_mult_saved($et_index) 1 } } @@ -6227,7 +6271,9 @@ proc check_effective_target_vect_int_mult { } { || [istarget aarch64*-*-*] || ([istarget mips*-*-*] && [et-is-effective-target mips_msa]) - || [check_effective_target_arm32] } { + || [check_effective_target_arm32] + || ([istarget s390*-*-*] + && [check_effective_target_s390_vx]) } { set et_vect_int_mult_saved($et_index) 1 } } @@ -6256,7 +6302,9 @@ proc check_effective_target_vect_extract_even_odd { } { || [istarget spu-*-*] || ([istarget mips*-*-*] && ([et-is-effective-target mips_msa] - || [et-is-effective-target mpaired_single])) } { + || [et-is-effective-target mpaired_single])) + || ([istarget s390*-*-*] + && [check_effective_target_s390_vx]) } { set et_vect_extract_even_odd_saved($et_index) 1 } } @@ -6284,7 +6332,9 @@ proc check_effective_target_vect_interleave { } { || [istarget spu-*-*] || ([istarget mips*-*-*] && ([et-is-effective-target mpaired_single] - || [et-is-effective-target mips_msa])) } { + || [et-is-effective-target mips_msa])) + || ([istarget s390*-*-*] + && [check_effective_target_s390_vx]) } { set et_vect_interleave_saved($et_index) 1 } } @@ -6401,7 +6451,9 @@ proc check_effective_target_sqrt_insn { } { if { [istarget i?86-*-*] || [istarget x86_64-*-*] || [istarget powerpc*-*-*] || [istarget aarch64*-*-*] - || ([istarget arm*-*-*] && [check_effective_target_arm_vfp_ok]) } { + || ([istarget arm*-*-*] && [check_effective_target_arm_vfp_ok]) + || ([istarget s390*-*-*] + && [check_effective_target_s390_vx]) } { set et_sqrt_insn_saved 1 } } @@ -6422,7 +6474,9 @@ proc check_effective_target_vect_call_sqrtf { } { set et_vect_call_sqrtf_saved($et_index) 0 if { [istarget aarch64*-*-*] || [istarget i?86-*-*] || [istarget x86_64-*-*] - || ([istarget powerpc*-*-*] && [check_vsx_hw_available]) } { + || ([istarget powerpc*-*-*] && [check_vsx_hw_available]) + || ([istarget s390*-*-*] + && [check_effective_target_s390_vx]) } { set et_vect_call_sqrtf_saved($et_index) 1 } } @@ -8027,6 +8081,25 @@ proc check_vect_support_and_set_flags { } { } } elseif [istarget "aarch64*-*-*"] { set dg-do-what-default run + } elseif [istarget s390*-*-*] { + # The S/390 backend set a default of 2 for that value. + # Override it to have the same situation as with other + # targets. + lappend DEFAULT_VECTCFLAGS "--param" "min-vect-loop-bound=1" + lappend DEFAULT_VECTCFLAGS "--param" "max-unrolled-insns=200" + lappend DEFAULT_VECTCFLAGS "--param" "max-unroll-times=8" + lappend DEFAULT_VECTCFLAGS "--param" "max-completely-peeled-insns=200" + lappend DEFAULT_VECTCFLAGS "--param" "max-completely-peel-times=16" + if [check_effective_target_s390_vxe] { + lappend DEFAULT_VECTCFLAGS "-march=z14" "-mzarch" + set dg-do-what-default run + } elseif [check_effective_target_s390_vx] { + lappend DEFAULT_VECTCFLAGS "-march=z13" "-mzarch" + set dg-do-what-default run + } else { + lappend DEFAULT_VECTCFLAGS "-march=z14" "-mzarch" + set dg-do-what-default compile + } } else { return 0 } @@ -8453,7 +8526,7 @@ proc check_effective_target_s390_vx { } { } "-march=z13 -mzarch" ] } -# Same as above but for the arch12 vector enhancement facility. Test +# Same as above but for the z14 vector enhancement facility. Test # is performed with the vector nand instruction. proc check_effective_target_s390_vxe { } { if ![istarget s390*-*-*] then { @@ -8466,7 +8539,7 @@ proc check_effective_target_s390_vxe { } { asm ("vnn %%v24, %%v26, %%v28" : : : "v24", "v26", "v28"); return 0; } - } "-march=arch12 -mzarch" ] + } "-march=z14 -mzarch" ] } #For versions of ARM architectures that have hardware div insn, From patchwork Tue Sep 26 10:37:45 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Krebbel X-Patchwork-Id: 818514 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=gcc.gnu.org (client-ip=209.132.180.131; helo=sourceware.org; envelope-from=gcc-patches-return-462947-incoming=patchwork.ozlabs.org@gcc.gnu.org; receiver=) Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=gcc.gnu.org header.i=@gcc.gnu.org header.b="WAZUohJj"; dkim-atps=neutral Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3y1cqy0wn6z9t6C for ; Tue, 26 Sep 2017 20:38:37 +1000 (AEST) 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:in-reply-to:references:message-id; q=dns; s= default; b=eHCuHGNTKnfz1EHakyw01Mxn9cD8RPakGiZH2Xq0AUvqbzAoEg104 Xrxtc3LV52QeNlW569b/l3rzznTEJEuz94GPsrpiRoIP5cAUeQzfXJvBI2U/w1oF 6Gh/XqxPNA36zyd+zrUZ9ZzddFOXsIrj8C8NrRDfeqQ+WnxZsJrFtA= 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:in-reply-to:references:message-id; s=default; bh=m1RbYIv77AQ6y6RqG1WlFUqctvE=; b=WAZUohJjS3rjPZM+0n9pOi893KgE FdeoTF37bZgYc6S7toJFhCFgercM9DnZArzZkZyKEIfi77hdQehR+UcWuF9RGQuS Ga1ktHeuPePTQgE7iSUPyDwy4usO2qFrWC/F5m+zlNO8rp20AuG5bHpzEdC7oN+7 vgCV0AqBWjD0Mcw= Received: (qmail 102145 invoked by alias); 26 Sep 2017 10:38:06 -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 102038 invoked by uid 89); 26 Sep 2017 10:38:05 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-24.6 required=5.0 tests=AWL, BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, KAM_LAZY_DOMAIN_SECURITY, RCVD_IN_DNSWL_LOW autolearn=ham version=3.3.2 spammy=vml X-HELO: mx0a-001b2d01.pphosted.com Received: from mx0b-001b2d01.pphosted.com (HELO mx0a-001b2d01.pphosted.com) (148.163.158.5) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Tue, 26 Sep 2017 10:38:04 +0000 Received: from pps.filterd (m0098413.ppops.net [127.0.0.1]) by mx0b-001b2d01.pphosted.com (8.16.0.21/8.16.0.21) with SMTP id v8QAZ5Dg133485 for ; Tue, 26 Sep 2017 06:37:57 -0400 Received: from e06smtp10.uk.ibm.com (e06smtp10.uk.ibm.com [195.75.94.106]) by mx0b-001b2d01.pphosted.com with ESMTP id 2d7jbt32c6-1 (version=TLSv1.2 cipher=AES256-SHA bits=256 verify=NOT) for ; Tue, 26 Sep 2017 06:37:57 -0400 Received: from localhost by e06smtp10.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Tue, 26 Sep 2017 11:37:55 +0100 Received: from b06cxnps4075.portsmouth.uk.ibm.com (9.149.109.197) by e06smtp10.uk.ibm.com (192.168.101.140) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; Tue, 26 Sep 2017 11:37:54 +0100 Received: from d06av21.portsmouth.uk.ibm.com (d06av21.portsmouth.uk.ibm.com [9.149.105.232]) by b06cxnps4075.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id v8QAbsb320316406 for ; Tue, 26 Sep 2017 10:37:54 GMT Received: from d06av21.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 68A3152041 for ; Tue, 26 Sep 2017 10:32:44 +0100 (BST) Received: from maggie.boeblingen.de.ibm.com (unknown [9.152.212.134]) by d06av21.portsmouth.uk.ibm.com (Postfix) with ESMTPS id 4E0995203F for ; Tue, 26 Sep 2017 10:32:44 +0100 (BST) From: Andreas Krebbel To: gcc-patches@gcc.gnu.org Subject: [PATCH 2/8] S/390: Add widening vector mult lo/hi patterns Date: Tue, 26 Sep 2017 12:37:45 +0200 In-Reply-To: <20170926103751.21907-1-krebbel@linux.vnet.ibm.com> References: <20170926103751.21907-1-krebbel@linux.vnet.ibm.com> X-TM-AS-GCONF: 00 x-cbid: 17092610-0040-0000-0000-000003DD25BC X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 17092610-0041-0000-0000-000025DE6F3E Message-Id: <20170926103751.21907-3-krebbel@linux.vnet.ibm.com> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:, , definitions=2017-09-26_03:, , signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 spamscore=0 suspectscore=1 malwarescore=0 phishscore=0 adultscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1707230000 definitions=main-1709260158 X-IsSubscribed: yes Add support for widening vector multiply lo/hi patterns. These do not directly match on IBM Z instructions but can be emulated with even/odd + vector merge. gcc/ChangeLog: 2017-09-26 Andreas Krebbel * config/s390/vector.md ("vec_widen_umult_lo_") ("vec_widen_umult_hi_", "vec_widen_smult_lo_") ("vec_widen_smult_hi_"): New expander definitions. --- gcc/ChangeLog | 6 ++++ gcc/config/s390/vector.md | 83 ++++++++++++++++++++++++++++++++++++++++++++--- 2 files changed, 85 insertions(+), 4 deletions(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 7c6d7dc..dcee7cb 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +2017-09-26 Andreas Krebbel + + * config/s390/vector.md ("vec_widen_umult_lo_") + ("vec_widen_umult_hi_", "vec_widen_smult_lo_") + ("vec_widen_smult_hi_"): New expander definitions. + 2017-09-26 Richard Biener PR tree-optimization/82320 diff --git a/gcc/config/s390/vector.md b/gcc/config/s390/vector.md index 3cf7989..29131cd 100644 --- a/gcc/config/s390/vector.md +++ b/gcc/config/s390/vector.md @@ -1065,10 +1065,85 @@ "vmlo\t%v0,%v1,%v2" [(set_attr "op_type" "VRR")]) -; vec_widen_umult_hi -; vec_widen_umult_lo -; vec_widen_smult_hi -; vec_widen_smult_lo + +; Widening hi/lo multiplications + +; The S/390 instructions vml and vmh return the low or high parts of +; the double sized result elements in the corresponding elements of +; the target register. That's NOT what the vec_widen_umult_lo/hi +; patterns are expected to do. + +; We emulate the widening lo/hi multiplies with the even/odd versions +; followed by a vector merge + + +(define_expand "vec_widen_umult_lo_" + [(set (match_dup 3) + (unspec: [(match_operand:VI_QHS 1 "register_operand" "%v") + (match_operand:VI_QHS 2 "register_operand" "v")] + UNSPEC_VEC_UMULT_EVEN)) + (set (match_dup 4) + (unspec: [(match_dup 1) (match_dup 2)] + UNSPEC_VEC_UMULT_ODD)) + (set (match_operand: 0 "register_operand" "=v") + (unspec: [(match_dup 3) (match_dup 4)] + UNSPEC_VEC_MERGEL))] + "TARGET_VX" + { + operands[3] = gen_reg_rtx (mode); + operands[4] = gen_reg_rtx (mode); + }) + +(define_expand "vec_widen_umult_hi_" + [(set (match_dup 3) + (unspec: [(match_operand:VI_QHS 1 "register_operand" "%v") + (match_operand:VI_QHS 2 "register_operand" "v")] + UNSPEC_VEC_UMULT_EVEN)) + (set (match_dup 4) + (unspec: [(match_dup 1) (match_dup 2)] + UNSPEC_VEC_UMULT_ODD)) + (set (match_operand: 0 "register_operand" "=v") + (unspec: [(match_dup 3) (match_dup 4)] + UNSPEC_VEC_MERGEH))] + "TARGET_VX" + { + operands[3] = gen_reg_rtx (mode); + operands[4] = gen_reg_rtx (mode); + }) + +(define_expand "vec_widen_smult_lo_" + [(set (match_dup 3) + (unspec: [(match_operand:VI_QHS 1 "register_operand" "%v") + (match_operand:VI_QHS 2 "register_operand" "v")] + UNSPEC_VEC_SMULT_EVEN)) + (set (match_dup 4) + (unspec: [(match_dup 1) (match_dup 2)] + UNSPEC_VEC_SMULT_ODD)) + (set (match_operand: 0 "register_operand" "=v") + (unspec: [(match_dup 3) (match_dup 4)] + UNSPEC_VEC_MERGEL))] + "TARGET_VX" + { + operands[3] = gen_reg_rtx (mode); + operands[4] = gen_reg_rtx (mode); + }) + +(define_expand "vec_widen_smult_hi_" + [(set (match_dup 3) + (unspec: [(match_operand:VI_QHS 1 "register_operand" "%v") + (match_operand:VI_QHS 2 "register_operand" "v")] + UNSPEC_VEC_SMULT_EVEN)) + (set (match_dup 4) + (unspec: [(match_dup 1) (match_dup 2)] + UNSPEC_VEC_SMULT_ODD)) + (set (match_operand: 0 "register_operand" "=v") + (unspec: [(match_dup 3) (match_dup 4)] + UNSPEC_VEC_MERGEH))] + "TARGET_VX" + { + operands[3] = gen_reg_rtx (mode); + operands[4] = gen_reg_rtx (mode); + }) ; vec_widen_ushiftl_hi ; vec_widen_ushiftl_lo From patchwork Tue Sep 26 10:37:46 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Krebbel X-Patchwork-Id: 818516 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=gcc.gnu.org (client-ip=209.132.180.131; helo=sourceware.org; envelope-from=gcc-patches-return-462949-incoming=patchwork.ozlabs.org@gcc.gnu.org; receiver=) Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=gcc.gnu.org header.i=@gcc.gnu.org header.b="ZdVsyuQp"; dkim-atps=neutral Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3y1crR3h1Xz9tXc for ; Tue, 26 Sep 2017 20:39:03 +1000 (AEST) 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:in-reply-to:references:message-id; q=dns; s= default; b=bRc0AZDAScLV2P1u6sQ3ZnN2NQ9MGL7Aj+Par43xW3QdLoMqaleEU pbQjnOSrpw4JTfqyGIbWcxcTJmJNQet0elfMBCpHk3tG6ui7ZPbmP62dy15TVafE iaGkuFI4y6tqGlwAB4DyOe3KWjWPnZnx+BSNSf/XmwKSDkeGdOhALY= 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:in-reply-to:references:message-id; s=default; bh=kOppX6LxOEzhlw/fXgF/eI3DUAY=; b=ZdVsyuQpL5sHGGz1r6bCnaiiofU2 csGMo/OO5R4oEfWsBzTZCi6ak7B5reHAVrdRAIxNJ8qqvJVX5fi4gb/T4CbYhrk/ Xl6VRg/0qd/ljWFNUzOJ23yWvbxJtE/X78r6LEfXa9lWsi3wanN/J4q3/3OhYvyE ah6zVGCvYxjUutE= Received: (qmail 102591 invoked by alias); 26 Sep 2017 10:38:07 -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 102478 invoked by uid 89); 26 Sep 2017 10:38:07 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-24.6 required=5.0 tests=AWL, BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, KAM_LAZY_DOMAIN_SECURITY, RCVD_IN_DNSWL_LOW autolearn=ham version=3.3.2 spammy=Turn X-HELO: mx0a-001b2d01.pphosted.com Received: from mx0b-001b2d01.pphosted.com (HELO mx0a-001b2d01.pphosted.com) (148.163.158.5) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Tue, 26 Sep 2017 10:38:05 +0000 Received: from pps.filterd (m0098420.ppops.net [127.0.0.1]) by mx0b-001b2d01.pphosted.com (8.16.0.21/8.16.0.21) with SMTP id v8QAY6fX064274 for ; Tue, 26 Sep 2017 06:37:58 -0400 Received: from e06smtp10.uk.ibm.com (e06smtp10.uk.ibm.com [195.75.94.106]) by mx0b-001b2d01.pphosted.com with ESMTP id 2d7k1m8tqp-1 (version=TLSv1.2 cipher=AES256-SHA bits=256 verify=NOT) for ; Tue, 26 Sep 2017 06:37:58 -0400 Received: from localhost by e06smtp10.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Tue, 26 Sep 2017 11:37:56 +0100 Received: from b06cxnps4076.portsmouth.uk.ibm.com (9.149.109.198) by e06smtp10.uk.ibm.com (192.168.101.140) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; Tue, 26 Sep 2017 11:37:55 +0100 Received: from d06av21.portsmouth.uk.ibm.com (d06av21.portsmouth.uk.ibm.com [9.149.105.232]) by b06cxnps4076.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id v8QAbtU215925422 for ; Tue, 26 Sep 2017 10:37:55 GMT Received: from d06av21.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 82FE852045 for ; Tue, 26 Sep 2017 10:32:45 +0100 (BST) Received: from maggie.boeblingen.de.ibm.com (unknown [9.152.212.134]) by d06av21.portsmouth.uk.ibm.com (Postfix) with ESMTPS id 693695203F for ; Tue, 26 Sep 2017 10:32:45 +0100 (BST) From: Andreas Krebbel To: gcc-patches@gcc.gnu.org Subject: [PATCH 3/8] S/390: Add support for vec_shr Date: Tue, 26 Sep 2017 12:37:46 +0200 In-Reply-To: <20170926103751.21907-1-krebbel@linux.vnet.ibm.com> References: <20170926103751.21907-1-krebbel@linux.vnet.ibm.com> X-TM-AS-GCONF: 00 x-cbid: 17092610-0040-0000-0000-000003DD25BD X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 17092610-0041-0000-0000-000025DE6F3F Message-Id: <20170926103751.21907-4-krebbel@linux.vnet.ibm.com> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:, , definitions=2017-09-26_03:, , signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 spamscore=0 suspectscore=1 malwarescore=0 phishscore=0 adultscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1707230000 definitions=main-1709260158 X-IsSubscribed: yes gcc/ChangeLog: 2017-09-26 Andreas Krebbel * config/s390/predicates.md ("const_shift_by_byte_operand"): New predicate. * config/s390/vector.md ("*vec_srb"): Change modes to V_128 and V16QI. ("*vec_slb"): New insn pattern. ("vec_shr_"): New expander. * config/s390/vx-builtins.md ("vec_slb"): Turn into expander and force the shift count operand to V16QImode. ("vec_srb"): Set shift count mode to V16QI. --- gcc/ChangeLog | 12 ++++++++++++ gcc/config/s390/predicates.md | 7 +++++++ gcc/config/s390/vector.md | 39 ++++++++++++++++++++++++++++++++------- gcc/config/s390/vx-builtins.md | 23 +++++++++++++---------- 4 files changed, 64 insertions(+), 17 deletions(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index dcee7cb..7843857 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,5 +1,17 @@ 2017-09-26 Andreas Krebbel + * config/s390/predicates.md ("const_shift_by_byte_operand"): New + predicate. + * config/s390/vector.md ("*vec_srb"): Change modes to V_128 + and V16QI. + ("*vec_slb"): New insn pattern. + ("vec_shr_"): New expander. + * config/s390/vx-builtins.md ("vec_slb"): Turn into expander + and force the shift count operand to V16QImode. + ("vec_srb"): Set shift count mode to V16QI. + +2017-09-26 Andreas Krebbel + * config/s390/vector.md ("vec_widen_umult_lo_") ("vec_widen_umult_hi_", "vec_widen_smult_lo_") ("vec_widen_smult_hi_"): New expander definitions. diff --git a/gcc/config/s390/predicates.md b/gcc/config/s390/predicates.md index db966dd..bbff8d8 100644 --- a/gcc/config/s390/predicates.md +++ b/gcc/config/s390/predicates.md @@ -508,3 +508,10 @@ } return true; }) + +(define_predicate "const_shift_by_byte_operand" + (match_code "const_int") +{ + unsigned HOST_WIDE_INT val = INTVAL (op); + return val <= 128 && val % 8 == 0; +}) diff --git a/gcc/config/s390/vector.md b/gcc/config/s390/vector.md index 29131cd..e61bb88 100644 --- a/gcc/config/s390/vector.md +++ b/gcc/config/s390/vector.md @@ -980,15 +980,43 @@ ; Pattern used by e.g. popcount (define_insn "*vec_srb" - [(set (match_operand:V_HW 0 "register_operand" "=v") - (unspec:V_HW [(match_operand:V_HW 1 "register_operand" "v") - (match_operand: 2 "register_operand" "v")] - UNSPEC_VEC_SRLB))] + [(set (match_operand:V_128 0 "register_operand" "=v") + (unspec:V_128 [(match_operand:V_128 1 "register_operand" "v") + (match_operand:V16QI 2 "register_operand" "v")] + UNSPEC_VEC_SRLB))] "TARGET_VX" "vsrlb\t%v0,%v1,%v2" [(set_attr "op_type" "VRR")]) +; Vector shift left by byte + +(define_insn "*vec_slb" + [(set (match_operand:V_128 0 "register_operand" "=v") + (unspec:V_128 [(match_operand:V_128 1 "register_operand" "v") + (match_operand:V16QI 2 "register_operand" "v")] + UNSPEC_VEC_SLB))] + "TARGET_VX" + "vslb\t%v0,%v1,%v2" + [(set_attr "op_type" "VRR")]) + +; vec_shr is defined as shift towards element 0 +; this means it is a left shift on BE targets! +(define_expand "vec_shr_" + [(set (match_dup 3) + (unspec:V16QI [(match_operand:SI 2 "const_shift_by_byte_operand" "") + (const_int 7) + (match_dup 3)] + UNSPEC_VEC_SET)) + (set (match_operand:V_128 0 "register_operand" "") + (unspec:V_128 [(match_operand:V_128 1 "register_operand" "") + (match_dup 3)] + UNSPEC_VEC_SLB))] + "TARGET_VX" + { + operands[3] = gen_reg_rtx(V16QImode); + }) + ; vmnb, vmnh, vmnf, vmng (define_insn "smin3" [(set (match_operand:VI 0 "register_operand" "=v") @@ -1779,9 +1807,6 @@ ; reduc_umin ; reduc_umax -; vec_shl vrep + vsl -; vec_shr - ; vec_pack_sfix_trunc: convert + pack ? ; vec_pack_ufix_trunc ; vec_unpacks_float_hi diff --git a/gcc/config/s390/vx-builtins.md b/gcc/config/s390/vx-builtins.md index 54796df..4c157e3 100644 --- a/gcc/config/s390/vx-builtins.md +++ b/gcc/config/s390/vx-builtins.md @@ -1005,15 +1005,16 @@ ; Vector shift left by byte -(define_insn "vec_slb" - [(set (match_operand:V_HW 0 "register_operand" "=v") - (unspec:V_HW [(match_operand:V_HW 1 "register_operand" "v") - (match_operand: 2 "register_operand" "v")] +; Pattern definition in vector.md, see vec_vslb +(define_expand "vec_slb" + [(set (match_operand:V_HW 0 "register_operand" "") + (unspec:V_HW [(match_operand:V_HW 1 "register_operand" "") + (match_operand: 2 "register_operand" "")] UNSPEC_VEC_SLB))] "TARGET_VX" - "vslb\t%v0,%v1,%v2" - [(set_attr "op_type" "VRR")]) - +{ + PUT_MODE (operands[2], V16QImode); +}) ; Vector shift left double by byte @@ -1076,14 +1077,16 @@ ; Vector shift right logical by byte -; Pattern definition in vector.md +; Pattern definition in vector.md, see vec_vsrb (define_expand "vec_srb" [(set (match_operand:V_HW 0 "register_operand" "") (unspec:V_HW [(match_operand:V_HW 1 "register_operand" "") (match_operand: 2 "register_operand" "")] UNSPEC_VEC_SRLB))] - "TARGET_VX") - + "TARGET_VX" +{ + PUT_MODE (operands[2], V16QImode); +}) ; Vector subtract From patchwork Tue Sep 26 10:37:47 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Krebbel X-Patchwork-Id: 818515 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=gcc.gnu.org (client-ip=209.132.180.131; helo=sourceware.org; envelope-from=gcc-patches-return-462948-incoming=patchwork.ozlabs.org@gcc.gnu.org; receiver=) Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=gcc.gnu.org header.i=@gcc.gnu.org header.b="lXqO+6QS"; dkim-atps=neutral Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3y1crC11gfz9t6C for ; Tue, 26 Sep 2017 20:38:50 +1000 (AEST) 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:in-reply-to:references:message-id; q=dns; s= default; b=s0+o97m+eVjULM6nYskZkW6l73TXpSS7F++Ui7oX8ulQjAKVxtyYk HYxrhUzqOMCnEV5trzhiyM9WhT5Detbz+Ji2sptJL9dpsWkBymrKA4KZXFNvHgld f7bbmsX2/QKtDSaDHNz5sEr/n1WeNLknVvjnhzvxYM1y6Yj9g9vrxo= 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:in-reply-to:references:message-id; s=default; bh=JNsKQaykdfkoajl0TMgKGzLOcpM=; b=lXqO+6QSQsdU4Dw6wUC/kUvJo6FI BqH5xGP7mrX+eS6DOLWdINY9EdMiWmByAyPuf3yOuig0eGa3hssShb9Y8QY7rxoE 0dzX2uxsbp7X9c1KbtrJHfEYGOQTtjgluk3z9trGYRDZkypmz4bsBS+GXYFt25jA uOitf/jp8QVvhz8= Received: (qmail 102514 invoked by alias); 26 Sep 2017 10:38:07 -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 102434 invoked by uid 89); 26 Sep 2017 10:38:07 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-24.6 required=5.0 tests=AWL, BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, KAM_LAZY_DOMAIN_SECURITY, RCVD_IN_DNSWL_LOW autolearn=ham version=3.3.2 spammy= X-HELO: mx0a-001b2d01.pphosted.com Received: from mx0a-001b2d01.pphosted.com (HELO mx0a-001b2d01.pphosted.com) (148.163.156.1) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Tue, 26 Sep 2017 10:38:05 +0000 Received: from pps.filterd (m0098394.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.0.21/8.16.0.21) with SMTP id v8QAbcfY113921 for ; Tue, 26 Sep 2017 06:38:00 -0400 Received: from e06smtp12.uk.ibm.com (e06smtp12.uk.ibm.com [195.75.94.108]) by mx0a-001b2d01.pphosted.com with ESMTP id 2d7k4h8g82-1 (version=TLSv1.2 cipher=AES256-SHA bits=256 verify=NOT) for ; Tue, 26 Sep 2017 06:38:00 -0400 Received: from localhost by e06smtp12.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Tue, 26 Sep 2017 11:37:58 +0100 Received: from b06cxnps4076.portsmouth.uk.ibm.com (9.149.109.198) by e06smtp12.uk.ibm.com (192.168.101.142) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; Tue, 26 Sep 2017 11:37:56 +0100 Received: from d06av21.portsmouth.uk.ibm.com (d06av21.portsmouth.uk.ibm.com [9.149.105.232]) by b06cxnps4076.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id v8QAbudw21627098 for ; Tue, 26 Sep 2017 10:37:56 GMT Received: from d06av21.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 9E3AC52041 for ; Tue, 26 Sep 2017 10:32:46 +0100 (BST) Received: from maggie.boeblingen.de.ibm.com (unknown [9.152.212.134]) by d06av21.portsmouth.uk.ibm.com (Postfix) with ESMTPS id 83FB65203F for ; Tue, 26 Sep 2017 10:32:46 +0100 (BST) From: Andreas Krebbel To: gcc-patches@gcc.gnu.org Subject: [PATCH 4/8] S/390: Add FP vec_pack/unpack Date: Tue, 26 Sep 2017 12:37:47 +0200 In-Reply-To: <20170926103751.21907-1-krebbel@linux.vnet.ibm.com> References: <20170926103751.21907-1-krebbel@linux.vnet.ibm.com> X-TM-AS-GCONF: 00 x-cbid: 17092610-0008-0000-0000-0000049A254E X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 17092610-0009-0000-0000-00001E2B6F31 Message-Id: <20170926103751.21907-5-krebbel@linux.vnet.ibm.com> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:, , definitions=2017-09-26_03:, , signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 spamscore=0 suspectscore=1 malwarescore=0 phishscore=0 adultscore=1 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1707230000 definitions=main-1709260158 X-IsSubscribed: yes gcc/ChangeLog: 2017-09-26 Andreas Krebbel * config/s390/vector.md ("vec_unpacks_lo_v4sf") ("vec_unpacks_hi_v4sf", "vec_unpacks_lo_v2df") ("vec_unpacks_hi_v2df", "vec_pack_trunc_v2df"): New expanders. --- gcc/ChangeLog | 6 +++ gcc/config/s390/vector.md | 96 ++++++++++++++++++++++++++++++++++++++++++++++- 2 files changed, 101 insertions(+), 1 deletion(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 7843857..d2808b5 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,5 +1,11 @@ 2017-09-26 Andreas Krebbel + * config/s390/vector.md ("vec_unpacks_lo_v4sf") + ("vec_unpacks_hi_v4sf", "vec_unpacks_lo_v2df") + ("vec_unpacks_hi_v2df", "vec_pack_trunc_v2df"): New expanders. + +2017-09-26 Andreas Krebbel + * config/s390/predicates.md ("const_shift_by_byte_operand"): New predicate. * config/s390/vector.md ("*vec_srb"): Change modes to V_128 diff --git a/gcc/config/s390/vector.md b/gcc/config/s390/vector.md index e61bb88..c15d81d 100644 --- a/gcc/config/s390/vector.md +++ b/gcc/config/s390/vector.md @@ -1781,7 +1781,7 @@ ;; vector load lengthened -; vflls +; vflls float -> double (define_insn "*vec_extendv4sf" [(set (match_operand:V2DF 0 "register_operand" "=v") (float_extend:V2DF @@ -1792,6 +1792,34 @@ "vldeb\t%v0,%v1" [(set_attr "op_type" "VRR")]) +(define_expand "vec_unpacks_lo_v4sf" + [(set (match_dup 2) + (unspec:V4SF [(match_operand:V4SF 1 "register_operand" "v") + (match_dup 1)] + UNSPEC_VEC_MERGEL)) + (set (match_operand:V2DF 0 "register_operand" "=v") + (float_extend:V2DF + (vec_select:V2SF + (match_dup 2) + (parallel [(const_int 0) (const_int 2)]))))] + "TARGET_VX" +{ operands[2] = gen_reg_rtx(V4SFmode); }) + +(define_expand "vec_unpacks_hi_v4sf" + [(set (match_dup 2) + (unspec:V4SF [(match_operand:V4SF 1 "register_operand" "v") + (match_dup 1)] + UNSPEC_VEC_MERGEH)) + (set (match_operand:V2DF 0 "register_operand" "=v") + (float_extend:V2DF + (vec_select:V2SF + (match_dup 2) + (parallel [(const_int 0) (const_int 2)]))))] + "TARGET_VX" +{ operands[2] = gen_reg_rtx(V4SFmode); }) + + +; double -> long double (define_insn "*vec_extendv2df" [(set (match_operand:V1TF 0 "register_operand" "=v") (float_extend:V1TF @@ -1802,6 +1830,72 @@ "wflld\t%v0,%v1" [(set_attr "op_type" "VRR")]) +(define_expand "vec_unpacks_lo_v2df" + [(set (match_dup 2) + (unspec:V2DF [(match_operand:V2DF 1 "register_operand" "v") + (match_dup 1)] + UNSPEC_VEC_MERGEL)) + (set (match_operand:V1TF 0 "register_operand" "=v") + (float_extend:V1TF + (vec_select:V1DF + (match_dup 2) + (parallel [(const_int 0)]))))] + "TARGET_VXE" +{ operands[2] = gen_reg_rtx (V2DFmode); }) + +(define_expand "vec_unpacks_hi_v2df" + [(set (match_dup 2) + (unspec:V2DF [(match_operand:V2DF 1 "register_operand" "v") + (match_dup 1)] + UNSPEC_VEC_MERGEH)) + (set (match_operand:V1TF 0 "register_operand" "=v") + (float_extend:V1TF + (vec_select:V1DF + (match_dup 2) + (parallel [(const_int 0)]))))] + "TARGET_VXE" +{ operands[2] = gen_reg_rtx (V2DFmode); }) + + +; 2 x v2df -> 1 x v4sf +(define_expand "vec_pack_trunc_v2df" + [(set (match_dup 3) + (unspec:V4SF [(match_operand:V2DF 1 "register_operand" "") + (const_int VEC_INEXACT) + (const_int VEC_RND_CURRENT)] + UNSPEC_VEC_VFLR)) + (set (match_dup 4) + (unspec:V4SF [(match_operand:V2DF 2 "register_operand" "") + (const_int VEC_INEXACT) + (const_int VEC_RND_CURRENT)] + UNSPEC_VEC_VFLR)) + (set (match_dup 6) + (unspec:V16QI [(subreg:V16QI (match_dup 3) 0) + (subreg:V16QI (match_dup 4) 0) + (match_dup 5)] + UNSPEC_VEC_PERM)) + (set (match_operand:V4SF 0 "register_operand" "") + (subreg:V4SF (match_dup 6) 0))] + "TARGET_VX" +{ + rtx constv, perm[16]; + int i; + + for (i = 0; i < 4; ++i) + { + perm[i] = GEN_INT (i); + perm[i + 4] = GEN_INT (i + 8); + perm[i + 8] = GEN_INT (i + 16); + perm[i + 12] = GEN_INT (i + 24); + } + constv = gen_rtx_CONST_VECTOR (V16QImode, gen_rtvec_v (16, perm)); + + operands[3] = gen_reg_rtx (V4SFmode); + operands[4] = gen_reg_rtx (V4SFmode); + operands[5] = force_reg (V16QImode, constv); + operands[6] = gen_reg_rtx (V16QImode); +}) + ; reduc_smin ; reduc_smax ; reduc_umin From patchwork Tue Sep 26 10:37:48 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Krebbel X-Patchwork-Id: 818517 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=gcc.gnu.org (client-ip=209.132.180.131; helo=sourceware.org; envelope-from=gcc-patches-return-462950-incoming=patchwork.ozlabs.org@gcc.gnu.org; receiver=) Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=gcc.gnu.org header.i=@gcc.gnu.org header.b="ilhL5mQ4"; dkim-atps=neutral Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3y1crh2rgwz9t6C for ; Tue, 26 Sep 2017 20:39:16 +1000 (AEST) 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:in-reply-to:references:message-id; q=dns; s= default; b=DwwNIkOaB3dbsadM0uKnIieicaCWzRtka8h80gP1d4HN02DUoB7YZ 0l7Hh/lK4YR6AWPgD0C7NZkj3iZd5TQhhWM+gbUsJhJyLGhktI9W1lTII6E6JC/5 fNQfgJxFyX8CXuazHIb4YMTQI/wbUYOxy07fGwWg517yY5ygXgClTc= 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:in-reply-to:references:message-id; s=default; bh=ko0uwv9zP70pP1Ofr6ohPxQjXnE=; b=ilhL5mQ4cz/iInOZdlHCySLd2oDE OczK5wRUz3+UB0z8BZSPdR9K2euaPpdlGvoFjHUhYG6rz85uaIrI69u5bI3LNNEk ME+bsDcdu89K7re2HScTwx0yNvs2M7C0X0ZLO1Rwusan3iKauonu+ySh1snXyl8E XLv6nQ95Jxm7cCg= Received: (qmail 103459 invoked by alias); 26 Sep 2017 10:38:10 -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 103125 invoked by uid 89); 26 Sep 2017 10:38:09 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-24.6 required=5.0 tests=AWL, BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, KAM_LAZY_DOMAIN_SECURITY, RCVD_IN_DNSWL_LOW autolearn=ham version=3.3.2 spammy= X-HELO: mx0a-001b2d01.pphosted.com Received: from mx0a-001b2d01.pphosted.com (HELO mx0a-001b2d01.pphosted.com) (148.163.156.1) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Tue, 26 Sep 2017 10:38:08 +0000 Received: from pps.filterd (m0098399.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.0.21/8.16.0.21) with SMTP id v8QAY6lo007364 for ; Tue, 26 Sep 2017 06:38:02 -0400 Received: from e06smtp15.uk.ibm.com (e06smtp15.uk.ibm.com [195.75.94.111]) by mx0a-001b2d01.pphosted.com with ESMTP id 2d7jwh9dw6-1 (version=TLSv1.2 cipher=AES256-SHA bits=256 verify=NOT) for ; Tue, 26 Sep 2017 06:38:02 -0400 Received: from localhost by e06smtp15.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Tue, 26 Sep 2017 11:38:00 +0100 Received: from b06cxnps4074.portsmouth.uk.ibm.com (9.149.109.196) by e06smtp15.uk.ibm.com (192.168.101.145) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; Tue, 26 Sep 2017 11:37:58 +0100 Received: from d06av21.portsmouth.uk.ibm.com (d06av21.portsmouth.uk.ibm.com [9.149.105.232]) by b06cxnps4074.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id v8QAbvdw18940114 for ; Tue, 26 Sep 2017 10:37:57 GMT Received: from d06av21.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id B8C9F52043 for ; Tue, 26 Sep 2017 10:32:47 +0100 (BST) Received: from maggie.boeblingen.de.ibm.com (unknown [9.152.212.134]) by d06av21.portsmouth.uk.ibm.com (Postfix) with ESMTPS id 9EAE95203F for ; Tue, 26 Sep 2017 10:32:47 +0100 (BST) From: Andreas Krebbel To: gcc-patches@gcc.gnu.org Subject: [PATCH 5/8] S/390: Fix rtl standard names for vector unpack low->lo Date: Tue, 26 Sep 2017 12:37:48 +0200 In-Reply-To: <20170926103751.21907-1-krebbel@linux.vnet.ibm.com> References: <20170926103751.21907-1-krebbel@linux.vnet.ibm.com> X-TM-AS-GCONF: 00 x-cbid: 17092610-0020-0000-0000-000003BB271F X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 17092610-0021-0000-0000-0000424CFF26 Message-Id: <20170926103751.21907-6-krebbel@linux.vnet.ibm.com> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:, , definitions=2017-09-26_03:, , signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 spamscore=0 suspectscore=1 malwarescore=0 phishscore=0 adultscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1707230000 definitions=main-1709260158 X-IsSubscribed: yes gcc/ChangeLog: 2017-09-26 Andreas Krebbel * config/s390/vector.md ("vec_unpacks_low_v16qi"): Rename to vec_unpacks_lo_v16qi. ("vec_unpacku_low_v16qi"): Rename to vec_unpacku_lo_v16qi. --- gcc/ChangeLog | 6 ++++++ gcc/config/s390/vector.md | 4 ++-- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index d2808b5..7863af1 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,5 +1,11 @@ 2017-09-26 Andreas Krebbel + * config/s390/vector.md ("vec_unpacks_low_v16qi"): Rename to + vec_unpacks_lo_v16qi. + ("vec_unpacku_low_v16qi"): Rename to vec_unpacku_lo_v16qi. + +2017-09-26 Andreas Krebbel + * config/s390/vector.md ("vec_unpacks_lo_v4sf") ("vec_unpacks_hi_v4sf", "vec_unpacks_lo_v2df") ("vec_unpacks_hi_v2df", "vec_pack_trunc_v2df"): New expanders. diff --git a/gcc/config/s390/vector.md b/gcc/config/s390/vector.md index c15d81d..06c88c1 100644 --- a/gcc/config/s390/vector.md +++ b/gcc/config/s390/vector.md @@ -1652,7 +1652,7 @@ "vuphb\t%0,%1" [(set_attr "op_type" "VRR")]) -(define_insn "vec_unpacks_low_v16qi" +(define_insn "vec_unpacks_lo_v16qi" [(set (match_operand:V8HI 0 "register_operand" "=v") (sign_extend:V8HI (vec_select:V8QI @@ -1676,7 +1676,7 @@ "vuplhb\t%0,%1" [(set_attr "op_type" "VRR")]) -(define_insn "vec_unpacku_low_v16qi" +(define_insn "vec_unpacku_lo_v16qi" [(set (match_operand:V8HI 0 "register_operand" "=v") (zero_extend:V8HI (vec_select:V8QI From patchwork Tue Sep 26 10:37:49 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Krebbel X-Patchwork-Id: 818519 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=gcc.gnu.org (client-ip=209.132.180.131; helo=sourceware.org; envelope-from=gcc-patches-return-462952-incoming=patchwork.ozlabs.org@gcc.gnu.org; receiver=) Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=gcc.gnu.org header.i=@gcc.gnu.org header.b="pnqmZCwc"; dkim-atps=neutral Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3y1csD0wyjz9t6C for ; Tue, 26 Sep 2017 20:39:43 +1000 (AEST) 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:in-reply-to:references:message-id; q=dns; s= default; b=pKumgkp7jhYfP+LHHhOiTjfe3VhVtFXgGH3G6BhZou6e6ju/PoeOz zH2w4z8xaLwSW/rfhZCCWzNsOVpdU4lNCYBSwnoBcbhhpWYIdc/Zne39Ox9lOZGU lQkXznG41AxCDr2U6OU16nYrXSSoWuX7Qt5fXcf69kQSmaEf91YP94= 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:in-reply-to:references:message-id; s=default; bh=zF2GHD6bG6hyo1B6RUXCId8I//A=; b=pnqmZCwcsy0Xrz+YHmCVvhKvMLIf 9reF6GnCGm89gk3o5h6XFA7XrHuiLFYM38dF9bL63Q82V/JNl2zQrjhnFD3/LY+m xjOGod1JjOND0aThawb4ZhlifNv19aoaUfGMTpj8/Nryn+dz4qpuKeZflEDZBPnx 5CwgE+b1AohPwlE= Received: (qmail 103944 invoked by alias); 26 Sep 2017 10:38:11 -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 103850 invoked by uid 89); 26 Sep 2017 10:38:11 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-24.6 required=5.0 tests=AWL, BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, KAM_LAZY_DOMAIN_SECURITY, RCVD_IN_DNSWL_LOW autolearn=ham version=3.3.2 spammy= X-HELO: mx0a-001b2d01.pphosted.com Received: from mx0a-001b2d01.pphosted.com (HELO mx0a-001b2d01.pphosted.com) (148.163.156.1) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Tue, 26 Sep 2017 10:38:10 +0000 Received: from pps.filterd (m0098393.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.0.21/8.16.0.21) with SMTP id v8QAXi8D020170 for ; Tue, 26 Sep 2017 06:38:02 -0400 Received: from e06smtp11.uk.ibm.com (e06smtp11.uk.ibm.com [195.75.94.107]) by mx0a-001b2d01.pphosted.com with ESMTP id 2d7junhn7y-1 (version=TLSv1.2 cipher=AES256-SHA bits=256 verify=NOT) for ; Tue, 26 Sep 2017 06:38:02 -0400 Received: from localhost by e06smtp11.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Tue, 26 Sep 2017 11:38:00 +0100 Received: from b06cxnps4075.portsmouth.uk.ibm.com (9.149.109.197) by e06smtp11.uk.ibm.com (192.168.101.141) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; Tue, 26 Sep 2017 11:37:59 +0100 Received: from d06av21.portsmouth.uk.ibm.com (d06av21.portsmouth.uk.ibm.com [9.149.105.232]) by b06cxnps4075.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id v8QAbwn419333368 for ; Tue, 26 Sep 2017 10:37:58 GMT Received: from d06av21.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id D3CEC52045 for ; Tue, 26 Sep 2017 10:32:48 +0100 (BST) Received: from maggie.boeblingen.de.ibm.com (unknown [9.152.212.134]) by d06av21.portsmouth.uk.ibm.com (Postfix) with ESMTPS id B99D95204B for ; Tue, 26 Sep 2017 10:32:48 +0100 (BST) From: Andreas Krebbel To: gcc-patches@gcc.gnu.org Subject: [PATCH 6/8] S/390: Set the preferred mode for float vectors Date: Tue, 26 Sep 2017 12:37:49 +0200 In-Reply-To: <20170926103751.21907-1-krebbel@linux.vnet.ibm.com> References: <20170926103751.21907-1-krebbel@linux.vnet.ibm.com> X-TM-AS-GCONF: 00 x-cbid: 17092610-0040-0000-0000-000003FD21DF X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 17092610-0041-0000-0000-0000209E6BCF Message-Id: <20170926103751.21907-7-krebbel@linux.vnet.ibm.com> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:, , definitions=2017-09-26_03:, , signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 spamscore=0 suspectscore=1 malwarescore=0 phishscore=0 adultscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1707230000 definitions=main-1709260158 X-IsSubscribed: yes gcc/ChangeLog: 2017-09-26 Andreas Krebbel * config/s390/s390.c (s390_preferred_simd_mode): Return V4SFmode for SFmode. --- gcc/ChangeLog | 5 +++++ gcc/config/s390/s390.c | 8 ++++++++ 2 files changed, 13 insertions(+) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 7863af1..a33de8f 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,5 +1,10 @@ 2017-09-26 Andreas Krebbel + * config/s390/s390.c (s390_preferred_simd_mode): Return V4SFmode + for SFmode. + +2017-09-26 Andreas Krebbel + * config/s390/vector.md ("vec_unpacks_low_v16qi"): Rename to vec_unpacks_lo_v16qi. ("vec_unpacku_low_v16qi"): Rename to vec_unpacku_lo_v16qi. diff --git a/gcc/config/s390/s390.c b/gcc/config/s390/s390.c index e3fafa2a6..0ceeef4 100644 --- a/gcc/config/s390/s390.c +++ b/gcc/config/s390/s390.c @@ -15859,6 +15859,14 @@ s390_atomic_assign_expand_fenv (tree *hold, tree *clear, tree *update) static machine_mode s390_preferred_simd_mode (scalar_mode mode) { + if (TARGET_VXE) + switch (mode) + { + case E_SFmode: + return V4SFmode; + default:; + } + if (TARGET_VX) switch (mode) { From patchwork Tue Sep 26 10:37:50 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Krebbel X-Patchwork-Id: 818518 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=gcc.gnu.org (client-ip=209.132.180.131; helo=sourceware.org; envelope-from=gcc-patches-return-462951-incoming=patchwork.ozlabs.org@gcc.gnu.org; receiver=) Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=gcc.gnu.org header.i=@gcc.gnu.org header.b="k8Zg+9wx"; dkim-atps=neutral Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3y1crx0Rmcz9tXc for ; Tue, 26 Sep 2017 20:39:28 +1000 (AEST) 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:in-reply-to:references:message-id; q=dns; s= default; b=PqouEtwzE9NboG9mwr4Rt1m8bOhiF1eGPp4YJMaz5LlGlDG04EbNO KUCS0MBNpe2+hwqHfG8HNzPFbqwpwZa7f9W9/qZPZIJU0u+wp4O3HdsOpBCKIPJO tMWV9YHBSgG9UZwAwISyGUPIDy8ThW7E3bp9cKnQ7urW6D+ROhRJBE= 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:in-reply-to:references:message-id; s=default; bh=GSNgVlu+iNhJm89sVWEWjQ/CDds=; b=k8Zg+9wxqcDDrn7QDKylTfHYtVe9 gLc7PyCHzSKmj9o34O3TUAAo71EGfl9m1fOtDEyr+I+a/JBQtmJQX0SwSWfFpzdh EJ/D4lZRcCeBatHhvqA/H+XGmKeIY++DNqwtfoLJEj+A1zQk8WKar+zuWJweL31U sJqRe5ZZLoUmjzY= Received: (qmail 103528 invoked by alias); 26 Sep 2017 10:38:10 -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 103140 invoked by uid 89); 26 Sep 2017 10:38:09 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-24.6 required=5.0 tests=AWL, BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, KAM_LAZY_DOMAIN_SECURITY, RCVD_IN_DNSWL_LOW autolearn=ham version=3.3.2 spammy=vv, dv X-HELO: mx0a-001b2d01.pphosted.com Received: from mx0b-001b2d01.pphosted.com (HELO mx0a-001b2d01.pphosted.com) (148.163.158.5) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Tue, 26 Sep 2017 10:38:07 +0000 Received: from pps.filterd (m0098417.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.0.21/8.16.0.21) with SMTP id v8QAZF8g065844 for ; Tue, 26 Sep 2017 06:38:03 -0400 Received: from e06smtp13.uk.ibm.com (e06smtp13.uk.ibm.com [195.75.94.109]) by mx0a-001b2d01.pphosted.com with ESMTP id 2d7mfk3bxp-1 (version=TLSv1.2 cipher=AES256-SHA bits=256 verify=NOT) for ; Tue, 26 Sep 2017 06:38:03 -0400 Received: from localhost by e06smtp13.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Tue, 26 Sep 2017 11:38:01 +0100 Received: from b06cxnps4076.portsmouth.uk.ibm.com (9.149.109.198) by e06smtp13.uk.ibm.com (192.168.101.143) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; Tue, 26 Sep 2017 11:38:00 +0100 Received: from d06av21.portsmouth.uk.ibm.com (d06av21.portsmouth.uk.ibm.com [9.149.105.232]) by b06cxnps4076.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id v8QAbx8A21299322 for ; Tue, 26 Sep 2017 10:37:59 GMT Received: from d06av21.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id EF12152043 for ; Tue, 26 Sep 2017 10:32:49 +0100 (BST) Received: from maggie.boeblingen.de.ibm.com (unknown [9.152.212.134]) by d06av21.portsmouth.uk.ibm.com (Postfix) with ESMTPS id D4BC15203F for ; Tue, 26 Sep 2017 10:32:49 +0100 (BST) From: Andreas Krebbel To: gcc-patches@gcc.gnu.org Subject: [PATCH 7/8] S/390: Fix vector fp unordered compares Date: Tue, 26 Sep 2017 12:37:50 +0200 In-Reply-To: <20170926103751.21907-1-krebbel@linux.vnet.ibm.com> References: <20170926103751.21907-1-krebbel@linux.vnet.ibm.com> X-TM-AS-GCONF: 00 x-cbid: 17092610-0012-0000-0000-0000057C2DD4 X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 17092610-0013-0000-0000-000018F57A30 Message-Id: <20170926103751.21907-8-krebbel@linux.vnet.ibm.com> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:, , definitions=2017-09-26_03:, , signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 spamscore=0 suspectscore=1 malwarescore=0 phishscore=0 adultscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1707230000 definitions=main-1709260158 X-IsSubscribed: yes V2DF mode was still hard-coded here. gcc/ChangeLog: 2017-09-26 Andreas Krebbel * config/s390/s390.c (s390_expand_vec_compare): Use the new mode independent expanders. * config/s390/vector.md ("vec_cmpuneq", "vec_cmpltgt") ("vec_ordered", "vec_unordered"): New expanders. --- gcc/ChangeLog | 7 ++++++ gcc/config/s390/s390.c | 8 +++--- gcc/config/s390/vector.md | 64 +++++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 75 insertions(+), 4 deletions(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index a33de8f..d4f67f5 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,5 +1,12 @@ 2017-09-26 Andreas Krebbel + * config/s390/s390.c (s390_expand_vec_compare): Use the new mode + independent expanders. + * config/s390/vector.md ("vec_cmpuneq", "vec_cmpltgt") + ("vec_ordered", "vec_unordered"): New expanders. + +2017-09-26 Andreas Krebbel + * config/s390/s390.c (s390_preferred_simd_mode): Return V4SFmode for SFmode. diff --git a/gcc/config/s390/s390.c b/gcc/config/s390/s390.c index 0ceeef4..d2671ba 100644 --- a/gcc/config/s390/s390.c +++ b/gcc/config/s390/s390.c @@ -6396,16 +6396,16 @@ s390_expand_vec_compare (rtx target, enum rtx_code cond, /* UNLT: a u< b -> !(a >= b) */ case UNLT: cond = GE; neg_p = true; break; case UNEQ: - emit_insn (gen_vec_cmpuneqv2df (target, cmp_op1, cmp_op2)); + emit_insn (gen_vec_cmpuneq (target, cmp_op1, cmp_op2)); return; case LTGT: - emit_insn (gen_vec_cmpltgtv2df (target, cmp_op1, cmp_op2)); + emit_insn (gen_vec_cmpltgt (target, cmp_op1, cmp_op2)); return; case ORDERED: - emit_insn (gen_vec_orderedv2df (target, cmp_op1, cmp_op2)); + emit_insn (gen_vec_ordered (target, cmp_op1, cmp_op2)); return; case UNORDERED: - emit_insn (gen_vec_unorderedv2df (target, cmp_op1, cmp_op2)); + emit_insn (gen_vec_unordered (target, cmp_op1, cmp_op2)); return; default: break; } diff --git a/gcc/config/s390/vector.md b/gcc/config/s390/vector.md index 06c88c1..d40bf1e 100644 --- a/gcc/config/s390/vector.md +++ b/gcc/config/s390/vector.md @@ -1406,6 +1406,22 @@ operands[3] = gen_reg_rtx (mode); }) +(define_expand "vec_cmpuneq" + [(match_operand 0 "register_operand" "") + (match_operand 1 "register_operand" "") + (match_operand 2 "register_operand" "")] + "TARGET_VX" +{ + if (GET_MODE (operands[1]) == V4SFmode) + emit_insn (gen_vec_cmpuneqv4sf (operands[0], operands[1], operands[2])); + else if (GET_MODE (operands[1]) == V2DFmode) + emit_insn (gen_vec_cmpuneqv2df (operands[0], operands[1], operands[2])); + else + gcc_unreachable (); + + DONE; +}) + ; LTGT a <> b -> a > b | b > a (define_expand "vec_cmpltgt" [(set (match_operand: 0 "register_operand" "=v") @@ -1418,6 +1434,22 @@ operands[3] = gen_reg_rtx (mode); }) +(define_expand "vec_cmpltgt" + [(match_operand 0 "register_operand" "") + (match_operand 1 "register_operand" "") + (match_operand 2 "register_operand" "")] + "TARGET_VX" +{ + if (GET_MODE (operands[1]) == V4SFmode) + emit_insn (gen_vec_cmpltgtv4sf (operands[0], operands[1], operands[2])); + else if (GET_MODE (operands[1]) == V2DFmode) + emit_insn (gen_vec_cmpltgtv2df (operands[0], operands[1], operands[2])); + else + gcc_unreachable (); + + DONE; +}) + ; ORDERED (a, b): a >= b | b > a (define_expand "vec_ordered" [(set (match_operand: 0 "register_operand" "=v") @@ -1430,6 +1462,22 @@ operands[3] = gen_reg_rtx (mode); }) +(define_expand "vec_ordered" + [(match_operand 0 "register_operand" "") + (match_operand 1 "register_operand" "") + (match_operand 2 "register_operand" "")] + "TARGET_VX" +{ + if (GET_MODE (operands[1]) == V4SFmode) + emit_insn (gen_vec_orderedv4sf (operands[0], operands[1], operands[2])); + else if (GET_MODE (operands[1]) == V2DFmode) + emit_insn (gen_vec_orderedv2df (operands[0], operands[1], operands[2])); + else + gcc_unreachable (); + + DONE; +}) + ; UNORDERED (a, b): !ORDERED (a, b) (define_expand "vec_unordered" [(set (match_operand: 0 "register_operand" "=v") @@ -1443,6 +1491,22 @@ operands[3] = gen_reg_rtx (mode); }) +(define_expand "vec_unordered" + [(match_operand 0 "register_operand" "") + (match_operand 1 "register_operand" "") + (match_operand 2 "register_operand" "")] + "TARGET_VX" +{ + if (GET_MODE (operands[1]) == V4SFmode) + emit_insn (gen_vec_unorderedv4sf (operands[0], operands[1], operands[2])); + else if (GET_MODE (operands[1]) == V2DFmode) + emit_insn (gen_vec_unorderedv2df (operands[0], operands[1], operands[2])); + else + gcc_unreachable (); + + DONE; +}) + (define_insn "*vec_load_pair" [(set (match_operand:V_HW_64 0 "register_operand" "=v,v") (vec_concat:V_HW_64 (match_operand: 1 "register_operand" "d,v") From patchwork Tue Sep 26 10:37:51 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Krebbel X-Patchwork-Id: 818520 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=gcc.gnu.org (client-ip=209.132.180.131; helo=sourceware.org; envelope-from=gcc-patches-return-462953-incoming=patchwork.ozlabs.org@gcc.gnu.org; receiver=) Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=gcc.gnu.org header.i=@gcc.gnu.org header.b="xhfvTCxT"; dkim-atps=neutral Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3y1csS4cbYz9t6C for ; Tue, 26 Sep 2017 20:39:56 +1000 (AEST) 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:in-reply-to:references:message-id; q=dns; s= default; b=VA+Vciu80IzhV0lTjqYyw4uahpezKtwV+cSusz/xMEXqX5KIrJl6h T1j3iqZLxM9+xlPNgco7eIegdCH2DWtuwsIKHQX77lWTJG3mZ8jlXP6sQRE0qO0R Qce3bq+lqJJqkM21Sc+JgJnmznKI9v8qzLb9W3ADIJfXna/1gtu/5k= 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:in-reply-to:references:message-id; s=default; bh=eA0IaAbN0efLDlPE2ivr/WvQPuo=; b=xhfvTCxTctFpA4BhoBgtAl9233ys iYYNN2FVMAevHWCDBaM7AgaTvY25UWP+TdRaAjg5NbNa0mmtwXb00dLH9PrfCiPT ivJlp9gi9bWisEbcNQ785I9O4TTLFpmPAGixx/pwsX8m28/CSezEW8w2jsKt1vfk nitDvL0da5ncjuo= Received: (qmail 104058 invoked by alias); 26 Sep 2017 10:38:11 -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 103934 invoked by uid 89); 26 Sep 2017 10:38:11 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-24.6 required=5.0 tests=AWL, BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, KAM_LAZY_DOMAIN_SECURITY, RCVD_IN_DNSWL_LOW autolearn=ham version=3.3.2 spammy=Hx-languages-length:2316, 12017 X-HELO: mx0a-001b2d01.pphosted.com Received: from mx0a-001b2d01.pphosted.com (HELO mx0a-001b2d01.pphosted.com) (148.163.156.1) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Tue, 26 Sep 2017 10:38:10 +0000 Received: from pps.filterd (m0098410.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.0.21/8.16.0.21) with SMTP id v8QAXmtt127772 for ; Tue, 26 Sep 2017 06:38:04 -0400 Received: from e06smtp12.uk.ibm.com (e06smtp12.uk.ibm.com [195.75.94.108]) by mx0a-001b2d01.pphosted.com with ESMTP id 2d7mpajr0t-1 (version=TLSv1.2 cipher=AES256-SHA bits=256 verify=NOT) for ; Tue, 26 Sep 2017 06:38:04 -0400 Received: from localhost by e06smtp12.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Tue, 26 Sep 2017 11:38:02 +0100 Received: from b06cxnps3074.portsmouth.uk.ibm.com (9.149.109.194) by e06smtp12.uk.ibm.com (192.168.101.142) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; Tue, 26 Sep 2017 11:38:01 +0100 Received: from d06av21.portsmouth.uk.ibm.com (d06av21.portsmouth.uk.ibm.com [9.149.105.232]) by b06cxnps3074.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id v8QAc0L924772610 for ; Tue, 26 Sep 2017 10:38:00 GMT Received: from d06av21.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 162395203F for ; Tue, 26 Sep 2017 10:32:51 +0100 (BST) Received: from maggie.boeblingen.de.ibm.com (unknown [9.152.212.134]) by d06av21.portsmouth.uk.ibm.com (Postfix) with ESMTPS id EFDC252043 for ; Tue, 26 Sep 2017 10:32:50 +0100 (BST) From: Andreas Krebbel To: gcc-patches@gcc.gnu.org Subject: [PATCH 8/8] S/390: Fix vmslg instruction and builtin. Date: Tue, 26 Sep 2017 12:37:51 +0200 In-Reply-To: <20170926103751.21907-1-krebbel@linux.vnet.ibm.com> References: <20170926103751.21907-1-krebbel@linux.vnet.ibm.com> X-TM-AS-GCONF: 00 x-cbid: 17092610-0008-0000-0000-0000049A2552 X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 17092610-0009-0000-0000-00001E2B6F36 Message-Id: <20170926103751.21907-9-krebbel@linux.vnet.ibm.com> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:, , definitions=2017-09-26_03:, , signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 spamscore=0 suspectscore=1 malwarescore=0 phishscore=0 adultscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1707230000 definitions=main-1709260158 X-IsSubscribed: yes gcc/ChangeLog: 2017-09-26 Andreas Krebbel * config/s390/vx-builtins.md ("vmslg"): Add missing operand in assembler output. * config/s390/s390-builtins.def: Fix constraint on op4. --- gcc/ChangeLog | 6 ++++++ gcc/config/s390/s390-builtins.def | 2 +- gcc/config/s390/vx-builtins.md | 4 ++-- 3 files changed, 9 insertions(+), 3 deletions(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index d4f67f5..07d665c 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,5 +1,11 @@ 2017-09-26 Andreas Krebbel + * config/s390/vx-builtins.md ("vmslg"): Add missing operand in + assembler output. + * config/s390/s390-builtins.def: Fix constraint on op4. + +2017-09-26 Andreas Krebbel + * config/s390/s390.c (s390_expand_vec_compare): Use the new mode independent expanders. * config/s390/vector.md ("vec_cmpuneq", "vec_cmpltgt") diff --git a/gcc/config/s390/s390-builtins.def b/gcc/config/s390/s390-builtins.def index ddcf370..3f7bae7 100644 --- a/gcc/config/s390/s390-builtins.def +++ b/gcc/config/s390/s390-builtins.def @@ -2271,7 +2271,7 @@ OB_DEF_VAR (s390_vec_test_mask_dbl, s390_vtm, 0, B_DEF (s390_vtm, vec_test_mask_intv16qi,0, B_VX, 0, BT_FN_INT_UV16QI_UV16QI) B_DEF (s390_vec_msum_u128, vec_msumv2di, 0, B_VXE, O4_U2, BT_FN_UV16QI_UV2DI_UV2DI_UV16QI_INT) -B_DEF (s390_vmslg, vmslg, 0, B_VXE, O4_U2, BT_FN_INT128_UV2DI_UV2DI_INT128_INT) +B_DEF (s390_vmslg, vmslg, 0, B_VXE, O4_U4, BT_FN_INT128_UV2DI_UV2DI_INT128_INT) OB_DEF (s390_vec_eqv, s390_vec_eqv_b8, s390_vec_eqv_dbl_c, B_VXE, BT_FN_OV4SI_OV4SI_OV4SI) OB_DEF_VAR (s390_vec_eqv_b8, s390_vnx, 0, 0, BT_OV_BV16QI_BV16QI_BV16QI) diff --git a/gcc/config/s390/vx-builtins.md b/gcc/config/s390/vx-builtins.md index 4c157e3..7fb176c 100644 --- a/gcc/config/s390/vx-builtins.md +++ b/gcc/config/s390/vx-builtins.md @@ -1190,7 +1190,7 @@ (match_operand:QI 4 "const_mask_operand" "C")] UNSPEC_VEC_MSUM))] "TARGET_VXE" - "vmslg\t%v0,%v1,%v2,%v3" + "vmslg\t%v0,%v1,%v2,%v3,%4" [(set_attr "op_type" "VRR")]) (define_insn "vmslg" @@ -1201,7 +1201,7 @@ (match_operand:QI 4 "const_mask_operand" "C")] UNSPEC_VEC_MSUM))] "TARGET_VXE" - "vmslg\t%v0,%v1,%v2,%v3" + "vmslg\t%v0,%v1,%v2,%v3,%4" [(set_attr "op_type" "VRR")])