Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id A29ADEC1449 for ; Tue, 3 Mar 2026 13:47:26 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 4DAEE10E81F; Tue, 3 Mar 2026 13:47:26 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.b="n3G999NC"; dkim-atps=neutral Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.13]) by gabe.freedesktop.org (Postfix) with ESMTPS id 2D54110E81F for ; Tue, 3 Mar 2026 13:47:25 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1772545645; x=1804081645; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=gqWeivFkI0WzohERaG35+EZO39Upa7g2BXPUNH63bTg=; b=n3G999NCg83izgxWx26I0Aiu2/X8Sqt//wkgSoMEZnzuXoiB4OLxaR3N pImX/gzOrCoib9J6aMMY46ttFq7TGGAFI0VeWkMbWZmr5lhZxNMo3TcTy 0+fnDplOZGE+zskzv48+deS8gn228ANhwDq9tkzbLqwnBP0rdbJXnhFhI DSvdzS/Yt5wHtijO1v+SzyoO8m5EjlOGuynAuqF+RPJzK1GX5vB5QN/o/ O3mmMdOB/Xh9+nc8lU74FwpwELK/RhCsZmNL3xoNYRksKy/5S5hb+pBS5 2PzQp4yN/PARLKeUb6fUZkIAVo4jFyrz6iCAXbbs9t/5vCS7CcjwG5TKS w==; X-CSE-ConnectionGUID: +ADiIrveR8aySyEmPbG2Kg== X-CSE-MsgGUID: 2PeMiI44SNK6hLdWj136vg== X-IronPort-AV: E=McAfee;i="6800,10657,11718"; a="76180670" X-IronPort-AV: E=Sophos;i="6.21,322,1763452800"; d="scan'208";a="76180670" Received: from orviesa001.jf.intel.com ([10.64.159.141]) by fmvoesa107.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 03 Mar 2026 05:47:25 -0800 X-CSE-ConnectionGUID: LwjMbGZzSl+q/P9Wt/u18w== X-CSE-MsgGUID: kRbSke03RmGIn8ZuV5UF7A== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.21,322,1763452800"; d="scan'208";a="255877780" Received: from pgcooper-mobl3.ger.corp.intel.com (HELO localhost) ([10.245.245.58]) by smtpauth.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 03 Mar 2026 05:47:24 -0800 From: =?UTF-8?q?Zbigniew=20Kempczy=C5=84ski?= To: igt-dev@lists.freedesktop.org Cc: =?UTF-8?q?Zbigniew=20Kempczy=C5=84ski?= , Nishit Sharma Subject: [PATCH i-g-t v4 3/5] lib/intel_compute: Use user offsets and loop size if provided Date: Tue, 3 Mar 2026 14:47:10 +0100 Message-ID: <20260303134706.41948-10-zbigniew.kempczynski@intel.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20260303134706.41948-7-zbigniew.kempczynski@intel.com> References: <20260303134706.41948-7-zbigniew.kempczynski@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: igt-dev@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Development mailing list for IGT GPU Tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: igt-dev-bounces@lists.freedesktop.org Sender: "igt-dev" If user passes its own input/output or number of iterations start to use it instead of hardcoded ones. This pattern was already used in other pipelines and only Xe3p missed this. Signed-off-by: Zbigniew KempczyƄski Cc: Nishit Sharma --- lib/intel_compute.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/lib/intel_compute.c b/lib/intel_compute.c index 1165bdafd9..bfe0a75a7c 100644 --- a/lib/intel_compute.c +++ b/lib/intel_compute.c @@ -2189,6 +2189,8 @@ static void xe3p_compute_exec(int fd, const unsigned char *kernel, struct inline_data idata = {}; struct bo_execenv execenv; float *input_data, *output_data; + uint64_t bind_input_addr = (user && user->input_addr) ? user->input_addr : ADDR_INPUT; + uint64_t bind_output_addr = (user && user->output_addr) ? user->output_addr : ADDR_OUTPUT; uint64_t indirect_addr = ADDR_GENERAL_STATE_BASE + OFFSET_INDIRECT_DATA_START; int entries = ARRAY_SIZE(bo_dict); int64_t timeout_one_ns = 1; @@ -2205,7 +2207,7 @@ static void xe3p_compute_exec(int fd, const unsigned char *kernel, memcpy(bo_dict[0].data, kernel, size); memset(bo_dict[1].data, 0, 4096); - xe3p_create_indirect_data(bo_dict[1].data, ADDR_INPUT, ADDR_OUTPUT, + xe3p_create_indirect_data(bo_dict[1].data, bind_input_addr, bind_output_addr, execenv.loop_count); idata.xe3p.indirect_addr_lo = indirect_addr; idata.xe3p.indirect_addr_hi = indirect_addr >> 32; @@ -2233,7 +2235,7 @@ static void xe3p_compute_exec(int fd, const unsigned char *kernel, } if (!user || (user && !user->skip_results_check)) - bo_check_square(input_data, output_data, execenv.array_size); + bo_check_square(input_data, output_data, execenv.loop_count); bo_execenv_unbind(&execenv, bo_dict, entries); bo_execenv_destroy(&execenv); -- 2.43.0