mesa.git
14 years agou_blitter: use PIPE_TRANSFER_DISCARD to prevent cpu/gpu stall
Marek Olšák [Tue, 23 Nov 2010 13:09:21 +0000 (14:09 +0100)]
u_blitter: use PIPE_TRANSFER_DISCARD to prevent cpu/gpu stall

But the driver must be smart here and follow PIPE_TRANSFER_DISCARD,
as it should.

14 years agonvfx: reset nvfx->hw_zeta
Xavier Chantry [Wed, 24 Nov 2010 20:50:36 +0000 (21:50 +0100)]
nvfx: reset nvfx->hw_zeta

If nvfx_framebuffer prepare and validate were called successively with
fb->zsbuf not NULL and then NULL, nvfx->hw_zeta would contain garbage and
this would cause failures in nvfx_framebuffer_relocate/OUT_RELOC(hw_zeta).

This was triggered by piglit/texwrap 2D GL_DEPTH_COMPONENT24 and caused
first a 'write to user buffer!!' error in libdrm and then worse things.

Signed-off-by: Xavier Chantry <chantry.xavier@gmail.com>
Signed-off-by: Francisco Jerez <currojerez@riseup.net>
14 years agonvfx: fb->nr_cbufs <= 1 on nv30
Xavier Chantry [Wed, 24 Nov 2010 20:50:35 +0000 (21:50 +0100)]
nvfx: fb->nr_cbufs <= 1 on nv30

7e1bf946316ff99feaa3f2e85f70b45bd9a77ade changed
PIPE_CAP_MAX_RENDER_TARGETS to 1 on nv30.

Signed-off-by: Xavier Chantry <chantry.xavier@gmail.com>
Signed-off-by: Francisco Jerez <currojerez@riseup.net>
14 years agoglsl: Add a virtual as_discard() method.
Kenneth Graunke [Thu, 25 Nov 2010 05:33:07 +0000 (21:33 -0800)]
glsl: Add a virtual as_discard() method.

NOTE: This is candidate for the 7.9 branch.

14 years agoglsl: Use do_common_optimization in the standalone compiler.
Kenneth Graunke [Thu, 25 Nov 2010 07:54:03 +0000 (23:54 -0800)]
glsl: Use do_common_optimization in the standalone compiler.

NOTE: This is a candidate for the 7.9 branch.

14 years agoglsl: Don't inline function prototypes.
Kenneth Graunke [Thu, 25 Nov 2010 08:09:43 +0000 (00:09 -0800)]
glsl: Don't inline function prototypes.

Currently, the standalone compiler tries to do function inlining before
linking shaders (including linking against the built-in functions).
This resulted in the built-in function _prototypes_ being inlined rather
than the actual function definition.

This is only known to fix a bug in the standalone compiler; most
programs should be unaffected.  Still, it seems like a good idea.

NOTE: This is a candidate for the 7.9 branch.

14 years agor300/compiler: Move declaration before code.
Vinson Lee [Thu, 25 Nov 2010 07:03:26 +0000 (23:03 -0800)]
r300/compiler: Move declaration before code.

Fixes this GCC warning with linux-x86 build.
radeon_pair_regalloc.c: In function ‘compute_live_intervals’:
radeon_pair_regalloc.c:222: warning: ISO C90 forbids mixed declarations and code

14 years agor300/compiler: Move declaration before code.
Vinson Lee [Thu, 25 Nov 2010 07:00:03 +0000 (23:00 -0800)]
r300/compiler: Move declaration before code.

Fixes this GCC warning with linux-x86 build.
radeon_pair_regalloc.c: In function ‘compute_live_intervals’:
radeon_pair_regalloc.c:221: warning: ISO C90 forbids mixed declarations and code

14 years agost/vega: Fix a typo in EXTENDED_BLENDER_OVER_FUNC.
Chia-I Wu [Thu, 25 Nov 2010 05:18:47 +0000 (13:18 +0800)]
st/vega: Fix a typo in EXTENDED_BLENDER_OVER_FUNC.

The typo was introduced by commit
231d5457b275c1d9bbeff14165cf3da33dda176b.

