From: Yuanhan Liu Subject: Re: [PATCH 2/2] intel: Add .aub file output support. Date: Fri, 9 Mar 2012 11:53:06 +0800 Message-ID: <20120309035306.GW17001@yliu-dev.sh.intel.com> References: <1331148067-8932-1-git-send-email-eric@anholt.net> <1331148067-8932-2-git-send-email-eric@anholt.net> <20120308025120.GT17001@yliu-dev.sh.intel.com> <4F590513.9000005@whitecape.org> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mga09.intel.com (mga09.intel.com [134.134.136.24]) by gabe.freedesktop.org (Postfix) with ESMTP id F39D79E960 for ; Thu, 8 Mar 2012 19:53:58 -0800 (PST) Content-Disposition: inline In-Reply-To: <4F590513.9000005@whitecape.org> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: intel-gfx-bounces+gcfxdi-intel-gfx=m.gmane.org@lists.freedesktop.org Errors-To: intel-gfx-bounces+gcfxdi-intel-gfx=m.gmane.org@lists.freedesktop.org To: Kenneth Graunke Cc: intel-gfx@lists.freedesktop.org List-Id: intel-gfx@lists.freedesktop.org On Thu, Mar 08, 2012 at 11:14:27AM -0800, Kenneth Graunke wrote: > On 03/07/2012 06:51 PM, Yuanhan Liu wrote: > >On Wed, Mar 07, 2012 at 11:21:07AM -0800, Eric Anholt wrote: > >>From: Kenneth Graunke > >> > >>This will allow the driver to capture all of its execution state to a > >>file for later debugging. intel_gpu_dump is limited in that it only > >>captures batchbuffers, and Mesa's captures, while more complete, still > >>capture only a portion of the state involved in execution. > >> > >>It also enables us to load traces in our internal simulator. > >> > >>Signed-off-by: Eric Anholt > >>Signed-off-by: Yuanhan Liu > >>Signed-off-by: Kenneth Graunke > >>--- > >> intel/Makefile.am | 1 + > >> intel/intel_aub.h | 123 ++++++++++++++++++ > >> intel/intel_bufmgr.h | 14 ++ > >> intel/intel_bufmgr_gem.c | 315 ++++++++++++++++++++++++++++++++++++++++++++++ > >> 4 files changed, 453 insertions(+), 0 deletions(-) > >> create mode 100644 intel/intel_aub.h > >> [snip]... > >>+ /* MI_FLUSH enable */ > >>+ if (bufmgr_gem->gen>= 6) { > >>+ aub_out(bufmgr_gem, CMD_AUB_TRACE_HEADER_BLOCK | (5 - 2)); > >>+ aub_out(bufmgr_gem, AUB_TRACE_OP_MMIO_WRITE); > >>+ aub_out(bufmgr_gem, 0); > >>+ aub_out(bufmgr_gem, 0x209c); /* reg addr */ > >>+ aub_out(bufmgr_gem, 0x04); /* Length in byte */ > >>+ aub_out(bufmgr_gem, ((1<< 12)<< 16) | (1<< 12)); > >>+ } > > > >Zhenyu and me came to an agreement that it's the driver side to do the > >MI_FLUSH enable stuff. Since using MI_FLUSH is deprecated, and if you still > >use it, it is your job to set up the MI_FLUSH enable bit. > > Oh...yeah, we should definitely drop that. > > >>+} > >>+ > >>+/** > >> * Initializes the GEM buffer manager, which uses the kernel to allocate, map, > >> * and manage map buffer objections. > >> * > >>-- > >>1.7.9.1 > > Otherwise, > Reviewed-by: Kenneth Graunke > > Please set yourself as the author, though - I just squashed this and > fixed up a few minor things. Eric wrote the original code, I just made it work. But, of course, feel free to set it if you think it's a need ;) Thanks, Yuanhan Liu