[Bf-committers] Re: [XFree86] [blender 2.26cvs + XFree430] Total machinge lock
Michel Dänzer
bf-committers@blender.org
10 Mar 2003 23:40:06 +0100
--=-iRDGO1mIehPHrk3tPNQX
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 8bit
On Mon, 2003-03-10 at 16:43, Meino Christian Cramer wrote:
>
> I use a recent cvs checkout of Blender CVS (2.26++) together with the
> XFree 4.30 release. Furthermore I compiled the Linux 2.4.20 kernel
> with DRM/DRI module support for my ATI Radeon 7500 (built by
> Sapphire). After installing the kernel I compiled the drm-kernel
> module for Linux in the XFree430 source tree and overwrite the
> according module in /lib/modules/2.4.20/kernel/driver/char/drm/...
> Reboot.
>
> DRI/DRM is shown as working in the XFree logfile.
>
> Now...whhen using Blender with DispWin enabled (rendering shown in
> extra window) crashes Blender (this was reported before).
>
> A friendly hacker of the bf-blender mailing list sends me a
> workaround: I should "export RADEON_NO_VTXFMT=1" right before
> starting blender.
>
> Now Blender could display its renderings in an extra window again.
>
> (wait...now it comes..!)
>
> BUT (and this is a very *BIG* "BUT"):
>
> When using PovAnim for Blender 2.26 (which do work right for me
> before this workaround) together with "RADEON_NO_VTXFMT=1" the
> results are very heavy:
> As soon as I press "ALT-P" to start the script, my Linux box
> freezes hard at once -- I had to reboot.
>
> Removing RADEON_NO_VTXFMT=1 will make the script work but now
> blender crashes while trying to open an extra window.
>
> Sigh.
>
> Since I have no access to my box right after a freeze I cannot
> provide any logfile or something like that. If one have an idea how
> to provide more help to fix this nasty bug...let me know and I will
> try help more.
You could try more environment variables like RADEON_TCL_FORCE_DISABLE
to see if any of them works around the problem. There's a list on
http://dri.sourceforge.net/doc/dri_driver_features.phtml .
You could also try this patch, which seems to fix some other lockups.
Fingers crossed.
--
Earthling Michel Dänzer (MrCooper)/ Debian GNU/Linux (powerpc) developer
XFree86 and DRI project member / CS student, Free Software enthusiast
--=-iRDGO1mIehPHrk3tPNQX
Content-Disposition: attachment; filename=radeon-flushvertices.diff
Content-Type: text/plain; name=radeon-flushvertices.diff; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
? lib/GL/mesa/src/drv/radeon/DONE
? lib/GL/mesa/src/drv/radeon/Makefile
Index: lib/GL/mesa/src/drv/radeon/radeon_context.c
===================================================================
RCS file: /cvs/xc/lib/GL/mesa/src/drv/radeon/radeon_context.c,v
retrieving revision 1.7
diff -p -u -r1.7 radeon_context.c
--- lib/GL/mesa/src/drv/radeon/radeon_context.c 2003/02/08 21:26:45 1.7
+++ lib/GL/mesa/src/drv/radeon/radeon_context.c 2003/03/10 22:37:47
@@ -382,6 +382,7 @@ radeonCreateContext( Display *dpy, const
*/
_tnl_destroy_pipeline( ctx );
_tnl_install_pipeline( ctx, radeon_pipeline );
+ ctx->Driver.FlushVertices = radeonFlushVertices;
/* Try and keep materials and vertices separate:
*/
Index: lib/GL/mesa/src/drv/radeon/radeon_swtcl.c
===================================================================
RCS file: /cvs/xc/lib/GL/mesa/src/drv/radeon/radeon_swtcl.c,v
retrieving revision 1.4
diff -p -u -r1.4 radeon_swtcl.c
--- lib/GL/mesa/src/drv/radeon/radeon_swtcl.c 2003/02/15 22:18:48 1.4
+++ lib/GL/mesa/src/drv/radeon/radeon_swtcl.c 2003/03/10 22:37:47
@@ -45,6 +45,7 @@ USE OR OTHER DEALINGS IN THE SOFTWARE.
#include "math/m_translate.h"
#include "tnl/tnl.h"
#include "tnl/t_context.h"
+#include "tnl/t_imm_exec.h"
#include "tnl/t_pipeline.h"
#include "radeon_context.h"
@@ -1133,6 +1134,14 @@ void radeonFallback( GLcontext *ctx, GLu
}
}
+
+void radeonFlushVertices( GLcontext *ctx, GLuint flags )
+{
+ _tnl_flush_vertices( ctx, flags );
+
+ if (flags & FLUSH_STORED_VERTICES)
+ RADEON_FIREVERTICES( RADEON_CONTEXT( ctx ) );
+}
/**********************************************************************/
/* Initialization. */
Index: lib/GL/mesa/src/drv/radeon/radeon_swtcl.h
===================================================================
RCS file: /cvs/xc/lib/GL/mesa/src/drv/radeon/radeon_swtcl.h,v
retrieving revision 1.1
diff -p -u -r1.1 radeon_swtcl.h
--- lib/GL/mesa/src/drv/radeon/radeon_swtcl.h 2002/10/30 12:51:57 1.1
+++ lib/GL/mesa/src/drv/radeon/radeon_swtcl.h 2003/03/10 22:37:47
@@ -43,6 +43,7 @@ USE OR OTHER DEALINGS IN THE SOFTWARE.
extern void radeonInitSwtcl( GLcontext *ctx );
extern void radeonDestroySwtcl( GLcontext *ctx );
+extern void radeonFlushVertices( GLcontext *ctx, GLuint flags );
extern void radeonChooseRenderState( GLcontext *ctx );
extern void radeonChooseVertexState( GLcontext *ctx );
Index: lib/GL/mesa/src/drv/radeon/radeon_vtxfmt.c
===================================================================
RCS file: /cvs/xc/lib/GL/mesa/src/drv/radeon/radeon_vtxfmt.c,v
retrieving revision 1.5
diff -p -u -r1.5 radeon_vtxfmt.c
--- lib/GL/mesa/src/drv/radeon/radeon_vtxfmt.c 2002/12/16 16:18:59 1.5
+++ lib/GL/mesa/src/drv/radeon/radeon_vtxfmt.c 2003/03/10 22:37:47
@@ -38,6 +38,7 @@ USE OR OTHER DEALINGS IN THE SOFTWARE.
#include "radeon_ioctl.h"
#include "radeon_tex.h"
#include "radeon_tcl.h"
+#include "radeon_swtcl.h"
#include "radeon_vtxfmt.h"
#include "api_noop.h"
@@ -59,7 +60,7 @@ USE OR OTHER DEALINGS IN THE SOFTWARE.
struct radeon_vb vb;
-static void radeonFlushVertices( GLcontext *, GLuint );
+static void radeonVtxfmtFlushVertices( GLcontext *, GLuint );
static void count_func( const char *name, struct dynfn *l )
{
@@ -336,12 +337,13 @@ static void VFMT_FALLBACK_OUTSIDE_BEGIN_
fprintf(stderr, "%s from %s\n", __FUNCTION__, caller);
if (ctx->Driver.NeedFlush)
- radeonFlushVertices( ctx, ctx->Driver.NeedFlush );
+ radeonVtxfmtFlushVertices( ctx, ctx->Driver.NeedFlush );
if (ctx->NewState)
_mesa_update_state( ctx ); /* clear state so fell_back sticks */
_tnl_wakeup_exec( ctx );
+ ctx->Driver.FlushVertices = radeonFlushVertices;
assert( rmesa->dma.flush == 0 );
rmesa->vb.fell_back = GL_TRUE;
@@ -382,6 +384,7 @@ static void VFMT_FALLBACK( const char *c
prim = rmesa->vb.prim[0];
ctx->Driver.CurrentExecPrimitive = GL_POLYGON+1;
_tnl_wakeup_exec( ctx );
+ ctx->Driver.FlushVertices = radeonFlushVertices;
assert(rmesa->dma.flush == 0);
rmesa->vb.fell_back = GL_TRUE;
@@ -731,7 +734,7 @@ static void radeonVtxfmtValidate( GLcont
fprintf(stderr, "reinstall (new install)\n");
_mesa_install_exec_vtxfmt( ctx, &rmesa->vb.vtxfmt );
- ctx->Driver.FlushVertices = radeonFlushVertices;
+ ctx->Driver.FlushVertices = radeonVtxfmtFlushVertices;
ctx->Driver.NewList = radeonNewList;
rmesa->vb.installed = GL_TRUE;
vb.context = ctx;
@@ -747,6 +750,7 @@ static void radeonVtxfmtValidate( GLcont
if (rmesa->dma.flush)
rmesa->dma.flush( rmesa );
_tnl_wakeup_exec( ctx );
+ ctx->Driver.FlushVertices = radeonFlushVertices;
rmesa->vb.installed = GL_FALSE;
vb.context = 0;
}
@@ -905,7 +909,7 @@ static GLboolean radeonNotifyBegin( GLco
return GL_TRUE;
}
-static void radeonFlushVertices( GLcontext *ctx, GLuint flags )
+static void radeonVtxfmtFlushVertices( GLcontext *ctx, GLuint flags )
{
radeonContextPtr rmesa = RADEON_CONTEXT( ctx );
--=-iRDGO1mIehPHrk3tPNQX--