View Full Version : Running AviSynth+ x64 Is Much Slower (nnedi3)


MysteryX
17th December 2014, 05:09
I made a script that runs fine in either AviSynth 2.5.8 (for preview) or AviSynth+ (for actual encoding)

Now I tried running it with AviSynth+ x64 instead to see the performance difference.

The x64 version of x264 works fine. I can re-encode videos perfectly well. I can also feed it a simple "ColorBars" script and it encodes well.

Now, if I add the eedi3.dll x64 file, starting the encoding takes forever and it then goes very slowly. With nnedi3.dll x64, I'm getting 21.5 fps instead of 30.5 fps.

Why is running those in x64 mode so much slower?

What's installed on my system is AviSynth 2.5.8 MT, and I copied the x64 AviSynth.dll and all other x64 filter files into the x264 folder so that the encoder uses AviSynth+ x64.

TurboPascal7
17th December 2014, 07:05
Either you're using some older versions of these plugins or they're just not optimized for x64. Nothing you can do about it.

Groucho2004
17th December 2014, 10:11
With nnedi3.dll x64, I'm getting 21.5 fps instead of 30.5 fps.
You must be doing something wrong, see here (http://forum.doom9.org/showthread.php?p=1665633#post1665633). Even when you include the encoder in the benchmark it should be much faster since 64 Bit x264 is faster than its 32 Bit counterpart.

feisty2
17th December 2014, 11:11
or you used avs 2.5.8 MT
and the official build of avs+ is not mt supported

Groucho2004
17th December 2014, 11:34
or you used avs 2.5.8 MT
and the official build of avs+ is not mt supported
Quite possible, good point.

Edit: This would also be a rather bizarre choice, 2.5.8 MT is probably one of the least stable versions around.

MysteryX
17th December 2014, 18:28
I have 2.5.8 MT installed because that's what SVP uses.

But when I do the actual encoding, I'm using AviSynth+ x86

so I'm comparing AviSynth+ x86 with AviSynth+ x64

MysteryX
17th December 2014, 18:32
OK I tried encoding a basic "ColorBars" script.

AviSynth+ x86: 665 fps
AviSynth+ x64: 707 fps

That's more like it.

Did another test with a simple AviSource, x64 performance is also considerably better.

As soon as I add NNEDI3, however, performance is much worse.

Groucho2004
17th December 2014, 18:54
If you want help you'll have to post your script and the links where you got the NNEDI3 plugins.

MysteryX
17th December 2014, 20:26
Got the NNEDI3 x64 v0.9.2 here
http://forum.doom9.org/showthread.php?t=147695

The x86 version, however, is v0.9.4

Test #1:

AviSource("Preview.avi", audio=false).ConvertToYV12()

Result:
AviSynth+ x86: total 30 sec
AviSynth+ x64: total 26 sec

Test #2:

AviSource("Preview.avi", audio=false).ConvertToYV12()
LoadPlugin("nnedi3.dll")
nnedi3_rpow2 (2)

Result:
AviSynth+ x86: 42 fps
AviSynth+ x64: 30 fps

colours
17th December 2014, 21:11
https://github.com/jpsdr/NNEDI3/releases

This is linked on page 25 (currently the second last page) of the nnedi3 thread. It sure wouldn't hurt to check more than just the first and last pages of the relevant threads.

Groucho2004
17th December 2014, 21:22
That old 0.9.2 64 Bit version is indeed slower than 0.9.4 32 Bit.

I just tried jpsdr's 64 Bit version (SSE4.2) and it's pretty much the same speed as tritical's 32 Bit version on my i5 2500K. The AVX version may be a bit faster.

MysteryX
17th December 2014, 22:12
Wow, this version as MUCH better performance!
I'm getting 50-60 fps for both x64 and x86. Very similar performance. Couldn't say x64 is faster though.

EEDI3 is still what is taking the most time. Is there a a version later than x86 0.9.2 and x64 0.9.1 ?

MysteryX
18th December 2014, 04:12
Actually... NNEDI3 v0.9.4.7 (standard) has slightly lower performance than v0.9.4 in x86 mode. The SSE4.2 version has slightly better performance but selecting from 3 versions isn't practical when bundling it into an installable software. I might just as well stick to x86 v0.9.4

The main advantage to v0.9.4.7 is that the x64 and x86 versions are consistent with their performance.

Reel.Deel
18th December 2014, 04:38
Another advantage of nnedi3 v0.9.4.7 is that you can use FTurn (http://forum.doom9.org/showthread.php?t=168315) to get better performance when using nnedi3_rpow2.


Edit: In AviSynth+ FTurn is obsolete, those optimizations are already included in the core.

jpsdr
18th December 2014, 10:05
https://github.com/jpsdr/NNEDI3/releases
This is linked on page 25 (currently the second last page) of the nnedi3 thread.

Or in the first page of this thread (http://forum.doom9.org/showthread.php?t=170083).

I'll probably within one week put a new compile version (with ICL 2015 + VS2013), with and without XP support.
But as the code will not change, don't realy expect great change in speed.

The advantage of my version is the support of more color format. After, the code is the same (except the inline asm put outside in ASM files), with, in the asm code, some little adjustement/improvement for x64.
Theoricaly, in x86, my version and original should have similar performance, and maybe x64 will be a very little better.

Groucho2004
18th December 2014, 11:36
Actually... NNEDI3 v0.9.4.7 (standard) has slightly lower performance than v0.9.4 in x86 mode. The SSE4.2 version has slightly better performance but selecting from 3 versions isn't practical when bundling it into an installable software. I might just as well stick to x86 v0.9.4

The main advantage to v0.9.4.7 is that the x64 and x86 versions are consistent with their performance.
I'll throw another 32 Bit version into the mix. I used triticals 0.9.4 code base and built it with ICL10. It's a few percent faster than any of the other 32 Bit versions, tested with AVS+.
Get it here (https://www.dropbox.com/s/4wznvnqtnsumea1/nnedi3_ICl10.zip?dl=0).

MysteryX
18th December 2014, 16:07
I'll throw another 32 Bit version into the mix. I used triticals 0.9.4 code base and built it with ICL10. It's a few percent faster than any of the other 32 Bit versions, tested with AVS+.
Get it here (https://www.dropbox.com/s/4wznvnqtnsumea1/nnedi3_ICl10.zip?dl=0).
Nice. I'm getting better performance than the SSE4.2 version

jpsdr
25th December 2014, 14:33
I've made a new build (new compiler version), if curious want to benchmark... ;)

Link on page here (http://forum.doom9.org/showthread.php?t=170083).

tebasuna51
27th December 2014, 13:59
I add nnedi3 to thread title to help search.

Is a good thread to see nnedi3 links, and differences between versions.