summaryrefslogtreecommitdiffstats
path: root/src
Commit message (Collapse)AuthorAgeFilesLines
* nvfx: new 2D: rewrite miptree code, adapt transfersLuca Barbieri2010-08-216-224/+207
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Changes: - Disable swizzling on non-RGBA 2D textures, since the current 2D code is mostly broken in those cases. A later patch will fix this. Thanks to Andrew Randrianasulu who reported this. - Fix compressed texture transfers and hack around the current 2D code inability to copy compressed textures by using direct access. Thanks to Andrew Randrianasulu who reported this. This patch rewrites all the miptree layout and transfer code in the nvfx driver. The current code is broken in several ways: 1. 3D textures are laid out first by face, then by level, which is incorrect 2. Cube maps should have 128-byte aligned faces 3. Swizzled textures have a strange alignment test that seems unnecessary 4. We store the image_offsets for each face/slice but they can be easily computed instead 5. "Swizzling" is not supported for compressed formats. They can be "swizzled" but swizzling only means that there are no gaps (pitch is level-dependant) and the layout is still linear 6. Swizzling is not supported for non-RGBA formats. All formats (except possibly depth) can be swizzled according to my testing. The miptree layout is rewritten based on my empirical testing, which I posted in the "miptree findings" mail. The image_offset array is removed, since it can be calculated with a simple multiplication; the only array in the miptree structure is now the one for mipmap level starts, which it seems cannot be easily computed in constant time. Also, we now directly store a nouveau_bo instead of a pipe_buffer in the miptree structure, like nv50 does. Support for render temporaries is removed, and will be readded in a later patch. Note that the current temporary code is broken, because it does not copy the temporary back on render cache flushes.
* nvfx: add nouveau_resource_on_gpuLuca Barbieri2010-08-211-1/+15
| | | | | | Add a function to get whether a resource is likely on the GPU or not. Currently always returns TRUE.
* nvfx: add linear flag for buffersLuca Barbieri2010-08-214-2/+5
|
* nvfx: properly unreference bound objects on context destructionLuca Barbieri2010-08-211-0/+8
|
* nvfx: reference count bound objectsLuca Barbieri2010-08-211-7/+29
|
* nvfx: fix format support code for compressed textureLuca Barbieri2010-08-211-1/+1
| | | | A source line was put in the wrong place.
* gallium/auxiliary: add semantic linkage utility codeLuca Barbieri2010-08-213-0/+211
|
* u_debug_describe: use switch instead of if chainLuca Barbieri2010-08-211-7/+17
|
* u_debug_describe: add PIPE_TEXTURE_RECTLuca Barbieri2010-08-211-0/+2
|
* auxiliary: add copyright headersLuca Barbieri2010-08-2110-5/+258
| | | | Thanks to Jose Fonseca for pointing out they were missing.
* util: Match printf format to silence warning.José Fonseca2010-08-211-1/+1
|
* mesa: Remove unsused local variable.José Fonseca2010-08-211-1/+0
|
* util: Make the reference debuggin code more C++ friendly.José Fonseca2010-08-214-13/+30
| | | | | C++ doesn't accept function <-> void* conversions without a putting a fight.
* util: Remove the x86 exception handlers.José Fonseca2010-08-211-55/+0
| | | | Unused now that check_os_katmai_support was removed.
* trace: Don't immediately destroy the pipe's sampler view in the trace driver.Alex Corscadden2010-08-211-1/+1
| | | | | | | | | | The trace driver's implementation of sampler_view_destroy was calling directly into the underlying pipe's sampler_view_destroy implementation. This causes problems for pipes that keep references to sampler views even after the state tracker has released them. Instead, we'll simply drop the trace driver's reference to the pipe's sampler view. Signed-off-by: José Fonseca <[email protected]>
* trace: Trace the correct version of the resource when setting the index buffer.Alex Corscadden2010-08-211-1/+1
| | | | | | | | | The trace driver was tracing the unwrapped version of the index buffer when setting the index buffer. This caused an assert validating that a resource belonged to the trace driver to fail. Instead, we'll log the unmodified index buffer structure when setting the index buffer. Signed-off-by: José Fonseca <[email protected]>
* generate_builtins.py: Remove unused import sys.Vinson Lee2010-08-211-1/+1
|
* mapi: Use MAPI_EXPORT to export public functions.Chia-I Wu2010-08-212-6/+17
| | | | | mapi.h is included by vgapi and st/vega. On win32, the macro expands to dllexport and dllimport respectively.
* mapi: Prefix functions in u_current.h by u_current.Chia-I Wu2010-08-215-79/+94
| | | | | | | That is, replace the old _glapi_* names by new names that start with u_current_. When MAPI_GLAPI_CURRENT is defined, u_current.h defines rename macros to restore the old names. That is done for ABI compatibility.
* glapi: Move public function/variable declarations to glapi.h.Chia-I Wu2010-08-215-47/+107
| | | | | | | glapi defines an interface that is used by DRI drivers. It must not be changed in an ABI incompatible way. This commit moves all functions/variables belong to the interface to glapi.h. Instead of including u_current.h from glapi.h, u_current.h now includes glapi.h.
* evergreen : initial support driver code.richard2010-08-2041-249/+12426
|
* i965: Rename nr_depth_regs to nr_payload_regs.Eric Anholt2010-08-205-8/+8
| | | | | | | Only 8 out of the up to 13 regs are for source/dest depth, so the name wasn't particularly appropriate. Note that this doesn't count the constant or URB payload regs. Also, don't pre-divide by 2, so it's actually a number of registers.
* i965: Also use the SIMD8 FB writes for SIMD8 mode on non-SNB.Eric Anholt2010-08-203-17/+18
|
* i965: Add support for FB writes on Sandybridge.Zhenyu Wang2010-08-202-12/+74
|
* i965: Set the destination horiz stride even for da16, as SNB seems to need it.Zhenyu Wang2010-08-202-2/+6
|
* i965: Set the maximum number of threads on Sandybridge.Zhenyu Wang2010-08-201-1/+5
|
* i965: Add AccWrCtl support on Sandybridge.Zhenyu Wang2010-08-205-2/+20
| | | | Whenever the accumulator results are needed, this bit must be set.
* i965: Mention the mlen and rlen for URB reads.Zhenyu Wang2010-08-201-0/+5
|
* i965: Sandybridge doesn't have Compr4 mode, since it's not needed any more.Zhenyu Wang2010-08-201-1/+2
|
* i965: Adjust disasm of subreg numbers to be in units of the register type.Zhenyu Wang2010-08-201-6/+20
| | | | | This makes reading the code easier when matching up to the specs, which also use this format.
* i965: Fix DP write channel ordering on Sandybridge.Eric Anholt2010-08-201-2/+25
| | | | | The SIMD16 message no longer has the goofy interleaved format that made Compr4 compression necessary before.
* os_stream: fix bugs in allocation pathLuca Barbieri2010-08-211-16/+8
|
* p_compiler: add replacement va_copyLuca Barbieri2010-08-211-0/+8
| | | | | | | | | This might technically not always be correct, because va_copy might be a function, or a system might not have va_copy, and not work with assignment. Hopefully this is never the case. Without configure tests, it doesn't seem possible to do better.
* Delete more vestiges of the old shader compiler.Kenneth Graunke2010-08-209-1252/+0
|
* glsl: Remove bogus "ambient" field from vec4 gl_TextureEnvColor.Kenneth Graunke2010-08-201-1/+1
|
* glsl: add missing ambient field to gl_LightModelLuca Barbieri2010-08-201-1/+1
| | | | | Again, this is a one-element struct that was incorrectly missing the field.
* glsl: don't crash if a field is specified for a non-struct uniformLuca Barbieri2010-08-201-1/+1
| | | | | This was triggered by the previous bug, but is a separate problem in the general sense.
* glsl: add missing sceneColor field to gl_{Front, Back}LightModelProductLuca Barbieri2010-08-201-2/+2
| | | | | | | According to both GLSL 1.20 and 4.0, these are a struct with one field called "sceneColor". Fixes a crash on loading in FlightGear.
* intel: Don't try to do work for BufferSubData with a size of 0.Eric Anholt2010-08-201-0/+6
| | | | | | | If we hit the linear blit path, we'd come up with a pitch of 0, then divide by zero. Fixes vbo-subdata-zero, made for bug #28931 (warsow).
* mesa: Fix GetUniformLocation while compiling display lists.Nick Bowler2010-08-201-1/+9
| | | | | | | | | | | | This function was apparently missing from the display list dispatch table, causing the generic no-op function to be called instead. To make matters worse, the no-op function is indistinguishable from a successful call to GetUniformLocation. GL specifies that GetUniformLocation is executed immediately when compiling display lists. Fixes fdo bug 29622. Signed-off-by: Nick Bowler <[email protected]>
* Remove remnants of the old glsl compiler.Eric Anholt2010-08-2080-36985/+0
|
* r600g: add POW instructionJerome Glisse2010-08-201-18/+73
| | | | Signed-off-by: Jerome Glisse <[email protected]>
* r600g: cleanup definition, fix segfault when no valid pixel shaderJerome Glisse2010-08-203-37/+40
| | | | Signed-off-by: Jerome Glisse <[email protected]>
* util: Fix build for C++ compilers.Michal Krol2010-08-202-0/+16
|
* gallium: hook up reference count debugging codeLuca Barbieri2010-08-201-6/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | This commit adds the ability to produce a log file containing all reference count changes, and object creation/destruction, on Gallium objects. The data allows to answer these crucial questions: 1. This app is exhausting all my memory due to a resource leak: where is the bug? 2. Which resources is this app using at a given moment? Which parts of the code created them? 3. What kinds of resources does this app use? 4. How fast does this app create and destroy resources? Which parts of the code create resources fast? The output is compatible with the one produced by the similar facility in Mozilla Firefox, allowing to use Mozilla's tools to analyze the data. To get the log file: export GALLIUM_REFCNT_LOG=<file> To get function names and source lines in the log file: tools/addr2line.sh <file> To process the log file, see: http://www.mozilla.org/performance/refcnt-balancer.html
* auxiliary: add reference count debugging codeLuca Barbieri2010-08-204-0/+187
|
* os_stream: add printf facilityLuca Barbieri2010-08-208-3/+85
|
* u_debug_symbol: add symbol name cachingLuca Barbieri2010-08-202-1/+43
| | | | | Without this, any form of logging that dumps stack traces continuously will spend a lot of time resolving symbol names.
* u_debug_symbol: add support for getting symbol names from glibcLuca Barbieri2010-08-202-0/+49
|
* u_debug_symbol: support getting a string without outputLuca Barbieri2010-08-202-14/+27
|