From patchwork Sat Dec 2 21:15:54 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Christoph_M=C3=BCllner?= X-Patchwork-Id: 81208 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 014A03858D33 for ; Sat, 2 Dec 2023 21:16:22 +0000 (GMT) X-Original-To: gcc-patches@gcc.gnu.org Delivered-To: gcc-patches@gcc.gnu.org Received: from mail-lf1-x12b.google.com (mail-lf1-x12b.google.com [IPv6:2a00:1450:4864:20::12b]) by sourceware.org (Postfix) with ESMTPS id 098DD3858D33 for ; Sat, 2 Dec 2023 21:16:02 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 098DD3858D33 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=vrull.eu Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=vrull.eu ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 098DD3858D33 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2a00:1450:4864:20::12b ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1701551766; cv=none; b=AizDrCOFHizwt4Jrg1JxpslBKrQMv757U8qsew4jRkyxYpUF8DnMpcz1wY6ieyNWLxJTSnqrvUbb+VwvtN2lWwHBbA+dUClxs+SyMRq65m939zqjA1ZnFubKoFQk4Itk1RWiKcktWsMsY2dTpvhTg+OAAxJRlAvUm2IPscGpjS0= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1701551766; c=relaxed/simple; bh=z8mrTFIJtYHP5I3PWNYpztzAArpSTdCNEdPb/SRwba0=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=db7ndoSl4fXPKQuO1ZJwUGb7dVgB7XCNzUlforqPRib/Vaq5uKX3aNzT+UMoXzykRB/ErRlhT7vD5plkIh8AMpI9IxJN+ghEH4/6bLLHwDqBBCZGTOxcOowsZJznhjTe5EtIDDQwU/GXr6ek+x6+nxlq7rIPdN/Gund/H/E+qWo= ARC-Authentication-Results: i=1; server2.sourceware.org Received: by mail-lf1-x12b.google.com with SMTP id 2adb3069b0e04-50abbb23122so4572391e87.3 for ; Sat, 02 Dec 2023 13:16:01 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=vrull.eu; s=google; t=1701551760; x=1702156560; darn=gcc.gnu.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=/WWe5gc6rkNGzTBjsubk1NlNLe1eyqiPesW4T3RIb6U=; b=Us8mVX/YkZflWGBQpgjln4Jk7EQtmOW36ky2EDU6khxhZyaNLmHLZddFoO66WU5XJF G4pC/r6uQwxNWEysH5erVcWYXlBmR43OGxtGWsPNWceI2AoGbdm2LidVFp/oE5ItF2XJ bTA1ncB9u4BP6DTG/fbc5JUN/gpFkqJd6opbrHiyYc1YJDQoUtO4NpfTkz2jF5W39AsJ A9h3tqxcpaNdYAdIYYrtaDx64dGaq4MCHQCDZqaw7aIyuxrAqlzZTm2lYZVARWI93OBz CUFAq9HcxBfq9jz7gAE29BiTf3IkELbt//2pkOVvzRFczYLKdhrj01GtMd/hGCRovAUS XVkQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1701551760; x=1702156560; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=/WWe5gc6rkNGzTBjsubk1NlNLe1eyqiPesW4T3RIb6U=; b=SZgwqIOQeLBLHPVrvSKdoEw/x1IappYvWXU53pHoEa64G/4svQiGONyleGwRbQXg6p Tur5BKZWuBcHBSAgX8wmzNI9gilivzNbNGjIzM3/z6xqaq+inmfnJ406ScbJqmd6Xq7V 70IDy/fxw/IRmcI3zaD+a1VqlLWdFlN651MapAHVmE1MjjGvPnR4nJW21DYwSN1f1eZ6 O3oKHk6gzsPEpI1kphCC0LUncUiVfQBRQDBT7iaa+0pKaxEXO/Fhs19AlhwUUD6szi3x urcMv2nTYWX7zz4/QDPSJ+StHuCEr3ZhEGVf3quART9dJ8tERfY8gN68CGsw91TZHz7U 5z4Q== X-Gm-Message-State: AOJu0Yw+Z71Wau/6yaIVP1oR0pMOVIlN7sIKVznpUfgVhXgMqlAydBoH Wn8r2IcuQpHQ2a50CmteCEcQ9ZOx7iTvZtjDZKNO9w== X-Google-Smtp-Source: AGHT+IGj+qKSQ/uZPfPdeYP14Znjxp0Ugdqob3kxccnn3IC0ti0k/Chg13IfJJpMsQrBIrHDa2Upzw== X-Received: by 2002:a19:c514:0:b0:50b:f15d:1eac with SMTP id w20-20020a19c514000000b0050bf15d1eacmr80878lfe.4.1701551758801; Sat, 02 Dec 2023 13:15:58 -0800 (PST) Received: from beast.fritz.box (62-178-148-172.cable.dynamic.surfer.at. [62.178.148.172]) by smtp.gmail.com with ESMTPSA id cf5-20020a0564020b8500b0054c4db03b9dsm2164469edb.30.2023.12.02.13.15.57 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 02 Dec 2023 13:15:57 -0800 (PST) From: =?utf-8?q?Christoph_M=C3=BCllner?= To: gcc-patches@gcc.gnu.org, Kito Cheng , Jim Wilson , Palmer Dabbelt , Andrew Waterman , Philipp Tomsich , Jeff Law , Jeremy Bennett Cc: =?utf-8?q?Christoph_M=C3=BCllner?= Subject: [PATCH] RISC-V: Document optimization parameter riscv-strcmp-inline-limit Date: Sat, 2 Dec 2023 22:15:54 +0100 Message-ID: <20231202211554.2319770-1-christoph.muellner@vrull.eu> X-Mailer: git-send-email 2.41.0 MIME-Version: 1.0 X-Spam-Status: No, score=-12.8 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, KAM_MANYTO, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: gcc-patches@gcc.gnu.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Gcc-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: gcc-patches-bounces+patchwork=sourceware.org@gcc.gnu.org This patch documents the optimization parameter riscv-strcmp-inline-limit, which can be used to tweak the behaviour of -minline-strcmp and -minline-strncmp. gcc/ChangeLog: PR target/112650 * doc/invoke.texi: Document riscv-strcmp-inline-limit. Signed-off-by: Christoph Müllner --- gcc/doc/invoke.texi | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/gcc/doc/invoke.texi b/gcc/doc/invoke.texi index 2fab4c5d71f..ba2d843b484 100644 --- a/gcc/doc/invoke.texi +++ b/gcc/doc/invoke.texi @@ -29846,6 +29846,10 @@ Inlining will only be done if the strings are properly aligned and instructions for accelerated processing are available. The default is to not inline strcmp calls. +The @option{--param riscv-strcmp-inline-limit=@{n}} parameter controls +the maximum number of bytes compared by the inlined code. +The default value is 64. + @opindex minline-strncmp @item -minline-strncmp @itemx -mno-inline-strncmp @@ -29854,6 +29858,10 @@ Inlining will only be done if the strings are properly aligned and instructions for accelerated processing are available. The default is to not inline strncmp calls. +The @option{--param riscv-strcmp-inline-limit=@{n}} parameter controls +the maximum number of bytes compared by the inlined code. +The default value is 64. + @opindex mshorten-memrefs @item -mshorten-memrefs @itemx -mno-shorten-memrefs