From: Leif D. <lde...@re...> - 2002-08-08 20:51:55
|
I've commited some changes to AGP and offscreen memory management for mach64, which are available now in CVS and the latest binary snapshots for testing. I'm particularly interested in finding out if the AGP changes (the second item below) are unstable for anyone, relative to the previous code. Here's a summary of the changes: - Allocate/free back, depth, and texture memory when transitioning from 2d to 3d and back. (Taken from tdfx and the reinit branch). Note that this doesn't change the static allocation requirement for useable modes, since the buffers are still shared by all contexts and the buffers are not resized for mode switches. However, when no GL contexts are active, the offscreen mem. allocated (for XAA) is the same as with DRI disabled. - Use only AGP for textures when available. Use of a local texture heap in addition to AGP can be forced with Option "LocalTextures". PCI cards (and AGP cards with Option "ForcePCIMode") still use only a local texture heap. This means that a few modes will be useable only on AGP cards: 8MB card: 1024x768 @ 24-bit depth, 1280x1024 @ 16-bit depth 6MB card: 1152x864 @ 16-bit depth (if there's such a thing as a 2MB AGP card: 640x480@16) This change increases the XAA cache for AGP cards when GL contexts are active, relative to the previous code, and should reduce the amount of texture swapping for multitexturing. - To try to reduce the performance impact of using AGP only, AGP is initialized to use the default mode set by agpgart (Option "AGPMode" can still be used to force 1x or 2x), rather than always defaulting to 1x. Also, at 1x the card is configured to generate all AGP reads as high priority. This setting was always used in the Utah driver, but it's unstable for me at 2x, so I've only enabled it at 1x. On my system the end result of the changes is a slight increase in performance at 2x, and a slight decrease in performance at 1x, relative to the previous code (the difference is <1 FPS in quake3). - New texture/2D cache allocation algorithm: Instead of a fixed 128 scanlines for XAA cache, try for a full viewport or enough for single-buffered DVD (will be needed for Xvideo in the future), whichever is larger. If that fails or gives less than half the available offscreen mem. for textures (after front/back/depth buffers), split the available mem. between textures and XAA cache. If there's not enough space for 2 256x256 textures in the texture heap at once, DRI is disabled. These changes decrease the local texture memory used, but shouldn't change the usable modes and should help 2D acceleration. So, happy testing, and please post to dri-devel with results if you try it out. -- Leif Delgass http://www.retinalburn.net |