History log of /haiku/src/add-ons/accelerants/nvidia/engine/nv_acc_dma.c
Revision Date Author Comments
# f92ba94c 05-May-2016 Murai Takashi <tmurai01@gmail.com>

nv_acc_dma.c: fix gcc6 build

Signed-off-by: Augustin Cavalier <waddlesplash@gmail.com>


# dc234e79 18-Oct-2014 Adrien Destugues <pulkomandy@gmail.com>

NVidia: 64bit fixes.


# e48ec1b5 16-Jun-2010 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added engine function OFFSCREEN_TO_SCREEN_SCALED_FILTERED_BLIT. Not used yet, testing and wip. Function is confirmed up and running on geforce 7200, 6200, 6600, 5200.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@37158 a95241bf-73f2-0310-859d-f6bbb57e9c96


# aeb4bf93 26-May-2009 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30867 a95241bf-73f2-0310-859d-f6bbb57e9c96


# fa0fea5f 17-May-2009 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

fixed acceleration engine crashes on at least G72 cards by powering up a new part of the engine. This fixes acc on Geforce 7300/7400/7500 cards, and closes tickets #927, #1535 and #3482. In order to test this you need to go back to Haiku R30277 at least since app_server nolonger uses acceleration. Acceleration code was synced to Xfree86 4.8.0. and no chances were found. Bumped version to 0.90, updated docs.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30783 a95241bf-73f2-0310-859d-f6bbb57e9c96


# f8863cf6 24-Sep-2007 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added engine command fifo setup for TCL_PRIMITIVE_3D for NV15 only for now (testing). Over here the NV15 keeps running and the command seems responsive. I hope this doesn't crash other NV15's outthere.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22290 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 69cf084e 07-Apr-2006 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

checked G73 setup against today's XFree86 CVS. G73 should be supported now, that is, after the kerneldriver is updated as well (for cardIDs)

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@17047 a95241bf-73f2-0310-859d-f6bbb57e9c96


# ecf7bfa1 07-Apr-2006 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

removed NV47 references, replaced with G70. Also added G71, G72 and G73 engines.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@17037 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 8735e82e 04-Apr-2006 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

updated pre-NV10 card init code for a small 3D rendering speed increase on TNT2 and TNT2-M64 cardtypes: gain is some 1-4% depending on colorspace and exact card-type. This completes the 2D driver's 3D related init programming sweep. Next up should be adding cardID's and adding a new nv.setting to force screen aspect. Bumped version to 0.77.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@17000 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 235f540d 31-Mar-2006 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

what? didn't upgrade to 0.75 while you are using hardware 3D? Well, maybe now I can convince you!. New speeds: another 43% gain for NV11, in 1024x768x32 Q1 now at 27.1fps, NV15 gets another 60% boost for the winning score of 45.4fps, and NV18 tries to keep up (but fails :) with now 41% speedup for 37.0fps. 3D users, it's time to upgrade to 0.76. :)

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@16941 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 33441648 30-Mar-2006 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

improved 3D init programming. NV11 gained 44% speed, NV15 gained 21% speed, NV18 and other cards remain at the same speed. These gains (or about) are in all resolutions, all colordepths. If your CPU is fast enough of course. Bumped version to 0.75. There's no doubt about it, if you use 3D, upgrade!

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@16931 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 7fe04ec7 14-Feb-2006 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added retrace sync programming for NV12_IMAGE_BLIT command. Works OK it seems (testing in 3D add-on).

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@16400 a95241bf-73f2-0310-859d-f6bbb57e9c96


# f36f5d56 14-Feb-2006 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

switched to a newer blit function in the driver for NV11 and higher (below does not support it). Benchmarking shows this blit has about the same speed as the old one. The reason for switching is the fact that this new function supports auto_sync_to_retrace. That should counteract the drop in fps for synced swaps (3D) a bit.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@16398 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 0dd48593 10-Feb-2006 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

updated 3D related colorspace settings to be optimal speed wise. Also removed redundant stuff not having any effect with the current engine setup. 3D rendering speed stays same on RGB15 and 16, but RGB32 space just gained about 11% gain :)

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@16321 a95241bf-73f2-0310-859d-f6bbb57e9c96


# c0634c02 03-Feb-2006 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

completely removed concurrent 3D/overlay workaround number 2 (executing a 3D command in engine init). Overlay and fifo-assignment-switching on-the-fly / 3D are working OK indeed. The dangerous-RAM-area patch completely solves that problem.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@16221 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 71c43a7a 02-Feb-2006 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

disabled 3D/overlay patch number two: looks like I nailed this one good. Looks to be confirmed on TNT1, will test more before final delete of this patch.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@16203 a95241bf-73f2-0310-859d-f6bbb57e9c96


# f67620f9 02-Feb-2006 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

fixed overlay playback and accelerantion engine crashes if all is right: it turns out the last piece of cardRAM may not be accessed by software. This looks to be a hardware bug, size of dangerous RAM depends on pre/post NV40 architecture, bug exists for both FIFO channel assignment on the fly, and DMA command buffer existing in cardRAM. If there are still users outthere using PIO acceleration and 3D they have a good chance of having working concurrent overlay as well, as the fifo-assignment bug turns up with PIO acc as well. Note: the bugfix is still in test: confirmed on TNT1 only for now.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@16200 a95241bf-73f2-0310-859d-f6bbb57e9c96


# d24c6abf 31-Jan-2006 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

comment update: pitch granularity now confirmed for 15, 16 and 32bit RGB depths (SCALED_BLIT).

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@16169 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 9f6aebed 31-Jan-2006 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

updated SCALED_BLIT to do 15-bit space correctly.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@16168 a95241bf-73f2-0310-859d-f6bbb57e9c96


# c6cacf3f 21-Dec-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

removed 'typo' introduced while testing.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15645 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 04928d2c 20-Dec-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

fixed with-issues with scaled_filtered blit. Tested for 16bit space. Over here this new function is now stable. Other spaces will be tested asap.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15615 a95241bf-73f2-0310-859d-f6bbb57e9c96


# a06a87b9 20-Dec-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

corrected scaled_filtered_blit setup according to test results with a node. Now it correctly works for a 'number of source-widths': tested 320 and 640 pixels source bitmaps. This source-width thing is still under test..

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15613 a95241bf-73f2-0310-859d-f6bbb57e9c96


# c0f61627 20-Dec-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

updated scaled_filtered_blit code and fixed NV1_RENDER_SOLID_LIN setup. Scaled blit might still be down, but we are getting there.. (in progress)

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15602 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 010c6409 15-Dec-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

finished and enabled support for 2D acceleration function SCREEN_TO_SCREEN_SCALED_FILTERED_BLIT (DMA mode only). While still untested, the engine keeps running at least. Should work on all cards the driver supports. Note: overlay support is now broken: 2D engine freezes at some point. Will fix that asap (I hope)...

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15542 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 2a2d8512 15-Dec-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

fixed not asking cmd buffer for room for all items (scaled_fiterled_blit)

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15541 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 0cb2429a 14-Dec-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

completed preliminary (untested) scaled_filtered_blit function, although it wont' work yet: the engine cmd define and fifo assignment has yet to be setup.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15538 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 9af6e789 14-Dec-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