14 years agost/vega: No flipping in vg_prepare_blend_surface.
Chia-I Wu [Thu, 25 Nov 2010 05:01:17 +0000 (13:01 +0800)]
st/vega: No flipping in vg_prepare_blend_surface.

The blend sampler view is addressed with unnormalized coordinates in the
fragment shader.  It should have the same orientation as the surface
does.

14 years agost/vega: Masks and surfaces should share orientation.
Chia-I Wu [Thu, 25 Nov 2010 04:20:15 +0000 (12:20 +0800)]
st/vega: Masks and surfaces should share orientation.

The alpha mask is addressed with unnormalized coordinates in the
fragment shader.  It should have the same orientation as the surface
does.

This fixes "mask" OpenVG demo.

14 years agost/vega: Fix a crash with empty paths.
Chia-I Wu [Wed, 24 Nov 2010 08:29:10 +0000 (16:29 +0800)]
st/vega: Fix a crash with empty paths.

14 years agoauxiliary: util_blit_pixels_tex should restore the viewport.
Chia-I Wu [Thu, 25 Nov 2010 05:00:18 +0000 (13:00 +0800)]
auxiliary: util_blit_pixels_tex should restore the viewport.

Viewport state should be saved/restored.

14 years agor300g/r600g: bump cache manager timeouts to 1s
Dave Airlie [Wed, 24 Nov 2010 21:29:03 +0000 (07:29 +1000)]
r300g/r600g: bump cache manager timeouts to 1s

On lightsmark on my r500 this drop the bufmgr allocations of the sysprof.

14 years agomesa: Fix glGet of ES2's GL_MAX_*_VECTORS properties.
Kenneth Graunke [Wed, 24 Nov 2010 21:59:46 +0000 (13:59 -0800)]
mesa: Fix glGet of ES2's GL_MAX_*_VECTORS properties.

Previously, the get table listed all three as having custom locations,
yet find_custom_value did not have cases to handle them.

MAX_VARYING_VECTORS does not need a custom location since MaxVaryings is
already stored as float[4] (or vec4).  MaxUniformComponents is stored as
the number of floats, however, so a custom implementation that divides
by 4 is necessary.

Fixes bugs.freedesktop.org #31495.

14 years agometa: Mask Stencil.Clear against stencilMax in _mesa_meta_Clear
Peter Clifton [Wed, 24 Nov 2010 15:24:31 +0000 (15:24 +0000)]
meta: Mask Stencil.Clear against stencilMax in _mesa_meta_Clear

This fixes incorrect behaviour when the stencil clear value exceeds
the size of the stencil buffer, for example, when set with:

glClearStencil (~1); /* Set a bit pattern of 111...11111110 */
glClear (GL_STENCIL_BUFFER_BIT);

The clear value needs to be masked by the value 2^m - 1, where m is the
number of bits in the stencil buffer. Previously, we passed the value
masked with 0x7fffffff to _mesa_StencilFuncSeparate which then clamps,
NOT masks the value to the range 0 to 2^m - 1.

The result would be clearing the stencil buffer to 0xff, rather than 0xfe.

Signed-off-by: Peter Clifton <pcjc2@cam.ac.uk>
Signed-off-by: Brian Paul <brianp@vmware.com>
14 years agox11: remove test_proxy_teximage() function
Brian Paul [Wed, 24 Nov 2010 19:01:02 +0000 (12:01 -0700)]
x11: remove test_proxy_teximage() function

This was really just for testing purposes.

14 years agomesa: added _mesa_format_image_size64()
Brian Paul [Wed, 24 Nov 2010 19:00:16 +0000 (12:00 -0700)]
mesa: added _mesa_format_image_size64()

14 years agomesa: add assertion and update comment in _mesa_format_image_size()
Brian Paul [Wed, 24 Nov 2010 17:24:17 +0000 (10:24 -0700)]
mesa: add assertion and update comment in _mesa_format_image_size()

14 years agoi965: Don't write mrf assignment for pointsize output
Kristian Høgsberg [Wed, 24 Nov 2010 15:12:20 +0000 (10:12 -0500)]
i965: Don't write mrf assignment for pointsize output

