Felix, Last night I did some thinging about the pitch and linear vs. tiled mode. To be honest, I don't think it matters. 2D uses the GBD and can be tiled or linear. 3D uses the PBD and has to be tiled. Since they are using different BDs, it shouldn't matter whether 2D is tiled or not. for savagespan, we should use the tiled pitch whether or not 2D is tiled because they are writing to different BDs. I think the reason linear provides a small speed boost is because in linear mode, 2D does not require the use of a tiling reg. that frees tiling reg 0 completely for use by the 3D engine whereas before it had to share it with the 2D side. one thing I'm not clear on is the pitch in savagespan. that's for sw fallbacks right? are swfallbacks handled by the 2D driver? should the destination for those be the GBD (2D) or the PBD (3D)? that would determine which pitch we need. I presume the PBD since that is the destination for other 3D stuff (also in savage_dri.c the XAA fucntions in there write to the PBD rather than the GBD as the regular 2D accel functions do) and 2D accel can write to either BD you just have to set the destination right.
The utah driver used Tim's 2D driver which used linear mode for 2D. it just calcuated it's pitch based on the PBD in the 3D driver. perhaps if we add a new item, psav->ul3DAperturePitch and calculate it the way ulAperturePitch is for tiled mode whether or not we are using tiled for 2D it should work and pitch shold be right whether or not 2D is tiled. Does this make sense? Alex --- Felix Kühling <[EMAIL PROTECTED]> wrote: > On Fri, 9 Jan 2004 16:00:46 -0800 (PST) > Alex Deucher <[EMAIL PROTECTED]> wrote: > > > whoops. I'll have to check that out. Can you point me to the > code? > > I'm assuming savage_span in the DRI somewhere? Also, only 16 bpp > works > > The span stuff itself is in savagespan.c in the Mesa driver. However, > it > gets the line pitch from the Xserver during initialization. It is set > in > savage_dri.c:1432. Using ulAperturePitch here fixed the pitch in 16 > and > 32 bit modes (when tiling was still enabled and 32bit mode worked). > However, this seems to be wrong with linear mode. I havn't been able > to > figure out why yet. Everything looks right to me. ulAperturePitch is > just set in SavageEnableMode to lDelta in the linear case. > > > at the moment on savage4. I've only been able to run one 3d app at > 32 > > bpp, glxheads from the mesa demos. all the rest spit out this > error > > message: > > savagedma.c:39: SavageDMACommit: Assertion: 'end <= > dmaBuff->allocEnd' > > failed. > > aborted. > > Perhaps not enough memory for much 3d at 32 bpp? my card only has > 16 > > MB. > > I saw it too when I wanted to check if the line pitch is broken in > 32bpp > mode too. The assertion failure is coming from the new DMA code. It > indicates that someone tried to commit more DMA memory than he > allocated. However, due to a gdb bug (I think) I can't get a usefull > backtrace. This is as far as it gets: > > #0 0x401dad89 in raise () from /lib/tls/libc.so.6 > (gdb) bt > #0 0x401dad89 in raise () from /lib/tls/libc.so.6 > #1 0x402e6f30 in ?? () from /lib/tls/libc.so.6 > #2 0xc0000000 in ?? () > #3 0x401dc5e1 in abort () from /lib/tls/libc.so.6 > > Can you get a real backtrace? > > No hurry. I'm going to bed now. > > Felix > > > > > at 32 bpp, glxheads shows the same corruption that glxgears, etc. > had > > before I fixed the linear/tile code. I suspect I'll need to muck > > around with the bitmap descriptors and tiling regs again and find > out > > what's breaking 32 bpp. > > > > Alex > > > > --- Felix K_hling <[EMAIL PROTECTED]> wrote: > > > I just noticed that your changes broke the line pitch in the span > > > functions (again). You see the effect when you run xscreensaver > hacks > > > with > > > -fps. I'll see if I can fix it once more. ;-) > > > > > > Felix > > > > > > On Fri, 9 Jan 2004 12:45:10 -0800 (PST) > > > Alex Deucher <[EMAIL PROTECTED]> wrote: > [snip] > > > ------------ __\|/__ ___ ___ > ------------------------- > Felix ___\_e -_/___/ __\___/ __\_____ You can do anything, > Kühling (_____\Ä/____/ /_____/ /________) just not everything > [EMAIL PROTECTED] \___/ \___/ U at the same time. __________________________________ Do you Yahoo!? Yahoo! Hotjobs: Enter the "Signing Bonus" Sweepstakes http://hotjobs.sweepstakes.yahoo.com/signingbonus ------------------------------------------------------- This SF.net email is sponsored by: Perforce Software. Perforce is the Fast Software Configuration Management System offering advanced branching capabilities and atomic changes on 50+ platforms. Free Eval! http://www.perforce.com/perforce/loadprog.html -- _______________________________________________ Dri-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/dri-devel