summaryrefslogtreecommitdiff
path: root/src/gallium/drivers/r600
AgeCommit message (Collapse)Author
2010-09-18r600g: Remove unused variable.Vinson Lee
2010-09-17r600g: Silence unused variable warnings.Vinson Lee
The variables are used in code that is currently ifdef'ed out.
2010-09-17r600g: Remove unnecessary header.Vinson Lee
2010-09-17r600g: alternative command stream building from contextJerome Glisse
Winsys context build a list of register block a register block is a set of consecutive register that will be emited together in the same pm4 packet (the various r600_block* are there to provide basic grouping that try to take advantage of states that are linked together) Some consecutive register are emited each in a different block, for instance the various cb[0-7]_base. At winsys context creation, the list of block is created & an index into the list of block. So to find into which block a register is in you simply use the register offset and lookup the block index. Block are grouped together into group which are the various pkt3 group of config, context, resource, Pipe state build a list of register each state want to modify, beside register value it also give a register mask so only subpart of a register can be updated by a given pipe state (the oring is in the winsys) There is no prebuild register list or define for each pipe state. Once pipe state are built they are bound to the winsys context. Each of this functions will go through the list of register and will find into which block each reg falls and will update the value of the block with proper masking (vs/ps resource/constant are specialized variant with somewhat limited capabilities). Each block modified by r600_context_pipe_state_set* is marked as dirty and we update a count of dwords needed to emit all dirty state so far. r600_context_pipe_state_set* should be call only when pipe context change some of the state (thus when pipe bind state or set state) Then to draw primitive you make a call to r600_context_draw void r600_context_draw(struct r600_context *ctx, struct r600_draw *draw) It will check if there is enough dwords in current cs buffer and if not will flush. Once there is enough room it will copy packet from dirty block and then add the draw packet3 to initiate the draw. The flush will send the current cs, reset the count of dwords to 0 and remark all states that are enabled as dirty and recompute the number of dwords needed to send the current context. Signed-off-by: Jerome Glisse <jglisse@redhat.com>
2010-09-17r600g: Fixed the shift in S_02880C_KILL_ENABLE.Tilman Sauerbeck
Signed-off-by: Tilman Sauerbeck <tilman@code-monkey.de>
2010-09-17r600g: Enable PIPE_SHADER_CAP_TGSI_CONT_SUPPORTED.Tilman Sauerbeck
Signed-off-by: Tilman Sauerbeck <tilman@code-monkey.de>
2010-09-17r600g: Only set PA_SC_EDGERULE on rv770 and greater.Tilman Sauerbeck
This is what xf86-video-ati and r600c do. Signed-off-by: Tilman Sauerbeck <tilman@code-monkey.de>
2010-09-17r600g: Added DB_SHADER_CONTROL defines.Tilman Sauerbeck
Signed-off-by: Tilman Sauerbeck <tilman@code-monkey.de>
2010-09-17r600g: Formatting fixes.Tilman Sauerbeck
Signed-off-by: Tilman Sauerbeck <tilman@code-monkey.de>
2010-09-17r600g: add upload manager support.Dave Airlie
this add support for the upload manager for uploading user vbo/index buffers. this provides a considerable speedup in q3 type games.
2010-09-17r600g: add support for kernel boDave Airlie
this moves to using a pb bufmgr instead of kernel bos directly.
2010-09-17r600g: move constant buffer creation behind winsys abstraction.Dave Airlie
this paves the way for moving to pb bufmgrs now.
2010-09-17r600g: attempt to abstract kernel bos from pipe driver.Dave Airlie
introduce an abstraction layer between kernel bos and the winsys BOs. this is to allow plugging in pb manager with minimal disruption to pipe driver.
2010-09-17r600g: hide radeon_ctx inside winsys.Dave Airlie
no need for this info to be exported to pipe driver.
2010-09-16r600g: Use clamped math for RCP and RSQ.Tilman Sauerbeck
This is likely only correct for OpenGL and not other state trackers. Signed-off-by: Tilman Sauerbeck <tilman@code-monkey.de>
2010-09-16r600g: Fixed a bo leak in r600_blit_state_ps_shader().Tilman Sauerbeck
We would leak the newly created bo if it cannot be mapped. Signed-off-by: Tilman Sauerbeck <tilman@code-monkey.de>
2010-09-16r600g: fix texture bos and avoid doing depth blit on evergreenDave Airlie
since the depth blit code is hardcoded hex yay \o/
2010-09-16r600g: fixup texture state on evergreen.Dave Airlie
This whole set of state just seems wrong, another cut-n-paste nightmare.
2010-09-16r600g: add vgt dma src definesDave Airlie
2010-09-16r600g: use index min/max + index buffer offset.Dave Airlie
more prep work for fixing up buffer handling
2010-09-16r600g: pull r600_draw struct out into headerDave Airlie
we need this for future buffer rework, it also makes the vtbl easier
2010-09-15r600g: misc cleanupJohn Doe
Avoid using r600_screen structure to get ptr to radeon winsys structure. Signed-off-by: Jerome Glisse <jglisse@redhat.com>
2010-09-15r600g: Silence unused variable warning.Vinson Lee
The code that uses dname is currently ifdef'ed out.
2010-09-15r600g: Silence uninitialized variable warning.Vinson Lee
2010-09-15r600g: Silence uninitialized variable warning.Vinson Lee
2010-09-15r600g: Silence uninitialized variable warning.Vinson Lee
2010-09-15r600g: Silence uninitialized variable warning.Vinson Lee
2010-09-15r600g: Silence uninitialized variable warning.Vinson Lee
2010-09-14r600g: Remove unnecessary headers.Vinson Lee
2010-09-14gallium: introduce get_shader_param (ALL DRIVERS CHANGED) (v3)Luca Barbieri
Changes in v3: - Also change trace, which I forgot about Changes in v2: - No longer adds tessellation shaders Currently each shader cap has FS and VS versions. However, we want a version of them for geometry, tessellation control, and tessellation evaluation shaders, and want to be able to easily query a given cap type for a given shader stage. Since having 5 duplicates of each shader cap is unmanageable, add a new get_shader_param function that takes both a shader cap from a new enum and a shader stage. Drivers with non-unified shaders will first switch on the shader and, within each case, switch on the cap. Drivers with unified shaders instead first check whether the shader is supported, and then switch on the cap. MAX_CONST_BUFFERS is now per-stage. The geometry shader cap is removed in favor of checking whether the limit of geometry shader instructions is greater than 0, which is also used for tessellation shaders. WARNING: all drivers changed and compiled but only nvfx tested
2010-09-13r600g: evergreen fixup dsa state for running query.Dave Airlie
evergreen is always the same as r700 here.
2010-09-12pb: add void * for flush ctx to mapping functionsDave Airlie
If the buffer we are attempting to map is referenced by the unsubmitted command stream for this context, we need to flush the command stream, however to do that we need to be able to access the context at the lowest level map function, currently we set the buffer in the toplevel map, but this racy between context. (we probably have a lot more issues than that.) I'll look into a proper solution as suggested by jrfonseca when I get some time.
2010-09-11r600g: Undo bo placement change.Tilman Sauerbeck
This reverts a part of e795ca8f3175fa6fd97b6b2ef2775e3f8803012a that causes artefacts and a performance drop. Signed-off-by: Tilman Sauerbeck <tilman@code-monkey.de>
2010-09-10r600g: Fixed a bo reference leak in the draw module.Tilman Sauerbeck
Signed-off-by: Tilman Sauerbeck <tilman@code-monkey.de>
2010-09-10r600g: Fixed a bo leak in r600_texture_from_handle().Tilman Sauerbeck
We would leak bo if the argument check failed. Signed-off-by: Tilman Sauerbeck <tilman@code-monkey.de>
2010-09-10r600g: Don't leave stale references in query_list when we cannot create bo.Tilman Sauerbeck
Signed-off-by: Tilman Sauerbeck <tilman@code-monkey.de>
2010-09-10r600g: Implemented the y component write for the LOG opcode.Tilman Sauerbeck
This makes the 'vp1-LOG test' piglit test work. Signed-off-by: Tilman Sauerbeck <tilman@code-monkey.de>
2010-09-10r600g: fixup state calculations for picking states.Dave Airlie
for evergreen I ended up using a non-contig array of states, but this code needs a bit of fixing up to deal with that.
2010-09-10r600g: fixup CB state numbering headerDave Airlie
2010-09-10r600g: fix warning in r600 pipe driverDave Airlie
2010-09-10r600g: evergreen CBs are more sane to support with a single stateDave Airlie
2010-09-10r600g: add initial evergreen supportDave Airlie
adds shader opcodes + assembler support (except ARL) uses constant buffers add interp instructions in fragment shader adds all evergreen hw states adds evergreen pm4 support. this runs gears for me on my evergreen
2010-09-10r600g: align flushing of cb/db with DDX/r600c.Dave Airlie
the DDX and r600c both flush cb/db after the draw is emitted, as long as they do that, r600g can't be different, as it races. We end up with r600g flush, set CB, DDX set CB, flush. This was causing misrendering on my evergreen, where sometimes the drawing would go to an old CB.
2010-09-10r600g: don't need 3 bos here.Dave Airlie
the code should reloc correctly a single BO 3 times.
2010-09-08r600g: add initial bank swizzle support.Dave Airlie
this is ported from r600c mostly, bank swizzling is real messy and I don't think I got enough sleep last night to fully understand it.
2010-09-08r600g: Added missing r600_bc_add_literal() calls to XPD implementation.Tilman Sauerbeck
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-09-08r600g: Added preliminary support for the LOG opcode.Tilman Sauerbeck
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-09-08r600g: Added missing abs-ification to RSQ.Tilman Sauerbeck
This makes the 'fp1-RSQ test 2' piglit test work. Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-09-08r600g: split opcodes out and add wrapper around usage.Dave Airlie
This splits the r600 opcodes out of the sq file and adds a wrapper so we can convert to evergreen opcodes later without touching these functions too much.
2010-09-08r600g: add support for constants in memory buffers.Dave Airlie
DX9 constants were in the constant file, and evergreen no longer support cfile. r600/700 can also use constants in memory buffers, so add the code (disabled for now) to enable that as precursor for evergreen.