summaryrefslogtreecommitdiffstats
path: root/src
Commit message (Collapse)AuthorAgeFilesLines
* llvmpipe: we need to subdivide if fb is bigger in either directionZack Rusin2013-09-251-1/+1
| | | | | | | | | We need to subdivide triangles if either of the dimensions is larger than the max edge length, not when both of them are larger. Signed-off-by: Zack Rusin <[email protected]> Reviewed-by: José Fonseca <[email protected]> Reviewed-by: Roland Scheidegger <[email protected]>
* radeon/llvm: fix shadow cube texturing for GL3.0Marek Olšák2013-09-251-23/+15
| | | | | | | | | The fix is at the end (TGSI_TEXTURE_SHADOWCUBE handling), but I also restructured the code for it to be more readable. Fixes spec/!OpenGL 3.0/sampler-cube-shadow. Reviewed-by: Michel Dänzer <[email protected]>
* radeonsi: fix blitting the last 2 mipmap levels of compressed texturesMarek Olšák2013-09-253-2/+20
| | | | | | | | | | | This fixes compressedteximage piglit tests. +10 piglits Evergreen and Cayman have the same issue. R600 and R700 don't. Cc: "9.2" <[email protected]> Reviewed-by: Michel Dänzer <[email protected]>
* radeonsi: add missing colorbuffer formats (rework format translation)Marek Olšák2013-09-251-346/+104
| | | | | | | | | This fixes some piglits, e.g: spec/!OpenGL 3.0/required-renderbuffer-attachment-formats. This can be ported to r600g. Reviewed-by: Michel Dänzer <[email protected]>
* radeonsi: bypass alpha-test for integer colorbuffersMarek Olšák2013-09-251-1/+10
| | | | | | Fixes spec/EXT_texture_integer/fbo-blending. Reviewed-by: Michel Dänzer <[email protected]>
* r600g: fix texture buffer object cache flushingMarek Olšák2013-09-251-1/+4
| | | | Cc: "9.2" <[email protected]>
* r600g: fix constant buffer cache flushingMarek Olšák2013-09-251-1/+5
| | | | Cc: "9.2" <[email protected]>
* radeon/winsys: keep screen pointer in winsys v2Christian König2013-09-258-22/+48
| | | | | | | | | | Only create one screen for each winsys instance. This helps with buffer sharing and interop handling. v2: rebased and some minor cleanup Signed-off-by: Christian König <[email protected]> Reviewed-by: Marek Olšák <[email protected]>
* build/radeonsi: group all targets in common subdirChristian König2013-09-259-97/+74
| | | | | | | Allows us to share more code between different targets. Signed-off-by: Christian König <[email protected]> Acked-by: Marek Olšák <[email protected]>
* build/r600: group all targets in common subdirChristian König2013-09-2511-123/+76
| | | | | | | Allows us to share more code between different targets. Signed-off-by: Christian König <[email protected]> Acked-by: Marek Olšák <[email protected]>
* build/r300: group build target in common subdirChristian König2013-09-258-79/+58
| | | | | | | Allows us to share more code between different targets. Signed-off-by: Christian König <[email protected]> Acked-by: Marek Olšák <[email protected]>
* radeon/uvd: try to place msg/fb buffer into GARTChristian König2013-09-251-2/+2
| | | | | | This is only supported on NI+, but the kernel takes care of those limitations. Signed-off-by: Christian König <[email protected]>
* radeon/uvd: move alignment to winsysChristian König2013-09-252-6/+6
| | | | | | | Similar to GFX and DMA. Signed-off-by: Christian König <[email protected]> Reviewed-by: Marek Olšák <[email protected]>
* st/vdpau: use a separate lock per decoderChristian König2013-09-252-9/+12
| | | | Signed-off-by: Christian König <[email protected]>
* st/vdpau: use new vlc function to serach for VC-1 start codesChristian König2013-09-251-2/+1
| | | | Signed-off-by: Christian König <[email protected]>
* vl/mpeg12: use new vlc function to search for start codesChristian König2013-09-251-1/+1
| | | | Signed-off-by: Christian König <[email protected]>
* vl/vlc: add fast forward search for byte valueChristian König2013-09-251-10/+74
| | | | | | | Commonly used to find start codes and has far less overhead to searching manually. Signed-off-by: Christian König <[email protected]>
* glsl: Initialize ir_lower_jumps_visitor member variables.Vinson Lee2013-09-241-1/+6
| | | | | | | Fixes "Unintialized scalar field" defect reported by Coverity. Signed-off-by: Vinson Lee <[email protected]> Reviewed-by: Kenneth Graunke <[email protected]>
* glsl: Initialize lower_vector_visitor::dont_lower_swz.Vinson Lee2013-09-241-1/+1
| | | | | | | Fixes "Uninitialized scalar field" defect reported by Coverity. Signed-off-by: Vinson Lee <[email protected]> Reviewed-by: Kenneth Graunke <[email protected]>
* glsl: Initialize assignment_generator member variables.Vinson Lee2013-09-241-0/+6
| | | | | | | Fixes "Uninitialized pointer field" defect reported by Coverity. Signed-off-by: Vinson Lee <[email protected]> Reviewed-by: Kenneth Graunke <[email protected]>
* glsl: Remove unused pointer value.Vinson Lee2013-09-241-1/+1
| | | | | | | Silences "Unused pointer value" defect reported by Coverity. Signed-off-by: Vinson Lee <[email protected]> Reviewed-by: Eric Anholt <[email protected]>
* Revert "llvmpipe: increase number of subpixel bits to eight"Zack Rusin2013-09-243-17/+11
| | | | | | | | | This reverts commit 755c11dc5e94f17097c186edaaa39d818396f14c. We agreed that this is band-aid that's not very useful and the proper solution is to rewrite the rasterization algo so that it operates on 64 bit values. Signed-off-by: Zack Rusin <[email protected]>
* mesa: remove handcounted magic numberDylan Noblesmith2013-09-241-13/+20
| | | | | | Also make it a compile-time error with STATIC_ASSERT. Reviewed-by: Kenneth Graunke <[email protected]>
* mesa: remove outdated commentDylan Noblesmith2013-09-241-1/+0
| | | | | | | | | | | | | | No such argument exists since this commit: commit 92f3fca0ea429dcf07123e63447449db53308266 Author: Ian Romanick <[email protected]> AuthorDate: Sun Aug 21 17:23:58 2011 -0700 Commit: Ian Romanick <[email protected]> CommitDate: Tue Aug 23 14:52:09 2011 -0700 mesa: Remove target parameter from dd_function_table::BufferSubData Reviewed-by: Kenneth Graunke <[email protected]>
* mesa: remove stale commentDylan Noblesmith2013-09-241-2/+0
| | | | | | | This line stopped making sense in the great sed replace of commit f9995b30756140724f41daf963fa06167912be7f Reviewed-by: Kenneth Graunke <[email protected]>
* llvmpipe: align the array used for subdivived verticesZack Rusin2013-09-231-1/+1
| | | | | | | | | | | When subdiving a triangle we're using a temporary array to store the new coordinates for the subdivided triangles. Unfortunately the array used for that was not aligned properly causing random crashes in the llvm jit code which was trying to load vectors from it. Signed-off-by: Zack Rusin <[email protected]> Reviewed-by: Roland Scheidegger <[email protected]>
* glapi: Move declaration before code.Vinson Lee2013-09-231-4/+6
| | | | | | | | | | | | | | | This patch fixes the MSVC build error introduced by commit 673129e0b936b1c748e988d3f74f3efaab9e5693. enums.c mesa\main\enums.c(3776) : error C2143: syntax error : missing ';' before 'type' mesa\main\enums.c(3781) : error C2065: 'elt' : undeclared identifier mesa\main\enums.c(3781) : warning C4047: '!=' : 'int' differs in levels of indirection from 'void *' mesa\main\enums.c(3782) : error C2065: 'elt' : undeclared identifier mesa\main\enums.c(3782) : error C2223: left of '->offset' must point to struct/union mesa\main\enums.c(3782) : warning C4033: '_mesa_lookup_enum_by_nr' must return a value Signed-off-by: Vinson Lee <[email protected]>
* mesa: Use -Bsymbolic in the linker to locally resolve Mesa-internal symbols.Eric Anholt2013-09-237-7/+12
| | | | | | | | | | | | | Normally, LD_PRELOAD will take precedence over your own symbols, which you want for things like malloc() in libc. But we don't have any local symbols we would want overridden (like hash_table_insert(), for example!), so tell the linker to resolve them internally. This also avoids calls through the PLT. Saves almost 100k on libdricore's size, and gets us a bunch of the performance back that we had with non-dricore. Reviewed-by: Ian Romanick <[email protected]>
* glsl: Hide many classes local to individual .cpp files in anon namespaces.Eric Anholt2013-09-2333-2/+126
| | | | | | | | This gives the compiler the chance to inline and not export class symbols even in the absence of LTO. Saves about 60kb on disk. Reviewed-by: Kenneth Graunke <[email protected]> Reviewed-by: Ian Romanick <[email protected]>
* mesa: Drop an extra copy-and-pasted copy in the program clone function.Eric Anholt2013-09-231-1/+0
| | | | | | Reviewed-by: Brian Paul <[email protected]> Reviewed-by: Kenneth Graunke <[email protected]> Reviewed-by: Ian Romanick <[email protected]>
* mesa: Convert some runtime asserts to static asserts.Eric Anholt2013-09-231-2/+2
| | | | | | | | | Noticed while grepping through the code for something else. v2: Don't convert really-runtime asserts to static asserts. Reviewed-by: Kenneth Graunke <[email protected]> Reviewed-by: Ian Romanick <[email protected]>
* mesa: Shrink the size of the enum string lookup struct.Eric Anholt2013-09-232-2/+13
| | | | | | | | | | Since it's only used for debug information, we can misalign the struct and save the disk space. Another 19k on a 64-bit build. v2: Make a compiler.h macro to only use the attribute if we know we can. Reviewed-by: Kenneth Graunke <[email protected]> Reviewed-by: Ian Romanick <[email protected]>
* mesa: Remove the extra enum strings and extra lookup table.Eric Anholt2013-09-231-41/+20
| | | | | | | | | | Now that there's no name -> enum direction, we can drop the extra strings, and merge the offsets table and the reduced_enums table. Between the previous commit and this one, Mesa core drops by 30k. Acked-by: Kenneth Graunke <[email protected]> Reviewed-by: Ian Romanick <[email protected]>
* mesa: Remove _mesa_lookup_enum_by_name().Eric Anholt2013-09-233-63/+0
| | | | | | | | It's been unused for a long time. I stopped digging through git history as of 2009. Reviewed-by: Kenneth Graunke <[email protected]> Reviewed-by: Ian Romanick <[email protected]>
* llvmpipe: increase number of subpixel bits to eightZack Rusin2013-09-233-11/+17
| | | | | | | | | | | | | Unfortunately d3d10 requires a lot higher precision (e.g. wgf11clipping tests for it). The smallest number of precision bits with which it passes is 8. That means that we need to decrease the maximum length of an edge that we can handle without subdivision by 4 bits. Abstracted the code a bit to make it easier to change once to switch to 64bit rasterization. Signed-off-by: Zack Rusin <[email protected]> Reviewed-by: José Fonseca <[email protected]> Reviewed-by: Roland Scheidegger <[email protected]>
* glsl: Define isnormal and copysign for MSVC to fix build.Vinson Lee2013-09-221-0/+14
| | | | | | | | | | | | | This patch fixes these MSVC build errors. ir_constant_expression.cpp src\glsl\ir_constant_expression.cpp(564) : warning C4244: '=' : conversion from 'int' to 'float', possible loss of data src\glsl\ir_constant_expression.cpp(1384) : error C3861: 'isnormal': identifier not found src\glsl\ir_constant_expression.cpp(1385) : error C3861: 'copysign': identifier not found Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=69541 Signed-off-by: Vinson Lee <[email protected]> Acked-by: Matt Turner <[email protected]>
* radeon/uvd: async flush the UVD csChristian König2013-09-221-1/+1
| | | | | | | No need to block for the CS thread here. Signed-off-by: Christian König <[email protected]> Reviewed-by: Marek Olšák <[email protected]>
* winsys/radeon: share winsys between different fd'sChristian König2013-09-221-2/+17
| | | | | | | Share the winsys between different fd's if they point to the same device. Signed-off-by: Christian König <[email protected]> Reviewed-by: Marek Olšák <[email protected]>
* winsys/radeon: remove cs_queue_emptyChristian König2013-09-223-19/+3
| | | | | | | | | | | | Waiting for an empty queue is nonsense and can lead to deadlocks if we have multiple waiters or another thread that continuously sends down new commands. Just post the cs to the queue and immediately wait for it to finish. This is a candidate for the stable branch. Signed-off-by: Christian König <[email protected]> Reviewed-by: Marek Olšák <[email protected]>
* winsys/radeon: fix killing the CS threadChristian König2013-09-221-4/+4
| | | | | | | Kill the thread only after we checked that it's not used any more, not before. Signed-off-by: Christian König <[email protected]> Reviewed-by: Marek Olšák <[email protected]>
* i965/gen4: Fix fragment program rectangle texture shadow compares.Eric Anholt2013-09-211-4/+4
| | | | | | | | | | | | | | The rescale_texcoord(), if it does something, will return just the GLSL-sized coordinate, leaving out the 3rd and 4th components where we were storing our projected shadow compare and the texture projector. Deref the shadow compare before using the shared rescale-the-coordinate code to fix the problem. Fixes piglit tex-shadow2drect.shader_test and txp-shadow2drect.shader_test Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=69525 NOTE: This is a candidate for stable branches. Reviewed-by: Kenneth Graunke <[email protected]>
* i965/gen7.5: Fix missing Shader Channel Select entries on HaswellAbdiel Janulgue2013-09-211-0/+7
| | | | | | | | | | | Probably non-intentional, but the SURFACE_STATE setup refactoring for buffer surfaces had missed the scs bits when creating constant surface states. Fixes broken GLB 2.5 on Haswell where the knight's textures are missing Signed-off-by: Abdiel Janulgue <[email protected]> Reviewed-by: Kenneth Graunke <[email protected]>
* i965, mesa: Use the new DECLARE_R[Z]ALLOC_CXX_OPERATORS macros.Kenneth Graunke2013-09-217-122/+12
| | | | | | | | | | | | | | | | These classes declared a placement new operator, but didn't declare a delete operator. Switching to the macro gives them a delete operator, which probably is a good idea anyway. This also eliminates a lot of boilerplate. v2: Properly use RZALLOC in Mesa IR/TGSI translators. Caught by Eric and Chad. Signed-off-by: Kenneth Graunke <[email protected]> Reviewed-by: Eric Anholt <[email protected]> Reviewed-by: Chad Versace <[email protected]> Reviewed-by: Ian Romanick <[email protected]>
* glsl: Use the new DECLARE_R[Z]ALLOC_CXX_OPERATORS in a bunch of places.Kenneth Graunke2013-09-215-121/+7
| | | | | | | | | This eliminates a lot of boilerplate and should be 100% equivalent. Signed-off-by: Kenneth Graunke <[email protected]> Reviewed-by: Eric Anholt <[email protected]> Reviewed-by: Chad Versace <[email protected]> Reviewed-by: Ian Romanick <[email protected]>
* ralloc: Introduce new macros for defining C++ new/delete operators.Kenneth Graunke2013-09-211-0/+26
| | | | | | | | | | | | | | | | Most of our C++ classes define placement new and delete operators so we can do convenient allocation via: thing *foo = new(mem_ctx) thing(...) Currently, this is done via a lot of boilerplate. By adding simple macros to ralloc, we can condense this to a single line, making it trivial to add this feature to a new class. Signed-off-by: Kenneth Graunke <[email protected]> Reviewed-by: Eric Anholt <[email protected]> Reviewed-by: Chad Versace <[email protected]> Reviewed-by: Ian Romanick <[email protected]>
* r600g: fast color clears for single-sample buffersGrigori Goronzy2013-09-205-11/+86
| | | | | | | | | | | Allocate a CMASK on demand and use it to fast clear single-sample colorbuffers. Both FBOs and window system colorbuffers are fast cleared. Expand as needed when colorbuffers are mapped or displayed on screen. v2: cosmetics, move transfer expansion into dma_blit Signed-off-by: Marek Olšák <[email protected]>
* r600g: add support for separately allocated CMASKsGrigori Goronzy2013-09-204-10/+60
| | | | | | v2: check for NULL cbufs Signed-off-by: Marek Olšák <[email protected]>
* gallium: add flush_resource context functionMarek Olšák2013-09-2023-3/+188
| | | | | | | | | r600g needs explicit flushing before DRI2 buffers are presented on the screen. v2: add (stub) implementations for all drivers, fix frontbuffer flushing v3: fix galahad Signed-off-by: Marek Olšák <[email protected]>
* radeonsi: simplify and fix MSAA texture sampling for array texturesMarek Olšák2013-09-202-27/+17
| | | | Reviewed-by: Michel Dänzer <[email protected]>
* radeonsi: fix textureOffset and texelFetchOffset GLSL functionsMarek Olšák2013-09-201-9/+23
| | | | Reviewed-by: Michel Dänzer <[email protected]>