summaryrefslogtreecommitdiffstats
path: root/src/gallium/auxiliary
Commit message (Collapse)AuthorAgeFilesLines
* auxillary: Append LLVM_CXXFLAGS to CXXFLAGSTom Stellard2012-11-131-0/+1
|
* gallivm,draw,llvmpipe: use base ptr + mip offsets instead of mip pointersRoland Scheidegger2012-11-128-25/+48
| | | | | | | | | This might have a slight overhead but handling mip offsets more like the width (and image) strides should make some things easier (mip level being just part of the offset calculation) later. Reviewed-by: Brian Paul <[email protected]> Reviewed-by: José Fonseca <[email protected]>
* gallium/u_blitter: handle PIPE_TEXTURE_CUBE_ARRAY in is_box_inside_resourceMarek Olšák2012-11-111-0/+6
|
* u_blitter: fix cube array checkDave Airlie2012-11-101-1/+1
| | | | | | | | Pointed out by Marek on irc, no committing after beer! Signed-off-by: Dave Airlie <[email protected]>
* util/u_surface: Support 3D/array textures in util_resource_copy_region().José Fonseca2012-11-091-26/+44
| | | | | Reviewed-by: Brian Paul <[email protected]> Reviewed-by: Roland Scheidegger <[email protected]>
* draw: Remove redundant draw_geometry_shader_delete().José Fonseca2012-11-092-8/+2
| | | | | | | draw_delete_geometry_shader() seems to be the real one. Reviewed-by: Brian Paul <[email protected]> Reviewed-by: Roland Scheidegger <[email protected]>
* util/u_surface: Fix util_clear_depth_stencil for Z32_FLOAT_S8X24_UINT.José Fonseca2012-11-091-12/+6
| | | | | | | | | | util_pack_z_stencil was being unconditionally invoked for all formats, causing an assertion failure for Z32_FLOAT_S8X24_UINT. NOTE: Candidate for the stable branches. Reviewed-by: Brian Paul <[email protected]> Reviewed-by: Roland Scheidegger <[email protected]>
* softpipe,util: Fix blending of R and RG formats.José Fonseca2012-11-091-25/+1
| | | | | | | | | Alpha is also 1 for formats like R32G32_FLOAT. NOTE: Candidate for the stable branches. Reviewed-by: Brian Paul <[email protected]> Reviewed-by: Roland Scheidegger <[email protected]>
* tgsi: Lift the requirement of indirection being done by ADDR register.José Fonseca2012-11-091-1/+0
| | | | | | | For drivers with native integer / SM4 support this is just an hindrance. Reviewed-by: Brian Paul <[email protected]> Reviewed-by: Roland Scheidegger <[email protected]>
* util: Fix reduction of line adjacency primitives.José Fonseca2012-11-091-0/+2
| | | | | Reviewed-by: Brian Paul <[email protected]> Reviewed-by: Roland Scheidegger <[email protected]>
* util/u_rect: Make it C++ safe.José Fonseca2012-11-091-0/+15
| | | | | Reviewed-by: Brian Paul <[email protected]> Reviewed-by: Roland Scheidegger <[email protected]>
* u_blitter: don't create fragment program for cube maps unless supported.Dave Airlie2012-11-091-1/+6
| | | | | | should fix http://bugs.freedesktop.org/56906 Signed-off-by: Dave Airlie <[email protected]>
* u_blitter: add cube map array support.Dave Airlie2012-11-091-2/+3
| | | | | | | This adds cube array support to the blitter. Reviewed-by: Brian Paul <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
* softpipe: add ARB_texture_cube_map_array support (v1.1)Dave Airlie2012-11-092-30/+103
| | | | | | | | | | | | | This adds support to the softpipe texture sampler and tgsi exec. In order to handle the extra input to the texture sampling, I've had to expand the interfaces to take a c1 value for storing the texture compare value for the TEX2 case. v1.1: add comments (Brian) Reviewed-by: Brian Paul <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
* gallium: add defines/shader opcode for texture cube map arrayDave Airlie2012-11-094-2/+12
| | | | | | | | | | | | | | | | This just adds the texture target and capability along with 3 new opcodes required to support this extension. As this extension requires some texture opcodes with samp + 5 args, we need to use another src register, this is only required for TEX, TXL and TXB opcodes to implement this spec. TEX2 is required for shadow cube map arrays TXL2 is required for cube map array sampler + explicit lod TXB2 is required for cube map array sampler + lod bias Reviewed-by: Brian Paul <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
* r600g: add in-place DB decompression and texturing with DB tilingMarek Olšák2012-11-061-1/+2
| | | | | | | | | | | | | | | | | | | | | The decompression is done in-place and only the compressed tiles are decompressed. Note: R6xx-R7xx can do that only with Z16 and Z32F. The texture unit is programmed to use non-displayable tiling and depth ordering of samples, so that it can fetch the texture in the native DB format. The latest version of the libdrm surface allocator is required for stencil texturing to work. The old one didn't create the mipmap tree correctly. We need a separate mipmap tree for stencil, because the stencil mipmap offsets are not really depth offsets/4. There are still some known bugs, but this should save some memory and it also improves performance a little bit in Lightsmark (especially with low resolutions; tested with Radeon HD 5000). The DB->CB copy is still used for transfers. Reviewed-by: Jerome Glisse <[email protected]>
* util: Make u_framebuffer.h C++ safe.José Fonseca2012-11-051-0/+8
|
* gallium/u_vbuf: document how it worksMarek Olšák2012-11-012-3/+63
|
* gallium/u_vbuf: optimize looping over the list of buffers to uploadMarek Olšák2012-11-011-9/+12
|
* gallium/u_vbuf: skip processing of buffers unused by the vertex element stateMarek Olšák2012-11-011-15/+24
|
* draw: fix assertion failure in draw_emit_vertex_attrMarek Olšák2012-10-311-2/+3
| | | | | | | | | | | This is a regression since b3921e1f53833420e0a0fd581f7417. The array stores VS outputs, not FS inputs. Now llvmpipe can do 32 varyings too. NOTE: This is a candidate for the stable branches. Reviewed-by: Brian Paul <[email protected]>
* gallium: add start_slot parameter to set_vertex_buffersMarek Olšák2012-10-3122-220/+404
| | | | | | | | | | | | | | | | | | | | | This allows updating only a subrange of buffer bindings. set_vertex_buffers(pipe, start_slot, count, NULL) unbinds buffers in that range. Binding NULL resources unbinds buffers too (both buffer and user_buffer must be NULL). The meta ops are adapted to only save, change, and restore the single slot they use. The cso_context can save and restore only one vertex buffer slot. The clients can query which one it is using cso_get_aux_vertex_buffer_slot. It's currently set to 0. (the Draw module breaks if it's set to non-zero) It should decrease the CPU overhead when using a lot of meta ops, but the drivers must be able to treat each vertex buffer slot as a separate state (only r600g does so at the moment). I can imagine this also being useful for optimizing some OpenGL use cases. Reviewed-by: Brian Paul <[email protected]>
* r600g: implement texturing with 8x MSAA compressed surfaces for EvergreenMarek Olšák2012-10-292-0/+14
| | | | | | | | | | The 2x and 4x MSAA cases are completely broken. The lfdptr instruction returns garbage there. The 8x MSAA case is broken on Cayman, though at least the result looks somewhat correct. Only the 8x MSAA case works on Evergreen and is enabled.
* mesa: bump MAX_VARYING to 32Marek Olšák2012-10-291-1/+1
| | | | | | | | | | | | | | | | | We're starting to get apps utilizing more than 16 varyings and most current hardware supports 32 anyway. Tested with r600g. swrast, softpipe and llvmpipe still advertise 16 varyings. This fixes a WebGL crash after launching this demo: https://developer.mozilla.org/en-US/demos/detail/falling-cubes Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=54402 NOTE: This is a candidate for the stable branches. Acked-by: Kenneth Graunke <[email protected]>
* gallium/gallivm: code generation options for LLVM 3.1+Alexander V. Nikolaev2012-10-283-17/+44
| | | | | | | | | | | | | | | LLVM 3.1+ haven't more "extern unsigned llvm::StackAlignmentOverride" and friends for configuring code generation options, like stack alignment. So I restrict assiging of lvm::StackAlignmentOverride and other variables to LLVM 3.0 only, and wrote similiar code using TargetOptions. This patch fix segfaulting of WINE using llvmpipe built with LLVM 3.1 Signed-off-by: Alexander V. Nikolaev <[email protected]> Signed-off-by: José Fonseca <[email protected]>
* gallivm/llvmpipe: fix 64-bit %ll format compiler warnings for mingw32Brian Paul2012-10-261-4/+3
| | | | | Use the PRIx64 and PRIu64 format macros from inttypes.h. We made a similar change in prog_print.c in df2d81ea59993a77bd1f1ef96c5cf19ac692d5f7.
* vl: fix the dri winsys helper screen initChristian König2012-10-261-0/+2
| | | | Signed-off-by: Christian König <[email protected]>
* gallivm: Hide AVX support when requested by LP_NATIVE_VECTOR_WIDTH or ↵José Fonseca2012-10-171-0/+10
| | | | | | unsupported by LLVM. Reviewed-by: Roland Scheidegger <[email protected]>
* gallivm: Use mcjit for ppc_64 architectureWill Schmidt2012-10-171-1/+4
| | | | | | | | | Per commentary and direction in the LLVM community, support for ppc64 is going into MCJIT rather than the old JIT. There is no existing support in prior llvm versions, so no need to specify LLVM version numbers. Signed-off-by: Will Schmidt <[email protected]> Signed-off-by: José Fonseca <[email protected]>
* tgsi: silence MSVC signed/unsigned comparison warningsBrian Paul2012-10-172-2/+2
| | | | Reviewed-by: Jose Fonseca <[email protected]>
* util: fix MSVC signed/unsigned comparison warning in u_upload_mgr.c codeBrian Paul2012-10-171-1/+1
| | | | Reviewed-by: Jose Fonseca <[email protected]>
* util: fix MSVC signed/unsigned comparison warning in u_vbuf.c codeBrian Paul2012-10-171-1/+1
| | | | Reviewed-by: Jose Fonseca <[email protected]>
* util: fix MSVC double/float conversion warning in u_format_r11g11b10f.hBrian Paul2012-10-171-1/+1
| | | | Reviewed-by: Jose Fonseca <[email protected]>
* draw: silence MSVC signed/unsigned comparison warningsBrian Paul2012-10-174-8/+8
| | | | Reviewed-by: Jose Fonseca <[email protected]>
* util/blitter: silence assorted MSVC warningsBrian Paul2012-10-172-21/+22
| | | | | | | Fix signed/unsigned comparison warnings and float/int assignment warnings. Reviewed-by: Marek Olšák <[email protected]> Reviewed-by: Jose Fonseca <[email protected]>
* tgsi: Add support to parse IMM[x] too.José Fonseca2012-10-171-0/+28
| | | | Thanks to Brian for pointing this out.
* Revert "gallivm: Don't use llvm.x86.avx.max/min.ps.256 inadvertently."José Fonseca2012-10-171-4/+4
| | | | This reverts commit bf2edc776b02a2a63862bf69a23adf666ecfcc57.
* util: added debug_print_transfer_flags() functionBrian Paul2012-10-152-0/+45
|
* util: null-out the node's prev/next pointers in list_del()Chris Fester2012-10-151-0/+1
| | | | | Note: This is a candidate for the 9.0 branch. Signed-off-by: Brian Paul <[email protected]>
* u_format_s3tc.c: Don't call getenv() twiceMatt Turner2012-10-121-2/+3
| | | | Reviewed-by: Brian Paul <[email protected]>
* gallivm: Don't use llvm.x86.avx.max/min.ps.256 inadvertently.José Fonseca2012-10-121-4/+4
| | | | Could happen when CPU supports AVX, but LLVM doesn't.
* tgsi: Dump register number when dumping immediates.José Fonseca2012-10-121-1/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For example: VERT DCL IN[0] DCL OUT[0], POSITION DCL OUT[1], GENERIC[12] DCL CONST[0..4] DCL TEMP[0], LOCAL DCL TEMP[1], LOCAL IMM[0] UINT32 {4294967295, 0, 0, 0} IMM[1] FLT32 { 0.0000, 1.0000, 0.0000, 0.0000} 0: SEQ TEMP[0].x, CONST[3].xxxx, IMM[0].xxxx 1: F2I TEMP[0].x, -TEMP[0] 2: SEQ TEMP[1].x, CONST[4].xxxx, IMM[0].xxxx 3: F2I TEMP[1].x, -TEMP[1] 4: AND TEMP[0].x, TEMP[0].xxxx, TEMP[1].xxxx 5: IF TEMP[0].xxxx :0 6: MOV TEMP[0], IMM[1].xyxy 7: ELSE :0 8: MOV TEMP[0], IMM[1].yxxy 9: ENDIF 10: MOV OUT[1], TEMP[0] 11: MOV OUT[0], IN[0] 12: END instead of VERT DCL IN[0] DCL OUT[0], POSITION DCL OUT[1], GENERIC[12] DCL CONST[0..4] DCL TEMP[0], LOCAL DCL TEMP[1], LOCAL IMM UINT32 {4294967295, 0, 0, 0} IMM FLT32 { 0.0000, 1.0000, 0.0000, 0.0000} 0: SEQ TEMP[0].x, CONST[3].xxxx, IMM[0].xxxx 1: F2I TEMP[0].x, -TEMP[0] 2: SEQ TEMP[1].x, CONST[4].xxxx, IMM[0].xxxx 3: F2I TEMP[1].x, -TEMP[1] 4: AND TEMP[0].x, TEMP[0].xxxx, TEMP[1].xxxx 5: IF TEMP[0].xxxx :0 6: MOV TEMP[0], IMM[1].xyxy 7: ELSE :0 8: MOV TEMP[0], IMM[1].yxxy 9: ENDIF 10: MOV OUT[1], TEMP[0] 11: MOV OUT[0], IN[0] 12: END
* gallivm: fix rsqrt failuresRoland Scheidegger2012-10-121-8/+41
| | | | | | | | | | | | | | | | | | | | | | | | | lp_build_rsqrt initially did not do any newton-raphson step. This meant that precision was only ~11 bits, but this handled both input 0.0 and +infinity correctly. It did not however handle input 1.0 accurately, and denormals always generated infinity result. Doing a newton-raphson step increased precision significantly (but notably input 1.0 still doesn't give output 1.0), however this fails for inputs 0.0 and infinity (both result in NaNs). Try to fix this up by using cmp/select but since this is all quite fishy (and still doesn't handle denormals) disable for now. Note that even with workarounds it should still have been faster since the fallback uses sqrt/div (which both use the usually unpipelined and slow divider hw). Also add some more test values to lp_test_arit and test lp_build_rcp() too while there. v2: based on José's feedback, avoid hacky infinity definition which doesn't work with msvc (unfortunately using INFINITY won't cut it neither on non-c99 compilers) in lp_build_rsqrt, and while here fix up the input infinity case too (it's disabled anyway). Only test infinity input case if we have c99, and use float cast for calculating reference rsqrt value so we really get what we expect. Reviewed-by: José Fonseca <[email protected]>
* r600g: implement MSAA resolving for 8-bit and 16-bit integer formatsMarek Olšák2012-10-122-3/+5
| | | | by changing the format to NORM.
* util: fix broken pipe_get_tile_rgba() callBrian Paul2012-10-111-1/+1
| | | | Fix breakage from commit 369e468.
* gallium: unify transfer functionsMarek Olšák2012-10-1118-414/+210
| | | | | | | | | | | | | | "get_transfer + transfer_map" becomes "transfer_map". "transfer_unmap + transfer_destroy" becomes "transfer_unmap". transfer_map must create and return the transfer object and transfer_unmap must destroy it. transfer_map is successful if the returned buffer pointer is not NULL. If transfer_map fails, the pointer to the transfer object remains unchanged (i.e. doesn't have to be NULL). Acked-by: Brian Paul <[email protected]>
* llvmpipe: remove unused variables to fix compile warningsMarek Olšák2012-10-092-6/+3
|
* gallium: allow debug helpers in the release buildMarek Olšák2012-10-061-8/+0
| | | | | | | No idea why this is #ifdef'd. Trace and Noop are definitely useful no matter how Mesa is built. Reviewed-by: Brian Paul <[email protected]>
* st/mesa: implement decompress_with_blit using gallium blitMarek Olšák2012-09-302-36/+5
| | | | | Tested-by: Michel Dänzer <[email protected]> Reviewed-by: Brian Paul <[email protected]>
* gallium: add helpers for dumping pipe_box and pipe_blit_infoMarek Olšák2012-09-302-0/+79
| | | | | Tested-by: Michel Dänzer <[email protected]> Reviewed-by: Brian Paul <[email protected]>