https://bugs.freedesktop.org/show_bug.cgi?id=31894

14 years agogallium/targets/xorg-vmwgfx: Xv fixes
Thomas Hellstrom [Wed, 24 Nov 2010 14:18:15 +0000 (15:18 +0100)]
gallium/targets/xorg-vmwgfx: Xv fixes

Make sure regions are properly updated and that the colorkey painting is
flushed before we update the HW overlay.

Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
14 years agost/xorg: Add a function to flush pending rendering and damage
Thomas Hellstrom [Wed, 24 Nov 2010 14:15:42 +0000 (15:15 +0100)]
st/xorg: Add a function to flush pending rendering and damage

This is needed to properly sync with host side rendering. For example,
make sure we flush colorkey painting before updating the overlay.

Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
14 years agoegl_dri2: Fix one context, multiple surfaces.
Chia-I Wu [Wed, 24 Nov 2010 05:42:06 +0000 (13:42 +0800)]
egl_dri2: Fix one context, multiple surfaces.

When a context was made current to another surface, the old code did
this

  dri2_dpy->core->bindContext(cctx, ddraw, rdraw);
  dri2_dpy->core->unbindContext(old_cctx);

and there will be no current context due to the second line.

unbindContext should be called only when bindContext is not.  This fixes
a regression since d19afc57.  Thanks to Neil Roberts for noticing the
issue and creating a test case.

14 years agoi915: Disallow alpha, red, RG, and sRGB as render targets
Ian Romanick [Wed, 24 Nov 2010 00:17:21 +0000 (16:17 -0800)]
i915: Disallow alpha, red, RG, and sRGB as render targets

Fixes bugzilla #31832

NOTE: This is a candidate for the 7.9 branch.

14 years agoglsl: start restoring some geometry shader code
Brian Paul [Wed, 24 Nov 2010 00:23:42 +0000 (17:23 -0700)]
glsl: start restoring some geometry shader code

14 years agoglsl: better handling of linker failures
Brian Paul [Wed, 24 Nov 2010 00:18:44 +0000 (17:18 -0700)]
glsl: better handling of linker failures

Upon link error, exit translation loop, free program instructions.
Check for null pointers in calling code.

14 years agomesa: use gl_shader_type enum
Brian Paul [Wed, 24 Nov 2010 00:00:08 +0000 (17:00 -0700)]
mesa: use gl_shader_type enum

14 years agomesa: replace #defines with new gl_shader_type enum
Brian Paul [Tue, 23 Nov 2010 17:28:43 +0000 (10:28 -0700)]
mesa: replace #defines with new gl_shader_type enum

14 years agomesa: _mesa_valid_register_index() to validate register indexes
Brian Paul [Tue, 23 Nov 2010 17:12:55 +0000 (10:12 -0700)]
mesa: _mesa_valid_register_index() to validate register indexes

14 years agomesa: rename, make _mesa_register_file_name() non-static
Brian Paul [Tue, 23 Nov 2010 17:11:46 +0000 (10:11 -0700)]
mesa: rename, make _mesa_register_file_name() non-static

Plus remove unused parameter.

14 years agoglsl: use gl_register_file in a few places
Brian Paul [Mon, 22 Nov 2010 23:55:10 +0000 (16:55 -0700)]
glsl: use gl_register_file in a few places

14 years agoglsl: fix off by one in register index assertion
Brian Paul [Mon, 22 Nov 2010 22:06:47 +0000 (15:06 -0700)]
glsl: fix off by one in register index assertion

14 years agogallium/egl: fix r300 vs r600 loading
Alex Deucher [Tue, 23 Nov 2010 20:18:31 +0000 (15:18 -0500)]
gallium/egl: fix r300 vs r600 loading

Should fix:
https://bugs.freedesktop.org/show_bug.cgi?id=31841

14 years agoi965: Use the new embedded compare in SEL on gen6 for VS MIN and MAX opcodes.
Eric Anholt [Mon, 15 Nov 2010 08:01:04 +0000 (16:01 +0800)]
i965: Use the new embedded compare in SEL on gen6 for VS MIN and MAX opcodes.

