From patchwork Fri Nov 8 10:54:02 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 1191809 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=gcc.gnu.org (client-ip=209.132.180.131; helo=sourceware.org; envelope-from=gcc-patches-return-512801-incoming=patchwork.ozlabs.org@gcc.gnu.org; receiver=) Authentication-Results: ozlabs.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=gcc.gnu.org header.i=@gcc.gnu.org header.b="lQMK71XI"; dkim=pass (2048-bit key; unprotected) header.d=linaro.org header.i=@linaro.org header.b="ZCyee8V9"; 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 478cbc5DgYz9sNT for ; Fri, 8 Nov 2019 21:54:34 +1100 (AEDT) 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:cc:subject:date:message-id; q=dns; s=default; b=lL2STcRWxPgQ /shiBg/QX4wvl8NglK++AsYcqJHbd/vlORQ7SFN64ZS6yg45nAbJ+Ssx958SJMtq 4xbMM3lvuFlxu0O0b4qyx+kWz16k1fKl2UuclcLVR59TMOOX5r+RErjqVjr+9V3l ApwHMzzJlxxicC0LxtqnXCIDAEY+N9c= 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:cc:subject:date:message-id; s=default; bh=IYGCOJEGlsx22YyWoH qgvqFuWoY=; b=lQMK71XIC3kRC9nqHSpLGKa2V8JAMf6Ew1WWeHbJGDOe5bxnKQ 1h4wWM+p0wP0YlmqvFWG5gbaAarfYDPWBL8JyVcf8dp16KtohlXcdD2CYLZWJbPi d7I8nXxApL5YNDGbmwweNT9kVZnLCusyVAq3G31cpQ2fsIKsw7+uVqiis= Received: (qmail 105484 invoked by alias); 8 Nov 2019 10:54:26 -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 105446 invoked by uid 89); 8 Nov 2019 10:54:25 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-11.4 required=5.0 tests=BAYES_00, GIT_PATCH_2, GIT_PATCH_3, KAM_NUMSUBJECT, RCVD_IN_DNSWL_NONE, SPF_PASS autolearn=ham version=3.3.1 spammy=HX-Languages-Length:2179 X-HELO: mail-wr1-f67.google.com Received: from mail-wr1-f67.google.com (HELO mail-wr1-f67.google.com) (209.85.221.67) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Fri, 08 Nov 2019 10:54:24 +0000 Received: by mail-wr1-f67.google.com with SMTP id b3so6459612wrs.13 for ; Fri, 08 Nov 2019 02:54:23 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id; bh=qHeO6ib4z4P0sW9PCUphh7Cl0XhE3F2lkx4ITvDji+M=; b=ZCyee8V9LrN36uo7/D/QlspTrqZNQ++nwluf8nQ/IWfdbMlNS2M0+Mji4CamGKRyNe HZoLMvKuYRQZOAYYMWLt3ezgV4HlmP9PnSy8JMHpNEkckuFcguJ56cTr0z2/+dMJU/19 gkvdt6AAAqvWAfqaK8VfUBdQ/6kyViB8Wm1ubd3N1QtGFYOEJ1HFy2Vjgkc4FMbAAMwm ryTXk0DOTv3dmjjLoQbvufPF+mMVAduwMkFPI/9316fZSk45zFRTZhTq2R80ES72M2Gq fjtCZ/tAIfHUxqDFR2rqkKSWqEcFqHd3GzQUqGpjsRhwce7yXE9XMoYEBt244nMV56xE MeuQ== Received: from localhost.localdomain (212.red-213-99-162.dynamicip.rima-tde.net. [213.99.162.212]) by smtp.gmail.com with ESMTPSA id 19sm8046565wrc.47.2019.11.08.02.54.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 08 Nov 2019 02:54:21 -0800 (PST) From: Richard Henderson To: gcc-patches@gcc.gnu.org Cc: richard.earnshaw@arm.com, james.greenhalgh@arm.com, richard.sandiford@arm.com, marcus.shawcroft@arm.com, kyrylo.tkachov@arm.com Subject: [PATCH 0/6] Implement asm flag outputs for arm + aarch64 Date: Fri, 8 Nov 2019 11:54:02 +0100 Message-Id: <20191108105408.27584-1-richard.henderson@linaro.org> I've put the implementation into config/arm/aarch-common.c, so that it can be shared between the two targets. This required a little bit of cleanup to the CC modes and constraints to get the two targets to match up. I really should have done more than just x86 years ago, so that it would be done now and I could just use it in the kernel... ;-) r~ Richard Henderson (6): aarch64: Add "c" constraint arm: Fix the "c" constraint arm: Rename CC_NOOVmode to CC_NZmode arm, aarch64: Add support for __GCC_ASM_FLAG_OUTPUTS__ arm: Add testsuite checks for asm-flag aarch64: Add testsuite checks for asm-flag gcc/config/arm/aarch-common-protos.h | 6 + gcc/config/aarch64/aarch64-c.c | 2 + gcc/config/aarch64/aarch64.c | 3 + gcc/config/arm/aarch-common.c | 131 ++++++++++++ gcc/config/arm/arm-c.c | 1 + gcc/config/arm/arm.c | 15 +- gcc/testsuite/gcc.target/aarch64/asm-flag-1.c | 34 ++++ gcc/testsuite/gcc.target/aarch64/asm-flag-3.c | 36 ++++ gcc/testsuite/gcc.target/aarch64/asm-flag-5.c | 30 +++ gcc/testsuite/gcc.target/aarch64/asm-flag-6.c | 43 ++++ gcc/testsuite/gcc.target/arm/asm-flag-1.c | 35 ++++ gcc/testsuite/gcc.target/arm/asm-flag-3.c | 36 ++++ gcc/testsuite/gcc.target/arm/asm-flag-5.c | 30 +++ gcc/testsuite/gcc.target/arm/asm-flag-6.c | 43 ++++ gcc/config/aarch64/constraints.md | 4 + gcc/config/arm/arm-modes.def | 4 +- gcc/config/arm/arm.md | 186 +++++++++--------- gcc/config/arm/constraints.md | 5 +- gcc/config/arm/predicates.md | 2 +- gcc/config/arm/thumb1.md | 8 +- gcc/config/arm/thumb2.md | 34 ++-- gcc/doc/extend.texi | 33 ++++ 22 files changed, 596 insertions(+), 125 deletions(-) create mode 100644 gcc/testsuite/gcc.target/aarch64/asm-flag-1.c create mode 100644 gcc/testsuite/gcc.target/aarch64/asm-flag-3.c create mode 100644 gcc/testsuite/gcc.target/aarch64/asm-flag-5.c create mode 100644 gcc/testsuite/gcc.target/aarch64/asm-flag-6.c create mode 100644 gcc/testsuite/gcc.target/arm/asm-flag-1.c create mode 100644 gcc/testsuite/gcc.target/arm/asm-flag-3.c create mode 100644 gcc/testsuite/gcc.target/arm/asm-flag-5.c create mode 100644 gcc/testsuite/gcc.target/arm/asm-flag-6.c