Chia-I Wu [Wed, 19 Feb 2014 04:57:15 +0000 (12:57 +0800)]
Revert "egl: Unhide functionality in _eglInitContext()"
This reverts commit
1456ed85f0ed8b9c9f0abd6bd389a089fa3824b2.
_eglInitResource can and is supposed to be called on subclass objects.
Acked-by: Juha-Pekka Heikkila <juhapekka.heikkila@gmail.com>
Chia-I Wu [Wed, 19 Feb 2014 04:57:11 +0000 (12:57 +0800)]
Revert "egl: Unhide functionality in _eglInitSurface()"
This reverts commit
498d10e230663f8604d00608cae6324f779c9cdd.
_eglInitResource can and is supposed to be called on subclass objects.
Acked-by: Juha-Pekka Heikkila <juhapekka.heikkila@gmail.com>
Kenneth Graunke [Sun, 2 Feb 2014 11:03:39 +0000 (03:03 -0800)]
i965: Bump MaxTexMbytes from 1GB to 1.5GB.
Even with the other limits raised, TestProxyTexImage would still reject
textures > 1GB in size. This is an artificial limit; nothing prevents
us from having a larger texture. I stayed shy of 2GB to avoid the
larger-than-aperture situation.
For 3D textures, this raises the effective limit:
- RGBA8: 645 -> 738
- RGBA16: 512 -> 586
- RGBA32F: 406 -> 465
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=74130
Signed-off-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Kenneth Graunke [Sun, 2 Feb 2014 10:58:42 +0000 (02:58 -0800)]
i965: Bump GL_MAX_CUBE_MAP_TEXTURE_SIZE to 8192.
Gen4+ supports 8192x8192 cube maps. Ivybridge and later can actually
support 16384, but that would place GL_MAX_CUBE_MAP_TEXTURE_SIZE above
GL_MAX_TEXTURE_SIZE, which seems like a bad idea.
(Unfortunately, we can't bump GL_MAX_TEXTURE_SIZE to 16384 without
causing regressions due to awful W-tiled stencil buffer interactions.)
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=74130
Signed-off-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Kenneth Graunke [Sun, 2 Feb 2014 10:51:45 +0000 (02:51 -0800)]
i965: Bump MAX_3D_TEXTURE_SIZE to 2048.
It's highly unlikely that there will be enough memory in the system to
allocate enough space for this, but we should still expose the hardware
limit. It's what the Intel Windows driver does, and it seems most other
vendors do likewise.
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=74130
Signed-off-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Ian Romanick [Tue, 18 Feb 2014 23:24:21 +0000 (15:24 -0800)]
docs: Trivial updates to MESA_query_renderer.spec
Fix the version and the status before sending to Khronos for listing in
the registry.
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
Sinclair Yeh [Thu, 13 Feb 2014 00:21:11 +0000 (16:21 -0800)]
Prevent zero sized wl_egl_window
It is illegal to create or resize a window to zero (or negative) width
and/or height. This patch prevents such a request from happening.
Anuj Phogat [Thu, 19 Dec 2013 22:17:19 +0000 (14:17 -0800)]
glsl: Fix condition to generate shader link error
GL_ARB_ES2_compatibility doesn't say anything about shader linking
when one of the shaders (vertex or fragment shader) is absent. So,
the extension shouldn't change the behavior specified in GLSL
specification.
Tested the behavior on proprietary linux drivers of NVIDIA and AMD.
Both of them allow linking a version 100 shader program in OpenGL
context, when one of the shaders is absent.
Makes following Khronos CTS tests to pass:
successfulcompilevert_linkprogram.test
successfulcompilefrag_linkprogram.test
Cc: mesa-stable@lists.freedesktop.org
Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com>
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Anuj Phogat [Sat, 15 Feb 2014 01:27:29 +0000 (17:27 -0800)]
mesa: Add GL_TEXTURE_CUBE_MAP_ARRAY to legal_get_tex_level_parameter_target()
Fixes failing Khronos CTS test packed_depth_stencil_init.test
Cc: <mesa-stable@lists.freedesktop.org>
Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com>
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Eric Anholt [Fri, 14 Feb 2014 05:37:50 +0000 (21:37 -0800)]
i965/fs: Use conditional sends to do FB writes on HSW+.
This drops the MOVs for header setup, which are totally mis-scheduled.
total instructions in shared programs:
1590047 ->
1589331 (-0.05%)
instructions in affected programs: 43729 -> 43013 (-1.64%)
GAINED: 0
LOST: 0
glb27-trex:
x before
+ after
+-----------------------------------------------------------------------------+
| + x xx + + + |
| ++ + xxx ++x xx + ** *x+ + + + x * |
|+x xx x* x+++xx*x*xx+++*+*xx++** *x* x+***x*+xx+* + * + + *|
| |__|__________MA___A___________|___| |
+-----------------------------------------------------------------------------+
N Min Max Median Avg Stddev
x 49 62.33 65.41 63.49 63.53449 0.
62757822
+ 50 62.28 65.4 63.7 63.6982 0.656564
No difference proven at 95.0% confidence
Reviewed-by: Matt Turner <mattst88@gmail.com>
Eric Anholt [Fri, 14 Feb 2014 23:41:40 +0000 (15:41 -0800)]
i965/fs: Drop dead comment about the old proj_attrib_mask optimization.
The code was removed early last year.
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Eric Anholt [Fri, 14 Feb 2014 21:00:40 +0000 (13:00 -0800)]
i965: Drop mt->levels[].width/height.
It often confused people because it was unclear on whether it was the
physical or logical, and people needed the other one as well. We can
recompute it trivially using the minify() macro, clarifying which value is
being used and making getting the other value obvious.
v2: Fix a pasteo in intel_blit.c's dst flip.
Reviewed-by: Chris Forbes <chrisf@ijw.co.nz> (v1)
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Eric Anholt [Thu, 13 Feb 2014 18:45:35 +0000 (10:45 -0800)]
i965: Move singlesample_mt to the renderbuffer.
Since only window system renderbuffers can have a singlesample_mt, this
lets us drop a bunch of sanity checking to make sure that we're just a
renderbuffer-like thing.
v2: Fix a badly-written comment (thanks Kenneth!), drop the now trivial
helper function for set_needs_downsample.
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Eric Anholt [Thu, 13 Feb 2014 22:33:57 +0000 (14:33 -0800)]
i965: Drop some duplicated code in DRI winsys BO updates.
The only DRI2 vs DRI3 delta was just how to decide about frontbuffer-ness
for doing the upsample.
v2: Fix missing singlesample_mt->region->name update in the merged code,
which would have broken the DRI2 don't-recreate-the-miptree
optimization.
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Eric Anholt [Thu, 13 Feb 2014 18:52:47 +0000 (10:52 -0800)]
i965: Simplify intel_miptree_updownsample.
Pretty silly to pass in values dereferenced out of one of the arguments.
v2: Get the destination size from the dst, even though the callers are
always dealing with src size == dst size cases.
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Eric Anholt [Thu, 13 Feb 2014 23:58:21 +0000 (15:58 -0800)]
i965: Don't try to use the ctx->ReadBuffer when asked to blorp miptrees.
So far it's happened to be that we're only ever calling
intel_miptree_blit() (up/downsampling) from the ReadBuffer, but I stumbled
over a null ReadBuffer case when debugging later parts of the series.
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Eric Anholt [Fri, 7 Feb 2014 22:20:34 +0000 (14:20 -0800)]
i965: Make the mt->target of multisample renderbuffers be 2D_MS.
Mostly mt->target == 2D_MS just results in a few checks that we don't try
to allocate multiple LODs and don't try to do slice copies with them. But
with the introduction of binding renderbuffers to textures, we need more
consistency.
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Eric Anholt [Tue, 11 Feb 2014 20:10:59 +0000 (12:10 -0800)]
meta: Push into desktop GL mode when doing meta operations.
This lets us simplify our shaders, and rely on GLES-prohibited
functionality (like ARB_texture_multisample) when writing these
driver-internal functions.
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Eric Anholt [Fri, 14 Feb 2014 22:31:17 +0000 (14:31 -0800)]
meta: Fix blit shader compile on non-glsl-130 drivers.
Compare this VS to the one for the post-130 case. Fixes piglit
glsl-lod-bias, and presumably tons of other code (I haven't done a full
piglit run on swrast).
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=74911
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Rob Clark [Tue, 18 Feb 2014 13:12:37 +0000 (08:12 -0500)]
configure: fix build error with XA
Fixes:
xa_tracker.c: In function 'xa_tracker_create':
xa_tracker.c:147:5: error: implicit declaration of function 'pipe_loader_drm_probe_fd' [-Werror=implicit-function-declaration]
in some build configurations, as XA now implicitly depends on
gallium_drm_loader.
Signed-off-by: Rob Clark <robclark@freedesktop.org>
Reviewed-by: Jakob Bornecrantz <jakob@vmware.com>
Michel Dänzer [Thu, 13 Feb 2014 02:51:09 +0000 (11:51 +0900)]
r600g,radeonsi: Consolidate logic for short-circuiting flushes
Fixes radeonsi emitting command streams to the kernel even when there
have been no draw calls before a flush, potentially powering up the GPU
needlessly.
Incidentally, this also cuts the runtime of piglit gpu.py in about half
on my Kaveri system, probably because an X11 client going away no longer
always results in a command stream being submitted to the kernel via
glamor.
Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=65761
Cc: "10.1" mesa-stable@lists.freedesktop.org
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Emil Velikov [Thu, 13 Feb 2014 00:44:32 +0000 (00:44 +0000)]
st/dri: remove #ifdef DRM_CAP_PRIME guard
Required for libdrm 2.4.37 and earlier. Both scons and automake
require version 2.4.38 now so that guard is not longer needed.
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Reviewed-by: Matt Turner <mattst88@gmail.com>
Emil Velikov [Tue, 18 Feb 2014 00:08:03 +0000 (00:08 +0000)]
automake: remove leftover XORG and LIBKMS variables
No longer set or used since the removal of st/xorg.
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Reviewed-by: Matt Turner <mattst88@gmail.com>
Emil Velikov [Thu, 13 Feb 2014 00:28:27 +0000 (00:28 +0000)]
scons: sync package requirements
xorg-server and libkms is no longer required since the removal
of the xorg state-tracker.
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Reviewed-by: Matt Turner <mattst88@gmail.com>
Emil Velikov [Thu, 13 Feb 2014 00:23:16 +0000 (00:23 +0000)]
configure: bump up libdrm requirement to 2.4.38
This is the first version that introduced DRM_CAP_PRIME, which is
implicitly required by egl/wayland.
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Reviewed-by: Matt Turner <mattst88@gmail.com>
Emil Velikov [Tue, 4 Feb 2014 17:32:03 +0000 (17:32 +0000)]
configure: use test -n whenever possible
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Reviewed-by: Matt Turner <mattst88@gmail.com>
Emil Velikov [Tue, 11 Feb 2014 14:47:37 +0000 (14:47 +0000)]
configure: use test -z whenever possible
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Reviewed-by: Matt Turner <mattst88@gmail.com>
Emil Velikov [Tue, 4 Feb 2014 17:26:38 +0000 (17:26 +0000)]
configure: cleanup classic dri drivers handling
* Make sure that only drivers that are handled by configure.ac
are included in DRI_DIRS.
* Change with_dri_drivers default value to auto, and set enable
autodetection, when enable_opengl is on.
v2: Move "test" to the correct location.
v3: Squash DRI_DIRS handling before the switch statement.
Suggested by Ilia Mirkin
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Reviewed-by: Matt Turner <mattst88@gmail.com>
Emil Velikov [Mon, 3 Feb 2014 21:05:19 +0000 (21:05 +0000)]
configure: compact ppc/sparc DRI_DIRS handling
Both arches have the same list of dri_dirs.
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Reviewed-by: Matt Turner <mattst88@gmail.com>
Emil Velikov [Mon, 3 Feb 2014 20:54:08 +0000 (20:54 +0000)]
configure: drop explicit DRI_DIRS assignment on some platforms/arches
Both x86_64|amd64 and *bsd, already set the full range of available
classic dri drivers. Drop the explicit assignment, and fall back to
the generic default.
Keep explicit list from plafroms/arches that do not handle the default
list.
Update help strings, to explicitly mention "classic" for applicable
DRI drivers.
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Reviewed-by: Matt Turner <mattst88@gmail.com>
Emil Velikov [Mon, 3 Feb 2014 20:38:10 +0000 (20:38 +0000)]
configure: cleanup switch statement
Move all the cases within one switch statement and handle
i9{1,6}5 and r{adeon,200} independently.
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Reviewed-by: Matt Turner <mattst88@gmail.com>
Kusanagi Kouichi [Mon, 17 Feb 2014 08:29:14 +0000 (17:29 +0900)]
targets/vdpau: Don't link unused libraries
libvdpau, libselinux and libexpat are not used.
Signed-off-by: Kusanagi Kouichi <slash@ac.auone-net.jp>
Kusanagi Kouichi [Sat, 15 Feb 2014 02:53:00 +0000 (11:53 +0900)]
configure: Try pkg-config first for libselinux
v2 (Emil) Add SELINUX_CFLAGS in the respective locations
Signed-off-by: Kusanagi Kouichi <slash@ac.auone-net.jp>
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Reviewed-by: Matt Turner <mattst88@gmail.com> (v1)
Kusanagi Kouichi [Wed, 12 Feb 2014 07:07:55 +0000 (16:07 +0900)]
targets/vdpau: Always use c++ to link
If built without llvm, the following error occurs with mplayer:
Failed to open VDPAU backend .../libvdpau_r600.so: undefined symbol: _ZTVN10__cxxabiv117__class_type_infoE
[vo/vdpau] Error when calling vdp_device_create_x11: 1
Cc: <mesa-stable@lists.freedesktop.org>
Signed-off-by: Kusanagi Kouichi <slash@ac.auone-net.jp>
Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com>
Ilia Mirkin [Sun, 16 Feb 2014 07:21:59 +0000 (02:21 -0500)]
st/xvmc: fix tests so that they pass
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
Reviewed-by: Christian König <christian.koenig@amd.com>
Rob Clark [Mon, 10 Feb 2014 15:45:36 +0000 (10:45 -0500)]
pipe-loader: add pipe loader for freedreno/msm
Signed-off-by: Rob Clark <robclark@freedesktop.org>
Rob Clark [Mon, 10 Feb 2014 15:44:02 +0000 (10:44 -0500)]
st/xa: missing handle type
DRM_API_HANDLE_TYPE_SHARED is zero, so doesn't actually fix anything.
But we shouldn't rely on SHARED handle type being zero.
Signed-off-by: Rob Clark <robclark@freedesktop.org>
Rob Clark [Mon, 10 Feb 2014 15:43:11 +0000 (10:43 -0500)]
st/xa: use pipe-loader to get screen
This lets multiple gallium drivers use XA.
Signed-off-by: Rob Clark <robclark@freedesktop.org>
Rob Clark [Mon, 10 Feb 2014 14:39:23 +0000 (09:39 -0500)]
pipe-loader: split out "client" version
Build two versions of pipe-loader, with only the client version linking
in x11 client side dependencies. This will allow the XA state tracker
to use pipe-loader.
Signed-off-by: Rob Clark <robclark@freedesktop.org>
Rob Clark [Sun, 16 Feb 2014 00:01:38 +0000 (19:01 -0500)]
freedreno/a3xx/compiler: use (ss) for WAR hazards
Seems texture sample instructions don't immediately consume there
src(s). In fact, some shaders from blob compiler seem to indiciate that
it does not even count the texture sample instructions when calculating
number of delay slots to fill for non-sample instructions. (Although so
far it seems inconclusive as to whether this is required.)
In particular, when a src register of a previous texture sample
instruction is clobbered, the (ss) bit is needed to synchronize with the
tex pipeline to ensure it has picked up the previous values before they
are overwritten.
Signed-off-by: Rob Clark <robclark@freedesktop.org>
Rob Clark [Sun, 16 Feb 2014 12:41:59 +0000 (07:41 -0500)]
freedreno/a3xx/compiler: fix RA typo
Was supposed to be a '+', otherwise we end up with a negative offset and
choosing registers below the assigned range.
This seems to fix the scheduling mystery "solved" by adding in extra
delay slots.
Signed-off-by: Rob Clark <robclark@freedesktop.org>
Rob Clark [Sun, 16 Feb 2014 12:35:20 +0000 (07:35 -0500)]
freedreno/a3xx/compiler: handle kill properly (new compiler)
Since 'kill' does not produce a result, the new compiler was happily
optimizing them out. We need to instead track 'kill's similar to
outputs. But since there is no non-predicated kill instruction,
(and for flattend if/else we do want them to be predicated), we need
to track the topmost branch condition on the stack and use that as src
arg to the kill. For a kill at the topmost level, we have to generate
an immediate 1.0 to feed into the cmps.f for setting the predicate
register.
Signed-off-by: Rob Clark <robclark@freedesktop.org>
Rob Clark [Sun, 16 Feb 2014 12:29:13 +0000 (07:29 -0500)]
freedreno/a3xx/compiler: trans_cmp() sanity
Thanks to figuring out 32bit float render target, and adding regdump
test in fdre-a3xx, I can more easily play around with instructions to
figure out range of inputs/outputs/etc. And from this I can conclude
that cmps.f works more like expected and I can do something much more
simple in trans_cmp() (compared to before which was more closely
emulating the instruction sequence of the blob compiler).
And using sel.b32 (binary 0/1) often makes more sense than sel.f32
(+/- float) or sel.u32 (+/- uint) as it can use the output directly
from cmps.f without needing the 'add.s tmp0, tmp0, -1'.
Signed-off-by: Rob Clark <robclark@freedesktop.org>
Rob Clark [Mon, 10 Feb 2014 14:14:15 +0000 (09:14 -0500)]
freedreno: fix problems if no color buf bound
Signed-off-by: Rob Clark <robclark@freedesktop.org>
Eric Anholt [Wed, 5 Feb 2014 23:45:25 +0000 (15:45 -0800)]
meta: Don't try to enable FF texturing when we're using GLSL.
On a core context, this would throw an error.
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Carl Worth [Thu, 13 Feb 2014 17:49:27 +0000 (09:49 -0800)]
main: Avoid double-free of shader Label
As documented, the _mesa_free_shader_program_data function:
"Frees all the data that hangs off a shader program object, but not
the object itself."
This means that this function may be called multiple times on the same object,
(and has been observed to). Meanwhile, the shProg->Label field was not being
set to NULL after its free(). This led to a second call to free() of the same
address on the second call to this function.
Fix this by setting this field to NULL after free(), (just as with all other
calls to free() in this function).
Reviewed-by: Brian Paul <brianp@vmware.com>
CC: mesa-stable@lists.freedesktop.org
Brian Paul [Fri, 14 Feb 2014 14:45:23 +0000 (07:45 -0700)]
gallium/pipebuffer: change pb_cache_manager_create() size_factor to float
Requested by Marek.
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Cc: "10.1" <mesa-stable@lists.freedesktop.org>
Thomas Hellstrom [Sat, 8 Feb 2014 17:51:15 +0000 (09:51 -0800)]
svga/winsys: Propagate surface shared information to the winsys
The linux winsys needs to know whether a surface is shared.
For guest-backed surfaces we need this information to avoid allocating a
mob out of the mob cache for shared surfaces, but instead allocate a shared
mob, that is never put in the mob cache, from the kernel.
Also previously, all surfaces were given the "shareable" attribute when
allocated from the kernel. This is too permissive for client-local surfaces.
Now that we have the needed info, only set the "shareable" attribute if the
client indicates that it needs to share the surface.
Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
Reviewed-by: Jakob Bornecrantz <jakob@vmware.com>
Reviewed-by: Brian Paul <brianp@vmware.com>
Cc: "10.1" <mesa-stable@lists.freedesktop.org>
Brian Paul [Sat, 8 Feb 2014 17:51:15 +0000 (09:51 -0800)]
svga/winsys: implement GBS support
This is a squash commit of many commits by Thomas Hellstrom.
Reviewed-by: Thomas Hellstrom <thellstrom@vmware.com>
Cc: "10.1" <mesa-stable@lists.freedesktop.org>
Thomas Hellstrom [Sat, 8 Feb 2014 17:51:15 +0000 (09:51 -0800)]
gallium/util: Add flush/map debug utility code
Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
Reviewed-by: Brian Paul <brianp@vmware.com>
Cc: "10.1" <mesa-stable@lists.freedesktop.org>
Thomas Hellstrom [Sat, 8 Feb 2014 17:51:15 +0000 (09:51 -0800)]
gallium/pipebuffer: Add a cache buffer manager bypass mask
In some situations, it may be desirable to bypass the cache at buffer
creation but to insert the buffer in the cache at buffer destruction.
One such situation is where we already have a kernel representation of a
buffer that we want to use, but we also want to insert it in the cache when
it's freed up.
Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
Reviewed-by: José Fonseca <jfonseca@vmware.com>
Reviewed-by: Brian Paul <brianp@vmware.com>
Cc: "10.1" <mesa-stable@lists.freedesktop.org>
Thomas Hellstrom [Sat, 8 Feb 2014 17:51:15 +0000 (09:51 -0800)]
pipebuffer, winsys: Add a size match parameter to the cached buffer manager
In some situations it's important to restrict the sizes of buffers that the
cached buffer manager is allowed to return
Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
Cc: "10.1" <mesa-stable@lists.freedesktop.org>
Brian Paul [Sat, 8 Feb 2014 17:51:15 +0000 (09:51 -0800)]
svga: update texture code for GBS
Reviewed-by: Thomas Hellstrom <thellstrom@vmware.com>
Cc: "10.1" <mesa-stable@lists.freedesktop.org>
Brian Paul [Sat, 8 Feb 2014 17:51:15 +0000 (09:51 -0800)]
svga: update buffer code for GBS
Reviewed-by: Thomas Hellstrom <thellstrom@vmware.com>
Cc: "10.1" <mesa-stable@lists.freedesktop.org>
Brian Paul [Sat, 8 Feb 2014 17:51:14 +0000 (09:51 -0800)]
svga: add new helper functions for GBS buffers
Reviewed-by: Thomas Hellstrom <thellstrom@vmware.com>
Cc: "10.1" <mesa-stable@lists.freedesktop.org>
Brian Paul [Sat, 8 Feb 2014 17:51:14 +0000 (09:51 -0800)]
svga: remove a couple unneeded assertions
Reviewed-by: Thomas Hellstrom <thellstrom@vmware.com>
Cc: "10.1" <mesa-stable@lists.freedesktop.org>
Brian Paul [Sat, 8 Feb 2014 17:51:14 +0000 (09:51 -0800)]
svga: adjust adjustment for point coordinates
Reviewed-by: Thomas Hellstrom <thellstrom@vmware.com>
Cc: "10.1" <mesa-stable@lists.freedesktop.org>
Brian Paul [Sat, 8 Feb 2014 17:51:14 +0000 (09:51 -0800)]
svga: track which textures are rendered to
Reviewed-by: Thomas Hellstrom <thellstrom@vmware.com>
Cc: "10.1" <mesa-stable@lists.freedesktop.org>
Brian Paul [Sat, 8 Feb 2014 17:51:14 +0000 (09:51 -0800)]
svga: add helpers for tracking rendering to textures
Reviewed-by: Thomas Hellstrom <thellstrom@vmware.com>
Cc: "10.1" <mesa-stable@lists.freedesktop.org>
Brian Paul [Sat, 8 Feb 2014 17:51:14 +0000 (09:51 -0800)]
svga: update shader code for GBS
Reviewed-by: Thomas Hellstrom <thellstrom@vmware.com>
Cc: "10.1" <mesa-stable@lists.freedesktop.org>
Brian Paul [Sat, 8 Feb 2014 17:51:14 +0000 (09:51 -0800)]
svga: update constant buffer code for GBS
Reviewed-by: Thomas Hellstrom <thellstrom@vmware.com>
Cc: "10.1" <mesa-stable@lists.freedesktop.org>
Brian Paul [Sat, 8 Feb 2014 17:51:14 +0000 (09:51 -0800)]
svga: add svga_have_gb_objects/dma() functions
Reviewed-by: Thomas Hellstrom <thellstrom@vmware.com>
Cc: "10.1" <mesa-stable@lists.freedesktop.org>
Brian Paul [Sat, 8 Feb 2014 17:51:14 +0000 (09:51 -0800)]
svga: add new GBS commands
And update some existing commands.
Reviewed-by: Thomas Hellstrom <thellstrom@vmware.com>
Cc: "10.1" <mesa-stable@lists.freedesktop.org>
Brian Paul [Sat, 8 Feb 2014 17:51:14 +0000 (09:51 -0800)]
svga: update svga_winsys interface for GBS
This adds new interface functions for guest-backed surfaces and
adds a mobid parameter to the surface_relocation() function.
Reviewed-by: Thomas Hellstrom <thellstrom@vmware.com>
Cc: "10.1" <mesa-stable@lists.freedesktop.org>
Brian Paul [Sat, 8 Feb 2014 17:51:14 +0000 (09:51 -0800)]
svga: update dumping code with new GBS commands, etc
Reviewed-by: Thomas Hellstrom <thellstrom@vmware.com>
Cc: "10.1" <mesa-stable@lists.freedesktop.org>
Brian Paul [Sat, 8 Feb 2014 17:51:13 +0000 (09:51 -0800)]
svga: split / update svga3d header files
The old svga3d_reg.h file is split into separate header files and we
add new items for guest-backed surfaces.
Plus some minor code fixes because of renamed symbols.
Reviewed-by: Thomas Hellstrom <thellstrom@vmware.com>
Cc: "10.1" <mesa-stable@lists.freedesktop.org>
Grigori Goronzy [Thu, 13 Feb 2014 20:32:30 +0000 (21:32 +0100)]
st/vdpau: add support for DEINTERLACE_TEMPORAL
Reviewed-by: Christian König <christian.koenig@amd.com>
Grigori Goronzy [Thu, 13 Feb 2014 20:32:29 +0000 (21:32 +0100)]
vl: add motion adaptive deinterlacer
Reviewed-by: Christian König <christian.koenig@amd.com>
Leo Liu [Mon, 3 Feb 2014 15:41:05 +0000 (10:41 -0500)]
st/omx/enc: fix scaling src alignment issue
Signed-off-by: Leo Liu <leo.liu@amd.com>
Signed-off-by: Christian König <christian.koenig@amd.com>
Alex Deucher [Wed, 12 Feb 2014 17:00:17 +0000 (12:00 -0500)]
radeon: reverse DBG_NO_HYPERZ logic
Change the flag to DBG_HYPERZ and reverse the logic
so setting the flag enabled the feature. This disables
hyperz on r600g and radeonsi by default. It can be
enabled by setting the env var. There are just too
many issues with certain apps so leave it disabled for
now until we sort out the issues with the problematic
apps.
Bugs:
https://bugs.freedesktop.org/show_bug.cgi?id=58660
https://bugs.freedesktop.org/show_bug.cgi?id=64471
https://bugs.freedesktop.org/show_bug.cgi?id=66352
https://bugs.freedesktop.org/show_bug.cgi?id=68799
https://bugs.freedesktop.org/show_bug.cgi?id=72685
https://bugs.freedesktop.org/show_bug.cgi?id=73088
https://bugs.freedesktop.org/show_bug.cgi?id=74428
https://bugs.freedesktop.org/show_bug.cgi?id=74803
https://bugs.freedesktop.org/show_bug.cgi?id=74863
https://bugs.freedesktop.org/show_bug.cgi?id=74892
https://bugzilla.kernel.org/show_bug.cgi?id=70411
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Cc: "10.1" "10.0" <mesa-stable@lists.freedesktop.org>
Acked-by: Marek Olšák <marek.olsak@amd.com>
Tom Stellard [Fri, 24 Jan 2014 22:51:06 +0000 (17:51 -0500)]
pipe-loader: Add support for render nodes v2
v2:
- Add missing call to pipe_loader_drm_release()
- Fix render node macros
- Drop render-node configure option
Tom Stellard [Mon, 27 Jan 2014 15:34:16 +0000 (10:34 -0500)]
pipe-loader: Add auth_x parameter to pipe_loader_drm_probe_fd()
The caller can use this boolean parameter to tell the pipe-loader
to authenticate with the X server when probing a file descriptor.
Christian König [Thu, 13 Feb 2014 11:50:51 +0000 (12:50 +0100)]
st/omx/dec/h264: fix pic_order_cnt_type==2
Signed-off-by: Christian König <christian.koenig@amd.com>
Ilia Mirkin [Wed, 12 Feb 2014 23:22:56 +0000 (18:22 -0500)]
nouveau: fix chipset checks for nv1a by using the oclass instead
Commit
f4ebcd133b9 ("dri/nouveau: NV17_3D class is not available for
NV1a chipset") fixed this partially by using the correct 3d class.
However there were a lot of checks left over comparing against the
chipset.
Reported-and-tested-by: John F. Godfrey <jfgodfrey@gmail.com>
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
Cc: 9.2 10.0 10.1 <mesa-stable@lists.freedesktop.org>
Reviewed-by: Francisco Jerez <currojerez@riseup.net>
Christian König [Mon, 5 Aug 2013 17:41:27 +0000 (11:41 -0600)]
st/omx: initial OpenMAX H264 encoder v7
v2 (chk): fix eos handling
v3 (leo): implement scaling configuration support
v4 (leo): fix bitrate bug
v5 (chk): add workaround for bug in Bellagio
v6 (chk): fix div by 0 if framerate isn't known,
user separate pipe object for scale and transfer,
always flush the transfer pipe before encoding
v7 (chk): make suggested changes, cleanup a bit more,
only advertise encoder on supported hardware
Signed-off-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Leo Liu <leo.liu@amd.com>
Christian König [Thu, 17 Oct 2013 12:21:40 +0000 (06:21 -0600)]
radeon/vce: initial VCE support v8
v2 (chk): revert feedback buffer hack
v3 (slava): fixed bitstream size calculation
v4 (chk): always create buffers in the right domain
v5 (chk): flush async
v6 (chk): rework fw interface add version check
v7 (leo): implement cropping support
v8 (chk): add hw checks
Signed-off-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Leo Liu <leo.liu@amd.com>
Signed-off-by: Slava Grigorev <slava.grigorev@amd.com>
Christian König [Mon, 8 Jul 2013 14:32:04 +0000 (08:32 -0600)]
radeon/winsys: add VCE support v4
v2: add fw version query
v3: add README.VCE
v4: avoid error msg when kernel doesn't support it
Signed-off-by: Christian König <christian.koenig@amd.com>
Ilia Mirkin [Thu, 13 Feb 2014 07:33:37 +0000 (02:33 -0500)]
nv50: mark scissors/viewports dirty on context switch
Commit
246ca4b001 ("nv50: implement multiple viewports/scissors, enable
ARB_viewport_array") added dirty tracking to scissors/viewports. However
it neglected to mark them all as dirty on a context switch. This fixes
an apparent regression in webgl in chrome, but probably in any
application that switches contexts.
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
Christian König [Tue, 11 Feb 2014 10:55:47 +0000 (11:55 +0100)]
gallium/vl: remove remaining softpipe video functions
Unused and unmaintained for quite a while.
Signed-off-by: Christian König <christian.koenig@amd.com>
Reviewed-by: Maarten Lankhorst <maarten.lankhorst@canonical.com>
Ilia Mirkin [Thu, 13 Feb 2014 03:14:23 +0000 (22:14 -0500)]
docs: add nv50 to the ARB_viewport_array list
Ilia Mirkin [Tue, 21 Jan 2014 07:56:01 +0000 (02:56 -0500)]
nv50: implement multiple viewports/scissors, enable ARB_viewport_array
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
Reviewed-by: Christoph Bumiller <e0425955@student.tuwien.ac.at>
Ilia Mirkin [Tue, 11 Feb 2014 05:26:32 +0000 (00:26 -0500)]
mesa/st: hardcode the viewport bounds range
The bound range is disconnected from the viewport dimensions. This is
the relevant bit from glViewportArray:
"""
The location of the viewport's bottom left corner, given by (x, y) is
clamped to be within the implementaiton-dependent viewport bounds range.
The viewport bounds range [min, max] can be determined by calling glGet
with argument GL_VIEWPORT_BOUNDS_RANGE. Viewport width and height are
silently clamped to a range that depends on the implementation. To query
this range, call glGet with argument GL_MAX_VIEWPORT_DIMS.
"""
Just set it to +/-16384, as that is the minimum required by
ARB_viewport_array and the value that all current drivers provide.
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Brian Paul [Thu, 13 Feb 2014 00:46:11 +0000 (17:46 -0700)]
scons: add meta_blit.c to src/mesa/SConscript
Eric Anholt [Wed, 5 Feb 2014 07:57:29 +0000 (23:57 -0800)]
meta: Add acceleration for depth glBlitFramebuffer().
Surprisingly, the GLSL shaders already wrote the sampled r value to
FragDepth.
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=51600
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Eric Anholt [Tue, 4 Feb 2014 23:00:46 +0000 (15:00 -0800)]
meta: Use BindRenderbufferTexImage() for meta glBlitFramebuffer().
This avoids a CopyTexImage() on Intel i965 hardware without blorp.
v2: Move the !readAtt check up higher.
v3: Rebase on idr's changes, plus readAtt check is totally gone, and also
fix a typo in a comment.
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org> (v2)
Eric Anholt [Tue, 4 Feb 2014 20:51:11 +0000 (12:51 -0800)]
i965: Add a driver hook for binding renderbuffers to textures.
This will let us use meta's acceleration from renderbuffers without having
to do a CopyTexImage first.
This is like what we do for TFP, but just taking an existing renderbuffer
and binding it to a texture with whatever its format was. The
implementation won't work for stencil renderbuffers, and it only does
non-texture renderbuffers (but then, if you're using a texture
renderbuffer, you can just pull the texture object/level/slice out of the
renderbuffer, anyway).
v2: Don't forget to propagate NumSamples to the teximage.
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Eric Anholt [Tue, 4 Feb 2014 22:52:27 +0000 (14:52 -0800)]
meta: Do a massive unindent (and rename) of blitframebuffer_texture().
This function is only handling the color case. We can just unindent as
long as we're willing to do the check for the bit outside of the
function.
v2: Rebase on idr's changes, drop readAtt check that's always non-null
anyway (it's a pointer into to the statically-allocated attachments
array in the renderbuffer).
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org> (v1)
Eric Anholt [Mon, 3 Feb 2014 23:31:01 +0000 (15:31 -0800)]
meta: Move glBlitFramebuffer() to a separate file.
v2: Drop a bunch of unnecessary includes (by Kenneth), rebase on idr's
changes.
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org> (v1)
Eric Anholt [Mon, 3 Feb 2014 23:08:54 +0000 (15:08 -0800)]
meta: De-static some of meta's functions.
I want split some meta.c code off to a separate file, so these functions
can't be static any more.
v2: Rebase on idr's changes, also expose setup_blit_shader,
blit_shader_table_cleanup, setup_vertex_objects,
setup_ff_tnl_for_blit.
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org> (v1)
Eric Anholt [Mon, 3 Feb 2014 23:02:16 +0000 (15:02 -0800)]
meta: Move the meta structures to the meta header.
I'd like to split some of our code to separate files, since 4k lines and
growing is pretty unreasonable for all these separate operations.
v2: Rebase on idr's changes.
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org> (v1)
Eric Anholt [Mon, 3 Feb 2014 23:58:03 +0000 (15:58 -0800)]
meta: Fold the texture setup into setup_copypix_texture().
There was this funny argument passed to setup for "did alloc decide we
need to allocate new texture storage?", which goes away if we don't have
the caller do alloc as a separate step.
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Eric Anholt [Wed, 5 Feb 2014 07:22:52 +0000 (23:22 -0800)]
meta: Drop the src == dst restriction on meta glBlitFramebuffer().
From the GL_ARB_fbo spec:
If the source and destination buffers are identical, and the
source and destination rectangles overlap, the result of the blit
operation is undefined.
As far as I know, that's the only thing that would have been of concern
for this.
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Eric Anholt [Tue, 4 Feb 2014 22:04:14 +0000 (14:04 -0800)]
mesa: Make TexImage error cases about internalFormat more informative.
I tripped over one of these when debugging meta, and it's a lot nicer to
just see the internalFormat being complained about.
v2: Drop a note in the other errors path that there is one early return.
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Eric Anholt [Wed, 12 Feb 2014 00:33:20 +0000 (16:33 -0800)]
meta: Rename the "sampler" stuff to "blit shader".
While these structs are generated per GLSL sampler type, they're structs
of data-about-shaders (notably, the ID of a shader program), not
data-about-samplers.
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Eric Anholt [Wed, 12 Feb 2014 00:19:29 +0000 (16:19 -0800)]
meta: Drop a now-trivial helper function.
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Eric Anholt [Wed, 12 Feb 2014 00:13:21 +0000 (16:13 -0800)]
meta: Fold the glUseProgram() into the blit program generator.
Everyone was just immediately calling it and doing nothing else with the
shader program id.
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Eric Anholt [Wed, 12 Feb 2014 00:08:51 +0000 (16:08 -0800)]
meta: Simplify the blit shader setup steps.
The only thing that wants to track the glsl_sampler structure is the
shader string generator.
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Francisco Jerez [Thu, 28 Nov 2013 06:21:45 +0000 (22:21 -0800)]
i965/vec4: Fix confusion between SWIZZLE and BRW_SWIZZLE macros.
Most of the VEC4 back-end agrees on src_reg::swizzle being one of the
BRW_SWIZZLE macros defined in brw_reg.h, except in two places where we
use Mesa's SWIZZLE macros. There is even a doxygen comment saying
that Mesa's macros are the right ones. They are incompatible swizzle
representations (3 bits vs. 2 bits per component), and the code using
Mesa's works by pure luck. Fix it.
Reviewed-by: Matt Turner <mattst88@gmail.com>
Reviewed-by: Paul Berry <stereotype441@gmail.com>
Francisco Jerez [Wed, 15 Jan 2014 21:21:50 +0000 (22:21 +0100)]
i965/fs: Remove fs_reg::sechalf.
The same effect can be achieved using ::subreg_offset. Remove the
less flexible alternative and define a convenience function to keep
the fs_reg interface sane.
Reviewed-by: Matt Turner <mattst88@gmail.com>
Reviewed-by: Paul Berry <stereotype441@gmail.com>
Francisco Jerez [Wed, 15 Jan 2014 21:21:30 +0000 (22:21 +0100)]
i965/fs: Remove fs_reg::smear.
The same effect can be achieved using a combination of ::stride and
::subreg_offset. Remove the less flexible ::smear to keep the data
members of fs_reg orthogonal.
Reviewed-by: Matt Turner <mattst88@gmail.com>
Reviewed-by: Paul Berry <stereotype441@gmail.com>