Cuts the extra CMP instruction that used to precede SEL.

14 years agoi965: Don't upload line smooth params unless we're line smoothing.
Eric Anholt [Fri, 19 Nov 2010 15:04:35 +0000 (23:04 +0800)]
i965: Don't upload line smooth params unless we're line smoothing.

14 years agoi965: Don't upload line stipple pattern unless we're stippling.
Eric Anholt [Fri, 19 Nov 2010 15:02:07 +0000 (23:02 +0800)]
i965: Don't upload line stipple pattern unless we're stippling.

14 years agoi965: Don't upload polygon stipple unless required.
Eric Anholt [Fri, 19 Nov 2010 14:53:31 +0000 (22:53 +0800)]
i965: Don't upload polygon stipple unless required.

14 years agoi965: Move gen4 blend constant color to the gen4 blending file.
Eric Anholt [Fri, 19 Nov 2010 14:58:48 +0000 (22:58 +0800)]
i965: Move gen4 blend constant color to the gen4 blending file.

14 years agor600g: Removed duplicated call to tgsi_split_literal_constant().
Tilman Sauerbeck [Fri, 19 Nov 2010 21:31:43 +0000 (22:31 +0100)]
r600g: Removed duplicated call to tgsi_split_literal_constant().

Signed-off-by: Tilman Sauerbeck <tilman@code-monkey.de>
14 years agor300/compiler: Don't allow presubtract sources to be remapped twice
Tom Stellard [Tue, 23 Nov 2010 07:48:47 +0000 (23:48 -0800)]
r300/compiler: Don't allow presubtract sources to be remapped twice

https://bugs.freedesktop.org/show_bug.cgi?id=31193

NOTE: This is a candidate for the 7.9 branch.

14 years agor600g: Only compare active vertex elements
Mathias Fröhlich [Tue, 23 Nov 2010 07:39:30 +0000 (08:39 +0100)]
r600g: Only compare active vertex elements

Signed-off-by: Tilman Sauerbeck <tilman@code-monkey.de>
14 years agomesa: Clean up header file inclusion in syncobj.h.
Vinson Lee [Tue, 23 Nov 2010 05:51:49 +0000 (21:51 -0800)]
mesa: Clean up header file inclusion in syncobj.h.

14 years agollvmpipe: Remove unnecessary headers.
Vinson Lee [Tue, 23 Nov 2010 05:39:14 +0000 (21:39 -0800)]
llvmpipe: Remove unnecessary headers.

14 years agomesa: fix regression from b4bb6680200b5a898583392f4c831c02f41e63f7
Xiang, Haihao [Tue, 23 Nov 2010 00:52:23 +0000 (08:52 +0800)]
mesa: fix regression from b4bb6680200b5a898583392f4c831c02f41e63f7

Pending commands to the previous context aren't flushed since commit b4bb668

Reported-by: Oleksiy Krivoshey <oleksiyk@gmail.com>
Signed-off-by: Xiang, Haihao <haihao.xiang@intel.com>
14 years agor600c: fix VC flush on cedar and palm
Alex Deucher [Tue, 23 Nov 2010 00:27:58 +0000 (19:27 -0500)]
r600c: fix VC flush on cedar and palm

14 years agor600g: add support for ontario APUs
Alex Deucher [Mon, 22 Nov 2010 22:47:24 +0000 (17:47 -0500)]
r600g: add support for ontario APUs

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
14 years agor600c: add Ontario Fusion APU support
Alex Deucher [Mon, 22 Nov 2010 18:25:42 +0000 (13:25 -0500)]
r600c: add Ontario Fusion APU support

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
14 years agor300g: Avoid returning values in a static array, fixing a potential race
Mathias Fröhlich [Mon, 22 Nov 2010 22:19:52 +0000 (23:19 +0100)]
r300g: Avoid returning values in a static array, fixing a potential race

(Marek: added the initializion of "vec" in the default statement)

NOTE: This is a candidate for the 7.9 branch.