more stuff for SCREEN_TO_SCREEN_SCALED_FILTERED_BLIT function. Not yet complete though.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15536 a95241bf-73f2-0310-859d-f6bbb57e9c96


# a89d8360 08-Dec-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

adding DMA acc function SCREEN_TO_SCREEN_SCALED_FILTERED_BLIT (in progress). The videonode turns out to be a nice playground to test it with, so I can set it up. Also it looks like I'm going to need it because I can't get a B_YCbCr422 connection going on R5 or dano (negotiation seems to fail).

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15424 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 40df1a3a 17-Nov-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

completed DMA acceleration init code sync to XF86. All cards should be operational again (still untested). Bumped version to 0.65.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15003 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 4cb53e7f 17-Nov-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

updating DMA acc engine init code: part 4. Still in progress, but maybe NV47 acc runs now: It's enabled now. This turns out to be an interesting update: init code has been extended for NV20 and higher cards, giving me reason enough to probably do some more 3D testing on newer cards. (probably for nothing though :)

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14999 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 1f6a1fb8 17-Nov-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

updated engine DMA acc init code, part 3 (in progress).

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14989 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 0229e158 17-Nov-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

updating DMA acc init code, part 2: in progress.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14987 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 5b3f3400 17-Nov-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

updating DMA acceleration code for NV41, 43, 44. Adding code for NV47: sync to XF86, in progress (acc might be broken now..)

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14984 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 845faf5e 04-Jul-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added some comments about the NV18 speedfix and resetting registers on NV28.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13424 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 21545d00 19-Jun-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added/modified shared_info to (better) support upto 32 3D accelants. Needs to be improved/expanded later though. Bumped version to 0.53.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13210 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 332f986f 15-Jun-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

modified 3d reload flag to support 32 clones, added clone counter as well.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13175 a95241bf-73f2-0310-859d-f6bbb57e9c96


# b7c59230 16-Jun-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added shared_info flag to inform 3D add-on to reload it's rendering state, further improving 3D rendering speed: Quake2 is at 105fps (GF4MX440, 640x480x16), Teapot renders at close to 500fps now. Bumped version to 0.52.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13169 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 3d83865e 13-Jun-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added a concurrent overlay/3D workaround making that combination work reliably now. No more engine crashes should occur. Bumped version to 0.51.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13092 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 081f4613 13-Jun-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

corrected all dummyreads to use volatile pointers. Thanks Marcus Overhagen for reading along.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13082 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 6dcf8a8b 09-Jun-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

modified a few comments only . All my cards BTW are running OK (including NV43/PCIe), so it looks like a release can be about done.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13029 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 740fbb06 02-Jun-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

updated explicit engine register clearing to be only carried out on pre-NV20: newer cards don't like this and hang. Also cleaned up a bit. Let's stick with the 1Mb cmd buffer as it seems to have proven itself now. (only pre-NV40 for now).

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12927 a95241bf-73f2-0310-859d-f6bbb57e9c96


# bbc828ca 01-Jun-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added some more comments for specs

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12926 a95241bf-73f2-0310-859d-f6bbb57e9c96


# ca459671 01-Jun-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

FIX FOR NV18cd obos_svn/trunk/src/add-ons/accelerants/nvidia/ We now have a new winner for 3D. Quake2 runs at 91.5fps in 640x480x16. I can hardly believe this..

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12925 a95241bf-73f2-0310-859d-f6bbb57e9c96


# f1909366 30-May-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

fixed NV1x 3D DMA acceleration. NV15 now renders the teapot at 400+fps in both 16 and 32bit, quake2 in 640x480x16 runs at 77fps. The DMA 3D driver is now fully operational to the same extent as the PIO version: but much faster :-). Note, this 2D driver is still in testing..

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12905 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 0188d866 26-May-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added shared_info flag to assess PCI or AGP mode. Engine (if in DMA mode) selects PCI or AGP transfers accordingly (pre-NV40 only for now). It seems the combination of the 1Mb cmd buffer size and it being in main mem makes it all fast. (1Mb in gfx card remains at same speed at 32kb.). Maybe we can even use AGP engine transfers for placing textures on the gfx card in the future: who knows.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12848 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 1e7ae055 26-May-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

forgot to tell the DMA cmd fetch engine it may write-back as well as read. Seems to not have influence on speed, as expected I'd say. Anyway: just tried enabling AGP transfers for cmd fetches: that actually works over here!. I just saw GLteapot spinning at over 400fps because of it. Note however that this doesn't mean we can reach that speed with a local DMA command buffer: the real reason for the higher speed might be the large size (1Mb compared to 32kB). testing some more..

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12844 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 5b5ef87b 26-May-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

on pre-NV40 I have activated the main mem DMA command buffer at size = 1Mb. It's working OK and is way faster on TNT1 (using the local-DMA-via-mainmem workaround) - of course. For all other cards however (so which have working local DMA command buffers) the mainmem implementation is actually a bit slower, and places a higher burder on the bus slowing down 2D a lot when 3D maxes out. All in all, I am not sure this is the way to go. It might be best to make this all a switch for nv.settings, disabled by default. Still testing... (Curious how AGP transfers will do - if possible, currently using PCI transfers)

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12843 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 395332ac 26-May-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

small update to keep accelerant working with already modified kerneldriver and shared_info for mainmem DMA buffer.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12836 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 23f40a23 22-May-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

more cleanup for DMA: re-organised cmd define locations.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12764 a95241bf-73f2-0310-859d-f6bbb57e9c96


# af9bb348 21-May-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

major hash and engine command defines cleanup (PIO and DMA). It looks like the hash-rules are quite simple after all. Hoping I'm right about that: looking good. PIO mode: 3D add-on alpha1 should nolonger work with the current 2D driver (hang). DMA mode: on TNT2 orig, DMA 3D acc is fully working now. All surface commands work, old ones are removed. I'll (try to) bring PIO mode upto par so 3D will work again there too. GLteapot stays at 360fps @ 16bit, 280 fps @ 32bit for now (TNT2 orig). Bumped version to 0.47.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12762 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 980fda26 21-May-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

fixed concurrent overlay and 3D use. This never worked before: it turns out that overlay requires a certain engine command setup order/chain without gaps to prevent hard crashes. 3D surface cmd still down though..

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12756 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 0fcc145d 21-May-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

removed more old surface commands related programming.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12755 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 1684de39 21-May-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

removed old 2D/3D surface commands. While the 'new' 3D surface command is still down, the 2D surface command has been replaced with NV4_SURFACE/NV10_CONTEXT_SURFACES_2D. These indeed work. Teapot: now @ 360fps on TNT2 orig (16bit).

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12754 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 6efe4e12 12-May-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

fixed introduced error for TNT1. DMA mode is a bit flaky ATM though here.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12650 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 00b2e25e 12-May-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

more colorspace dependand engine cmd programming for 3D. Now 15,16 and 32bit mode are up again: 15/16bit: teapot 320fps, 32: 280fps (tnt2). All demos run.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12642 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 1252f57f 12-May-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added DMA surface cmd's colorspace dependant programming. These commands were still down at last 3D test, but already the Teapot is spinning at 300fps in DMA mode ona TNT2 over here!!

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12641 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 372f7c3b 10-May-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added all 3D related commands found in PIO acceleration code to DMA pre-NV40 code as well. Bumped version to 0.46: experimental, should be fully OK though (for 2D).

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12626 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 7540371d 21-Feb-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

