From patchwork Wed Feb 26 14:03:31 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 868530 Delivered-To: patch@linaro.org Received: by 2002:a5d:5f56:0:b0:38f:210b:807b with SMTP id cm22csp820037wrb; Wed, 26 Feb 2025 06:11:22 -0800 (PST) X-Forwarded-Encrypted: i=2; AJvYcCX1tCFShd0KSI0BzfE+Vsp7xKzhb72zjWs7QrD0k34aaffRrkaZWFxHQPQVsoH/16t+Dic11A==@linaro.org X-Google-Smtp-Source: AGHT+IGIfKuQ///PoCZqe6yY6b5PjGaWd0Rgvwws/Gu+WFUVjRNzEbTa/y4M6cyqLv1037hmFTqU X-Received: by 2002:ac8:7dc2:0:b0:471:f730:20c0 with SMTP id d75a77b69052e-4722473d00bmr277902011cf.20.1740579082473; Wed, 26 Feb 2025 06:11:22 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1740579082; cv=none; d=google.com; s=arc-20240605; b=CaPqFRrcNUZT2WefIKJ9x9w8N9rAgTHDU/KgcSQken471djph2uIYfcc+JF4mhFK+A 3vvebo59M9GIEKRylwOQlx/ng2P7faycgx71y5MPl6mQtZI1oW830rVIS5kM5SLIzlJ6 8deHjBQrifa/n+7d9sjQZU5blrUoul8yHKYY/iVmFN4EV9R1D09taixp/qLEbEzVPv5Q pDPDgY1mv/wmNfAfxwtSGUpwz3qHXpe+LQmcAMKqAW07Gin8g2YK4eO4DK+vc8Q9G+4M uLRqtUjdNKMBznbKC7TFGSNpVDTdHZomqtYkSmTW8gE7W3p2skKhY23S+QGXeImJMwFR XRmQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=ThH5BQgbHAmOS+UQy2wCG4a6AKm/DC+QNI57Vzuv2mA=; fh=fySNGfDYHed5hYuWeyYWBmz9AHLCfB1G33J0dTYFdV4=; b=LyNigtxHGiDNOLi2ztWXpJ+hxJkq48tfNocMeFWHtR/O1XSdwZylqG+6Glx/jn5rnW OnPX/xghe6D5WDESIMG2JTPRiPd5chuqi2ZzpVbNtxBEdnusxjbvZTBpkoO03fNk9QG+ KELQNCThvTqsgFFtqaPMy6dAPAMceSpWN65LvRUBWYxU2mlNiPXhyNbEnj5zsirkNgSQ PHithxSC6W0tWmSYa7OGMVvpxMLbFYCqeFSkO/vMCTlvMUq4zUV2SAhOw8v25eIz7Mir cHfM0pfxJtARvnsldE0ovnH1PgGcmPIzRgVLDOkVHHHleDVtWSnu17EepV9jUPGGtgxw 7zgg==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=vcn7x9R7; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org; dara=neutral header.i=@linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id d75a77b69052e-473780952dfsi36042911cf.356.2025.02.26.06.11.22 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 26 Feb 2025 06:11:22 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=vcn7x9R7; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org; dara=neutral header.i=@linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tnI1e-0001Xp-UM; Wed, 26 Feb 2025 09:04:38 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tnI12-00016v-PD for qemu-devel@nongnu.org; Wed, 26 Feb 2025 09:04:01 -0500 Received: from mail-wm1-x329.google.com ([2a00:1450:4864:20::329]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1tnI10-0005jv-68 for qemu-devel@nongnu.org; Wed, 26 Feb 2025 09:04:00 -0500 Received: by mail-wm1-x329.google.com with SMTP id 5b1f17b1804b1-4398c8c8b2cso69757115e9.2 for ; Wed, 26 Feb 2025 06:03:57 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1740578637; x=1741183437; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=ThH5BQgbHAmOS+UQy2wCG4a6AKm/DC+QNI57Vzuv2mA=; b=vcn7x9R7CFOC1/nGW0tBaRzt5Ic16agommM6MpU4orZ38uJkXhfWGFm1u7yl7vL+d8 M6nh7mddfG+s+UGEMTqO9qBQhlRmH7VPodkPOoY9mejBX0hAe5e0f8okor9TaeU10/8f i5ElWUPxZcvj02zKbLq6J2PlUNtUodyIoosfyfmy9HQnfEiu4IubkAyQm3kaGNklzdlb zC0+stQCcCey8QXn8RwzbxdJH4+Qf/ntqyiDZLKBI/Kn5zmk3t3JhzuG+OouB1pgqyqQ yGHDdh4nQ2wR0I5qrpsFv5YEXwvzT1ZPEapzxLfB/W6YOTA5DeWkwACCrUlMnw8FEYCb z78w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1740578637; x=1741183437; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=ThH5BQgbHAmOS+UQy2wCG4a6AKm/DC+QNI57Vzuv2mA=; b=bOlZW8VM2iqh1obBlbG3obQ9OSzp2R30UQKgmIt1vZPfMY/Dgpk+sR2HopJtgBUFDk HhCIjMx23ldJAIrhl2feuPTlkJHocoGMIC3W4DJ6WlPf8AUsyI0fS6QY458Y5ltPFn4N GNC1WDJsUqsmetBHHjsLpzP73ZpvQc4aNv0Q2xtzP032wACrnxpL35EA0vAwm7I3DTCY 3X/OKzSIMzEdV/cmpcM0esGrSXsmu2K2LnyKGmwm+5BHjb09o1gbO6F7KNCVfAuKIMbH nI+0W66Lxusy08gn24qlx5snWzHR/UvXDpEI4fF3VOvu1zaKtSguAwDgmmdsHKrvhC3W n11A== X-Gm-Message-State: AOJu0Yy3iPdKvIgDgFGTMkBoKfdxzAQE+bzoz2hxbs973qG4WjK6UiT+ PV4YLfjAtxicnrPTTO9sqbxmNbUnq1wD9HrQUNtE/h7M2zOkTr7567XodRzF+r0= X-Gm-Gg: ASbGnctT9YFrns4mfl12CfDESXI8bchv3yea9g/V4jrS4qRQv93jRuFscdsoxfL62GW ShSrhHqr7I8CJW2JjRmGj0q7xfe2L7l1duK/m2xYDKfNtbcEbmX1WaJXhNkLa2hC+94ZZ+EETh3 m2xVWcQSGuAQHn2GiQJhrHgCT4XL25I/VuHSPSm6KQRVZMyxj2olMNncSzYflhAnng1KBmoFlX6 Ptoug8rzl5rNd5g4c8pi571pBdTsk2b6B6uvp2/eEcsArH6u7BNT9B8wzec+wAz80KAAtAZLw01 pjdPwXaZ2zNmeKmGB/dD6GM8Ox4g X-Received: by 2002:a05:600c:3d19:b0:43a:b186:8abc with SMTP id 5b1f17b1804b1-43ab1868ac3mr73031805e9.2.1740578636516; Wed, 26 Feb 2025 06:03:56 -0800 (PST) Received: from draig.lan ([185.126.160.109]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-43aba57145esm22493425e9.30.2025.02.26.06.03.48 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 26 Feb 2025 06:03:52 -0800 (PST) Received: from draig.lan (localhost [IPv6:::1]) by draig.lan (Postfix) with ESMTP id 38416603F4; Wed, 26 Feb 2025 14:03:45 +0000 (GMT) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Cc: qemu-arm@nongnu.org, =?utf-8?q?Daniel_P=2E_Berrang=C3=A9?= , Peter Maydell , Kyle Evans , Eduardo Habkost , Alexandre Iooss , =?utf-8?q?Marc-Andr=C3=A9_Lureau?= , Laurent Vivier , Mahmoud Mandour , Paolo Bonzini , Li-Wen Hsu , Riku Voipio , =?utf-8?q?Alex_Benn=C3=A9e?= , Warner Losh , Pierrick Bouvier , =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= , Richard Henderson , Ed Maste , Thomas Huth Subject: [PATCH 13/25] tests/tcg: fix constraints in test-i386-adcox Date: Wed, 26 Feb 2025 14:03:31 +0000 Message-Id: <20250226140343.3907080-14-alex.bennee@linaro.org> X-Mailer: git-send-email 2.39.5 In-Reply-To: <20250226140343.3907080-1-alex.bennee@linaro.org> References: <20250226140343.3907080-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::329; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x329.google.com X-Spam_score_int: 12 X-Spam_score: 1.2 X-Spam_bar: + X-Spam_report: (1.2 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_SBL_CSS=3.335, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=no autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Clang complains: clang -O2 -m64 -mcx16 /home/alex/lsrc/qemu.git/tests/tcg/i386/test-i386-adcox.c -o test-i386-adcox -static /home/alex/lsrc/qemu.git/tests/tcg/i386/test-i386-adcox.c:32:26: error: invalid input constraint '0' in asm : "r" ((REG)-1), "0" (flags), "1" (out_adcx), "2" (out_adox)); ^ /home/alex/lsrc/qemu.git/tests/tcg/i386/test-i386-adcox.c:57:26: error: invalid input constraint '0' in asm : "r" ((REG)-1), "0" (flags), "1" (out_adcx), "2" (out_adox)); ^ 2 errors generated. Pointing out a numbered input constraint can't point to a read/write output [1]. Convert to a read-only input constraint to allow this. [1] https://lists.llvm.org/pipermail/cfe-commits/Week-of-Mon-20101101/036036.html Signed-off-by: Alex Bennée Suggested-by: Daniel P. Berrangé --- tests/tcg/i386/test-i386-adcox.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/tcg/i386/test-i386-adcox.c b/tests/tcg/i386/test-i386-adcox.c index 16169efff8..b56dbc00f2 100644 --- a/tests/tcg/i386/test-i386-adcox.c +++ b/tests/tcg/i386/test-i386-adcox.c @@ -28,7 +28,7 @@ void test_adox_adcx(uint32_t in_c, uint32_t in_o, REG adcx_operand, REG adox_ope "adox %3, %2;" "adcx %3, %1;" "pushf; pop %0" - : "+r" (flags), "+r" (out_adcx), "+r" (out_adox) + : "=r"(flags), "=r"(out_adcx), "=r"(out_adox) : "r" ((REG)-1), "0" (flags), "1" (out_adcx), "2" (out_adox)); assert(out_adcx == in_c + adcx_operand - 1); @@ -53,7 +53,7 @@ void test_adcx_adox(uint32_t in_c, uint32_t in_o, REG adcx_operand, REG adox_ope "adcx %3, %1;" "adox %3, %2;" "pushf; pop %0" - : "+r" (flags), "+r" (out_adcx), "+r" (out_adox) + : "=r"(flags), "=r"(out_adcx), "=r"(out_adox) : "r" ((REG)-1), "0" (flags), "1" (out_adcx), "2" (out_adox)); assert(out_adcx == in_c + adcx_operand - 1);