[Mesa-dev] [PATCH 08/18] i965: Wire up initial support for DRI_RENDERER_QUERY extension
daniel at ffwll.ch
Thu Nov 7 13:33:39 PST 2013
On Sat, Oct 12, 2013 at 12:10 AM, Ian Romanick <idr at freedesktop.org> wrote:
> + /* Once a batch uses more than 75% of the maximum mappable size, we
> + * assume that there's some fragmentation, and we start doing extra
> + * flushing, etc. That's the big cliff apps will care about.
> + *
> + * Can only map 2G onto the GPU through the GTT.
> + */
> + const unsigned gpu_mappable_megabytes = 2 * 1024 * 3 / 4;
We have an ioctl to tell you that, since it's not really 2G on really
old stuff. And will probably change on newer platforms. Also, using
that ioctl allows the kernel to limit your usage in case the available
ram is less than the virtual size of the gtt (atm we don't bother with
that much cleverness, but probably will in the future). See
DRM_IOCTL_I915_GEM_GET_APERTURE in libdrm (it's unfortunately not
exposed through any libdrm function afaics.
Software Engineer, Intel Corporation
+41 (0) 79 365 57 48 - http://blog.ffwll.ch
More information about the mesa-dev