the DMA acc sub-cmd-lists are now issued to a single engine command (except for blit because it's hardware can't do that), instead of to multiple issued engine commands. (one could say 'parallel processing' but that's not the case: it remains serial: it's just faster).

DMA acceleration speed is up another 10% for rect and span commands.
commencing more testing now: code is complete (I hope).


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11433 a95241bf-73f2-0310-859d-f6bbb57e9c96


# d0ef756a 21-Feb-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

optimized DMA acc code more by splitting up command lists into sublists before issuing them to the engine. this further improves speed with upto about 70 percent, for a total of about doubling the speed by pure software optimation.

Note: code is now working the same as Thomas's ATI driver: he minimized calls in the same ways. (Curious how a benchmark contest would hold up now.. ;-)


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11431 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 1554e5cb 21-Feb-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

applied DMA mode speed optimations 'step 1.5': incorporated all top-level acceleration functions inside the engine's code so minimal nested calls are made. Confirmed further speedup of about 15% on fast CPU's...


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11427 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 18dfc8a2 19-Feb-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

optimizing DMA acc for speed ('step 1'). Also simplifies code.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11422 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 10988528 18-Feb-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added fix (not yet completely tested) for NV40/NV45 artifacts on heavy acc engine use. Bumped driverversion to 0.37.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11419 a95241bf-73f2-0310-859d-f6bbb57e9c96


# cb497231 19-Feb-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added one (still disabled) register for framebuffer config(?) on NV40/NV45 (in test)


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11417 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 36ad4411 17-Feb-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added some comments about NV40 architecture. We have several new unknown factors:
- DAC2 always detects a analog screen connected;
- it seems like there are at least two new registers we don't know about. One extra switch to place output on connectors, and one (extra) switch for pixelclock PLL to CRTC connections (one PLL drives both CRTC's in some cases, pre-programmed by the card BIOS determined on the screen configuration found at power-up.
- in a known register (TSTCTRL) b20 blocks/moves output on connectors (?).
All confirmed on NV43, GeForce PCIe 6600GT.

Driver status:
- one DVI monitor connected is OK;
- one analog screen connected on the DB15 connector is OK,
- two analog screens connected is OK and can be used for dualhead.
other combinations don't work well or at all. This is the status confirmed on
the NV43. Assuming same for other cards of NV40 architecture.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11399 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 9b501a81 12-Feb-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added some more PIO mode acceleration programming for NV40 and higher. This remains non-functional: aborting dev on this for now. Notes about the problem are in the code. For now I guess no-one cares about PIO mode nomore anyway... ;-)


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11354 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 7139e38e 10-Feb-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

updated a few comments, added some acc stuff for NV40+ for PIO mode: trying to get that up as well briefle now.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11328 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 4f985adf 08-Feb-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added NV04(TNT1) DMA workaround code. TNT1 now also works with DMA acceleration. TNT2-M64 has been confirmed up also. This means all cards should work now! (Except for a NV40 artifact on blits..).
Still some finetuning to do.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11293 a95241bf-73f2-0310-859d-f6bbb57e9c96


# e7b37d02 08-Feb-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added pre-NV10 screen location and size for completeness. NV05 (TNT2) is confirmed up and running speedy now :-)


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11292 a95241bf-73f2-0310-859d-f6bbb57e9c96


# c1d1fdbc 08-Feb-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added preliminary pre-NV10 specific DMA acceleration code. Not finished, not tested.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11290 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 36b7db70 06-Feb-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

updated a few register defines for NV44 type.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11271 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 94e32479 06-Feb-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

fixed NV44 and NV45 programming for acceleration


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11269 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 63def9b2 31-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

completed NV20 architecture DMA acceleration: confirmed both NV20 and NV30 architectur up and running OK BTW.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11171 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 8d2dfc64 31-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

small simplification for reading and writing DMAGET and DMAPUT, gives a minor speedup (a few percent max).


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11167 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 41dde765 28-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

completed DMA acc for NV30 architecture, still untested. Fixed two doubled registerdefines which adress the same registers.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11108 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 7309e1cd 27-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

needed to bump the DMA command buffer forced freespace up to 256 words: NV4_GDI_RECT needs a higher setting than the old version. Hopefully engine crashes are now past tense...


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11095 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 64efa4b4 27-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

Arrrgghh! I was still using NV3_GDI_RECTANGLE_TEXT instead of NV4_GDI_RECTANGLE_TEXT on pre-NV40 (NV11 tested). Fixed now.
Anyway: Now we know the reason the switch must be made: the old command, while being approx. of the same speed as the new one, has a hardware fault and has also therefore been removed in NV40 and later hardware.
The fault is the input->output colorspace conversion which doesn't work while being used with DMA acc. Glad I could loose that nasty workaround now!!


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11093 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 4e05353d 27-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

fixed overlay bitmap DMA adress, fixed overlay in 15 bit mode (NV11). nVidia hardware is broken here :-/. Anyway, it works now.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11092 a95241bf-73f2-0310-859d-f6bbb57e9c96


# fee251bc 26-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

modified overlay to stay outside DMA buffer if it exists.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11091 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 4dca5362 27-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added invert_rect DMA acc function. Tested in all colorspaces on NV11 (OK).


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11090 a95241bf-73f2-0310-859d-f6bbb57e9c96


# d4d5ee8b 27-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

updated DMA acc to use the full DMA buffersize instead of just one quarter.
Also improved forced freespace limit setting in this buffer, now finally completely preventing engine crashes it seems.
Engine speed went up again due to larger DMA buffer.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11089 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 1a713b18 26-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

fixed fill_rect and fill_span 8, 15 and 16 bit colorspaces for NV10Arch. Tested and OK on NV11.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11080 a95241bf-73f2-0310-859d-f6bbb57e9c96


# e846ba3d 24-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

updated DMA engine error handling: the driver should nolonger hang (again) if the engine crashes.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11018 a95241bf-73f2-0310-859d-f6bbb57e9c96


# ab26d7f8 24-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

finalized DMA buffer overfill checking for optimum speed. On NV11 accelerated functions are running at 130% to 200% speed in DMA mode compared to the 'old' PIO mode. Without trouble now.
Still only 32bit mode, and still missing invert_rect function though. Also still not explicitly adhering the engine constraints which needs to be rechecked/retuned compared to PIO mode (hence the non working 800x600x8 mode I expect..)


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11009 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 11e38e92 24-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added checking to prevent DMA buffer overfills: it turns out for instance NV11 can't keep up with BeRoMeter and the engine crashes otherwise. It turns out NV11 is currently only working correctly in 32bit color mode BTW.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11005 a95241bf-73f2-0310-859d-f6bbb57e9c96


# e2e0a5e1 24-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

shut-down that dumb ISA access for DMA. Acc speed just went through the roof! (testing with BeRoMeter). I'll now compare DMA and non-DMA speed on NV11 8-)


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11003 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 34b13629 24-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

DMA versions of fill_rect and fill_span (same core func still) are up! Removed some testlogging, their load became too high with these new functions added :)


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11001 a95241bf-73f2-0310-859d-f6bbb57e9c96