Signed-off-by: Marek Olšák <maraeo@gmail.com>
14 years agor600g: fix some winsys functions to deal properly with evergreen
Alex Deucher [Mon, 22 Nov 2010 22:39:54 +0000 (17:39 -0500)]
r600g: fix some winsys functions to deal properly with evergreen

Are these functions actually used anywhere?

14 years agor600g: fix additional EVENT_WRITE packet
Alex Deucher [Mon, 22 Nov 2010 22:39:16 +0000 (17:39 -0500)]
r600g: fix additional EVENT_WRITE packet

Add explicit EVENT_TYPE field

14 years agost/mesa: set MaxUniformComponents
Marek Olšák [Sun, 21 Nov 2010 21:02:02 +0000 (22:02 +0100)]
st/mesa: set MaxUniformComponents

Signed-off-by: Brian Paul <brianp@vmware.com>
14 years agoswrast: init alpha value to 1.0 in opt_sample_rgb_2d()
Brian Paul [Mon, 22 Nov 2010 16:04:13 +0000 (09:04 -0700)]
swrast: init alpha value to 1.0 in opt_sample_rgb_2d()

14 years agogallium: add PIPE_SHADER_CAP_SUBROUTINES
Marek Olšák [Sun, 14 Nov 2010 14:34:59 +0000 (15:34 +0100)]
gallium: add PIPE_SHADER_CAP_SUBROUTINES

This fixes piglit/glsl-vs-main-return and glsl-fs-main-return for the drivers
which don't support RET (i915g, r300g, r600g, svga).

ir_to_mesa does not currently generate subroutines, but it's a matter of time
till it's added. It would then break all the drivers which don't implement
them, so this CAP makes sense.

Signed-off-by: Marek Olšák <maraeo@gmail.com>
14 years agoMerge branch 'lp-offset-twoside'
Keith Whitwell [Mon, 22 Nov 2010 10:36:01 +0000 (10:36 +0000)]
Merge branch 'lp-offset-twoside'

14 years agor600g: pick correct color swap for A8 fbos.
Dave Airlie [Mon, 22 Nov 2010 06:03:00 +0000 (16:03 +1000)]
r600g: pick correct color swap for A8 fbos.

This fixes fdo bug 31810.

Signed-off-by: Dave Airlie <airlied@redhat.com>
14 years agor300/compiler: Add a more efficient version of rc_find_free_temporary()
Tom Stellard [Fri, 12 Nov 2010 08:59:13 +0000 (00:59 -0800)]
r300/compiler: Add a more efficient version of rc_find_free_temporary()

14 years agor300/compiler: Enable rename_reg pass for r500 cards
Tom Stellard [Thu, 11 Nov 2010 05:34:18 +0000 (21:34 -0800)]
r300/compiler: Enable rename_reg pass for r500 cards

In addition, the rename_reg pass has been rewritten to use
rc_get_readers().

14 years agor300/compiler: Use presubtract operations as much as possible
Tom Stellard [Tue, 9 Nov 2010 02:49:44 +0000 (18:49 -0800)]
r300/compiler: Use presubtract operations as much as possible

Previously, presubtract operations where only being used by instructions
with less than three source source registers.

14 years agor300/compiler: Convert RGB to alpha in the scheduler
Tom Stellard [Thu, 30 Sep 2010 06:52:49 +0000 (23:52 -0700)]
r300/compiler: Convert RGB to alpha in the scheduler

14 years agor300/compiler: Track readers through branches in rc_get_readers()
Tom Stellard [Sat, 6 Nov 2010 18:30:27 +0000 (11:30 -0700)]
r300/compiler: Track readers through branches in rc_get_readers()

14 years agor300/compiler: Handle BREAK and CONTINUE in rc_get_readers()
Tom Stellard [Sun, 14 Nov 2010 01:00:45 +0000 (17:00 -0800)]
r300/compiler: Handle BREAK and CONTINUE in rc_get_readers()

14 years agor300/compiler: Add rc_get_readers()
Tom Stellard [Sat, 30 Oct 2010 05:27:04 +0000 (22:27 -0700)]
r300/compiler: Add rc_get_readers()

