From mboxrd@z Thu Jan 1 00:00:00 1970 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 A1738C001DB for ; Tue, 8 Aug 2023 02:41:29 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 6A26610E1BE; Tue, 8 Aug 2023 02:41:29 +0000 (UTC) Received: from mgamail.intel.com (mgamail.intel.com [192.55.52.136]) by gabe.freedesktop.org (Postfix) with ESMTPS id 3990C10E1BE for ; Tue, 8 Aug 2023 02:41:28 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1691462488; x=1722998488; h=date:message-id:from:to:cc:subject:in-reply-to: references:mime-version; bh=ubtlZ9VnxVqWN/kilkMynUW0zWPCbuaAHQ8hCzIstFs=; b=BJCBSST0Lvj+hJH/ZY8gQjoYYd98BEJDjFJ7NA3qsackUwMzu0d7MCdW h/gVR50cWLWCb/XJhDmulNsNj8AcJxqYyb3qS/j61xN5nDNPDVmGlQlk7 3HGMtXdI/jwfxzEtaX4yVGbZNUGG+MwF0bE5S20wJazNWVf7OtTgubBJI GWVYzy/SX1zyhgR8isi6HCiPf0AeMb8lPVoRhEwWudSDzJtzF5DjP++qr lyjZG7R6J8rF0L1vgRoA8weOJRoWUgvZ/9aiKHRgroKe5Yz2XvomZRbxu Y0hOlvtRCPMITaTM47eYSFwD2u4XyVH/6iGmtSJMkX5/NkA4k6aqsoczc w==; X-IronPort-AV: E=McAfee;i="6600,9927,10795"; a="350293261" X-IronPort-AV: E=Sophos;i="6.01,263,1684825200"; d="scan'208";a="350293261" Received: from fmsmga008.fm.intel.com ([10.253.24.58]) by fmsmga106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 07 Aug 2023 19:41:27 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10795"; a="796558805" X-IronPort-AV: E=Sophos;i="6.01,263,1684825200"; d="scan'208";a="796558805" Received: from adixit-mobl.amr.corp.intel.com (HELO adixit-arch.intel.com) ([10.251.14.200]) by fmsmga008-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 07 Aug 2023 19:41:27 -0700 Date: Mon, 07 Aug 2023 19:41:04 -0700 Message-ID: <87jzu6xnlr.wl-ashutosh.dixit@intel.com> From: "Dixit, Ashutosh" To: intel-xe@lists.freedesktop.org In-Reply-To: <20230808013159.38811-1-ashutosh.dixit@intel.com> References: <20230808013159.38811-1-ashutosh.dixit@intel.com> User-Agent: Wanderlust/2.15.9 (Almost Unreal) SEMI-EPG/1.14.7 (Harue) FLIM-LB/1.14.9 (=?ISO-8859-4?Q?Goj=F2?=) APEL-LB/10.8 EasyPG/1.0.0 Emacs/29.1 (x86_64-pc-linux-gnu) MULE/6.0 (HANACHIRUSATO) MIME-Version: 1.0 (generated by SEMI-EPG 1.14.7 - "Harue") Content-Type: text/plain; charset=US-ASCII Subject: Re: [Intel-xe] [PATCH 00/10] Add OA functionality to Xe X-BeenThere: intel-xe@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Intel Xe graphics driver List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Robert Krzemien , Lionel Landwerlin Errors-To: intel-xe-bounces@lists.freedesktop.org Sender: "Intel-xe" On Mon, 07 Aug 2023 18:31:49 -0700, Ashutosh Dixit wrote: > Hi Umesh/Lionel, > This patchset is the initial port of i915 perf/OA functionality to the Xe > driver. It has been tested against the following IGT patch: > > https://patchwork.freedesktop.org/series/121082/ > > The following features in i915 have not been ported and will be added (as > new patches) if/as they are needed: > > * Inline batch submission on stream exec_queue/hw_engine > * NOA wait About these two in the "not-yet-ported" feature list for Xe: In i915 when a stream engine is specified, requests are submitted "inline" to that engine whenever the OA stream is opened or reconfigured. This feature is at present not ported to Xe (see xe_oa_submit_bb()). I have a couple of questions about this "inline submission": * Is inline submission a hard requirement? That is, in Xe can UMD's say (completely outside OA uapi) fence till a segment of the workload completes, then open/reconfigure the OA stream and then continue? If UMD's are able to do this we don't need inline submission in Xe. If UMD's cannot do this please explain why not. * If inline submission is indeed required, can we do away with NOA wait (as implemented in daed3e44396d ("drm/i915/perf: implement active wait for noa configurations")) or implement NOA wait differently in Xe? E.g. can we expose a fence in the OA uapi and UMD's would be required to wait on this fence/sync-object before continuing workload submissions after any OA stream open/reconfiguration. The reason I am brining this up is because in i915 there are a couple of scary bugs around this which are still unresolved. E.g.: https://gitlab.freedesktop.org/drm/intel/-/issues/8746 https://gitlab.freedesktop.org/drm/intel/-/issues/8190 There is therefore reason to think if this functionality can be done differently in Xe (not to say these bugs will be carried over to Xe). Thanks. -- Ashutosh > * GuC ctx id (guc_sw_ctx_id) > * CTX_R_PWR_CLK_STATE/GEN8_R_PWR_CLK_STATE > * hold_preemption (DRM_XE_OA_PROP_HOLD_PREEMPTION) > * sseu_config (DRM_XE_OA_PROP_GLOBAL_SSEU) > * Override gucrc (override_gucrc_mode) > * MTL bios_c6_setup > * ratelimits > * compat ioctl > > I am providing the following additional HAX patch (not part of this series) > to help review these patches: > > https://patchwork.freedesktop.org/patch/551683/?series=120100&rev=4 > > The commit message in the above patch explains how it can be useful for > reviewing this series. > > Test-with: 20230808010017.37819-1-ashutosh.dixit@intel.com > > v2: Fix build > v3: Rebase, due to s/xe_engine/xe_exec_queue/ > > Ashutosh Dixit (10): > drm/xe/oa: Introduce OA uapi > drm/xe/oa: Add OA types > drm/xe/oa: Add registers and GPU commands used by OA > drm/xe/oa: Module init/exit and probe/remove > drm/xe/oa: Add/remove config ioctl's > drm/xe/oa: Start implementing OA stream open ioctl > drm/xe/oa: OA stream initialization > drm/xe/oa: Expose OA stream fd > drm/xe/oa: Read file_operation > drm/xe/oa: Implement queries > > drivers/gpu/drm/xe/Makefile | 1 + > drivers/gpu/drm/xe/regs/xe_engine_regs.h | 5 + > drivers/gpu/drm/xe/regs/xe_gpu_commands.h | 27 + > drivers/gpu/drm/xe/regs/xe_oa_regs.h | 173 ++ > drivers/gpu/drm/xe/xe_device.c | 16 + > drivers/gpu/drm/xe/xe_device_types.h | 4 + > drivers/gpu/drm/xe/xe_gt_types.h | 4 + > drivers/gpu/drm/xe/xe_hw_engine_types.h | 2 + > drivers/gpu/drm/xe/xe_module.c | 5 + > drivers/gpu/drm/xe/xe_oa.c | 2356 +++++++++++++++++++++ > drivers/gpu/drm/xe/xe_oa.h | 28 + > drivers/gpu/drm/xe/xe_oa_types.h | 295 +++ > drivers/gpu/drm/xe/xe_query.c | 5 +- > include/uapi/drm/xe_drm.h | 257 ++- > 14 files changed, 3176 insertions(+), 2 deletions(-) > create mode 100644 drivers/gpu/drm/xe/regs/xe_oa_regs.h > create mode 100644 drivers/gpu/drm/xe/xe_oa.c > create mode 100644 drivers/gpu/drm/xe/xe_oa.h > create mode 100644 drivers/gpu/drm/xe/xe_oa_types.h > > -- > 2.41.0 >