# de653df8 24-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

small cleanup. This fixes DMA buffer freespace tracking as well.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11000 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 105a3567 23-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added fill_rect and fill_span functions (same). Not yet exported, not yet working either..


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10986 a95241bf-73f2-0310-859d-f6bbb57e9c96


# d4a57f27 23-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added timeout and abort for DMA idle waits. This keeps the system responsive if the DMA engine fails, which is way better than a complete hang. Adding this because it's not impossible to create a situation that stalls DMA: for instance if a video app writes (way) outside it's allocated overlay buffers.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10976 a95241bf-73f2-0310-859d-f6bbb57e9c96


# fc61675c 22-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

completed DMA buffer wraparounds. DMA acceleration is now stable on NV11 and NV43. Enjoy.. (still missing acc hooks will be setup asap.)


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10959 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 1a63a698 22-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

small cleanup (mostly comments updates)


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10944 a95241bf-73f2-0310-859d-f6bbb57e9c96


# f174c1bd 21-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

another nice milestone: NV43 (GeForce PCIe 6600 GT tested) has acceleration up and running as well now!. Please note that the same restrictions apply here as I just mentioned for NV11: to be fixed asap of course ;-)
Jippieeee!


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10941 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 8e3d3f5e 21-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added explicit clearing of the hashtable engine RAM. This sneaky thing won't get to me again: it keeps it's contents even over power-outages of upto say 15 seconds!!


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10932 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 16c2cf6b 18-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

small logging correction for DMA_PUT.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10847 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 18b2b9da 18-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

The DMA_PUT register is write-only on some cards (confirmed NV11).


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10846 a95241bf-73f2-0310-859d-f6bbb57e9c96


# e4d42ef7 18-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

fixed a stupid error I introduced with cleaning up some stuff: FIFO channel assignments should now work. Confirmed NV11 BTW being at the same level as NV43: DMA works, engine not yet.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10839 a95241bf-73f2-0310-859d-f6bbb57e9c96


# e0cbecd9 17-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

completed NV10 architecture DMA programming to the same level as NV43. Hopefully this engine will show more signs of life than NV43 still does..


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10800 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 4cd3f831 17-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added cmd defines (CTX registers) for pre-NV40 cards, corrected a CTX programming error for NV40 and higher (2d_surface).


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10798 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 20f19080 17-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added setting pattern colorspace (DMA)


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10795 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 02e231b7 16-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added 2D_surface setup (DMA), added fifo channel assignent check for aquire_engine, cleaned some stuff up.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10793 a95241bf-73f2-0310-859d-f6bbb57e9c96


# a9b9a914 17-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

fixed FIFO channel pointer error that caused assert_fifo to always fail (DMA, >NV40). Should fix driver hanging after changing workspaces with different modesettings on NV40 and later.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10792 a95241bf-73f2-0310-859d-f6bbb57e9c96


# fcc9f0ab 16-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added 2D_surface command engine defines and FIFO channel assignment: used for setting buffer colorspace, location and pitch later on.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10771 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 3c85aa4f 14-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

more DMA related programming. Still acceleration this way is disabled. DMA command fetching now actually works on GeForce 6600/NV43 (verified). The acceleration engine still refuses to process the fed commands (correctly) though. OTOH: programming not yet coplete ;-)


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10734 a95241bf-73f2-0310-859d-f6bbb57e9c96


# a3587d4d 13-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

modified cmd handles, added DMA blit partly. Still untested.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10713 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 0bfacfc2 12-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added DMA cmd related info


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10711 a95241bf-73f2-0310-859d-f6bbb57e9c96


# f180c737 13-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

more DMA stuff


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10709 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 230c6e57 12-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added more DMA programming: cmd buffer and FIFO setup.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10701 a95241bf-73f2-0310-859d-f6bbb57e9c96


# daaa7698 11-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added checking for engine idle: which is actually the case over here :-)


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10666 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 4610db26 10-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added DMA engine initialisation code for NV40 and higher. Still disabled, and needs support from driver (reserve DMA buffer RAM etc)


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10660 a95241bf-73f2-0310-859d-f6bbb57e9c96


# dd43fd34 10-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added cursor HW bug workaround for NV40 and higher on CRTC1; added seperate acc file for DMA test setup for NV40 and higher (for now).
The driver now works by default on NV40 and higher, but without acceleration.
If someone tests using overlay, let me know if it actually works: NV43 seems to have a new engine, NV40 _might_ still have the old, and so, useable engine.
NV40-plus overlay is something we will NOT have any time soon!


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10651 a95241bf-73f2-0310-859d-f6bbb57e9c96


# dc234e798d854e75a197ee9fc85c6a1eede67fef 18-Oct-2014 Adrien Destugues <pulkomandy@gmail.com>

NVidia: 64bit fixes.


# e48ec1b5e74ade7862ec451af571a2ad80cd8035 16-Jun-2010 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added engine function OFFSCREEN_TO_SCREEN_SCALED_FILTERED_BLIT. Not used yet, testing and wip. Function is confirmed up and running on geforce 7200, 6200, 6600, 5200.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@37158 a95241bf-73f2-0310-859d-f6bbb57e9c96


# aeb4bf93d4a09f6658b382da598eae5ba0cfb899 26-May-2009 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30867 a95241bf-73f2-0310-859d-f6bbb57e9c96


# fa0fea5f257dd13ff593302a88562b7e24814c86 17-May-2009 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

fixed acceleration engine crashes on at least G72 cards by powering up a new part of the engine. This fixes acc on Geforce 7300/7400/7500 cards, and closes tickets #927, #1535 and #3482. In order to test this you need to go back to Haiku R30277 at least since app_server nolonger uses acceleration. Acceleration code was synced to Xfree86 4.8.0. and no chances were found. Bumped version to 0.90, updated docs.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30783 a95241bf-73f2-0310-859d-f6bbb57e9c96


# f8863cf61de9b62950bc27392ea8f796a56b2004 24-Sep-2007 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added engine command fifo setup for TCL_PRIMITIVE_3D for NV15 only for now (testing). Over here the NV15 keeps running and the command seems responsive. I hope this doesn't crash other NV15's outthere.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22290 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 69cf084e73a32e0e756d1333ee404f44450ced4d 07-Apr-2006 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

checked G73 setup against today's XFree86 CVS. G73 should be supported now, that is, after the kerneldriver is updated as well (for cardIDs)

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@17047 a95241bf-73f2-0310-859d-f6bbb57e9c96


# ecf7bfa1db8ea63696842723865c1c7e00e09b91 07-Apr-2006 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

removed NV47 references, replaced with G70. Also added G71, G72 and G73 engines.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@17037 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 8735e82ee248a6d775adf3a1141c1a80fe71946a 04-Apr-2006 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

updated pre-NV10 card init code for a small 3D rendering speed increase on TNT2 and TNT2-M64 cardtypes: gain is some 1-4% depending on colorspace and exact card-type. This completes the 2D driver's 3D related init programming sweep. Next up should be adding cardID's and adding a new nv.setting to force screen aspect. Bumped version to 0.77.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@17000 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 235f540de927f264a1bad6ac9a734b8115f73074 31-Mar-2006 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

