Corbin Simpson [Mon, 18 May 2009 03:49:39 +0000 (20:49 -0700)]
r300-gallium: Size mismatch.
Corbin Simpson [Mon, 18 May 2009 00:03:15 +0000 (17:03 -0700)]
r300-gallium, radeon-gallium: Nuke gb_pipes from orbit.
See the previous commit for an explanation. This is just all the support code
for GB_TILE_CONFIG.
Corbin Simpson [Sun, 17 May 2009 23:42:54 +0000 (16:42 -0700)]
r300-gallium: Don't set GB_TILE_CONFIG (in userspace.)
This accompanies kernel patches that make GB_TILE_CONFIG's various members
completely controlled in DRM.
GB_TILE_CONFIG has the following controls:
- The number of GB (pixel) pipes enabled
- The size and style of tiling
- Subpixel precision (either 1/12 or 1/16)
Per airlied and glisse, userspace and kernel will now agree (always) on
a subpixel precision of 1/12, and tiling will always be kernel-controlled.
Corbin Simpson [Sun, 17 May 2009 20:23:39 +0000 (13:23 -0700)]
r300-gallium: Clean up more invariant state.
GA_ENHANCE is now the kernel's problem.
Corbin Simpson [Sun, 17 May 2009 19:51:18 +0000 (12:51 -0700)]
r300-gallium: Update XXX.
Lops work fine as long as HW TCL is off. (I think I know why.)
Corbin Simpson [Sun, 17 May 2009 18:58:53 +0000 (11:58 -0700)]
r300-gallium: Correct default MSPOS.
Per agd5f.
Corbin Simpson [Sun, 17 May 2009 17:33:56 +0000 (10:33 -0700)]
r300-gallium: vs: Fix vert shader init.
Makes the last three commits suck much less. :3
Corbin Simpson [Sun, 17 May 2009 17:30:59 +0000 (10:30 -0700)]
r300-gallium: r500-fs: Enable depth writes, kinda.
Should work, but doesn't. Hm.
Corbin Simpson [Sun, 17 May 2009 16:44:14 +0000 (09:44 -0700)]
r300-gallium: Comment out useless debugging code.
Those parts are nearly solid compared to the shaders.
Corbin Simpson [Sun, 17 May 2009 16:39:06 +0000 (09:39 -0700)]
r300-gallium: vs: Dupe tokens, better debug, count spurious insts.
Corbin Simpson [Sat, 16 May 2009 18:17:05 +0000 (11:17 -0700)]
r300-gallium: Die on bad texture formats.
Odds are good that we'll die later anyway, so we might as well do it before
we start dancing on random memory.
Corbin Simpson [Sat, 16 May 2009 17:56:17 +0000 (10:56 -0700)]
r300-gallium: Update floating-point params too.
Even though we *can* render 10,000-pixel-wide lines, let's not advertise it.
Corbin Simpson [Sat, 16 May 2009 17:46:55 +0000 (10:46 -0700)]
r300-gallium: Update screen caps.
Anisotropic filtering should work, and OQ is broken.
Corbin Simpson [Sat, 16 May 2009 17:03:46 +0000 (10:03 -0700)]
intel-gallium: Fix trace_drm integration.
Compile-tested only, sorry.
Corbin Simpson [Sat, 16 May 2009 16:58:54 +0000 (09:58 -0700)]
Create common trace_drm code, add to radeon_winsys.
Corbin Simpson [Sat, 16 May 2009 15:47:36 +0000 (08:47 -0700)]
r300-gallium: Various cleanups leftover from before.
BEGIN/END_CS pair, a few asserts, and a slightly more correct VTE setup.
Keith Whitwell [Sat, 16 May 2009 16:25:26 +0000 (17:25 +0100)]
gallium: remove occlusion_count flag from depth-stencil state
Drivers can just keep track of whether they are within a query
by monitoring the begin/end query callbacks. The flag adds no
information beyond that.
Only softpipe was examining this flag -- it has been fixed up
and retested with demos/arbocclude.
Jakob Bornecrantz [Sat, 16 May 2009 00:21:02 +0000 (01:21 +0100)]
gallium-intel: Enable trace driver
Jakob Bornecrantz [Sat, 16 May 2009 00:49:11 +0000 (01:49 +0100)]
trace: Export enabled status
Jakob Bornecrantz [Sat, 16 May 2009 00:19:44 +0000 (01:19 +0100)]
trace: Unwrap buffer in texture_blanket
Jakob Bornecrantz [Fri, 15 May 2009 03:59:24 +0000 (05:59 +0200)]
trace: If either shader is disabled don't draw
Jakob Bornecrantz [Fri, 15 May 2009 03:30:43 +0000 (05:30 +0200)]
trace: Put shaders on a list in the context
Jakob Bornecrantz [Fri, 15 May 2009 02:17:00 +0000 (04:17 +0200)]
trace: Move state dump functions to tr_dump_state.[c|h]
Eric Anholt [Sat, 16 May 2009 00:32:21 +0000 (17:32 -0700)]
intel: Don't complain on falling back from PBO fastpaths.
Instead, stash the debug info under the handy debug flag.
Bug #20053
Eric Anholt [Fri, 15 May 2009 23:24:59 +0000 (16:24 -0700)]
mesa: Mark FBOs with compressed color attachments as FBO-incomplete.
Both EXT_fbo and ARB_fbo agree on this. Fixes a segfault in the metaops
mipmap generation in Intel for SGIS_generate_mipmap of S3TC textures in
Regnum Online.
Bug #21654.
Jakob Bornecrantz [Fri, 15 May 2009 21:54:07 +0000 (22:54 +0100)]
gallium-intel: Build with scons
Jakob Bornecrantz [Fri, 15 May 2009 21:47:31 +0000 (22:47 +0100)]
st/egl: Use proper Makefile
Steinar H. Gunderson [Tue, 12 May 2009 18:32:03 +0000 (11:32 -0700)]
i915: Fix 945 cube map layout for the small mipmaps along the bottom.
Bug #21691.
Eric Anholt [Fri, 15 May 2009 19:32:51 +0000 (12:32 -0700)]
i915: Use Stencil.Enabled instead of Stencil._Enabled in DrawBuffers.
The _Enabled field isn't updated at the point that DrawBuffers is called,
and the Driver.Enable() function does the testing for stencil buffer
presence anyway.
bug #21608 for Radeon
Eric Anholt [Fri, 15 May 2009 18:41:42 +0000 (11:41 -0700)]
i915: Only use the new 945 cube layout for compressed textures.
The docs actually explain this, but not in a terribly clear manner.
This nearly fixes the piglit cubemap testcase, except that something's
going wrong with the nearest filtering at 2x2 sizes in the testcase.
Looks good by visual inspection, though.
Bug #21692
Eric Anholt [Thu, 14 May 2009 17:56:32 +0000 (10:56 -0700)]
i965: Fix varying payload reg assignment for the non-GLSL-instructions path.
I don't have a testcase for this, but it seems clearly wrong.
Eric Anholt [Thu, 14 May 2009 16:49:45 +0000 (09:49 -0700)]
i965: Fix register allocation of GLSL fp inputs.
Before, if the VP output something that is in the attributes coming into
the WM but which isn't used by the WM, then WM would end up reading subsequent
varyings from the wrong places. This was visible with a GLSL demo
using gl_PointSize in the VS and a varying in the WM, as point size is in
the VUE but not used by the WM. There is now a regression test in piglit,
glsl-unused-varying.
Eric Anholt [Thu, 14 May 2009 02:08:17 +0000 (19:08 -0700)]
intel: Use FRONT_AND_BACK for StencilOp as well.
Eric Anholt [Thu, 14 May 2009 01:18:29 +0000 (18:18 -0700)]
intel: Use GL_FRONT_AND_BACK for stencil clearing.
This comes from a radeon-rewrite fallback fix, but may also fix stencil
clear failure when the polygon winding mode is flipped.
Corbin Simpson [Thu, 14 May 2009 15:17:08 +0000 (08:17 -0700)]
r300-gallium: Correct VTE setup for surface_fill, make surface_copy emit right.
Robert Ellison [Thu, 14 May 2009 02:40:23 +0000 (20:40 -0600)]
i965: fix 1D texture borders with GL_CLAMP_TO_BORDER
With 1D textures, GL_TEXTURE_WRAP_T should be ignored (only
GL_TEXTURE_WRAP_S should be respected). But the i965 hardware
seems to follow the value of GL_TEXTURE_WRAP_T even when sampling
1D textures.
This fix forces GL_TEXTURE_WRAP_T to be GL_REPEAT whenever 1D
textures are used; this allows the texture to be sampled
correctly, avoiding "imaginary" border elements in the T direction.
This bug was demonstrated in the Piglit tex1d-2dborder test.
With this fix, that test passes.
Robert Ellison [Thu, 14 May 2009 02:38:33 +0000 (20:38 -0600)]
i965: send all warnings through _mesa_warning()
One warning message:
drm_i915_getparam: -22
was still being sent to fprintf(). This causes all Piglit tests to fail,
even with MESA_DEBUG=0.
Using _mesa_warning() to emit the message allows the general Mesa controls
for messages like this to be applied.
Corbin Simpson [Thu, 14 May 2009 00:24:47 +0000 (17:24 -0700)]
r300-gallium: Clean up outdated comments.
Corbin Simpson [Thu, 14 May 2009 00:01:03 +0000 (17:01 -0700)]
r300-gallium: Space accounting for textures.
Brian Paul [Wed, 13 May 2009 17:33:52 +0000 (11:33 -0600)]
Merge branch 'mesa_7_5_branch'
Brian Paul [Wed, 13 May 2009 17:31:35 +0000 (11:31 -0600)]
intel: added null ptr check
Fixes segfault in context tear-down when glClear was never called.
Brian Paul [Wed, 13 May 2009 17:24:11 +0000 (11:24 -0600)]
docs: GL_APPLE_vertex_array_object for Gallium drivers and Intel DRI drivers
Brian Paul [Wed, 13 May 2009 17:19:00 +0000 (11:19 -0600)]
intel: enable GL_APPLE_vertex_array_object
No special driver changes are needed for this extension.
Brian Paul [Wed, 13 May 2009 17:15:00 +0000 (11:15 -0600)]
st/mesa: enable GL_APPLE_vertex_array_object for gallium drivers
Brian Paul [Wed, 13 May 2009 16:33:21 +0000 (10:33 -0600)]
Merge branch 'mesa_7_5_branch'
Conflicts:
src/mesa/main/arrayobj.c
src/mesa/main/arrayobj.h
src/mesa/main/context.c
Brian Paul [Wed, 13 May 2009 16:28:00 +0000 (10:28 -0600)]
intel: create a private gl_array_object for intel_clear_tris(), fix bug 21638
gl_array_object encapsulates a set of vertex arrays (see the
GL_APPLE_vertex_array_object extension).
Create a private gl_array_object for drawing the quad for intel_clear_tris()
so we don't have to worry about the user's vertex array state.
This fixes the no-op glClear bug #21638 and removes the need to call
_mesa_PushClientAttrib() and _mesa_PopClientAttrib().
Brian Paul [Wed, 13 May 2009 15:47:13 +0000 (09:47 -0600)]
mesa: delete array objects before buffer objects during context tear-down
The former may point to the later.
Brian Paul [Wed, 13 May 2009 15:32:53 +0000 (09:32 -0600)]
mesa: clean-up vertex array object VBO unbinding and delete/refcounting
Don't really delete vertex array objects until the refcount hits zero.
At that time, unbind any pointers to VBOs.
(cherry picked from commit
32b851c80792623195069d7a41a5808cff3b2f6f)
Brian Paul [Wed, 13 May 2009 15:27:31 +0000 (09:27 -0600)]
mesa: reference counting for gl_array_object
Every kind of object that can be shared by multiple contexts should be
refcounted.
(cherry picked from commit
1030bf0ded2a88a5e27f7a4d393c11cfde3d3c5a)
Brian Paul [Tue, 12 May 2009 20:08:52 +0000 (14:08 -0600)]
i965: enable additional code in emit_fb_write()
Not 100% sure this is right, but the invalid assertion is fixed...
Brian Paul [Tue, 12 May 2009 20:07:51 +0000 (14:07 -0600)]
i965: increase BRW_EU_MAX_INSN
Brian Paul [Tue, 12 May 2009 15:16:27 +0000 (09:16 -0600)]
i965: comment
Joakim Sindholt [Tue, 12 May 2009 20:01:59 +0000 (22:01 +0200)]
r300-gallium: add missing semicolon
Yeah, that was stupid
Joakim Sindholt [Tue, 12 May 2009 19:41:48 +0000 (21:41 +0200)]
r300-gallium: duplicate tokens in create_fs_state
This was all phoenix64's idea. Credit goes to him
Joakim Sindholt [Tue, 12 May 2009 17:38:17 +0000 (19:38 +0200)]
progs/trivial: update .gitignore with new binaries
Eric Anholt [Sun, 10 May 2009 17:08:32 +0000 (10:08 -0700)]
intel: Skip the DRI2 renderbuffer update when doing Viewport on an FBO.
Eric Anholt [Sun, 10 May 2009 16:45:43 +0000 (09:45 -0700)]
intel: Map write-only buffer objects through the GTT when possible.
This looks to be a win of a few percent in cairogears with new vbo code,
thanks to not polluting caches.
Eric Anholt [Tue, 12 May 2009 17:03:08 +0000 (10:03 -0700)]
i915: Fix driver after HW glGenerateMipmap commit.
Brian Paul [Tue, 12 May 2009 15:05:31 +0000 (09:05 -0600)]
swrast: update/restore the opt_sample_rgb/rgba_2d() functions
Michel Dänzer [Tue, 12 May 2009 06:01:22 +0000 (08:01 +0200)]
glXChooseVisual: Only consider fbconfig if we can get the corresponding visual.
This can fail, e.g. when XLIB_SKIP_ARGB_VISUALS=1 is set.
See http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=524794 and
http://bugs.freedesktop.org/show_bug.cgi?id=21600 .
Ian Romanick [Tue, 28 Apr 2009 17:08:57 +0000 (10:08 -0700)]
Test either GL_FRONT_LEFT or GL_FRONT for front-buffer rendering
For non-stereo visuals, which is all we support, we treat
GL_FRONT_LEFT as GL_FRONT. However, they are technically different,
and they have different enum values. Test for either one to determine
if we're in front-buffer rendering mode.
This fix was suggested by Pierre Willenbrock.
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
(cherry picked from commit
2085cf24628be7cd297ab0f9ef5ce02bd5a006e2)
Brian Paul [Mon, 11 May 2009 22:27:50 +0000 (16:27 -0600)]
Merge branch 'mesa_7_5_branch'
Conflicts:
Makefile
src/mesa/main/version.h
Brian Paul [Mon, 11 May 2009 22:09:39 +0000 (16:09 -0600)]
st: do proper refcounting for framebuffer surfaces
Brian Paul [Mon, 11 May 2009 22:08:01 +0000 (16:08 -0600)]
trivial: destroy window upon exit
Joakim Sindholt [Mon, 11 May 2009 19:44:49 +0000 (21:44 +0200)]
r300-gallium: unbreak build
Corbin Simpson [Mon, 11 May 2009 17:09:59 +0000 (10:09 -0700)]
r300-gallium: Setup surface in r300_surface_copy.
I haven't tested, but this may unbreak surface copies.
Corbin Simpson [Mon, 11 May 2009 17:07:40 +0000 (10:07 -0700)]
r300-gallium: Cleanup some compile warnings.
Corbin Simpson [Mon, 11 May 2009 16:57:57 +0000 (09:57 -0700)]
r300-gallium: Cleanup PSC for HW TCL.
Still dies in assert, but at least it's not my assert anymore. :3
Corbin Simpson [Mon, 11 May 2009 16:55:28 +0000 (09:55 -0700)]
radeon-gallium: Forgot a typedef.
Corbin Simpson [Mon, 11 May 2009 16:04:15 +0000 (09:04 -0700)]
radeon-gallium: Support new info ioctls in addition to classic getparams.
This makes non-hybrid kernels like newttm from drm-next-radeon work
while avoiding breakage with Fedora/Ubuntu/etc.
Brian Paul [Mon, 11 May 2009 16:02:18 +0000 (10:02 -0600)]
mesa: updated comments for _mesa_generate_mipmap()
Brian Paul [Mon, 11 May 2009 15:39:52 +0000 (09:39 -0600)]
i965: handle extended swizzle terms (0,1) in get_src_reg()
Fixes failed assertion in progs/glsl/twoside.c (but still wrong rendering).
Brian Paul [Mon, 11 May 2009 15:38:32 +0000 (09:38 -0600)]
mesa: better handling/printing of driver-specific opcodes, register files
Drivers such as i965 define extra instruction opcodes and register files.
Improve the program printing code to handle those opcodes/files better.
Brian Paul [Mon, 11 May 2009 15:46:56 +0000 (09:46 -0600)]
mesa: Fixed a texture memory leak
The current texture for any particular texture unit is given an additional
reference in update_texture_state(); but if the context is closed before
that texture can be released (which is quite frequent in normal use, unless
a program unbinds and deletes the texture and renders without it to force
a call to update_texture_state(), the memory is lost.
This affects general Mesa; but the i965 is particularly affected because
it allocates a considerable amount of additional memory for each allocated
texture.
(cherry picked from master, commit
c230767d6956b63a2b101acb48f98823bb5dd31a)
Brian Paul [Sat, 9 May 2009 22:21:16 +0000 (16:21 -0600)]
mesa: added more gallium Makefiles to tarball list
Hanno Böck [Sat, 9 May 2009 22:17:37 +0000 (16:17 -0600)]
gallium: replace lib with $(LIB_DIR)
Corbin Simpson [Sat, 9 May 2009 07:43:05 +0000 (00:43 -0700)]
radeon-gallium: Clean up some of the BO counting logic.
Corbin Simpson [Sat, 9 May 2009 07:38:07 +0000 (00:38 -0700)]
r300-gallium: vs: Make imms work, cleanup some of the switches.
Corbin Simpson [Sat, 9 May 2009 07:28:49 +0000 (00:28 -0700)]
r300-gallium: Start VS dumper.
Corbin Simpson [Sat, 9 May 2009 05:54:52 +0000 (22:54 -0700)]
r300-gallium: vs: Add SLT, clean up MAX.
This should be all the opcodes for basic TCL.
Corbin Simpson [Sat, 9 May 2009 05:52:32 +0000 (22:52 -0700)]
r300-gallium: vs: Add MAX.
Corbin Simpson [Sat, 9 May 2009 05:46:12 +0000 (22:46 -0700)]
r300-gallium: vs: Add scalar setup, RSQ.
Icky icky icky icky. Icky icky, icky icky. Icky.
Corbin Simpson [Sat, 9 May 2009 05:45:56 +0000 (22:45 -0700)]
r300-gallium: vs: Add writemasks.
Corbin Simpson [Sat, 9 May 2009 05:05:18 +0000 (22:05 -0700)]
r300-gallium: Fix bad cast. Space accounting completely works now.
Boy, is my face red. :C
Corbin Simpson [Sat, 9 May 2009 02:40:38 +0000 (19:40 -0700)]
r300-gallium, radeon: BO handling fixes, some useful asserts.
Corbin Simpson [Sat, 9 May 2009 00:09:32 +0000 (17:09 -0700)]
radeon-gallium: Shut up Valgrind.
Corbin Simpson [Fri, 8 May 2009 23:50:42 +0000 (16:50 -0700)]
r300-gallium, radeon: A couple cleanups.
Trying to track down goddamn bugs. :C
Corbin Simpson [Fri, 8 May 2009 22:28:09 +0000 (15:28 -0700)]
r300-gallium: Finish space accounting.
Still broken...
Robert Ellison [Fri, 8 May 2009 20:51:11 +0000 (14:51 -0600)]
i965: improve debug logging
Looking for memory leaks that were causing crashes in my environment
in a situation where valgrind would not work, I ended up improving
the i965 debug traces so I could better see where the memory was
being allocated and where it was going, in the regions and miptrees
code, and in the state caches. These traces were specific enough
that external scripts could determine what elements were not being
released, and where the memory leaks were.
I also ended up creating my own backtrace code in intel_regions.c,
to determine exactly where regions were being allocated and for what,
since valgrind wasn't working. Because it was useful, I left it in,
but disabled and compiled out. It can be activated by changing a flag
at the top of the file.
Robert Ellison [Fri, 8 May 2009 20:42:47 +0000 (14:42 -0600)]
i965: fix memory leak in context/renderbuffer region management
A temporary change to the intelMakeCurrent() function to make
it work with frame buffer objects causes the static regions
associated with the context (the front_region, back_region,
and depth_region) to take on an additional reference, with
no corresponding release. This causes a memory leak if a
program repeatedly creates and destroys contexts.
The fix is the corresponding hack, to unreference these
regions when the context is deleted, but only if the
framebuffer objects are still present and the same
regions are still referenced within.
Both sets of code have comment blocks referring to each
other.
Robert Ellison [Fri, 8 May 2009 20:40:38 +0000 (14:40 -0600)]
i965: fix segfault on low memory conditions
When out of memory (in at least one case, triggered by a longrunning
memory leak), this code will segfault and crash. By checking for the
out-of-memory condition, the system can continue, and will report
the out-of-memory error later, a much preferable outcome.
Robert Ellison [Fri, 8 May 2009 17:13:57 +0000 (11:13 -0600)]
mesa: Fixed a texture memory leak
The current texture for any particular texture unit is given an additional
reference in update_texture_state(); but if the context is closed before
that texture can be released (which is quite frequent in normal use, unless
a program unbinds and deletes the texture and renders without it to force
a call to update_texture_state(), the memory is lost.
This affects general Mesa; but the i965 is particularly affected because
it allocates a considerable amount of additional memory for each allocated
texture.
Eric Anholt [Fri, 8 May 2009 05:50:19 +0000 (22:50 -0700)]
intel: Add a metaops version of glGenerateMipmapEXT/SGIS_generate_mipmaps.
In addition to being HW accelerated, it avoids the incorrect
(black) rendering of the mipmaps that SW was doing in fbo-generatemipmap.
Improves the performance of the mipmap generation and drawing in
fbo-generatemipmap by 30%.
Eric Anholt [Fri, 8 May 2009 19:46:18 +0000 (12:46 -0700)]
intel: Put the constant texcoords used in metaops into a vbo.
Make this be its own function for setup/teardown of the binding of these
texcoords. No performance difference in the engine demo (I just felt dirty
not using a VBO for this), and I think it should be more resilient to
interference from current GL state.
Brian Paul [Fri, 8 May 2009 21:07:22 +0000 (15:07 -0600)]
mesa: omit files that were removed from git
Brian Paul [Fri, 8 May 2009 21:04:12 +0000 (15:04 -0600)]
mesa: set version to 7.5-rc1
Brian Paul [Fri, 8 May 2009 19:48:41 +0000 (13:48 -0600)]
i965: const qualifiers
Brian Paul [Fri, 8 May 2009 20:34:43 +0000 (14:34 -0600)]
mesa: raise MAX_VARYING (number of shader varying vars) to 16
16 is the limit for now because of various 32-bit bitfields.
Brian Paul [Fri, 8 May 2009 20:34:15 +0000 (14:34 -0600)]
mesa: assertions to check for too many vertex outputs or fragment inputs
Brian Paul [Fri, 8 May 2009 20:32:19 +0000 (14:32 -0600)]
glsl: check number of varying variables against the limit
Link fails if too many varying vars.