14 years agor300/compiler: Ignore alpha dest register when replicating the result
Tom Stellard [Thu, 11 Nov 2010 09:13:01 +0000 (01:13 -0800)]
r300/compiler: Ignore alpha dest register when replicating the result

When the result of the alpha instruction is being replicated to the RGB
destination register, we do not need to use alpha's destination register.
This fixes an invalid "Too many hardware temporaries used" error in
the case where a transcendent operation writes to a temporary register
greater than max_temp_regs.

NOTE: This is a candidate for the 7.9 branch.

14 years agor300/compiler: Use zero as the register index for unused sources
Tom Stellard [Thu, 11 Nov 2010 09:01:13 +0000 (01:01 -0800)]
r300/compiler: Use zero as the register index for unused sources

This fixes an invalid "Too many hardware temporaries used" error in the
case where a source reads from a temporary register with an index greater
than max_temp_regs and then the source is marked as unused before the
register allocation pass.

NOTE: This is a candidate for the 7.9 branch.

14 years agor300/compiler: Fix instruction scheduling within IF blocks
Tom Stellard [Sun, 14 Nov 2010 01:12:58 +0000 (17:12 -0800)]
r300/compiler: Fix instruction scheduling within IF blocks

Reads of registers that where not written to within the same block were
not being tracked.  So in a situations like this:
0: IF
1: ADD t0, t1, t2
2: MOV t2, t1

Instruction 2 didn't know that instruction 1 read from t2, so
in some cases instruction 2 was being scheduled before instruction 1.

NOTE: This is a candidate for the 7.9 branch.

14 years agor300/compiler: Fix register allocator's handling of loops
Tom Stellard [Sun, 14 Nov 2010 00:57:06 +0000 (16:57 -0800)]
r300/compiler: Fix register allocator's handling of loops

NOTE: This is a candidate for the 7.9 branch.

14 years agor300/compiler: Make sure presubtract sources use supported swizzles
Tom Stellard [Thu, 11 Nov 2010 09:28:44 +0000 (01:28 -0800)]
r300/compiler: Make sure presubtract sources use supported swizzles

NOTE: This is a candidate for the 7.9 branch.

14 years agor600: Remove unnecessary header.
Vinson Lee [Sun, 21 Nov 2010 23:02:51 +0000 (15:02 -0800)]
r600: Remove unnecessary header.

14 years agodocs: add GL 4.1 status
Marek Olšák [Sun, 21 Nov 2010 21:54:33 +0000 (22:54 +0100)]
docs: add GL 4.1 status

14 years agost/mesa: enable ARB_explicit_attrib_location and EXT_separate_shader_objects
Marek Olšák [Sun, 21 Nov 2010 00:53:05 +0000 (01:53 +0100)]
st/mesa: enable ARB_explicit_attrib_location and EXT_separate_shader_objects

Gallium drivers pass all piglit tests for the two (there are 12 tests
for separate_shader_objects and 5 tests for explicit_attrib_location),
and I was told the extensions don't need any driver-specific code.

I made them dependent on PIPE_CAP_GLSL.

Signed-off-by: Brian Paul <brianp@vmware.com>
14 years agomesa: fix get_texture_dimensions() for texture array targets
Brian Paul [Sun, 21 Nov 2010 17:05:47 +0000 (10:05 -0700)]
mesa: fix get_texture_dimensions() for texture array targets

Fixes http://bugs.freedesktop.org/show_bug.cgi?id=31779

14 years agodocs: update some GL 3.0 status
Brian Paul [Sun, 21 Nov 2010 16:31:19 +0000 (09:31 -0700)]
docs: update some GL 3.0 status

14 years agomesa: hook up GL 3.x entrypoints
Brian Paul [Sun, 21 Nov 2010 16:19:23 +0000 (09:19 -0700)]
mesa: hook up GL 3.x entrypoints

Fix up some details in the xml files and regenerate dispatch files.

14 years agoglapi: rename GL3.xml to GL3x.xml as it covers all GL 3.x versions
Brian Paul [Sun, 21 Nov 2010 16:13:59 +0000 (09:13 -0700)]
glapi: rename GL3.xml to GL3x.xml as it covers all GL 3.x versions