what? didn't upgrade to 0.75 while you are using hardware 3D? Well, maybe now I can convince you!. New speeds: another 43% gain for NV11, in 1024x768x32 Q1 now at 27.1fps, NV15 gets another 60% boost for the winning score of 45.4fps, and NV18 tries to keep up (but fails :) with now 41% speedup for 37.0fps. 3D users, it's time to upgrade to 0.76. :)

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@16941 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 33441648ba5503967704f69e35fba83147922666 30-Mar-2006 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

improved 3D init programming. NV11 gained 44% speed, NV15 gained 21% speed, NV18 and other cards remain at the same speed. These gains (or about) are in all resolutions, all colordepths. If your CPU is fast enough of course. Bumped version to 0.75. There's no doubt about it, if you use 3D, upgrade!

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@16931 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 7fe04ec74b412aad6d4d50ab15b97cd486d2ac7b 14-Feb-2006 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added retrace sync programming for NV12_IMAGE_BLIT command. Works OK it seems (testing in 3D add-on).

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@16400 a95241bf-73f2-0310-859d-f6bbb57e9c96


# f36f5d56d55b3a8ffb7cd0d1e0f64cffa0a54446 14-Feb-2006 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

switched to a newer blit function in the driver for NV11 and higher (below does not support it). Benchmarking shows this blit has about the same speed as the old one. The reason for switching is the fact that this new function supports auto_sync_to_retrace. That should counteract the drop in fps for synced swaps (3D) a bit.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@16398 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 0dd48593ea06c30d8fa7344dcda5e2ff079b2cff 10-Feb-2006 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

updated 3D related colorspace settings to be optimal speed wise. Also removed redundant stuff not having any effect with the current engine setup. 3D rendering speed stays same on RGB15 and 16, but RGB32 space just gained about 11% gain :)

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@16321 a95241bf-73f2-0310-859d-f6bbb57e9c96


# c0634c022210637197bfa9c8c489e64efd028767 03-Feb-2006 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

completely removed concurrent 3D/overlay workaround number 2 (executing a 3D command in engine init). Overlay and fifo-assignment-switching on-the-fly / 3D are working OK indeed. The dangerous-RAM-area patch completely solves that problem.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@16221 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 71c43a7a1ea41953efd5e34c094868e8bcb6832e 02-Feb-2006 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

disabled 3D/overlay patch number two: looks like I nailed this one good. Looks to be confirmed on TNT1, will test more before final delete of this patch.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@16203 a95241bf-73f2-0310-859d-f6bbb57e9c96


# f67620f956a77d754a75756a16245a719de52b0a 02-Feb-2006 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

fixed overlay playback and accelerantion engine crashes if all is right: it turns out the last piece of cardRAM may not be accessed by software. This looks to be a hardware bug, size of dangerous RAM depends on pre/post NV40 architecture, bug exists for both FIFO channel assignment on the fly, and DMA command buffer existing in cardRAM. If there are still users outthere using PIO acceleration and 3D they have a good chance of having working concurrent overlay as well, as the fifo-assignment bug turns up with PIO acc as well. Note: the bugfix is still in test: confirmed on TNT1 only for now.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@16200 a95241bf-73f2-0310-859d-f6bbb57e9c96


# d24c6abf98bf3732208acecfb2ee186c85bf05ec 31-Jan-2006 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

comment update: pitch granularity now confirmed for 15, 16 and 32bit RGB depths (SCALED_BLIT).

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@16169 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 9f6aebed5fc8cc92170e6abae98819f3274fadbb 31-Jan-2006 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

updated SCALED_BLIT to do 15-bit space correctly.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@16168 a95241bf-73f2-0310-859d-f6bbb57e9c96


# c6cacf3fb610885cc70f9c17e7d06232b3bc6ed8 21-Dec-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

removed 'typo' introduced while testing.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15645 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 04928d2c97a59b7b7b8c0c5f9a60a8beca89ec0e 20-Dec-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

fixed with-issues with scaled_filtered blit. Tested for 16bit space. Over here this new function is now stable. Other spaces will be tested asap.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15615 a95241bf-73f2-0310-859d-f6bbb57e9c96


# a06a87b98ca39014e3dec37b9b337e958d9d2bbe 20-Dec-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

corrected scaled_filtered_blit setup according to test results with a node. Now it correctly works for a 'number of source-widths': tested 320 and 640 pixels source bitmaps. This source-width thing is still under test..

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15613 a95241bf-73f2-0310-859d-f6bbb57e9c96


# c0f616278374c8c4adfc285fd1c00a93bf2799c7 20-Dec-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

updated scaled_filtered_blit code and fixed NV1_RENDER_SOLID_LIN setup. Scaled blit might still be down, but we are getting there.. (in progress)

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15602 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 010c6409649920a593644e0e489bac2b9499f586 15-Dec-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

finished and enabled support for 2D acceleration function SCREEN_TO_SCREEN_SCALED_FILTERED_BLIT (DMA mode only). While still untested, the engine keeps running at least. Should work on all cards the driver supports. Note: overlay support is now broken: 2D engine freezes at some point. Will fix that asap (I hope)...

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15542 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 2a2d851212e73ee1881547d18964b09397cf7068 15-Dec-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

fixed not asking cmd buffer for room for all items (scaled_fiterled_blit)

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15541 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 0cb2429ad1b99389463773c2ee6efe95851f28dc 14-Dec-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

completed preliminary (untested) scaled_filtered_blit function, although it wont' work yet: the engine cmd define and fifo assignment has yet to be setup.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15538 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 9af6e789da5770e766a52f581f8485b4dbcdfb56 14-Dec-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

more stuff for SCREEN_TO_SCREEN_SCALED_FILTERED_BLIT function. Not yet complete though.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15536 a95241bf-73f2-0310-859d-f6bbb57e9c96


# a89d836024490274ed4c31fcbd9bedfcc06d25e5 08-Dec-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

adding DMA acc function SCREEN_TO_SCREEN_SCALED_FILTERED_BLIT (in progress). The videonode turns out to be a nice playground to test it with, so I can set it up. Also it looks like I'm going to need it because I can't get a B_YCbCr422 connection going on R5 or dano (negotiation seems to fail).

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15424 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 40df1a3a014ddbc97f61e4a43366937620670ecc 17-Nov-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

completed DMA acceleration init code sync to XF86. All cards should be operational again (still untested). Bumped version to 0.65.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15003 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 4cb53e7f3a589c949c953762ec9dfc2f9e904f6c 17-Nov-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

updating DMA acc engine init code: part 4. Still in progress, but maybe NV47 acc runs now: It's enabled now. This turns out to be an interesting update: init code has been extended for NV20 and higher cards, giving me reason enough to probably do some more 3D testing on newer cards. (probably for nothing though :)

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14999 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 1f6a1fb82442154025402f3a361d94f012ec367c 17-Nov-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

updated engine DMA acc init code, part 3 (in progress).

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14989 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 0229e1586c1c70b2118c3a46f639071dc1e88a57 17-Nov-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

updating DMA acc init code, part 2: in progress.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14987 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 5b3f340070c249aa4c072efa83dc26bdd91258fc 17-Nov-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

