[EMAIL PROTECTED] wrote:
Hello,
No idea if this problem has been raised, but I had a problem running the demos
@ http://www.garagegames.com on a radeon ddr 32.
It seems to crash (lock hardware, the new IRQ code gives EBUSY, but the exit()
isn't clean) rendering triangle fan elts :-
xc/extras/Mesa/src/tnl_dd/t_dd_dmatmp2.h for (j = start + 1 ; j + 1 < count; j += nr - 1 ) { nr = MIN2( currentsz, count - j + 1 ); TAG(emit_elts)( ctx, elts+start, 1 ); TAG(emit_elts)( ctx, elts+j, nr - 1 ); NEW_PRIMITIVE(); currentsz = dmasz;
iff the first vertex is emitted by itself at the end of a CmdBuf.
Here's a patch that prevents Think Tanks (and possibly other heavy users of triangle fans) from crashing on Radeon hardware.
To be pedantic - it's not caused by heavy usage of triangle fans, it was caused by a single triangle fan primitive occuring at the end of a cmd_buf [that could be filled with anything other than triangle fan primitives]
Basically, I just in-lined emit_elts and did some minor clean-up.
Yeah, that should work - but I did wonder whether other primitives / paths might have the same issue? There has been a few rendering related bugs reported that are "fixed" by changing the size of cmd_buf - which is one indirect way of "fixing" something like this. Other similar errors might not cause hardware hangs.
One problem that I have with emit_elts is that it seems to assume that the number of elts to emit is *always* a multiple of 2. Clearly this may not always be the case.
Yeah, though afaict an odd number (if that were the case) would be correctly set in the variable describing the primitive sent to the hardware - the variable(s) that are sent which describe the command itself are all a number of dwords anyway and rounded up if necessary, no?
Dunno what performance advantage emitting two at once had over emitting one, other than that, I don't suppose it matters either way.
-- Michael.
------------------------------------------------------- This SF.net email is sponsored by: VM Ware With VMware you can run multiple operating systems on a single machine. WITHOUT REBOOTING! Mix Linux / Windows / Novell virtual machines at the same time. Free trial click here: http://www.vmware.com/wl/offer/345/0 _______________________________________________ Dri-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/dri-devel