14 years agomesa: fix error msg typo
Brian Paul [Fri, 19 Nov 2010 21:34:07 +0000 (14:34 -0700)]
mesa: fix error msg typo

14 years agoi915g: kill idws->pool
Daniel Vetter [Fri, 19 Nov 2010 22:38:23 +0000 (23:38 +0100)]
i915g: kill idws->pool

The drm winsys only ever handles one gem memory manager. Rip out
the unnecessary complication.

Reviewed-by: Jakob Bornecrantz <wallbraker@gmail.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Jakob Bornecrantz <wallbraker@gmail.com>
14 years agoi915g: kill buf->map_gtt
Daniel Vetter [Fri, 19 Nov 2010 22:38:22 +0000 (23:38 +0100)]
i915g: kill buf->map_gtt

Not using the gtt is considered harmful for performance. And for
partial uploads there's always drm_intel_bo_subdata.

Reviewed-by: Jakob Bornecrantz <wallbraker@gmail.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Jakob Bornecrantz <wallbraker@gmail.com>
14 years agoi915g: kill RGBA/X formats
Daniel Vetter [Fri, 19 Nov 2010 22:38:21 +0000 (23:38 +0100)]
i915g: kill RGBA/X formats

It's intel, so always little endian!

Reviewed-by: Jakob Bornecrantz <wallbraker@gmail.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Jakob Bornecrantz <wallbraker@gmail.com>
14 years agoi915g: add pineview pci ids
Daniel Vetter [Fri, 19 Nov 2010 22:38:20 +0000 (23:38 +0100)]
i915g: add pineview pci ids

Reviewed-by: Jakob Bornecrantz <wallbraker@gmail.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Jakob Bornecrantz <wallbraker@gmail.com>
14 years agoi915g: s/hw_tiled/tiling
Daniel Vetter [Fri, 19 Nov 2010 22:38:19 +0000 (23:38 +0100)]
i915g: s/hw_tiled/tiling

More in line with other intel drivers.

Change to use enum by Jakob Bornecrantz.

Reviewed-by: Jakob Bornecrantz <wallbraker@gmail.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Jakob Bornecrantz <wallbraker@gmail.com>
14 years agoi915g: rip out ->sw_tiled
Daniel Vetter [Fri, 19 Nov 2010 22:38:18 +0000 (23:38 +0100)]
i915g: rip out ->sw_tiled

It looks like this was meant to facilitate unfenced access to textures/
color/renderbuffers. It's totally incomplete and fundamentally broken
on a few levels:
- broken: The kernel needs to about every tiled bo to fix up bit17
  swizzling on swap-in.
- unflexible: fenced/unfenced relocs from execbuffer2 do the same, much
  simpler.
- unneeded: with relaxed fencing tiled gem bos are as memory-efficient
  as this trick.

Hence kill it.

Reviewed-by: Jakob Bornecrantz <wallbraker@gmail.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Jakob Bornecrantz <wallbraker@gmail.com>
14 years agor300g: silence guard band cap errors
Joakim Sindholt [Sun, 21 Nov 2010 12:24:03 +0000 (13:24 +0100)]
r300g: silence guard band cap errors

Somebody should find out what these are. It can be found on Windows
getting a D3DCAPS9 from IDirect3D9::GetCaps() and reading the
GuardBand* values.

14 years agost/vega: Fix vgReadPixels with a subrectangle.
Chia-I Wu [Sun, 21 Nov 2010 10:58:47 +0000 (18:58 +0800)]
st/vega: Fix vgReadPixels with a subrectangle.

Fix a crash when the subrectangle is not inside the fb.  Fix wrong
pipe transfer when sx > 0 or sy + height != fb->height.

This fixes "readpixels" demo.

14 years agost/vega: Set wrap_r for mask and blend samplers.
Chia-I Wu [Sun, 21 Nov 2010 10:46:57 +0000 (18:46 +0800)]
st/vega: Set wrap_r for mask and blend samplers.

These two samplers use non-normalized texture coordinates.  wrap_r
cannot be PIPE_TEX_WRAP_REPEAT (the default).