updating DMA acceleration code for NV41, 43, 44. Adding code for NV47: sync to XF86, in progress (acc might be broken now..)

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14984 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 845faf5e8dd948ae8fb3471c4df019b099a75eca 04-Jul-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added some comments about the NV18 speedfix and resetting registers on NV28.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13424 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 21545d001fe1bfc6c6330c390f4b027061b525ba 19-Jun-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added/modified shared_info to (better) support upto 32 3D accelants. Needs to be improved/expanded later though. Bumped version to 0.53.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13210 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 332f986f39db9b0477830d22dcbe7988bf9ca517 15-Jun-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

modified 3d reload flag to support 32 clones, added clone counter as well.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13175 a95241bf-73f2-0310-859d-f6bbb57e9c96


# b7c592306b22a7e0256a5ead6f4434a779cf742a 16-Jun-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added shared_info flag to inform 3D add-on to reload it's rendering state, further improving 3D rendering speed: Quake2 is at 105fps (GF4MX440, 640x480x16), Teapot renders at close to 500fps now. Bumped version to 0.52.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13169 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 3d83865e2b6e9433a53d64af7e1b5b20c0eeebfe 13-Jun-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added a concurrent overlay/3D workaround making that combination work reliably now. No more engine crashes should occur. Bumped version to 0.51.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13092 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 081f461390903125d6705b2dd54d5cba6b71f6ec 13-Jun-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

corrected all dummyreads to use volatile pointers. Thanks Marcus Overhagen for reading along.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13082 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 6dcf8a8bdf19bac6e3dbec2e371daabcbda71cef 09-Jun-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

modified a few comments only . All my cards BTW are running OK (including NV43/PCIe), so it looks like a release can be about done.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13029 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 740fbb06efba2b6072b8198897650f37e71e22e7 02-Jun-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

updated explicit engine register clearing to be only carried out on pre-NV20: newer cards don't like this and hang. Also cleaned up a bit. Let's stick with the 1Mb cmd buffer as it seems to have proven itself now. (only pre-NV40 for now).

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12927 a95241bf-73f2-0310-859d-f6bbb57e9c96


# bbc828ca1ebac7d13cf02229594efb99e993fd94 01-Jun-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added some more comments for specs

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12926 a95241bf-73f2-0310-859d-f6bbb57e9c96


# ca459671044d2587b2e2dcd4f48bc343e39d2ae6 01-Jun-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

FIX FOR NV18cd obos_svn/trunk/src/add-ons/accelerants/nvidia/ We now have a new winner for 3D. Quake2 runs at 91.5fps in 640x480x16. I can hardly believe this..

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12925 a95241bf-73f2-0310-859d-f6bbb57e9c96


# f1909366e4836753304940e68db5c7f4817dbdb3 30-May-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

fixed NV1x 3D DMA acceleration. NV15 now renders the teapot at 400+fps in both 16 and 32bit, quake2 in 640x480x16 runs at 77fps. The DMA 3D driver is now fully operational to the same extent as the PIO version: but much faster :-). Note, this 2D driver is still in testing..

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12905 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 0188d8661ea5671a81f2d601167214df117277d2 26-May-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added shared_info flag to assess PCI or AGP mode. Engine (if in DMA mode) selects PCI or AGP transfers accordingly (pre-NV40 only for now). It seems the combination of the 1Mb cmd buffer size and it being in main mem makes it all fast. (1Mb in gfx card remains at same speed at 32kb.). Maybe we can even use AGP engine transfers for placing textures on the gfx card in the future: who knows.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12848 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 1e7ae0559fe5f4df94072d71ad6f99447968fe02 26-May-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

forgot to tell the DMA cmd fetch engine it may write-back as well as read. Seems to not have influence on speed, as expected I'd say. Anyway: just tried enabling AGP transfers for cmd fetches: that actually works over here!. I just saw GLteapot spinning at over 400fps because of it. Note however that this doesn't mean we can reach that speed with a local DMA command buffer: the real reason for the higher speed might be the large size (1Mb compared to 32kB). testing some more..

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12844 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 5b5ef87b84bc78d8601f1dfb116322a12c6e6749 26-May-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

on pre-NV40 I have activated the main mem DMA command buffer at size = 1Mb. It's working OK and is way faster on TNT1 (using the local-DMA-via-mainmem workaround) - of course. For all other cards however (so which have working local DMA command buffers) the mainmem implementation is actually a bit slower, and places a higher burder on the bus slowing down 2D a lot when 3D maxes out. All in all, I am not sure this is the way to go. It might be best to make this all a switch for nv.settings, disabled by default. Still testing... (Curious how AGP transfers will do - if possible, currently using PCI transfers)

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12843 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 395332ac33692a9f44bc4ed6f45e34b4a7aee59a 26-May-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

small update to keep accelerant working with already modified kerneldriver and shared_info for mainmem DMA buffer.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12836 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 23f40a23452a0e9aace1e2abec35db92c73495f4 22-May-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

more cleanup for DMA: re-organised cmd define locations.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12764 a95241bf-73f2-0310-859d-f6bbb57e9c96


# af9bb34820f9e95cf62900f1c59b76371257cffa 21-May-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

major hash and engine command defines cleanup (PIO and DMA). It looks like the hash-rules are quite simple after all. Hoping I'm right about that: looking good. PIO mode: 3D add-on alpha1 should nolonger work with the current 2D driver (hang). DMA mode: on TNT2 orig, DMA 3D acc is fully working now. All surface commands work, old ones are removed. I'll (try to) bring PIO mode upto par so 3D will work again there too. GLteapot stays at 360fps @ 16bit, 280 fps @ 32bit for now (TNT2 orig). Bumped version to 0.47.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12762 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 980fda2605eb5c5215217a5ad3c688a6600d570b 21-May-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

fixed concurrent overlay and 3D use. This never worked before: it turns out that overlay requires a certain engine command setup order/chain without gaps to prevent hard crashes. 3D surface cmd still down though..

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12756 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 0fcc145db7690d32c0fc1ddf48dcb33f9c840026 21-May-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

removed more old surface commands related programming.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12755 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 1684de39042b7e729d697c5dc9d254a24a6776d9 21-May-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

removed old 2D/3D surface commands. While the 'new' 3D surface command is still down, the 2D surface command has been replaced with NV4_SURFACE/NV10_CONTEXT_SURFACES_2D. These indeed work. Teapot: now @ 360fps on TNT2 orig (16bit).

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12754 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 6efe4e121fb72ee9940cbe6056137210c5f32c0f 12-May-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

fixed introduced error for TNT1. DMA mode is a bit flaky ATM though here.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12650 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 00b2e25e6205b57471e370c8f5f3dd59b92abf3b 12-May-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

more colorspace dependand engine cmd programming for 3D. Now 15,16 and 32bit mode are up again: 15/16bit: teapot 320fps, 32: 280fps (tnt2). All demos run.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12642 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 1252f57f6134a4a8b546dc42b06a847ebc310066 12-May-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added DMA surface cmd's colorspace dependant programming. These commands were still down at last 3D test, but already the Teapot is spinning at 300fps in DMA mode ona TNT2 over here!!

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12641 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 372f7c3b9e5f92fc3123f621b00fa25acc077ec7 10-May-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added all 3D related commands found in PIO acceleration code to DMA pre-NV40 code as well. Bumped version to 0.46: experimental, should be fully OK though (for 2D).

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12626 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 7540371dbba2264bbd124cc4b4da6cbee3ff288a 21-Feb-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

