Re: [AD] Optimized blitting between color depths

[ Thread Index | Date Index | More lists.liballeg.org/allegro-developers Archives ]


Elias Pschernig wrote:
Ideally, we would have more test results. For me, it always was faster,
except in the case where there should be no change - but there it was
very fast (between 1-3 ms/call, so faster than all the other results).
So probably things like code alignement/whatever only played a
significant role there. With only my result, I'd say, apply it - it will
speed up the cases where it brings something, and the case of normal
blitting is slower for some reason.

OK, if nothing new comes up within a week or so, I'll apply it.

A bigger problem is Milan's results (many thanks for running it btw.) -
in his case, the dithered and keep_trans cases all are slower with the
patch - if I interpret them right. So just the opposite of my results.
Or maybe the "patched"/"not patched" is swapped?

I think they must be, since the numbers are pretty much opposite to what you get...

Can you post your detail results as well? And maybe someone else? I must
say, I'm somewhat puzzled so far.

Sure, here are my results:
(on the form "src_bpp -> dest_bpp: before after percent")

dithered, keep trans
24 -> 15: 37.109375 ms/call 25.351562 ms/call 68.3157881263158%
32 -> 15: 37.812500 ms/call 25.507812 ms/call 67.4586763636364%
24 -> 16: 36.796875 ms/call 25.585938 ms/call 69.5329100636943%
32 -> 16: 37.070312 ms/call 25.898438 ms/call 69.8630159897224%
dithered, no keep trans
24 -> 15: 27.773438 ms/call 25.976562 ms/call 93.5302356157707%
32 -> 15: 29.023438 ms/call 27.460938 ms/call 94.6164200119917%
24 -> 16: 27.812500 ms/call 25.976562 ms/call 93.3988746067416%
32 -> 16: 28.984375 ms/call 27.382812 ms/call 94.4743918059299%
non-dithered, keep trans
15 -> 16: 29.062500 ms/call 14.101562 ms/call 48.521503655914%
15 -> 24: 31.093750 ms/call 15.820312 ms/call 50.8793953768844%
15 -> 32: 31.210938 ms/call 16.210938 ms/call 51.9399256760563%
16 -> 15: 29.687500 ms/call 14.101562 ms/call 47.4999983157895%
16 -> 24: 31.523438 ms/call 15.937500 ms/call 50.5576200159386%
16 -> 32: 31.835938 ms/call 16.210938 ms/call 50.9202461695961%
24 -> 15: 27.890625 ms/call 10.937500 ms/call 39.2156862745098%
24 -> 16: 27.656250 ms/call 10.781250 ms/call 38.9830508474576%
24 -> 32: 30.390625 ms/call 13.437500 ms/call 44.2159383033419%
32 -> 15: 29.375000 ms/call 11.484375 ms/call 39.0957446808511%
32 -> 16: 29.375000 ms/call 11.484375 ms/call 39.0957446808511%
32 -> 24: 30.859375 ms/call 14.062500 ms/call 45.5696202531646%
non-dithered, no keep trans
15 -> 16: 12.734375 ms/call 12.656250 ms/call 99.3865030674847%
15 -> 24: 15.117188 ms/call 15.000000 ms/call 99.2248029196964%
15 -> 32: 14.179688 ms/call 14.179688 ms/call 100%
16 -> 15: 13.398438 ms/call 13.359375 ms/call 99.7084510895972%
16 -> 24: 14.492188 ms/call 14.960938 ms/call 103.234501236114%
16 -> 32: 14.843750 ms/call 14.804688 ms/call 99.7368454736842%
24 -> 15: 9.726562 ms/call 10.156250 ms/call 104.417676050387%
24 -> 16: 9.296875 ms/call 10.039062 ms/call 107.98318789916%
24 -> 32: 12.265625 ms/call 11.992188 ms/call 97.7707047133758%
32 -> 15: 9.726562 ms/call 10.039062 ms/call 103.212851570781%
32 -> 16: 10.156250 ms/call 10.039062 ms/call 98.8461489230769%
32 -> 24: 12.890625 ms/call 12.890625 ms/call 100%


Here's a script to produce them (assuming the output from my program is in the files "before" and "after"):

#!/usr/bin/perl
open B, "< before" or die "Error opening before: $!\n";
open A, "< after" or die "Error opening after: $!\n";
while (<B>) {
    $a = <A>;
    if (/: ([0-9]+\.[0-9]+) /) {
	$bn=$1;
	$a =~ /: ([0-9]+\.[0-9]+) /;
	$an=$1;
	chomp;
	print "$_ $an ms/call ". ($an*100/$bn) . "%\n";
    }
    else {
	print;
    }
}


/Sven




Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/