This fixes

  sp_tex_sample.c:1790:get_linear_unorm_wrap: Assertion `0' failed

assertion failure.

14 years agost/vega: vegaLookupSingle should validate the state.
Chia-I Wu [Sun, 21 Nov 2010 10:44:21 +0000 (18:44 +0800)]
st/vega: vegaLookupSingle should validate the state.

Fix "lookup" demo crash.

14 years agotgsi: Add STENCIL to text parser.
Chia-I Wu [Sun, 21 Nov 2010 10:36:41 +0000 (18:36 +0800)]
tgsi: Add STENCIL to text parser.

Fix OpenVG "filter" demo

  Program received signal SIGSEGV, Segmentation fault.
  0xb7153dc9 in str_match_no_case (pcur=0xbfffe564, str=0x0) at
  tgsi/tgsi_text.c:86
  86         while (*str != '\0' && *str == uprcase( *cur )) {

14 years agomesa: Clean up header file inclusion in stencil.h.
Vinson Lee [Sun, 21 Nov 2010 06:44:33 +0000 (22:44 -0800)]
mesa: Clean up header file inclusion in stencil.h.

14 years agomesa: Clean up header file inclusion in shared.h.
Vinson Lee [Sun, 21 Nov 2010 06:30:27 +0000 (22:30 -0800)]
mesa: Clean up header file inclusion in shared.h.

14 years agomesa: Clean up header file inclusion in shaderapi.h.
Vinson Lee [Sun, 21 Nov 2010 06:17:28 +0000 (22:17 -0800)]
mesa: Clean up header file inclusion in shaderapi.h.

14 years agomesa: Clean up header file inclusion in scissor.h.
Vinson Lee [Sun, 21 Nov 2010 06:01:30 +0000 (22:01 -0800)]
mesa: Clean up header file inclusion in scissor.h.

14 years agomesa: Clean up header file inclusion in renderbuffer.h.
Vinson Lee [Sun, 21 Nov 2010 05:32:07 +0000 (21:32 -0800)]
mesa: Clean up header file inclusion in renderbuffer.h.

14 years agomesa: Clean up header file inclusion in readpix.h.
Vinson Lee [Sun, 21 Nov 2010 05:23:35 +0000 (21:23 -0800)]
mesa: Clean up header file inclusion in readpix.h.

14 years agomesa: Clean up header file inclusion in rastpos.h.
Vinson Lee [Sun, 21 Nov 2010 05:14:06 +0000 (21:14 -0800)]
mesa: Clean up header file inclusion in rastpos.h.

14 years agomesa: Clean up header file inclusion in polygon.h.
Vinson Lee [Sun, 21 Nov 2010 05:06:09 +0000 (21:06 -0800)]
mesa: Clean up header file inclusion in polygon.h.

14 years agointel: Remove unnecessary header.
Vinson Lee [Sun, 21 Nov 2010 04:13:50 +0000 (20:13 -0800)]
intel: Remove unnecessary header.

14 years agor600: Remove unnecesary header.
Vinson Lee [Sun, 21 Nov 2010 03:04:30 +0000 (19:04 -0800)]
r600: Remove unnecesary header.

14 years agoswrast: Remove unnecessary header.
Vinson Lee [Sun, 21 Nov 2010 03:00:18 +0000 (19:00 -0800)]
swrast: Remove unnecessary header.

14 years agost/mesa: Remove unnecessary headers.
Vinson Lee [Sun, 21 Nov 2010 02:48:09 +0000 (18:48 -0800)]
st/mesa: Remove unnecessary headers.

14 years agoscons: Define IN_DRI_DRIVER.
Chia-I Wu [Sun, 21 Nov 2010 01:47:11 +0000 (17:47 -0800)]
scons: Define IN_DRI_DRIVER.

The define is required for DRI drivers.  It is not needed for
libgl-xlib, but the overhead it introduces should be minor.

14 years agonvfx: only expose one rt on nv30
Xavier Chantry [Sat, 20 Nov 2010 21:51:12 +0000 (22:51 +0100)]
nvfx: only expose one rt on nv30

We do not know how to use more, GL_ARB_draw_buffers is not exposed on blob.