the DMA acc sub-cmd-lists are now issued to a single engine command (except for blit because it's hardware can't do that), instead of to multiple issued engine commands. (one could say 'parallel processing' but that's not the case: it remains serial: it's just faster).

DMA acceleration speed is up another 10% for rect and span commands.
commencing more testing now: code is complete (I hope).


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11433 a95241bf-73f2-0310-859d-f6bbb57e9c96


# d0ef756a52815f3372690785b4301005d70e4d49 21-Feb-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

optimized DMA acc code more by splitting up command lists into sublists before issuing them to the engine. this further improves speed with upto about 70 percent, for a total of about doubling the speed by pure software optimation.

Note: code is now working the same as Thomas's ATI driver: he minimized calls in the same ways. (Curious how a benchmark contest would hold up now.. ;-)


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11431 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 1554e5cb4cc1188427f740aa881ab95363d1e2bd 21-Feb-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

applied DMA mode speed optimations 'step 1.5': incorporated all top-level acceleration functions inside the engine's code so minimal nested calls are made. Confirmed further speedup of about 15% on fast CPU's...


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11427 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 18dfc8a2b034053e40f76370093d983665c3cf7e 19-Feb-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

optimizing DMA acc for speed ('step 1'). Also simplifies code.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11422 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 10988528d1befc7acc749b0a644131d3e205bd1e 18-Feb-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added fix (not yet completely tested) for NV40/NV45 artifacts on heavy acc engine use. Bumped driverversion to 0.37.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11419 a95241bf-73f2-0310-859d-f6bbb57e9c96


# cb49723124e6470d1fb12d165e4808830900971b 19-Feb-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added one (still disabled) register for framebuffer config(?) on NV40/NV45 (in test)


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11417 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 36ad4411a87a4487c144eb85725ee5d28f352da4 17-Feb-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added some comments about NV40 architecture. We have several new unknown factors:
- DAC2 always detects a analog screen connected;
- it seems like there are at least two new registers we don't know about. One extra switch to place output on connectors, and one (extra) switch for pixelclock PLL to CRTC connections (one PLL drives both CRTC's in some cases, pre-programmed by the card BIOS determined on the screen configuration found at power-up.
- in a known register (TSTCTRL) b20 blocks/moves output on connectors (?).
All confirmed on NV43, GeForce PCIe 6600GT.

Driver status:
- one DVI monitor connected is OK;
- one analog screen connected on the DB15 connector is OK,
- two analog screens connected is OK and can be used for dualhead.
other combinations don't work well or at all. This is the status confirmed on
the NV43. Assuming same for other cards of NV40 architecture.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11399 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 9b501a81b3a6e94e49b67e9cb98a1b6c6e3240f1 12-Feb-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added some more PIO mode acceleration programming for NV40 and higher. This remains non-functional: aborting dev on this for now. Notes about the problem are in the code. For now I guess no-one cares about PIO mode nomore anyway... ;-)


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11354 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 7139e38e411d2662caafa5d4e757b66fb9c581be 10-Feb-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

updated a few comments, added some acc stuff for NV40+ for PIO mode: trying to get that up as well briefle now.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11328 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 4f985adf3a9e4b609333209804f005bfbb09aad9 08-Feb-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added NV04(TNT1) DMA workaround code. TNT1 now also works with DMA acceleration. TNT2-M64 has been confirmed up also. This means all cards should work now! (Except for a NV40 artifact on blits..).
Still some finetuning to do.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11293 a95241bf-73f2-0310-859d-f6bbb57e9c96


# e7b37d0211aef8441e6eb87629b6122a00abdee2 08-Feb-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added pre-NV10 screen location and size for completeness. NV05 (TNT2) is confirmed up and running speedy now :-)


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11292 a95241bf-73f2-0310-859d-f6bbb57e9c96


# c1d1fdbc43477a250777ff04ad90fbed1d10e7a7 08-Feb-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added preliminary pre-NV10 specific DMA acceleration code. Not finished, not tested.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11290 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 36b7db70d15fabc8e37c04d166a29c6c94b015f2 06-Feb-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

updated a few register defines for NV44 type.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11271 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 94e32479c0b0e20527546df042719bd8a984441a 06-Feb-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

fixed NV44 and NV45 programming for acceleration


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11269 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 63def9b208b0e15494561d23d90099a46d080d3d 31-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

completed NV20 architecture DMA acceleration: confirmed both NV20 and NV30 architectur up and running OK BTW.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11171 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 8d2dfc64ee9a61f4a0f1aef7cda994e68711ae6b 31-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

small simplification for reading and writing DMAGET and DMAPUT, gives a minor speedup (a few percent max).


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11167 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 41dde765fc0d3abddcab04f8316ffe64d6136e46 28-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

completed DMA acc for NV30 architecture, still untested. Fixed two doubled registerdefines which adress the same registers.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11108 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 7309e1cd859fe2f5647a06bef350f404f1549972 27-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

needed to bump the DMA command buffer forced freespace up to 256 words: NV4_GDI_RECT needs a higher setting than the old version. Hopefully engine crashes are now past tense...


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11095 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 64efa4b4afa43875dfd36844486b38229c668844 27-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

Arrrgghh! I was still using NV3_GDI_RECTANGLE_TEXT instead of NV4_GDI_RECTANGLE_TEXT on pre-NV40 (NV11 tested). Fixed now.
Anyway: Now we know the reason the switch must be made: the old command, while being approx. of the same speed as the new one, has a hardware fault and has also therefore been removed in NV40 and later hardware.
The fault is the input->output colorspace conversion which doesn't work while being used with DMA acc. Glad I could loose that nasty workaround now!!


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11093 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 4e05353d7fb310fd2ec45e1ecab31bab5018b550 27-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

fixed overlay bitmap DMA adress, fixed overlay in 15 bit mode (NV11). nVidia hardware is broken here :-/. Anyway, it works now.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11092 a95241bf-73f2-0310-859d-f6bbb57e9c96


# fee251bc01435696b4f0dc6f89e77c53e350bfd7 26-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

modified overlay to stay outside DMA buffer if it exists.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11091 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 4dca5362dfa77fef04d20f705336127e4105d99c 27-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added invert_rect DMA acc function. Tested in all colorspaces on NV11 (OK).


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11090 a95241bf-73f2-0310-859d-f6bbb57e9c96


# d4d5ee8bbbf49c3408ba952ea1546617fe709eb7 27-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

updated DMA acc to use the full DMA buffersize instead of just one quarter.
Also improved forced freespace limit setting in this buffer, now finally completely preventing engine crashes it seems.
Engine speed went up again due to larger DMA buffer.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11089 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 1a713b1806e574e8e36c48736abcf8fcfb2c8f45 26-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

fixed fill_rect and fill_span 8, 15 and 16 bit colorspaces for NV10Arch. Tested and OK on NV11.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11080 a95241bf-73f2-0310-859d-f6bbb57e9c96


# e846ba3dd6ce5490cdbb8acfe3e8f44d8c596fe2 24-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

updated DMA engine error handling: the driver should nolonger hang (again) if the engine crashes.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11018 a95241bf-73f2-0310-859d-f6bbb57e9c96


