From: Chris Wilson Subject: Re: [PATCH 1/3] drm/i915: Enable FBC at Haswell. Date: Wed, 10 Apr 2013 10:28:53 +0100 Message-ID: <20130410092852.GQ3792@cantiga.alporthouse.com> References: <1365457784-3412-1-git-send-email-rodrigo.vivi@gmail.com> <1365457784-3412-2-git-send-email-rodrigo.vivi@gmail.com> <20130409083534.GJ4469@intel.com> <20130410081815.GX4469@intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mga03.intel.com (mga03.intel.com [143.182.124.21]) by gabe.freedesktop.org (Postfix) with ESMTP id EC7CFE6008 for ; Wed, 10 Apr 2013 02:28:56 -0700 (PDT) Content-Disposition: inline In-Reply-To: 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: Daniel Vetter Cc: intel-gfx List-Id: intel-gfx@lists.freedesktop.org On Wed, Apr 10, 2013 at 10:52:20AM +0200, Daniel Vetter wrote: > So the idea is now to enable fbc/psr when pageflipping and disable it > as soon as we detect a frontbuffer rendering event. Thanks to the > current gem api we can do this pretty cheaply: > - CPU writes to the frontbuffer call sw_finish_ioctl. I need to still > check whether that only applies to cpu maps or also gtt maps. > - GTT writes could easily be caught by unmapping userspace ptes (we > have the infrastructure for that already), but I hope we can avoid > that. > - Currently we have some fragile code in our execbuf handler to detect > render of the gpu. I think we can rip this all out and instead detect > frontbuffer gpu rendering in the busy ioctl - that has been > established as the canonical interface for userspace to ask the kernel > to flush the frontbuffer. Aside: This semantics was not designed, but > we've realized that this is what it is eventually ;-) To add my wishlist item: - a global property / param indicating the availabilty of FBC - a crtc property indicating the status of FBC That way X can avoid front buffer rendering when it would incur penalties and is likely to result in corruption (I'm sure the next generation of FBC will work, or maybe the next). -Chris -- Chris Wilson, Intel Open Source Technology Centre