From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 28A5A4411C; Fri, 31 May 2024 10:49:58 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id C3EE2402C9; Fri, 31 May 2024 10:49:57 +0200 (CEST) Received: from mail-qk1-f181.google.com (mail-qk1-f181.google.com [209.85.222.181]) by mails.dpdk.org (Postfix) with ESMTP id A6862402AF for ; Fri, 31 May 2024 10:49:55 +0200 (CEST) Received: by mail-qk1-f181.google.com with SMTP id af79cd13be357-794ab181ff7so125007085a.2 for ; Fri, 31 May 2024 01:49:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bytedance.com; s=google; t=1717145395; x=1717750195; darn=dpdk.org; h=user-agent:in-reply-to:content-disposition:mime-version:references :mail-followup-to:message-id:subject:cc:to:from:date:from:to:cc :subject:date:message-id:reply-to; bh=ALqkcXWBi+9q+C3whI3qc5JCD8OHlfYKHeb+qCJExb4=; b=Qoe4DxV65FNV8Jos0w71W0nQz9PauWMJTIDTDdUmcQKzGQeqlnxaUMLrkWimF2mD0g lPZVNa/Oz4P74vDlXz14x7wxT1XVcyd3lpjjc/p+qM+JY47GtkBn/5wQuDgjNyIBh+b5 /T3LiRS/TRx+U4UcPZFxUnd5YbzAHnl+4f4JOvXPeeGt3Akucg6+9aswOzBx+EkBKmrv 4bEW3wDoUQQ2GeRYNn7gb/XJCuVkqVmKPqRAhLw30WwYV/MvfpEHCUqw3nK5CtOgRKb2 bylnSaNeFoPm4Qi7Bu1gaTYZgERHbofPIaJVWxaWJwvajpQa8l3z1chy+/jkY9E9dNbK KgsQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1717145395; x=1717750195; h=user-agent:in-reply-to:content-disposition:mime-version:references :mail-followup-to:message-id:subject:cc:to:from:date :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=ALqkcXWBi+9q+C3whI3qc5JCD8OHlfYKHeb+qCJExb4=; b=gVgnnQI/xn0aySgj7H9cWAfTVIY85zN6npyFfdGKIP00xKWz3DqutbShyKmA3jwNje ePd7I3DM563DjH1dvom65hUxAfx/hD7uEsT5DC9deEb5zmtTmcVhEgbOHkV1NRn/gYTN HY+Nxzoo5RuYtyGgOJqOr7xNuYdllMLdXA3xBgivhsqaIIkKjAoUGzSJmoGeYs32t36b df6DCnmA8RmqGAcIIi9j6F2VHx8MxjM8DS/5AbG0VTgWYZpY1HxIDwXqry3YRrDwb/oJ oPsgMkI7MjG0wzg+YFoa8c216I3tfYxDBJWVjV0CiJ2LB7mdxFNv6Jy+dFrFo+Av1+oe wpUw== X-Forwarded-Encrypted: i=1; AJvYcCWD96UHomymlAC4g0J4xjnXO+v16HaJSb/5tywrnwZ8fimP3M7Vk3t0XruTBC7oiKMd47QjWB7sBSrSDSA= X-Gm-Message-State: AOJu0YzfFWsLoIO9JqErPbfvBB8QNDDudAwP9bpsb96qaMsLtmdr7jB0 3Rz52R8/wM0W7AbS9VaN1uM6+roD2/9bFlyw5r4s720WPkC/OLZuw8l6nOAaIyc= X-Google-Smtp-Source: AGHT+IGQVV4b4X8fEreWG72Qu3zjzZ0pqfSb/kbbREU+GnuYlD1ChhLHlUw5oetIh7yLAWk1KroUTA== X-Received: by 2002:a05:620a:1597:b0:794:f105:6d94 with SMTP id af79cd13be357-794f5c5ad6emr121210285a.15.1717145394645; Fri, 31 May 2024 01:49:54 -0700 (PDT) Received: from ste-uk-lab-gw ([79.173.157.19]) by smtp.gmail.com with ESMTPSA id af79cd13be357-794f301641dsm44118485a.62.2024.05.31.01.49.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 31 May 2024 01:49:54 -0700 (PDT) Date: Fri, 31 May 2024 09:49:51 +0100 From: Daniel Gregory To: Stanislaw Kardach Cc: Bruce Richardson , Tyler Retzlaff , dev@dpdk.org, Liang Ma , Punit Agrawal Subject: Re: [PATCH 2/2] eal/riscv: add support for zicbop extension Message-ID: <20240531084951.GA4018256@ste-uk-lab-gw> Mail-Followup-To: Stanislaw Kardach , Bruce Richardson , Tyler Retzlaff , dev@dpdk.org, Liang Ma , Punit Agrawal References: <20240530171948.19763-1-daniel.gregory@bytedance.com> <20240530171948.19763-3-daniel.gregory@bytedance.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20240530171948.19763-3-daniel.gregory@bytedance.com> User-Agent: Mutt/1.10.1 (2018-07-13) X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org On Thu, May 30, 2024 at 06:19:48PM +0100, Daniel Gregory wrote: > + * The RTE_RISCV_ZICBOP option controls whether we emit them manually for older > + * compilers that may not have the support to assemble them. > + */ > static inline void rte_prefetch0(const volatile void *p) > { > - RTE_SET_USED(p); > +#ifndef RTE_RISCV_ZICBOP > + /* by default __builtin_prefetch prepares for a read */ > + __builtin_prefetch((const void *)p); This cast causes warnings (which are treated as errors by the 0-day Robot) due to it discarding the 'volatile' on p. Removing the volatile from the definition of rte_prefetch0 causes build failures in some drivers (txgbe_rxtx.c:1809, ixgbe_rxtx.c:2174, enic_rxtx.c:127, ...). rte_prefetch0_write takes its argument as 'const void *' and so can use __builtin_prefetch().