# ab26d7f83768b1a9c8adc54fe9ac73d66c4b7e76 24-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

finalized DMA buffer overfill checking for optimum speed. On NV11 accelerated functions are running at 130% to 200% speed in DMA mode compared to the 'old' PIO mode. Without trouble now.
Still only 32bit mode, and still missing invert_rect function though. Also still not explicitly adhering the engine constraints which needs to be rechecked/retuned compared to PIO mode (hence the non working 800x600x8 mode I expect..)


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11009 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 11e38e920fafa73fe2f7140c78ea7751a8fd515a 24-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added checking to prevent DMA buffer overfills: it turns out for instance NV11 can't keep up with BeRoMeter and the engine crashes otherwise. It turns out NV11 is currently only working correctly in 32bit color mode BTW.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11005 a95241bf-73f2-0310-859d-f6bbb57e9c96


# e2e0a5e1771ae6880ae13cbb863583f8bc042b46 24-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

shut-down that dumb ISA access for DMA. Acc speed just went through the roof! (testing with BeRoMeter). I'll now compare DMA and non-DMA speed on NV11 8-)


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11003 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 34b1362959a8a1b35d7de1d7d854ae8d05e39ec5 24-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

DMA versions of fill_rect and fill_span (same core func still) are up! Removed some testlogging, their load became too high with these new functions added :)


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11001 a95241bf-73f2-0310-859d-f6bbb57e9c96


# de653df809eea6e0ae25ebe1893b212018033db4 24-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

small cleanup. This fixes DMA buffer freespace tracking as well.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@11000 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 105a3567a665128a25de7854372ce99af9b35db7 23-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added fill_rect and fill_span functions (same). Not yet exported, not yet working either..


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10986 a95241bf-73f2-0310-859d-f6bbb57e9c96


# d4a57f27363b9f61a9c288665919271b13940e23 23-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added timeout and abort for DMA idle waits. This keeps the system responsive if the DMA engine fails, which is way better than a complete hang. Adding this because it's not impossible to create a situation that stalls DMA: for instance if a video app writes (way) outside it's allocated overlay buffers.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10976 a95241bf-73f2-0310-859d-f6bbb57e9c96


# fc61675c5a3f99cfac3695afcf512781ea63c93d 22-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

completed DMA buffer wraparounds. DMA acceleration is now stable on NV11 and NV43. Enjoy.. (still missing acc hooks will be setup asap.)


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10959 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 1a63a6982eb64fc57542df8a80662319ca68fb54 22-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

small cleanup (mostly comments updates)


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10944 a95241bf-73f2-0310-859d-f6bbb57e9c96


# f174c1bdcebc2ab2b6aff8a2ff66412881e2e85f 21-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

another nice milestone: NV43 (GeForce PCIe 6600 GT tested) has acceleration up and running as well now!. Please note that the same restrictions apply here as I just mentioned for NV11: to be fixed asap of course ;-)
Jippieeee!


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10941 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 8e3d3f5e1848eba8928388979e09c17910c747d3 21-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added explicit clearing of the hashtable engine RAM. This sneaky thing won't get to me again: it keeps it's contents even over power-outages of upto say 15 seconds!!


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10932 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 16c2cf6bb2e404dea647a7e23d1ebde6a0e02002 18-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

small logging correction for DMA_PUT.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10847 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 18b2b9dab7c9da56624ce742f07ee1b8ffe3d37c 18-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

The DMA_PUT register is write-only on some cards (confirmed NV11).


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10846 a95241bf-73f2-0310-859d-f6bbb57e9c96


# e4d42ef757671a878aa12bd51811997805291bda 18-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

fixed a stupid error I introduced with cleaning up some stuff: FIFO channel assignments should now work. Confirmed NV11 BTW being at the same level as NV43: DMA works, engine not yet.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10839 a95241bf-73f2-0310-859d-f6bbb57e9c96


# e0cbecd9c9071258406dce098c1a50bcb1bd923a 17-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

completed NV10 architecture DMA programming to the same level as NV43. Hopefully this engine will show more signs of life than NV43 still does..


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10800 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 4cd3f831c2de2c432c46e6b10e47a1d466de9b5c 17-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added cmd defines (CTX registers) for pre-NV40 cards, corrected a CTX programming error for NV40 and higher (2d_surface).


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10798 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 20f190801031b46ecf7732ebf00eb59445f7f248 17-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added setting pattern colorspace (DMA)


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10795 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 02e231b77b2d407b8850b038f52e0171446452de 16-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added 2D_surface setup (DMA), added fifo channel assignent check for aquire_engine, cleaned some stuff up.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10793 a95241bf-73f2-0310-859d-f6bbb57e9c96


# a9b9a9147eaff26ee1bf4689a9dca1daf6a74349 17-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

fixed FIFO channel pointer error that caused assert_fifo to always fail (DMA, >NV40). Should fix driver hanging after changing workspaces with different modesettings on NV40 and later.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10792 a95241bf-73f2-0310-859d-f6bbb57e9c96


# fcc9f0ab48587adb2b8bbc8317b62c814a78001e 16-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added 2D_surface command engine defines and FIFO channel assignment: used for setting buffer colorspace, location and pitch later on.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10771 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 3c85aa4f00f350c46ac1bb7116e4350717822dd7 14-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

more DMA related programming. Still acceleration this way is disabled. DMA command fetching now actually works on GeForce 6600/NV43 (verified). The acceleration engine still refuses to process the fed commands (correctly) though. OTOH: programming not yet coplete ;-)


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10734 a95241bf-73f2-0310-859d-f6bbb57e9c96


# a3587d4de61a5973782653dbc73f0c4901439057 13-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

modified cmd handles, added DMA blit partly. Still untested.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10713 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 0bfacfc2a992215294e31bc1a87fa851ecdf8bf7 12-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added DMA cmd related info


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10711 a95241bf-73f2-0310-859d-f6bbb57e9c96


# f180c737d75bcbbc32f66268c17ce3b52cf4415f 13-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

more DMA stuff


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10709 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 230c6e57f399afc1860e997602438298673295a4 12-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added more DMA programming: cmd buffer and FIFO setup.


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10701 a95241bf-73f2-0310-859d-f6bbb57e9c96


# daaa769853094ce181e4a6fc263b6a01c3cbe522 11-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added checking for engine idle: which is actually the case over here :-)


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10666 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 4610db26001aa1082b8a2b3087bb1f37ec6413f9 10-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added DMA engine initialisation code for NV40 and higher. Still disabled, and needs support from driver (reserve DMA buffer RAM etc)


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10660 a95241bf-73f2-0310-859d-f6bbb57e9c96


# dd43fd34c1d5ccbfbc0654222f23e2bc855b4057 10-Jan-2005 Rudolf Cornelissen <rudolf.cornelissen@gmail.com>

added cursor HW bug workaround for NV40 and higher on CRTC1; added seperate acc file for DMA test setup for NV40 and higher (for now).
The driver now works by default on NV40 and higher, but without acceleration.
If someone tests using overlay, let me know if it actually works: NV43 seems to have a new engine, NV40 _might_ still have the old, and so, useable engine.
NV40-plus overlay is something we will NOT have any time soon!


git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10651 a95241bf-73f2-0310-859d-f6bbb57e9c96