Chia-I Wu [Sat, 30 Aug 2014 23:22:01 +0000 (07:22 +0800)]
ilo: replace cmd by dw0 in GPE
With
e3c251071b0c9396c3ec76d1cf943c60ae297281, the magic values are gone. We
no longer need "cmd" to hide them. Replace it by dw0.
Alexander von Gluck IV [Fri, 29 Aug 2014 15:06:09 +0000 (15:06 +0000)]
st/hgl: Move st_visual create/destroy into hgl state_tracker
Alexander von Gluck IV [Fri, 29 Aug 2014 14:42:26 +0000 (14:42 +0000)]
st/hgl: Move st_manager create/destroy into hgl state_tracker
Rob Clark [Sat, 30 Aug 2014 20:51:46 +0000 (16:51 -0400)]
freedreno/ir3: fix potential null ptr deref
Fix potential segfault in debug code.
Signed-off-by: Rob Clark <robclark@freedesktop.org>
Rob Clark [Sat, 30 Aug 2014 19:17:49 +0000 (15:17 -0400)]
freedreno/ir3: add TXB
Signed-off-by: Rob Clark <robclark@freedesktop.org>
Rob Clark [Fri, 29 Aug 2014 14:51:40 +0000 (10:51 -0400)]
freedreno/ir3: detect scheduler fail
There are some cases where the scheduler can get itself into impossible
situations, by scheduling the wrong write to pred or addr register
first. (Ie. it could end up being unable to schedule any instruction if
some instruction which depends on the current addr/reg value also
depends on another addr/reg value.)
To solve this we'd need to be able to insert extra mov instructions
(which would also help when register assignment gets into impossible
situations). To do that, we'd need to move the nop padding from sched
into legalize.
But to start with, just detect when we get into an impossible situation
and bail, rather than sitting forever in an infinite loop. This way it
will at least fall back to the old compiler, which might even work if
you are lucky.
Signed-off-by: Rob Clark <robclark@freedesktop.org>
Ian Romanick [Mon, 14 Jul 2014 22:48:38 +0000 (15:48 -0700)]
glsl: Use bit-flags image attributes and uint16_t for the image format
All of the GL image enums fit in 16-bits.
Also move the fields from the anonymous "image" structucture to the next
higher structure. This will enable packing the bits with the other
bitfield.
Valgrind massif results for a trimmed apitrace of dota2:
n time(i) total(B) useful-heap(B) extra-heap(B) stacks(B)
Before (32-bit): 76 40,572,916,873 68,831,248 63,328,783 5,502,465 0
After (32-bit): 70 40,577,421,777 68,487,584 62,973,695 5,513,889 0
Before (64-bit): 60 36,822,640,058 96,526,824 88,735,296 7,791,528 0
After (64-bit): 74 37,124,603,758 95,891,808 88,466,712 7,425,096 0
A real savings of 346KiB on 32-bit and 262KiB on 64-bit.
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Ian Romanick [Mon, 14 Jul 2014 22:48:37 +0000 (15:48 -0700)]
glsl: Use a single bit for the dual-source blend index
The only values allowed are 0 and 1, and the value is checked before
assigning.
Valgrind massif results for a trimmed apitrace of dota2:
n time(i) total(B) useful-heap(B) extra-heap(B) stacks(B)
Before (32-bit): 74 40,580,119,657 69,186,544 63,506,327 5,680,217 0
After (32-bit): 76 40,572,916,873 68,831,248 63,328,783 5,502,465 0
Before (64-bit): 89 36,822,971,897 96,526,616 88,735,296 7,791,320 0
After (64-bit): 60 36,822,640,058 96,526,824 88,735,296 7,791,528 0
A real savings of 173KiB on 32-bit and no change on 64-bit.
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Ian Romanick [Mon, 14 Jul 2014 22:48:36 +0000 (15:48 -0700)]
glsl: Eliminate ir_variable::data.atomic.buffer_index
Just use ir_variable::data.binding... because that's the where the
binding is stored for everything else that can use layout(binding=).
Valgrind massif results for a trimmed apitrace of dota2:
n time(i) total(B) useful-heap(B) extra-heap(B) stacks(B)
Before (32-bit): 50 40,564,927,443 69,185,408 63,683,871 5,501,537 0
After (32-bit): 74 40,580,119,657 69,186,544 63,506,327 5,680,217 0
Before (64-bit): 59 36,822,048,449 96,526,888 89,113,000 7,413,888 0
After (64-bit): 89 36,822,971,897 96,526,616 88,735,296 7,791,320 0
A real savings of 173KiB on 32-bit and 368KiB on 64-bit.
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Kenneth Graunke [Thu, 28 Aug 2014 03:14:54 +0000 (20:14 -0700)]
mesa: Delete ctx->GeometryProgram.Cache.
The VertexProgram and FragmentProgram have a Cache member for dealing
with fixed function programs. There are no fixed function geometry
programs, so this should never have existed, and was just copy and
pasted.
Signed-off-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Eric Anholt <eric@anholt.net>
Roland Scheidegger [Fri, 29 Aug 2014 03:12:00 +0000 (05:12 +0200)]
gallivm: fix somewhat broken NaN behavior for exp2
I actually screwed that up in
754319490f6946a9ad5ee619822d5fe4254e6759,
mistakenly thinking the code actually wanted the non-nan result before.
So, introduce that missing nan behavior case and use that instead.
For sse, there's no actual change in the resulting code at all, the fallback
code wouldn't have done the right thing though.
Of course, the actual issue I saw with pow() was completely unrelated...
Reviewed-by: Jose Fonseca <jfonseca@vmware.com>
Roland Scheidegger [Thu, 28 Aug 2014 03:13:35 +0000 (05:13 +0200)]
softpipe: handle vertex texture sampling when using llvm for draw
Pretty trivial, just fill in the offsets and such. The implementation
is near 100% copy and paste from llvmpipe. Should be useful for debugging.
No piglit change when not using SOFTPIPE_USE_LLVM=1.
Now that it can do the same tests with and without using llvm for vs/gs,
with llvm more pass, the only things failing only with llvm seems to be
edgeflags tests and vs/gs-pow-float-float (and for the latter I'm not
convinced the zero tolerance it requires is somehow mandated by glsl).
Reviewed-by: Jose Fonseca <jfonseca@vmware.com>
Roland Scheidegger [Thu, 28 Aug 2014 01:38:55 +0000 (03:38 +0200)]
llvmpipe: (trivial) enable cube map arrays
The code is all in place now so enable it.
Seems to pass all relevant piglit tests (just like cube maps, some of the
cube map array tests need GALLIVM_DEBUG=no_quad_lod,no_rho_approx)
Reviewed-by: Jose Fonseca <jfonseca@vmware.com>
Roland Scheidegger [Fri, 29 Aug 2014 23:32:59 +0000 (01:32 +0200)]
gallivm: handle cube map arrays for texture sampling
Pretty easy, just make sure that all paths testing for PIPE_TEXTURE_CUBE
also recognize PIPE_TEXTURE_CUBE_ARRAY, and add the layer * 6 calculation
to the calculated face.
Also handle it for texture size query, looks like OpenGL wants the number
of cubes, not layers (so need division by 6).
No piglit regressions.
v2: fix up adding cube layer to face for seamless filtering (needs to happen
after calculating per-sample face). Undetected by piglit unfortunately.
Reviewed-by: Jose Fonseca <jfonseca@vmware.com> (v1)
Roland Scheidegger [Wed, 27 Aug 2014 23:06:11 +0000 (01:06 +0200)]
draw: kill off bogus assertion in tgsi_fetch_gs_outputs
Not sure why it was there but it is definitely not an error if gs outputs are
infs/nans. Besides, the outputs can be ints, in which case any small negative
number asserted.
This fixes piglit's texelFetch gs isamplerXX crashes with softpipe (down from
14 to 2).
Bug https://bugs.freedesktop.org/show_bug.cgi?id=80012
Reviewed-by: Jose Fonseca <jfonseca@vmware.com>
Roland Scheidegger [Wed, 27 Aug 2014 22:43:32 +0000 (00:43 +0200)]
softpipe: don't assert on illegal wrap mode for rect textures
piglit tex-miplevel-selection nowadays doesn't use repeat wrap mode due to
sampler objects any longer, however at the time of the clear the wrap mode
is still illegal and at this point we get to verify the state, including
samplers (even though they won't get used), and because mesa doesn't treat
it as an incomplete texture as the spec says it should, we hit the assertion.
Just warn about this for now instead.
Gets crashes down from 44 to 14 in a piglit run (all were in various tests of
tex-miplevel-selection with texture rectangles). Though just about all
tex-miplevel-selection tests fail anyway for other reasons.
Reviewed-by: Jose Fonseca <jfonseca@vmware.com>
Roland Scheidegger [Wed, 27 Aug 2014 22:41:05 +0000 (00:41 +0200)]
tgsi: (trivial) fix handling msaa resources on TXF
Just handle as ordinary 2d / 2d array resources. Prevents an assertion failure
with softpipe and piglit glsl-resource-not-bound 2DMS/2DMSArray tests.
While here also fix TXD shadowCube similarly, which fixes the crash with piglit
tex-miplevel-selection textureGrad CubeShadow (the test will still fail due to
softpipe being broken).
This fixes https://bugs.freedesktop.org/show_bug.cgi?id=80011
Reviewed-by: Jose Fonseca <jfonseca@vmware.com>
Roland Scheidegger [Tue, 26 Aug 2014 23:39:44 +0000 (01:39 +0200)]
draw: remove fishy num_samplers/num_sampler_views check in llvm path
This was meant for softpipe to not crash at some point if vertex texturing
was used. It is, however, fishy because it uses values from
draw_set_samplers/draw_set_sampler_views and not from the shader key. Albeit
we should still in all cases actually generate a new shader if this changes
(because the samplers and views themselves are in the key) I don't want to
think again wondering if that's really correct in the future.
Besides, at least today, it does not actually work for softpipe, as this was
relying on softpipe not actually calling draw_set_samplers/sampler_views at
all - I've verified it crashes regardless (if there were a tex instruction in
the vs, which normally should not happen anyway). For drivers which do indeed
not call these functions because they don't support vertex texturing at all
(r300), this should still not crash because the static texture data is all
zero, which causes the sampling functions to take an early out (same as is done
if no texture is bound at the slot used for sampling - verified with hacked up
softpipe).
Reviewed-by: Jose Fonseca <jfonseca@vmware.com>
Roland Scheidegger [Thu, 28 Aug 2014 13:54:52 +0000 (15:54 +0200)]
mesa: fix fallback texture for cube map array
mesa was creating a cube map array texture with just one layer, which is
not legal. This caused an assertion failure when using that texture later
in llvmpipe (when enabling cube map arrays) since it verifies the number
of layers in the view is divisible by 6 (the sampling code might well crash
randomly otherwise) with piglit glsl-resource-not-bound CubeArray -fbo -auto.
v2: use appropriately sized texel array...
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com> (v1)
Aaron Watry [Wed, 20 Aug 2014 23:24:00 +0000 (18:24 -0500)]
r600/compute: Don't leak compute pool item_list/unallocated_list
v3: Fix multi-line comment format
v2: Change to C-style comments and fix indentation
Signed-off-by: Aaron Watry <awatry@gmail.com>
Reviewed-by: Bruno Jiménez <brunojimen@gmail.com>
Michel Dänzer [Thu, 28 Aug 2014 02:12:20 +0000 (11:12 +0900)]
u_vbuf: Make sure all caps are initialized
Pointed out by valgrind.
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=83148
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Michel Dänzer [Fri, 29 Aug 2014 03:09:16 +0000 (12:09 +0900)]
r600g: Reinstate include path to common radeon source directory
Fixes build failure since commit
a131263a2f19507ca0d2f6093672d930a7c054d1
('gallium/radeon: cleanup header inclusion'):
../../../../../src/gallium/drivers/r600/evergreen_compute.c:50:30: fatal error: radeon_llvm_util.h: No such file or directory
#include "radeon_llvm_util.h"
^
compilation terminated.
Trivial.
Matt Turner [Thu, 28 Aug 2014 01:39:35 +0000 (18:39 -0700)]
i965: Mark BRW_CONDITIONAL_R as Gen <= 5.
Matt Turner [Tue, 26 Aug 2014 01:40:24 +0000 (18:40 -0700)]
i965/disasm: Show jump count for if/iff/halt.
These instructions don't have pop count.
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Matt Turner [Sun, 24 Aug 2014 06:59:30 +0000 (23:59 -0700)]
i965/disasm: Disassemble JMPI's source properly.
The source can be a register as well as an immediate, and disassembling
a register as an immediate can have some strange results.
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Matt Turner [Fri, 22 Aug 2014 00:01:15 +0000 (17:01 -0700)]
i965/disasm: Add break/cont/halt to list of has_uip().
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Matt Turner [Sun, 24 Aug 2014 21:49:51 +0000 (14:49 -0700)]
i965/disasm: Disassemble Z/NZ conditional modifiers as .z/.nz.
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Ilia Mirkin [Fri, 29 Aug 2014 01:52:13 +0000 (21:52 -0400)]
nouveau: allow more tokens by default to avoid parse failures
Also print a note saying that parsing failed to help isolate issues.
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
Emil Velikov [Thu, 28 Aug 2014 21:22:21 +0000 (22:22 +0100)]
targets/haiku-softpipe: explicitly prefix sw/hgl header
Cc: Alexander von Gluck IV <kallisti5@unixzen.com>
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Emil Velikov [Thu, 28 Aug 2014 21:22:20 +0000 (22:22 +0100)]
sw/hgl: struct haiku_displaytarget is not public struct
It is meant to be private within the actual winsys. Remove it from
the exported header, and fold it into it's only user.
Cc: Alexander von Gluck IV <kallisti5@unixzen.com>
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Emil Velikov [Thu, 28 Aug 2014 21:22:19 +0000 (22:22 +0100)]
include/haiku: fix comment typo
Cc: Alexander von Gluck IV <kallisti5@unixzen.com>
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Emil Velikov [Thu, 28 Aug 2014 20:54:20 +0000 (21:54 +0100)]
hgl: trivial bits
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Alexander von Gluck IV [Mon, 25 Aug 2014 21:26:15 +0000 (21:26 +0000)]
gallium/targets: Break haiku state_tracker out to own directory
Ack'ed by Emil Velikov <emil.l.velikov@gmail.com>
Alexander von Gluck IV [Mon, 25 Aug 2014 14:32:42 +0000 (14:32 +0000)]
gallium/targets: Haiku softpipe, perform better framebuffer validation
* Check for back left attachment as well
* Set and act on pipe format none
Ack'ed by Emil Velikov <emil.l.velikov@gmail.com>
Emil Velikov [Mon, 18 Aug 2014 22:41:45 +0000 (23:41 +0100)]
st/egl: ship all the files in the tarball
Namely we were missing the headers and the Android/SCons buildscripts.
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Emil Velikov [Mon, 18 Aug 2014 22:16:24 +0000 (23:16 +0100)]
st/clover: sort the sources list
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Emil Velikov [Mon, 18 Aug 2014 00:17:30 +0000 (01:17 +0100)]
st/gbm: include the header in the sources list
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Emil Velikov [Sun, 17 Aug 2014 23:54:38 +0000 (00:54 +0100)]
st/xlib: Include the headers in the sources list.
Yet another step towards a working 'make dist'.
Cc: José Fonseca <jfonseca@vmware.com>
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Acked-by: José Fonseca <jfonseca@vmware.com>
Emil Velikov [Sun, 17 Aug 2014 23:51:07 +0000 (00:51 +0100)]
st/omx: use makefile.sources to handle sources lists
... and add the headers so that 'make check' is happy.
Cc: Christian König <christian.koenig@amd.com>
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Emil Velikov [Sun, 17 Aug 2014 23:47:38 +0000 (00:47 +0100)]
st/vdpau: pickup/ship the private header
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Emil Velikov [Mon, 18 Aug 2014 15:56:48 +0000 (16:56 +0100)]
st/vdpau: remove obsolete define VL_HANDLES
This define is always set and it had no real purpose according to
git log. Seems like it is a leftover from the vl/vdpau prototype
stage.
Cc: Christian König <christian.koenig@amd.com>
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Emil Velikov [Sun, 17 Aug 2014 23:43:16 +0000 (00:43 +0100)]
st/vega: add headers and SConscript in the tarball
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Emil Velikov [Sun, 17 Aug 2014 23:08:26 +0000 (00:08 +0100)]
st/xa: add remaining files in the tarball
Namely
- the private header (xa_priv.h)
- README and
- xa-indent
Sort the sources list while we're here.
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Emil Velikov [Sun, 17 Aug 2014 23:02:07 +0000 (00:02 +0100)]
st/xvmc: pick up the headers for distribution
- autotools/make will pick them up in the tarball.
- Sort the list alphabetically.
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Emil Velikov [Sun, 17 Aug 2014 22:56:19 +0000 (23:56 +0100)]
Revert "configure: Disable xvmc by default"
This reverts commit
6a19bb56e09e841553ad1295f74fa21bfbbe752a.
The above commit disabled the default build of xvmc as the xvmc tests
were failing. As pointed out by Ilia, the tests are "broken by design"
as they do not test the object that is build but the one that is
installed and setup on the workstation.
With previous commit we moved the programs from the 'make check' to
noinst automake target. This way they won't be run but will be around
for people to use them.
Cc: Tom Stellard <thomas.stellard@amd.com>
Emil Velikov [Sun, 17 Aug 2014 22:55:48 +0000 (23:55 +0100)]
st/xvmc: automake: move tests to noinst
All the tests require an installed and setup XvMC, thus they
are not good candidates for 'make check'.
Keep them around as the user might want to actually test the
implementation post installation/setup.
Cc: Ilia Mirkin <imirkin@alum.mit.edu>
Cc: Tom Stellard <thomas.stellard@amd.com>
Cc: Christian König <christian.koenig@amd.com>
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Emil Velikov [Sun, 17 Aug 2014 22:29:56 +0000 (23:29 +0100)]
winsys/sw: add the final files to the tarball
Add the final remaining files into the tarball (make dist), namely:
- SConscripts
- Non-autotooled winsys' - android, gdi and hgl.
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Emil Velikov [Sun, 17 Aug 2014 19:15:07 +0000 (20:15 +0100)]
winsys/sw: automake: consistently use Makefile.sources
- Include the headers within.
- Update scons to use them.
- Drop useless include (gallium/drivers) from scons.
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Emil Velikov [Sat, 16 Aug 2014 19:42:00 +0000 (20:42 +0100)]
winsys/$(hw): ship the Android/SCons scripts in the tarball
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Emil Velikov [Fri, 15 Aug 2014 22:40:48 +0000 (23:40 +0100)]
winsys/$(hw): include headers in Makefile.sources
Otherwise 'make dist' will not pick them up :'(
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Emil Velikov [Mon, 18 Aug 2014 22:50:06 +0000 (23:50 +0100)]
st/egl: cleanup sw winsys header inclusions
- Drop duplicate include compiler directives.
- Leave the sw/ prefix for all the software winsys headers.
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Emil Velikov [Fri, 15 Aug 2014 22:07:01 +0000 (23:07 +0100)]
winsys/radeon: move radeon_cs_dump.h to drm
... to ease packaging (make dist).
Update it to fetch libdrm's include/libs via pkg-config.
Cc: Marek Olšák <marek.olsak@amd.com>
Cc: Michel Dänzer <michel.daenzer@amd.com>
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Emil Velikov [Sat, 16 Aug 2014 16:58:25 +0000 (17:58 +0100)]
gallium/radeon: cleanup header inclusion
- Add top_srcdir/src/gallium/winsys to GALLIUM_DRIVER_C{XXFLAGS}.
- Remove top_srcdir/src/gallium/drivers/radeon from the includes.
As a result:
- Common radeon headers are prefixed with 'radeon/'
- Winsys header inclusion is prefixed 'radeon/drm'
Cc: Marek Olšák <marek.olsak@amd.com>
Cc: Michel Dänzer <michel.daenzer@amd.com>
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Emil Velikov [Sat, 16 Aug 2014 19:37:30 +0000 (20:37 +0100)]
winsys/svga: build: cleanup the includes
gallium/drivers is already part fo GALLIUM_WINSYS_CFLAGS.
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Emil Velikov [Sat, 16 Aug 2014 18:49:28 +0000 (19:49 +0100)]
winsys/i915: remove the software winsys
We stopped building it recently as it was unused and not tested.
Good bye, it's been nice knowing you :)
Cc: Stephane Marchesin <stephane.marchesin@gmail.com>
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Acked-by: Stephane Marchesin <stephane.marchesin@gmail.com>
Emil Velikov [Sat, 16 Aug 2014 18:34:10 +0000 (19:34 +0100)]
gallium/ilo: cleanup intel_winsys.h
Make the header location, inclusion and contents more common with
its i915,r* and nouveau counterparts:
- Move the header within drivers/ilo.
- Separate out intel_winsys_create_for_fd into 'drm_public' header.
- Cleanup the compiler includes.
v2: Move the header to drivers/ilo. Suggested by Chia-I.
v3: Correct intel_winsys.h inclusion. Spotted by Chia-I.
Cc: Chia-I Wu <olvaffe@gmail.com>
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Reviewed-by: Chia-I Wu <olvaffe@gmail.com>
Timothy Arceri [Thu, 14 Aug 2014 21:45:50 +0000 (07:45 +1000)]
docs: mark GL_MAX_VERTEX_ATTRIB_STRIDE as done
Signed-off-by: Timothy Arceri <t_arceri@yahoo.com.au>
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Timothy Arceri [Wed, 20 Aug 2014 07:09:58 +0000 (21:09 -1000)]
gallium: add cap for MAX_VERTEX_ATTRIB_STRIDE
Signed-off-by: Timothy Arceri <t_arceri@yahoo.com.au>
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Timothy Arceri [Thu, 14 Aug 2014 14:16:09 +0000 (00:16 +1000)]
mesa: implement GL_MAX_VERTEX_ATTRIB_STRIDE
V2: moved test for the VertexAttrib*Pointer() functions
to update_array(), and made constant available for drivers to set
Signed-off-by: Timothy Arceri <t_arceri@yahoo.com.au>
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Michel Dänzer [Thu, 28 Aug 2014 03:05:21 +0000 (12:05 +0900)]
st/clover: Fix build against LLVM SVN >= r216583
Reviewed-by: Francisco Jerez <currojerez@riseup.net>
Roland Scheidegger [Mon, 25 Aug 2014 20:05:16 +0000 (22:05 +0200)]
draw: fix base instance handling in llvm path
The base instance needs to be passed to the jited function, otherwise the
instanced data fetch will only work with the same start instance when the
jit function was created (and baking that into the key instead is not a viable
option).
This fixes piglit arb_base_instance-drawarrays (modulo some unrelated
core/compat context trouble I get for the test).
And fix the pipe cap bit in llvmpipe for it now that it actually works (it
already worked for softpipe).
Reviewed-by: Jose Fonseca <jfonseca@vmware.com>
Roland Scheidegger [Mon, 25 Aug 2014 16:21:53 +0000 (18:21 +0200)]
docs: fix up status of softpipe, llvmpipe
The docs were never really up to date for them, missing just about everything.
So mark them off as all done for GL 3.3 (though softpipe is in fact quite
broken for some newer things especially wrt texturing, and both don't have
compliant, real msaa support). And add the extensions missing too (no
guarantee of completeness).
Reviewed-by: Dave Airlie <airlied@gmail.com>
Alexander von Gluck IV [Wed, 27 Aug 2014 20:37:46 +0000 (20:37 +0000)]
glsl: Add strings.h on non-MSC platforms
* IEEE Std 1003.1-2001 placed strcasecmp() in strings.h.
* ISO C99 doesn't mention strcase* in string.h
* On all platforms I could find, strcasecmp is in strings.h and string.h
as a compatibility layer for software written pre-2001 POSIX
* Technically strcasecmp should be only in strings.h and the man
pages back this up.
* Tested build on CentOS and Haiku
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Alex Deucher [Wed, 27 Aug 2014 03:08:07 +0000 (23:08 -0400)]
radeon/uvd: remove comment about RV770
It doesn't seem to support field based decode after testing.
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Christian König [Sun, 24 Aug 2014 10:22:08 +0000 (12:22 +0200)]
radeon/uvd: fix field handling on R6XX style UVD
The first UVD generation can only do frame based output.
Signed-off-by: Christian König <christian.koenig@amd.com>
Christian König [Wed, 13 Aug 2014 19:01:33 +0000 (21:01 +0200)]
vl/compositor: set the scissor before clearing the render target
Otherwise we clear areas that shouldn't be cleared.
Signed-off-by: Christian König <christian.koenig@amd.com>
Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu>
Cc: mesa-stable@lists.freedesktop.org
Christian König [Wed, 13 Aug 2014 18:21:06 +0000 (20:21 +0200)]
st/vdpau: fix vlVdpOutputSurfaceRender(Output|Bitmap)Surface
Correctly handle that the source_surface is only optional.
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=80561
Signed-off-by: Christian König <christian.koenig@amd.com>
Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu>
Cc: mesa-stable@lists.freedesktop.org
Chia-I Wu [Thu, 21 Aug 2014 04:51:08 +0000 (12:51 +0800)]
ilo: use genhw command opcodes
Replace ILO_GPE_MI and ILO_GPE_CMD with magic values by descriptive genhw
macros.
Chia-I Wu [Tue, 26 Aug 2014 05:41:11 +0000 (13:41 +0800)]
ilo: rename intel_bo_map_unsynchronized()
Rename it to intel_bo_map_gtt_async().
Chia-I Wu [Tue, 26 Aug 2014 05:31:29 +0000 (13:31 +0800)]
ilo: remove max_batch_size
It is used to derive an artificial limit on max relocs per bo. We choose not
to export it anymore.
Chia-I Wu [Tue, 26 Aug 2014 04:36:33 +0000 (12:36 +0800)]
ilo: replace domains by reloc flags
It is simpler and is supported by the kernel. It cannot be used with
libdrm_intel yet though.
Chris Forbes [Mon, 25 Aug 2014 19:51:11 +0000 (07:51 +1200)]
docs: Update who is working on tessellation
Signed-off-by: Chris Forbes <chrisf@ijw.co.nz>
Chris Forbes [Fri, 22 Aug 2014 08:59:42 +0000 (20:59 +1200)]
glsl: Remove bogus "OUPTUT" token
This is never used. There is another token "OUTPUT" which the lexer can
generate, though. This has been around since the dawn of time; is most
likely a typo.
Signed-off-by: Chris Forbes <chrisf@ijw.co.nz>
Marek Olšák [Sat, 23 Aug 2014 09:19:29 +0000 (11:19 +0200)]
radeonsi: handle PIPE_BIND_BLENDABLE
Reviewed-by: Michel Dänzer <michel.daenzer@amd.com>
Marek Olšák [Sat, 23 Aug 2014 09:18:43 +0000 (11:18 +0200)]
r600g: only set PIPE_BIND_BLENDABLE if colorbuffer rendering is supported
Reviewed-by: Michel Dänzer <michel.daenzer@amd.com>
Marek Olšák [Fri, 22 Aug 2014 17:49:00 +0000 (19:49 +0200)]
r300g: handle PIPE_BIND_BLENDABLE
Reviewed-by: Michel Dänzer <michel.daenzer@amd.com>
Eric Anholt [Mon, 25 Aug 2014 00:58:24 +0000 (17:58 -0700)]
vc4: Stop doing qpu_inst(add, NOP) or qpu_inst(NOP, mul).
Now that the extra WADDR is set, we can knock this off. Saves a lot of
typing, and makes this code much more legible.
Eric Anholt [Mon, 25 Aug 2014 00:53:00 +0000 (17:53 -0700)]
vc4: Set the other WADDR in the qpu instruction helpers.
Now you don't need to qpu_inst() your instruction with a NOP to get the
other waddr set.
Eric Anholt [Mon, 25 Aug 2014 00:47:02 +0000 (17:47 -0700)]
vc4: Merge qpu_a_NOP() and qpu_m_NOP to a single qpu_NOP() helper.
Now that qpu_inst() ignores the WADDR from the other half of the
instruction, we can set both the ADD and MUL WADDRs in the NOP helper.
Thanks to that, we also no longer need to qpu_inst(NOP, NOP).
Eric Anholt [Mon, 25 Aug 2014 00:43:02 +0000 (17:43 -0700)]
vc4: Ignore WADDRs from the other half of the instruction when merging.
This allows setting the opposite-side WADDR to NOP (a non-zero value) in
qpu_* helpers, so that we don't need to qpu_inst() merge them with NOPs
all the time just to get the waddr set.
Eric Anholt [Sun, 24 Aug 2014 21:41:06 +0000 (14:41 -0700)]
vc4: Fix LT/GE set-0-or-1 compares.
We were using the integer sub, which worked for the common case of EQ and
NE. Fixes fs-lessThan-ivec2-ivec2 and other tests.
Eric Anholt [Fri, 22 Aug 2014 17:50:15 +0000 (10:50 -0700)]
u_vbuf: Add a few more format fallbacks.
Fixes piglit draw-vertices and gl-2.0-vertexattribpointer on vc4, where
I'm only advertising R32F to RGBA32F support so far.
Note: regresses gl-1.5-normal3b3s-invariance due to introduced flushes and
missing depth buffer load/store support in the driver.
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Eric Anholt [Fri, 22 Aug 2014 17:34:55 +0000 (10:34 -0700)]
u_vbuf: Simplify the format fallback translation.
Individual caps made supporting new fallbacks more complicated than it
needed to be. Instead, just make a table of fallbacks at context init
time.
v2: Fix inverted "do we need to install vbuf?" flagging caught by Marek.
Reviewed-by: Marek Olšák <marek.olsak@amd.com> (v2)
Rob Clark [Sun, 24 Aug 2014 17:06:37 +0000 (13:06 -0400)]
freedreno/a2xx: fix segfault
Signed-off-by: Rob Clark <robclark@freedesktop.org>
Rob Clark [Sat, 23 Aug 2014 15:35:31 +0000 (11:35 -0400)]
freedreno/a3xx: handle first/last level properly
Fixes some assumptions about first_level being zero.
Signed-off-by: Rob Clark <robclark@freedesktop.org>
Rob Clark [Sat, 23 Aug 2014 13:33:50 +0000 (09:33 -0400)]
freedreno: implement pipe_flush_resource()
Signed-off-by: Rob Clark <robclark@freedesktop.org>
Rob Clark [Fri, 22 Aug 2014 22:33:15 +0000 (18:33 -0400)]
freedreno: don't ignore src/dst level
Don't ignore src/dst_level in pipe_copy_region.
Signed-off-by: Rob Clark <robclark@freedesktop.org>
Eric Anholt [Fri, 22 Aug 2014 23:49:02 +0000 (16:49 -0700)]
vc4: Fix save/restore of the VS/FS in the blitter.
When I made the shader cache take the .fs member and moved the binding
point to .bind_fs, I failed to update these. Fixes crashes in
copyteximage-related tests.
Eric Anholt [Fri, 22 Aug 2014 23:36:29 +0000 (16:36 -0700)]
vc4: Clear padding of ioctl arguments.
Fixes valgrind complaints from valgrind being unaware of our ioctls.
Vinson Lee [Fri, 22 Aug 2014 17:18:40 +0000 (10:18 -0700)]
auxilary/os: Add Solaris support in os_get_total_physical_memory.
The patch fixes the build on Oracle Solaris.
CC os/os_misc.lo
"os/os_misc.c", line 59: #error: unexpected platform in os_sysinfo.c
Signed-off-by: Vinson Lee <vlee@freedesktop.org>
Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com>
Alexander von Gluck IV [Thu, 21 Aug 2014 20:00:59 +0000 (20:00 +0000)]
gallium/targets: Haiku, Fix some improper type warnings
Alexander von Gluck IV [Thu, 21 Aug 2014 19:53:02 +0000 (19:53 +0000)]
gallium/targets: Clean up Haiku softpipe renderer visual
* Drop creating gl_config first as it's only really used
to create the state tracker visual.
Carl Worth [Mon, 18 Aug 2014 18:36:12 +0000 (11:36 -0700)]
glcpp: Don't use alternation in the lookahead for empty pragmas.
We've found that there's a buffer overrun bug in flex that's triggered by
using alternation in a lookahead pattern.
Fortunately, we don't need to match the exact {NEWLINE} expression to
detect an empty pragma. It suffices to verify that there are no non-space
characters before any newline character. So we can use a simple [\r\n] to
get the desired behavior while avoiding the flex bug.
Fixes the regression of piglit's 17000-consecutive-chars-identifier test,
(which has been crashing since commit
04e40fd337a244ee77ef9553985e9398ff0344af ).
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=82472
Signed-off-by: Carl Worth <cworth@cworth.org>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
CC: <mesa-stable@lists.freedesktop.org>
Kenneth Graunke [Sat, 16 Aug 2014 22:18:21 +0000 (15:18 -0700)]
i965: Disable try_emit_b2f_of_compare on Gen4-6.
The optimization relies on CMP setting the destination to 0, which is
equivalent to 0.0f. However, early platforms only set the least
significant byte, leaving the other bits undefined. So, we must disable
the optimization on those platforms.
Oddly, Sandybridge wasn't reported as broken. The PRM states that it
only sets the LSB, but the internal documentation says that it follows
the IVB behavior. Since it wasn't reported as broken, we believe it
really does follow the IVB behavior.
v2: Allow the optimization on Sandybridge (requested by Matt).
+32 piglits on Ironlake.
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?=79963
Signed-off-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Chris Forbes <chrisf@ijw.co.nz>
Reviewed-by: Matt Turner <mattst88@gmail.com>
Matt Turner [Thu, 17 Jul 2014 17:50:31 +0000 (10:50 -0700)]
i965/fs: Preserve CFG in predicated break pass.
Operating on this code,
B0: ...
cmp.ne.f0(8)
(+f0) if(8)
B1: break(8)
B2: endif(8)
We can delete B2 without attempting to merge any blocks, since the
break/continue instruction necessarily ends the previous block.
After deleting the if instruction, we attempt to merge blocks B0 and B1.
Reviewed-by: Topi Pohjolainen <topi.pohjolainen@intel.com>
Matt Turner [Thu, 17 Jul 2014 18:14:02 +0000 (11:14 -0700)]
i965/fs: Rename variable in predicated break pass.
Reviewed-by: Topi Pohjolainen <topi.pohjolainen@intel.com>
Matt Turner [Thu, 17 Jul 2014 04:51:19 +0000 (21:51 -0700)]
i965/fs: Preserve CFG in the SEL peephole.
Reviewed-by: Topi Pohjolainen <topi.pohjolainen@intel.com>
Matt Turner [Wed, 16 Jul 2014 22:29:41 +0000 (15:29 -0700)]
i965: Preserve CFG when deleting dead control flow.
This pass deletes an IF/ELSE/ENDIF or IF/ENDIF sequence, or the ELSE in
an ELSE/ENDIF sequence.
In the typical case (where IF and ENDIF) aren't the only instructions in
their basic blocks, we can simply remove the instructions (implicitly
deleting the block containing only the ELSE), and attempt to merge
blocks B0 and B2 together.
B0: ...
(+f0) if(8)
B1: else(8)
B2: endif(8)
...
If the IF or ENDIF instructions are the only instructions in their
respective basic blocks (which are deleted by the removal of the
instructions), we'll want to instead merge the next blocks.
Both B0 and B2 are possibly removed by the removal of if & endif.
Same situation for if/endif. E.g., in the following example we'd remove
blocks B1 and B2, and then attempt to combine B0 and B3.
B0: ...
B1: (+f0) if(8)
B2: endif(8)
B3: ...
Reviewed-by: Topi Pohjolainen <topi.pohjolainen@intel.com>
Matt Turner [Tue, 15 Jul 2014 21:51:43 +0000 (14:51 -0700)]
i965/cfg: Add functions to combine basic blocks.
Reviewed-by: Topi Pohjolainen <topi.pohjolainen@intel.com>
Matt Turner [Wed, 16 Jul 2014 22:20:15 +0000 (15:20 -0700)]
i965/cfg: Point to bblock_t containing associated control flow
... rather than pointing directly to the associated instruction. This
will let us set the block containing the IF statement's else-pointer to
NULL, when we delete a useless ELSE instruction, as in the case
(+f0) if(8)
...
else(8)
endif(8)
Also, remove the pointer to the ENDIF, since it's unused, and it was
also potentially wrong, in the case of a basic block containing both an
ENDIF and an IF instruction:
endif(8)
cmp.ne.f0(8) ...
(+f0) if(8)
Reviewed-by: Topi Pohjolainen <topi.pohjolainen@intel.com>