summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2014-05-05mesa: Add missing types in _mesa_texstore_xx_xx() functionsAnuj Phogat1-2/+6
Depth-stencil teture targets are allowed to use source data of type GL_UNSIGNED_INT_24_8_EXT and GL_FLOAT_32_UNSIGNED_INT_24_8_REV. Fixes few crashes in Khronos OpenGL CTS packed_pixels tests. Cc: <mesa-stable@lists.freedesktop.org> Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com> (cherry picked from commit aeb9d4495dc32bcb457045b4ea8f4e5f0d4fc8c8)
2014-05-05i965: Fix crash in do_blit_readpixels()Anuj Phogat1-0/+7
Fixes a crash in Khronos CTS packed_pixels tests. Cc: <mesa-stable@lists.freedesktop.org> Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com> (cherry picked from commit d714b20eb4617f24b496a09028a90fdd8c19b5bd)
2014-05-05mesa: Add error condition for format=STENCIL_INDEX in glGetTexImage()Anuj Phogat1-0/+5
From OpenGL 4.0 spec, page 306: "Calling GetTexImage with a format of STENCIL_INDEX causes the error INVALID_ENUM." Cc: <mesa-stable@lists.freedesktop.org> Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com> (cherry picked from commit 5388fc157e2b78d67a05dc923b98857e6449cf1e)
2014-05-05mesa: Add entry for extension ARB_texture_stencil8Anuj Phogat1-0/+1
V2: Alphabetize the new entry Cc: <mesa-stable@lists.freedesktop.org> Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com> (cherry picked from commit 340658e44f87c98e840b98029c9b5a81d1bed837)
2014-05-05glsl: Compile error if fs uses gl_FragCoord before first redeclarationAnuj Phogat1-0/+17
Section 4.3.8.1, page 39 of GLSL 1.50 spec says: "Within any shader, the first redeclarations of gl_FragCoord must appear before any use of gl_FragCoord." GLSL compiler should generate an error in following case: vec4 p = gl_FragCoord; layout(origin_upper_left) in vec4 gl_FragCoord; void main() { } Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com> Cc: <mesa-stable@lists.freedesktop.org> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com> (cherry picked from commit a751adf07117ec4b3659fe60d0a833ebfcd4f840)
2014-05-05glsl: Compile error if fs defines conflicting qualifiers for gl_FragCoordAnuj Phogat2-0/+70
GLSL 1.50 spec says: "If gl_FragCoord is redeclared in any fragment shader in a program, it must be redeclared in all the fragment shaders in that program that have a static use gl_FragCoord. All redeclarations of gl_FragCoord in all fragment shaders in a single program must have the same set of qualifiers." This patch makes the glsl compiler to generate an error if we have a fragment shader defined with conflicting layout qualifier declarations for gl_FragCoord. For example: layout(origin_upper_left, pixel_center_integer) in vec4 gl_FragCoord; layout(pixel_center_integer) in vec4 gl_FragCoord; void main() { } V2: Some code refactoring for better readability. Add compiler error conditions for redeclarations like: layout(origin_upper_left) in vec4 gl_FragCoord; layout(origin_upper_left, pixel_center_integer) in vec4 gl_FragCoord; and in vec4 gl_FragCoord; layout(origin_upper_left, pixel_center_integer) in vec4 gl_FragCoord; V3: Simplify function is_conflicting_fragcoord_redeclaration() V4: Check for null pointer before doing strcmp(var->name, "gl_FragCoord"). Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com> Cc: <mesa-stable@lists.freedesktop.org> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com> (cherry picked from commit 581e4acb0d68eb1063df3919e19e0ef9d86eebff)
2014-05-05mesa: Use location VERT_ATTRIB_GENERIC0 for vertex attribute 0Anuj Phogat3-29/+40
In OpenGL 3.1 attribute 0 becomes non-magic, just like in OpenGL ES 2.0. Earlier versions of OpenGL used attribute 0 exclusively for vertex position. V2: Add a utility function _mesa_attr_zero_aliases_vertex() in varray.h Fixes 4 Khronos OpenGL CTS failures: glGetVertexAttrib depth24_basic depth24_precision rgb8_rgba8_rgb Cc: <mesa-stable@lists.freedesktop.org> Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com> (cherry picked from commit 49c71050de1e0df451e29621558b4adfefb7e098)
2014-05-05mesa: Fix querying location of nth element of an array variableAnuj Phogat1-5/+66
This patch makes changes to the behavior of glGetAttribLocation(), glGetFragDataLocation() and glGetFragDataIndex() functions. Code changes handle a case described in following example: shader program: layout(location = 1)in vec4[4] a; void main() { } Currently, glGetAttribLocation("a") returns 1. glGetAttribLocation("a[i]"), where i = {0, 1, 2, 3}, returns -1. But the expected locations for array elements are: 1, 2, 3 and 4 respectively. This clarification came up with the addition of ARB_program_interface_query to OpenGL 4.3. From Page 326 (page 347 of the PDF) of OpenGL 4.3 spec: "Otherwise, the command is equivalent to GetProgramResourceLocation(program, PROGRAM_INPUT, name);" And, From Page 101 (page 122 of the PDF) of OpenGL 4.3 spec: "A string provided to GetProgramResourceLocation or GetProgramResourceLocationIndex is considered to match an active variable if • the string exactly matches the name of the active variable; • if the string identifies the base name of an active array, where the string would exactly match the name of the variable if the suffix "[0]" were appended to the string; or • if the string identifies an active element of the array, where the string ends with the concatenation of the "[" character, an integer (with no "+" sign, extra leading zeroes, or whitespace) identifying an array element, and the "]" character, the integer is less than the number of active elements of the array variable, and where the string would exactly match the enumerated name of the array if the decimal integer were replaced with zero." V2: Simplify get_matching_index() function. Add relevant text from OpenGL spec in commit message. Fixes failures in Khronos OpenGL CTS tests: explicit_attrib_location_room draw_instanced_max_vertex_attribs Proprietary linux drivers of NVIDIA (331.49) matches the behavior expected by OpenGL 4.3 spec. Cc: <mesa-stable@lists.freedesktop.org> Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com> (cherry picked from commit dc75479b7a7b9207d9d7c9487085ad14fa5d26cc)
2014-05-05glsl: Allow overlapping locations for vertex input attributesAnuj Phogat1-15/+72
Currently overlapping locations of input variables are not allowed for all the shader types in OpenGL and OpenGL ES. From OpenGL ES 3.0 spec, page 56: "Binding more than one attribute name to the same location is referred to as aliasing, and is not permitted in OpenGL ES Shading Language 3.00 vertex shaders. LinkProgram will fail when this condition exists. However, aliasing is possible in OpenGL ES Shading Language 1.00 vertex shaders." Taking in to account what different versions of OpenGL and OpenGL ES specs say about aliasing: - It is allowed only on vertex shader input attributes in OpenGL (2.0 and above) and OpenGL ES 2.0. - It is explictly disallowed in OpenGL ES 3.0. Fixes Khronos CTS failing test: explicit_attrib_location_vertex_input_aliased.test See more details about this at below mentioned khronos bug. V2: Fix the case where location exceeds the maximum allowed attribute location. V3: Simplify the condition added in V2. Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com> Cc: "9.2 10.0 10.1" <mesa-stable@lists.freedesktop.org> Bugzilla: Khronos #9609 Reviewed-by: Ian Romanick <ian.d.romanick@intel.com> (cherry picked from commit 8c61b6a99b221439a8109c5a5cd03b7bf065d373)
2014-05-05i965: Actually emit PIPELINE_SELECT and 3DSTATE_VF_STATISTICS.Kenneth Graunke3-15/+8
For platforms using hardware contexts (currently Gen6+), we failed to emit PIPELINE_SELECT and 3DSTATE_VF_STATISTICS, instead emitting MI_NOOP for both. During one of the context initialization reordering patches, we accidentally moved brw_init_state before we set brw->CMD_PIPELINE_SELECT and brw->CMD_VF_STATISTICS. So, when brw_init_state uploaded initial GPU state (brw_init_state -> brw_upload_initial_gpu_state -> brw_upload_invariant_state), these would be 0 (MI_NOOP). Storing the commands in the context is not worthwhile. We have many generation checks in our state upload code, and for platforms with hardware contexts, this only gets called once per GL context anyway. The cost is negligable, and it's easy to botch context creation ordering. This may fix hangs on Gen6+ when using the media pipeline. Cc: "10.0 10.1" <mesa-stable@lists.freedesktop.org> Signed-off-by: Kenneth Graunke <kenneth@whitecape.org> Reviewed-by: Eric Anholt <eric@anholt.net> Reviewed-by: Ben Widawsky <ben@bwidawsk.net> (cherry picked from commit ac30e1adb49ec6947f740b47d90f8403fe416314) Conflicts: src/mesa/drivers/dri/i965/brw_context.h
2014-05-05i965: Don't enable reset notification support on Gen4-5.Kenneth Graunke1-4/+9
arekm reported that using Chrome with GPU acceleration enabled on GM45 triggered the hw_ctx != NULL assertion in brw_get_graphics_reset_status. We definitely do not want to advertise reset notification support on Gen4-5 systems, since it needs hardware contexts, and we never even request a hardware context on those systems. Cc: "10.1" <mesa-stable@lists.freedesktop.org> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=75723 Signed-off-by: Kenneth Graunke <kenneth@whitecape.org> (cherry picked from commit 0380ec467d78f40b5c8134158ca48b4c5378b282)
2014-05-05i965: Fix render-to-texture in non-FinishRenderTexture cases.Eric Anholt7-27/+87
We've had several problems now with FinishRenderTexture not getting called enough, and we're ready to just give up on it ever doing what we need. In particular, an upcoming Steam title had rendering bugs that could be fixed by always_flush_cache=true. Instead of hoping Mesa core can figure out when we need to flush our caches, just track what BOs we've rendered to in a set, and when we render from a BO in that set, emit a flush and clear the set. There's some overhead to keeping this set, but most of that is just hashing the pointer -- it turns out our set never even gets very large, because cache flushes are so common (even on cairo-gl). No statistically significant performance difference in cairo-gl (n=100), despite spending ~.5% CPU in these set operations. v1: (Original patch by Eric Anholt.) v2: (Changes by Ken Graunke.) - Rebase forward from May 7th 2013 -> March 4th 2014. - Drop the FinishRenderTexture hook entirely; after rebasing the patch, the hook was just an empty function. - Move the brw_render_cache_set_clear() call from intel_batchbuffer_emit_flush() to brw_emit_pipe_control_flush(). In theory, this could catch more cases where we've flushed. - Consider stencil as a possible texturing source. v3: (changes by anholt): - Move set_clear() back to emit_mi_flush() -- it means we can drop more forced flushes from the code. In the previous location, it wouldn't have been called when we wanted pre-gen6. - Move the set clear from batch init to reset -- it should be empty at the start of every batch, since the kernel handled any inter-batch flush for us. v4: Drop the debug code in set.c that I accidentally committed. v5: Back port to 10.1 stable branch (remove reference to stencil texture.) Signed-off-by: Eric Anholt <eric@anholt.net> Signed-off-by: Kenneth Graunke <kenneth@whitecape.org> Reviewed-by: Kenneth Graunke <kenneth@whitecape.org> Tested-by: Dylan Baker <baker.dylan.c@gmail.com> [v2] Conflicts: src/mesa/drivers/dri/i965/brw_draw.c src/mesa/drivers/dri/i965/intel_fbo.h
2014-05-05cherry-ignore: Ignore a patch causing a regressionCarl Worth1-0/+4
This may be just a bogus test. I'm waiting to see what the bugzilla decides: https://bugs.freedesktop.org/show_bug.cgi?id=77702
2014-05-05st/mesa: Fix NULL pointer dereference for incomplete framebuffersMichel Dänzer1-1/+6
This can happen with glamor, which uses EGL_KHR_surfaceless_context and only explicitly binds GL_READ_FRAMEBUFFER for glReadPixels. Cc: mesa-stable@lists.freedesktop.org Reviewed-by: Brian Paul <brianp@vmware.com> (cherry picked from commit 136c437cea3ebc9541735bb40951128e1210f06b)
2014-05-05egl: Protect use of gbm_dri with ifdef HAVE_DRM_PLATFORMAnder Conselvan de Oliveira1-0/+2
Otherwise it fails to compile if the drm egl platform is disabled. Cc: "10.0" "10.1" <mesa-stable@lists.freedesktop.org> Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com> (cherry picked from commit 17860309f17de78e729f77e86101004f61f6bcf3)
2014-05-05wayland: Fix the logic in disabling the prime capabilityNeil Roberts1-1/+1
It looks like this bit of code is trying to disable the prime capability if the driver doesn't support createImageFromFds. However the logic looks a bit broken and what it would actually do is disable all other capabilities apart from prime. This patch fixes it to actually disable prime. Cc: "10.0" "10.1" <mesa-stable@lists.freedesktop.org> Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com> (cherry picked from commit 63d4661ab28c036ab000f94812a91d93d538a72a)
2014-05-05gbm/dri: Fix out-of-memory error path in dri_device_create()Ander Conselvan de Oliveira1-0/+2
Cc: "10.0" "10.1" <mesa-stable@lists.freedesktop.org> Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com> (cherry picked from commit aa91fe1c09e066751c5419adb7810745336bd051)
2014-05-05r600g: fix hang on RV740 by using DX_RASTERIZATION_KILL instead of SX_MISCMarek Olšák5-7/+27
Changing SX_MISC hangs RV740. When we're at it, let's use DX_RASTERIZATION_KILL on all R700 and later chipsets. Cc: 10.0 10.1 mesa-stable@lists.freedesktop.org Reviewed-by: Alex Deucher <alexander.deucher@amd.com> (cherry picked from commit 3a3b1bf60e0ef233a8610684a7472e3600d0e65e)
2014-05-05r600g: fix for an MSAA hang on RV770Marek Olšák3-1/+12
Cc: 10.0 10.1 mesa-stable@lists.freedesktop.org Reviewed-by: Alex Deucher <alexander.deucher@amd.com> (cherry picked from commit 3d0c4f3b01569f43318e648786ae79f7b6b4948e)
2014-05-05r600g: fix for broken CULL_FRONT behavior on R6xxMarek Olšák4-61/+64
Cc: mesa-stable@lists.freedesktop.org Reviewed-by: Alex Deucher <alexander.deucher@amd.com> (cherry picked from commit ecc8a37ec5be7fca79205f08666fb76474ab5c0d) Conflicts: src/gallium/drivers/r600/r600_pipe.h
2014-05-05r600g: fix buffer copying on R600-R700Marek Olšák1-0/+6
This fixes broken rendering in DOTA 2. Cc: 10.0 10.1 mesa-stable@lists.freedesktop.org Reviewed-by: Alex Deucher <alexander.deucher@amd.com> (cherry picked from commit 0967970768c517c8c2f1a969e0a043982b4b1bf7)
2014-04-30r600g: fix flushing on RV670, RS780, RS880 againMarek Olšák1-0/+9
Cc: 10.0 10.1 mesa-stable@lists.freedesktop.org Reviewed-by: Alex Deucher <alexander.deucher@amd.com> (cherry picked from commit 042e40f67b4cec0bc1d5d783bc3207a191bf433b)
2014-04-30r600g: fix MSAA resolve on R6xx when the destination is 1D-tiledMarek Olšák1-0/+6
Cc: 10.0 10.1 mesa-stable@lists.freedesktop.org Reviewed-by: Alex Deucher <alexander.deucher@amd.com> (cherry picked from commit 20a9b784da3c286bdba5fbfb4e6592e16560895c)
2014-04-30r600g: disable async DMA on R700Marek Olšák1-1/+2
Cc: 10.0 10.1 mesa-stable@lists.freedesktop.org (cherry picked from commit 6dd045ef4074d23ac659eadb2388b12542e3aab8)
2014-04-30r600g: fix edge flags and layered rendering on R600-R700Marek Olšák1-1/+3
We forgot to set these bits. Cc: 10.1 mesa-stable@lists.freedesktop.org Reviewed-by: Alex Deucher <alexander.deucher@amd.com> (cherry picked from commit e5741f1e91429366699cb0a57c40968f0f9fd8cb) Conflicts: src/gallium/drivers/r600/r600_state.c
2014-04-30st/mesa: remove trailing NULL colorbuffersMarek Olšák1-0/+6
Cc: mesa-stable@lists.freedesktop.org Reviewed-by: Brian Paul <brianp@vmware.com> (cherry picked from commit 8a1dfba73e5b675635108e7d8309444704b8fef4)
2014-04-30r300g: don't crash when getting NULL colorbuffersMarek Olšák4-29/+60
Cc: mesa-stable@lists.freedesktop.org (cherry picked from commit e522c455e40b06a89885d413d564df40015259b3)
2014-04-30swrast: allocate swrast_texture_image::ImageSlices array if neededBrian Paul1-0/+10
Fixes a segmentation fault in conform divzero.c test. This happens when glTexImage(level, width=0, height=0) is called. We don't allocate texture memory in that case so the ImageSlices array was never allocated. Cc: "10.1" <mesa-stable@lists.freedesktop.org> Reviewed-by: José Fonseca <jfonseca@vmware.com> (cherry picked from commit 7cc2e2e99d857617178ce01f52ae2a9b04da3275)
2014-04-30swrast: Fix vertex color in _swsetup_Translate()nick1-1/+2
Straightforward fix to properly load dest->color with color data, as opposed to position data as previously implemented. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=27499 Cc: "10.1" <mesa-stable@lists.freedesktop.org> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Reviewed-by: Brian Paul <brianp@vmware.com> (cherry picked from commit 15c92464df07c5c0bb23a007358c560faeab76a8)
2014-04-27Upload to unstablemesa-10.1.1-1Julien Cristau1-2/+3
2014-04-26Add missing separator between dependency items '${misc:Depends}' and ↵Andreas Boll2-1/+3
'libglapi-mesa (= ${binary:Version})'.
2014-04-26Relax ocl-icd-libopencl1 dependency to allow the generic virtual libopencl1 ↵Andreas Boll2-1/+3
as a valid alternative Closes: #745765
2014-04-26New upstream release.Andreas Boll1-0/+6
2014-04-26Merge tag 'mesa-10.1.1' into debian-unstableAndreas Boll86-318/+1257
Mesa 10.1.1 release
2014-04-23glsl: Only allow `invariant` on shader in/out between stages.Chris Forbes1-24/+9
Previously this was special-cased for VS and FS; it never got updated when geometry shaders came along. Generalize using is_varying_var() so this won't be broken again with tessellation. Note that there are two copies of the logic for `invariant`: It can be present as part of a new declaration, and also as a redeclaration of an existing variable or block member. Fixes the four new piglits: spec/glsl-1.50/compiler/invariant-qualifier-*.geom Note for stable: This won't quite pick cleanly due to whitespace and state->target -> state->stage renames. Should be straightforward adjustments though. Cc: "10.0 10.1" <mesa-stable@lists.freedesktop.org> Signed-off-by: Chris Forbes <chrisf@ijw.co.nz> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com> (cherry picked from commit 0dfa6e7cf5a1f5207b32140f48cd3870db8a189b) Conflicts: src/glsl/ast_to_hir.cpp
2014-04-23mesa: Fix error code generation in glReadPixels()Anuj Phogat1-0/+16
Section 4.3.1, page 220, of OpenGL 3.3 specification explains the error conditions for glreadPixels(): "If the format is DEPTH_STENCIL, then values are taken from both the depth buffer and the stencil buffer. If there is no depth buffer or if there is no stencil buffer, then the error INVALID_OPERATION occurs. If the type parameter is not UNSIGNED_INT_24_8 or FLOAT_32_UNSIGNED_INT_24_8_REV, then the error INVALID_ENUM occurs." Fixes failing Khronos CTS test packed_depth_stencil_error.test V2: Avoid code duplication Cc: <mesa-stable@lists.freedesktop.org> Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com> (cherry picked from commit f8ae2a56c6164979223d2268691e354fe56d4bec)
2014-04-23mesa: Add an error condition in glGetFramebufferAttachmentParameteriv()Anuj Phogat1-0/+13
From the OpenGL 4.4 spec page 275: "If pname is FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE, param will contain the format of components of the specified attachment, one of FLOAT, INT, UNSIGNED_INT, SIGNED_NORMALIZED, or UNSIGNED_NORMALIZED for floating-point, signed integer, unsigned integer, signed normalized fixedpoint, or unsigned normalized fixed-point components respectively. If no data storage or texture image has been specified for the attachment, param will contain NONE. This query cannot be performed for a combined depth+stencil attachment, since it does not have a single format." Fixes Khronos CTS test: packed_depth_stencil_parameters.test Khronos Bug# 9170 Cc: <mesa-stable@lists.freedesktop.org> Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com> Reviewed-by: Brian Paul <brianp@vmware.com> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com> (cherry picked from commit bd1880dfe8fe1eea12eeb573df34ef328b96013e)
2014-04-23mesa: Add error condition for integer formats in glGetTexImage()Anuj Phogat1-0/+5
OpenGL 4.0 spec, page 306 suggests an INVALID_OPERATION in glGetTexImage if : "format is one of the integer formats in table 3.3 and the internal format of the texture image is not integer, or format is not one of the integer formats in table 3.3 and the internal format is integer." V2: Use helper function _mesa_is_format_integer() Cc: <mesa-stable@lists.freedesktop.org> Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com> Reviewed-by: Brian Paul <brianp@vmware.com> (cherry picked from commit cb6566f9df61bfc84c27b382ba3e494bbac782d9)
2014-04-23mesa: Add helper function _mesa_is_format_integer()Anuj Phogat2-0/+12
This function will be used in the following patch. Cc: <mesa-stable@lists.freedesktop.org> Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com> Reviewed-by: Brian Paul <brianp@vmware.com> (cherry picked from commit 313566825405c33f26a0471a997ec4c79fae6b08)
2014-04-23i965: Fix component mask and varying_to_slot mapping for gl_ViewportIndexAnuj Phogat1-1/+5
gl_ViewportIndex doesn't get its own varying slot. It is stored in VARYING_SLOT_PSIZ.z. This patch fixes the issue for both gen7 and gen8 because gen7_upload_3dstate_so_decl_list() is shared between them. Fixes failures in OpenGL Khronos CTS test transform_feedback_builtins. Makes new piglit test glsl-1.50-transform-feedback-builtins pass for 'gl_ViewportIndex'. Cc: <mesa-stable@lists.freedesktop.org> Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com> Reviewed-by: Chris Forbes <chrisf@ijw.co.nz> Reviewed-by: Kenneth Graunke <kenneth@whitecape.org> (cherry picked from commit 48fc2703e5d1c0a022a35fd77475d31d17c09177)
2014-04-23i965: Fix component mask and varying_to_slot mapping for gl_LayerAnuj Phogat1-4/+14
gl_Layer doesn't get its own varying slot. It is stored in VARYING_SLOT_PSIZ.y. This patch fixes the issue for both gen7 and gen8 because gen7_upload_3dstate_so_decl_list() is shared between them. Fixes failures in OpenGL Khronos CTS test transform_feedback_builtins. Makes new piglit test glsl-1.50-transform-feedback-builtins pass for 'gl_Layer'. Cc: <mesa-stable@lists.freedesktop.org> Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com> Reviewed-by: Chris Forbes <chrisf@ijw.co.nz> Reviewed-by: Kenneth Graunke <kenneth@whitecape.org> (cherry picked from commit 7928b9c249b2059c926d58a30f9f38bceafefb77)
2014-04-23i965: Put an assertion to check valid varying_to_slot[varying]Anuj Phogat1-0/+1
Cc: <mesa-stable@lists.freedesktop.org> Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com> Reviewed-by: Chris Forbes <chrisf@ijw.co.nz> Reviewed-by: Kenneth Graunke <kenneth@whitecape.org> (cherry picked from commit 969b461c2b28efbf44ea02cd09c8c6593f4c7343)
2014-04-23mesa: fix GetStringi error message with correct function nameBenjamin Bellec1-1/+1
Signed-off-by: Benjamin Bellec <b.bellec@gmail.com> Reviewed-by: Brian Paul <brianp@vmware.com> Cc: <mesa-stable@lists.freedesktop.org> (cherry picked from commit 9b3b9c613f186a09a0cc1080cc196c7a677dfc3c)
2014-04-23mesa: Fix error condition for multisample proxy texture targetsAnuj Phogat1-3/+13
Fixes failures in Khronos OpenGL CTS test proxy_textures_invalid_samples Cc: <mesa-stable@lists.freedesktop.org> Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com> Reviewed-by: Kenneth Graunke <kenneth@whitecape.org> (cherry picked from commit ee10e893cbd616da295dc46ca37ece664cd91d1a) Conflicts: src/mesa/main/teximage.c
2014-04-21swrast: Add glBlitFramebuffer to commands affected by conditional renderingAnuj Phogat1-0/+8
Cc: <mesa-stable@lists.freedesktop.org> Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com> Reviewed-by: Brian Paul <brianp@vmware.com> (cherry picked from commit 8ed42ddd7d31b6c9c65c735ad27ca2873859129e)
2014-04-21st/xa: Cache render target surfaceThomas Hellstrom1-3/+15
Otherwise it will trick the gallium driver into thinking that the render target has actually changed (due to different pipe_surface pointing to same underlying pipe_resource). This is really badness for tiling GPUs like adreno. This also appears to fix a rendering error with Motif on vmwgfx. Why that is is still under investigation. Based on an idea by Rob Clark. Cc: "10.0 10.1" <mesa-stable@lists.freedesktop.org> Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com> Reviewed-by: Rob Clark <robclark@freedesktop.org> (cherry picked from commit 09cd376353f534611323da9bedb9b88242b6e4fa)
2014-04-21mesa: fix check for dummy renderbuffer in _mesa_FramebufferRenderbufferEXT()Samuel Iglesias Gonsalvez1-2/+1
According to the spec: <renderbuffertarget> must be RENDERBUFFER and <renderbuffer> should be set to the name of the renderbuffer object to be attached to the framebuffer. <renderbuffer> must be either zero or the name of an existing renderbuffer object of type <renderbuffertarget>, otherwise an INVALID_OPERATION error is generated. This patch changes the previous returned GL_INVALID_VALUE to GL_INVALID_OPERATION. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=76894 Cc: mesa-stable@lists.freedesktop.org Reviewed-by: Anuj Phogat <anuj.phogat@gmail.com> Reviewed-by: Kenneth Graunke <kenneth@whitecape.org> Signed-off-by: Samuel Iglesias Gonsalvez <siglesias@igalia.com> (cherry picked from commit 9927180714662456ff7b895221f67112f2567a53)
2014-04-21mesa: Fix glGetVertexAttribi(GL_VERTEX_ATTRIB_ARRAY_SIZE)Anuj Phogat1-1/+1
mesa currently returns 4 when GL_VERTEX_ATTRIB_ARRAY_SIZE is queried for a vertex array initially set up with size=GL_BGRA. This patch makes changes to return size=GL_BGRA as required by the spec. Fixes Khronos OpenGL CTS test: vertex_array_bgra_basic.test V2: Use array->Format instead of adding a new variable Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com> Reviewed-by: Brian Paul <brianp@vmware.com> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com> Cc: <mesa-stable@lists.freedesktop.org> (cherry picked from commit fdd8bebc22f167f19d9cafbe2e7c189cb3720bcb)
2014-04-21r600g: Disable LLVM by default at runtime for graphicsMichel Dänzer3-5/+5
For graphics, the LLVM compiler backend currently has many shortcomings compared to the non-LLVM one. E.g. it can't handle geometry shaders yet, but that's just the tip of the iceberg. So building Mesa with --enable-r600-llvm-compiler is currently not recommended for anyone who doesn't want to work on fixing those issues. However, for protection of users who end up enabling it anyway for some reason, let's disable the LLVM backend at runtime by default. It can be enabled with the environment variable R600_DEBUG=llvm. Cc: "10.1" <mesa-stable@lists.freedesktop.org> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Reviewed-by: Marek Olšák <marek.olsak@amd.com> Reviewed-by: Tom Stellard <thomas.stellard@amd.com> (cherry picked from commit 7286739b9beea4683a29fe91850688a07ce23e1a)
2014-04-18docs: Add the MD5 sums for the 10.1.1 release tar files.Carl Worth1-0/+3
Now that those files have been generated.