From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wm1-x335.google.com (mail-wm1-x335.google.com [IPv6:2a00:1450:4864:20::335]) by sourceware.org (Postfix) with ESMTPS id 7D292385D0EE for ; Fri, 28 Oct 2022 08:35:06 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 7D292385D0EE Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=adacore.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=adacore.com Received: by mail-wm1-x335.google.com with SMTP id n14so2567826wmq.3 for ; Fri, 28 Oct 2022 01:35:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=adacore.com; s=google; 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=kfEcU/X3UG7kmYEj8r1/bClEjpLu57he5d0VjktYGhQ=; b=iIo328tjbYTAAYkVnY8cE5p4yOPQMUGrqgO6OmlD4PC0WbJZ9PuuSbBpaAC8AbYBsJ Zy08QKgWl/XHYh0eN3gOmZX7i5gOj0J8D+BfLu4MOxCBe+FhxmYdGvNzdTRh4jdjSS/w MSoj+VSfbcKh7PKyd+bwOKpK/1/eguYywZFN42wyhOBAV58obv9XLVLmfBlKSiWYXjgP jRRP7TqK6iEQrt51g+Su49rd1wCEKmWhctHOecrWDyYs1gCT58UpazXDA+dgTuDz2r/z d/iHY8sMa6Le3SDJTzIJuSuTNz1Sb1aMDqes+iBGPYZQQ+wZ79OSu0ekokOhbpaccGBG xFog== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; 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=kfEcU/X3UG7kmYEj8r1/bClEjpLu57he5d0VjktYGhQ=; b=MrVJhFkiv+q+/1uXPx8qm8sODaapFcNR21gozn9QfJZmie6+6Sc0mSR00tt9px6z8B ndYVoJ7806jCLas0vkyovIAGBWD8SkbYaKaU8xEUkopn3MzVCJi+GocIjLQ1iFvrn7DW eEx9Kb5IW1spORS3xvWGkRoZCHiBPDXpJ/oi51kNA3ts+DE1s8kFgcQsHCRfndZP/N+V xDrP07eJ/PlhYj6pSfVPygWh2/S/9IZ5SCXs9f3O/TUjP4BqOibJ4GwB/EHhz8Il2s3K EDUpqyV5l2oGffYvpxyBdkTmMD6JHUESoyOV0jMvhVe9qnajLNr5pWhVcEXDa5t++JoE k6wg== X-Gm-Message-State: ACrzQf3cdnm959jNiu8ey/XsutWkQwY3UVRMniULlyUlKc/DCt1MJkxz x1TXtXYCkqvMWePgvMgzuHqRcg== X-Google-Smtp-Source: AMsMyM4O7zxEqLPFMD/MrXAH9GvLAoTc5mMxmvHh0GMzSnL+5+VBFKTMhHHyGtn/aoioEaBb9d/mAQ== X-Received: by 2002:a05:6000:184c:b0:22f:edd8:821f with SMTP id c12-20020a056000184c00b0022fedd8821fmr33140104wri.363.1666946105242; Fri, 28 Oct 2022 01:35:05 -0700 (PDT) Received: from fomalhaut.localnet ([2a01:e0a:8d5:d990:e654:e8ff:fe8f:2ce6]) by smtp.gmail.com with ESMTPSA id v16-20020a5d43d0000000b00236733f0f98sm3007522wrr.107.2022.10.28.01.35.04 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 28 Oct 2022 01:35:04 -0700 (PDT) From: Eric Botcazou X-Google-Original-From: Eric Botcazou To: "H.J. Lu" Cc: gcc-patches@gcc.gnu.org, Uros Bizjak Subject: Re: [PATCH] x86: Replace ne:CCC/ne:CCO with UNSPEC_CC_NE in neg patterns Date: Fri, 28 Oct 2022 10:35:03 +0200 Message-ID: <4752529.GXAFRqVoOG@fomalhaut> In-Reply-To: <20221026185857.234023-1-hjl.tools@gmail.com> References: <20221026185857.234023-1-hjl.tools@gmail.com> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" X-Spam-Status: No, score=-4.9 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: > (set (reg:SI 93) > (neg:SI (ltu:SI (reg:CCC 17 flags) (const_int 0 [0])))) > > as > > (set (reg:SI 93) > (neg:SI (ltu:SI (const_int 1) (const_int 0 [0])))) > > which leads to incorrect results since LTU on MODE_CC register isn't the > same as "unsigned less than" in x86 backend. That's not specific to the x86 back-end, i.e. it's a generic caveat. > PR target/107172 > * config/i386/i386.md (UNSPEC_CC_NE): New. > Replace ne:CCC/ne:CCO with UNSPEC_CC_NE in neg patterns. FWIW the SPARC back-end uses a COMPARE instead of an UNSPEC here. -- Eric Botcazou