View Full Version : XviD Encoding *very* slow
Piece
9th September 2003, 21:47
I've coded a lot on my athlon 1333 and i got ~9 fps. now i have a p4 2.4 ht and i hardly get the 8 fps. any ideas what might be wrong? maybe the hyperthreading does problems?
my environment:
p4 2.4 ht
512mb ram
win xp + service pack 1
avisynth script
vdubmod 1.5.4
xvid binary from Jul 16 2003
xvid: ultra high, h.263, wide search, use chroma motion
i'm thankful for any suggestions.
greetz piece
MoonWalker
9th September 2003, 22:49
This is normal..I have a Athlon XP 3000+ and I get 10-12 fps with mode 6, VHQ4,bframes,CM...
MoonWalker
haibane
10th September 2003, 00:28
Maybe it's because xvid is more optimized for AMD.
I got 14ish fps on my T-bred 2.19GH with koepi's build.
api4 is faster, I get about 16-17fps on average.
Then it also depends on what material you are encoding......
it could be some heavy action material where xvid throws p-frame all the time.
YY1020
10th September 2003, 00:33
It is normal.I used P4 2.4C GHz and 1GB DDR 400 ram(Dual Channel), and processed 24m anime that needed 2hours(2-PASS).I think that about ~10fps(i also used avs to compress,so it will be process slowest.)
Joe Fenton
10th September 2003, 03:44
Well, the use of various filters in AviSynth will drop the speed of encoding quite a bit, especially certain smoothing filters. Try to not use filters when you don't have to. I get about 13 FPS on my Athlon XP 1600+ when doing just resizing and deinterlacing and no noise reduction or other smoothing filters.
These filters may also not be optimized for P4 systems, depending on what computer the filter programmer uses. Unless the person also has a P4 system, or someone else does the P4 optimizations for him, they will only be able to do AMD speedups. This goes the other way as well.
Tommy Carrot
10th September 2003, 11:28
VHQ mode 4 is the guilty here. Without it, the encoding is 3-4 times faster.
Imperial Llama
10th September 2003, 14:38
As slow as XviD may be, I don't see how that explains why Piece's Athlon 1.3 is encoding quicker then his P4 2.4. Surly the P4 should be significantly faster then the Athlon? :confused:
Tommy Carrot
10th September 2003, 16:16
I guess when he used athlon for encoding, xvid didn't have VHQ modes.
seewen
10th September 2003, 16:41
It depend A LOT of the source too.
With My P4 (2800Mhz), I usually reach 60-90fps with an Avisynth script like that (say that the *.avi is 576x240. And xvid settings; Lumi : off, B-frames : on/2, h.263, VHQ : 1, etc.. )
AviSource(".....MyAvi.avi")
But if I rip a DVD, and use such a script:
Mpeg2Source("......", iDCT=5)
Telecide()
Decimate()
Crop(...)
LanczosResize(704,416)
FluxSmooth(2,2)
Limiter()
It's really possible that, even with such a powerfull cpu as my P4C, the encoding speed is between 10-20... (with XviD settings: lumi : on, VHQ : 4, B-frames : off, etc.. ).
Piece
11th September 2003, 10:01
i changed absolutely nothing in the encoding. my avisynth script is very simple, load file, crop, resize, and i used also before VHQ Mode 4. the only thing changed is the hardware, which should be ~3 times faster ...
mf
11th September 2003, 10:33
Long live Intel... :rolleyes:
Prettz
11th September 2003, 20:42
I'm running a 1.7 Williamette P4 with 256MB ram. With a hell of a lot of filters in my avs script and xvid using qpel, chroma motion, and VHQ4 I get 2-4 fps. VHQ4 is the one thing that's responsible for it though, as I used to get 15-20 fps without it.
Tommy Carrot
11th September 2003, 23:00
With my athlon xp 1700+, on a 720*384 encoding, i can barely reach the 5 fps with VHQ4, b-frames and qpel (dev-api 4).
Prettz
12th September 2003, 00:01
Originally posted by mf
Long live Intel... :rolleyes:
I can't say anything about the choice of assembly instructions or branching the xvid devs used, but I would bet any amount of money that the poor performance of P4s (even when they have SSE2 and HT) is completely and entirely due to the 8KB L1 cache (as opposed to the Athlons, which have always had an unbelievable 128KB L1 cache).
Joe Fenton
12th September 2003, 00:17
Originally posted by Prettz
I can't say anything about the choice of assembly instructions or branching the xvid devs used, but I would bet any amount of money that the poor performance of P4s (even when they have SSE2 and HT) is completely and entirely due to the 8KB L1 cache (as opposed to the Athlons, which have always had an unbelievable 128KB L1 cache).
Quite right. Cacheing is a MAJOR source of speed increase for staying in the cache or decrease for exceeding the cache capacity. A poorly written program (or one not compiled for a particular cpu), can actually use the cache in such a way as to run worse with the cache than if the cache were disabled. I ran into this when doing a PowerPC version of DOOM. The columns and extents rendering code would hit every line of the cache in the exact same place. With cacheing enabled, the scene would render at maybe 10 FPS on a given PPC. Setting the output buffer to cache-disabled sped up the rendering on the same system to 50 FPS.
Rash
12th September 2003, 02:19
FIRST -> I don't want to start a flame war here. Not really. PEACE :)
I'll just support my P4. Programs like Folding@Home do amazinly better with SSE than with 3DNow (and I think it is SSE 1, not even 2). So I believe that maybe XviD is not as well assembly optimized to P4 than it is to Athlons. Obvioulsy I may be wrong, but I don't want to start a war here.
To tell you the truth I don't really expect the XviD guys to improve the SSE support or not. I think they've already done a terrific job writing this amazing codec for free. I don't actually defend AMD or Intel either. I always look for the current best processor when I have the money to upgrade my PC. ;)
Prettz
12th September 2003, 03:18
Originally posted by Rash
FIRST -> I don't want to start a flame war here. Not really. PEACE :)
I'll just support my P4. Programs like Folding@Home do amazinly better with SSE than with 3DNow (and I think it is SSE 1, not even 2).
Well 3DNow is for exactly what it says, and it's pretty old anyway. All it does mostly is add support for some fast single-precision float operations (and I think some of them, like the fast square root instruction, aren't even fully single-precision) for 3D games, where speed takes priority over minor loss in quality. In stuff like math-oriented programs and video you can't use them at all because of the precision loss.
t3ch
13th September 2003, 01:43
On my xp 1700 I usually get 3fps, regardless of how many filters or options I have enabled. Whether it's a heavily filtered high quality anime, or a simple straight-from-d2v it's always the same.
Can't figure it out... :confused:
mf
13th September 2003, 12:08
On my XP 2000+ it's around 10fps with a very lightweight source (like a d2v with some deinterlacing), and around 6fps from VBLE (I never filter directly to XviD with heavyweight filtering). That is with VHQ on.
Joe Fenton
14th September 2003, 01:46
Quite a bit of it depends on the memory speed as well. I only have an Athlon XP 1600+ (1.4 GHz), but I get about 13 FPS probably because I have a KT400 based motherboard and use DDR400 memory.
Sirber
14th September 2003, 02:34
You'll gain speed if you set your RAM to 266 MHz. Your FSB is at 266. Setting it at 400, in async with the FSB, recude performances. Also, try to set your CAS Latency at 2 instead of 2.5 if your memory supports it.
Joe Fenton
14th September 2003, 20:39
Originally posted by Sirber
You'll gain speed if you set your RAM to 266 MHz. Your FSB is at 266. Setting it at 400, in async with the FSB, recude performances. Also, try to set your CAS Latency at 2 instead of 2.5 if your memory supports it.
The second suggestion would speed up the system. The first wouldn't. Remember, the motherboard controller doesn't ask for data at a 1:1 ratio to the FSB, the FSB starts a request for a line of data, the mbc then asks for a corresponding line from the memory. Modern controllers will often buffer from several lines to several K of data on transfers to avoid just such a slowdown as you imply.
While the cpu won't get the data any faster than the FSB rate, it frees the memory from cpu accesses quicker so that other devices can access the memory. Only the mbc fifo connection to the cpu is stuck waiting at that point. Remember, there's more in the computer than just your cpu. ;)
Sirber
15th September 2003, 01:29
ok
I'll need a hardware guru to rescue me (Ramirez :p) :D
Ramirez
15th September 2003, 02:04
The second suggestion would speed up the system. The first wouldn't.
I wouldn't be so sure about it: P
Which mode is better Synch or Asynch it's really IS depends on the MB/Chipset in question, some will benefit from running asynchronously while for another it's a sure way of reducing performance quite a bit. (Some will no allow anything then synch mode anyway) experimenting with HW is the only way to found out for sure.
Oh yeah, and ask Sirber which mode worked better for him. ;)
Hectic
17th September 2003, 10:07
odd, i get between 30-60 fps depending on field opperations i have selected. if it's film my fps sometimes peaks at 60. i have an athlon 2600. i used to get about 4 fps on my 333mhz pII...
ewat
21st October 2003, 00:48
i thought my speeds were a bit slow but appears about right..
using an avisynth script for typical digital tv cap (decomb, fluxsmooth), and resizing/cropping in virtualdub
with vhq4/motion 6 etc.
~5fps ;| on a axp2100/256meg slowass ram (pc133)
i thought something was heavily wrong here! but guess not
dedicated box for encoding but still! wonder where i could gain some speeds ;p
i find it weird that even if you put the priority WAY up, does hardly no difference to the fps
Selur
21st October 2003, 07:34
The priority only takes performance form other running apllications, so if no other applications is running, no speed gain through this.
I would recommend to switch from vhq4 to vhq1 ;)
Cu Selur
cipher
24th October 2003, 15:31
Oh I just asked my roommate, and the situation was there, too.
Is it Xvid- or avisynth-related?
trbarry
25th October 2003, 07:48
I had a situation yesterday where something encoded in a little over an hour once and when I did it again took about 4 hours. All I was doing was comparing the same thing with H263 and MPEG quants, same script.
But I can't reproduce it.
- Tom
unixfs
27th October 2003, 17:33
Hi,
if you want to save time, why don't you try to encode using
mencoder in Linux? I constantly get a double fps than with windows
(mencoder in windows is as slow as VDub).
For a clean movie (from DVB) cropped and rescaled to 640x480 the average encoding speed usually is 28 fps; when I add a denoise filter it drops
to roughly 25.
Encoding to 640x352 is even faster (32/33 fps).
My CPU is an Athlon xp 1500- with a SIS 735 chipset and DDR 266, so not really high end.
Human_USB
28th October 2003, 03:15
I have always had slow encoding speeds with XVID.... even with the newest XVID. I hope someone can fix the problem is there is one.
Mole
30th October 2003, 16:30
Human_USB, I think you are the only one who can "fix" this problem by getting a faster box. :D
Tommy Carrot
30th October 2003, 17:02
Originally posted by Human_USB
I have always had slow encoding speeds with XVID.... even with the newest XVID. I hope someone can fix the problem is there is one.
Set the VHQ mode to 0. With a little quality loss, the encoding is hugely faster.
Human_USB
30th October 2003, 18:54
Originally posted by Mole
Human_USB, I think you are the only one who can "fix" this problem by getting a faster box. :D
BTW.... I have a 1800+ XP with 256 of 2600 DDR.
I will try changing the VHQ once my VP6 test gets done.
Mole
30th October 2003, 19:13
I have XP 2200+ overclocked to 2.16 GHz and 512 PC3200 CL2 DDR and I get around 15 fps with VHQ4. (I always use VHQ4)
Forgot to mention that I usually run decomb Telecide and decimate and Convolution3d. Resolution is around 576x320 24fps.
Human_USB
30th October 2003, 19:16
Well.... I'm not going to update intil I have the money to get a AMD 64 3200+. It's just crazy how slow it is. It took two days to encode a 2 Pass encoding with Qpel and VHQ 4 on
Eyecannon
31st October 2003, 01:23
You can significantly improve encoding speed by overclocking, even if it's just the FSB with a multi drop. I run my default 133Mhz board at 166Mhz FSB, and that provides a huge increase in speed. Also setting the CAS to 2 and other aggressive memory settings will drastically speed things up. BTW, just having 'fast' RAM won't give you ANY speed increase... you have to actually run the FSB at a higher speed to utilize the RAM's capabilities.
I have an AXP 1600+ at ~1400Mhz (166 x 8.5) and with motion 6, VHQ 4, B frames, CM, no qpel, and H.263, I get 10-15 fps which sounds alot better than what some of you with faster systems are getting.
Human_USB
31st October 2003, 03:45
I'm a newbie at overclocking.... I know the ins and outs of a computer but I never overclock. I have the following hardware;
Asus A7v333 Motherboard
AMD XP 1800+
256 2600 DRR
Can you guys help me tweak my hardware?
Thanks
Jason
Mole
31st October 2003, 04:13
Here's a table of AMD CPU settings (http://discussions.hardwarecentral.com/showthread.php?threadid=148978)
You'll need to find out if you have the older Palomino core or the new Thoroughbred core.
I haven't heard of PC2600 RAM before though. There's PC2100 (DDR266) and PC2700 (DDR333).
You can so to say forget about OC if you have Palomino core. Unless you happen to have an multiplier unlocked CPU or wants to modify your CPU to unlock it.
Thoroughbred core, you can try increasing the FBS in BIOS maybe to 140 MHz. Then first see if you manage to boot into Windows. If everythings boots fine, try increase some more, maybe to 145 MHz. Increase till it won't post or you can't get into Windows. Asus is good to OC because if it won't post, you just turn off the power and turn it back on and it'll defalt to 133 MHz bus.
Don't worry about frying your CPU because it'll take a hell lot more than this to fry it.
Try to find the fastest setting you manage to boot into Windows. Now we need to find out if it's stable or not. When you get into Windows, simply try running some CPU intensive tasks. Maybe encode a movie or something. If it's stable, it should run fine, if you get BSOD or it just freeze it obviously isn't stable.
Try till you find the max FBS speed that your CPU can handle.
You can also try increasing the CPU voltage, but this may be a bit dangerous. As a newbie, I'd say you should not touch it yet.
Also, OC may decrease the life of your CPU, but by the time your CPU craps on you it's probably time for an upgrade anyway. Who use a CPU for more than a couple of years anyway?
And of course, do everything at your own risk! :devil:
Eyecannon
31st October 2003, 04:17
Originally posted by Mole
Here's a table of AMD CPU settings (http://discussions.hardwarecentral.com/showthread.php?threadid=148978)
You'll need to find out if you have the older Palomino core or the new Thoroughbred core.
I haven't heard of PC2600 RAM before though. There's PC2100 (DDR266) and PC2700 (DDR333).
You can so to say forget about OC if you have Palomino core. Unless you happen to have an multiplier unlocked CPU or wants to modify your CPU to unlock it.
Thoroughbred core, you can try increasing the FBS in BIOS maybe to 140 MHz. Then first see if you manage to boot into Windows. If everythings boots fine, try increase some more, maybe to 145 MHz. Increase till it won't post or you can't get into Windows. Asus is good to OC because if it won't post, you just turn off the power and turn it back on and it'll defalt to 133 MHz bus.
Don't worry about frying your CPU because it'll take a hell lot more than this to fry it.
Try to find the fastest setting you manage to boot into Windows. Now we need to find out if it's stable or not. When you get into Windows, simply try running some CPU intensive tasks. Maybe encode a movie or something. If it's stable, it should run fine, if you get BSOD or it just freeze it obviously isn't stable.
Try till you find the max FBS speed that your CPU can handle.
You can also try increasing the CPU voltage, but this may be a bit dangerous. As a newbie, I'd say you should not touch it yet.
Also, OC may decrease the life of your CPU, but by the time your CPU craps on you it's probably time for an upgrade anyway. Who use a CPU for more than a couple of years anyway?
And of course, do everything at your own risk! :devil:
Pretty much what he said, if you can't adjust your clock multiplier, you are a little out of luck as far as pushing the FSB as high as it can go. The Asus a7v333 appears to be 166Mhz FSB out of the box, so you could try bumping it up a few Mhz at a time until your system is unstable (you can test with a variety of programs, such as Prime95, 3dMark, even Memtest86). If you can adjust your multiplier, you can bump it down to something low, then bump up your FSB until it is unstable, then you will know your highest FSB (aka the limit of your RAM). Then you can raise the clock multiplier until it is unstable and then you will know the limits of your chip (aka the limit of your CPU). That's the basics really. Besides that, if you don't have your RAM at the fastest settings (CAS 2 is the biggie) then make sure you bump all of those settings up too.
Human_USB
31st October 2003, 04:39
Sorry.... I have 2100 DDR. I have 256 of 266, I always get the numbers mixed up. I will work on over clocking later, but I have togo work soon.
Didée
31st October 2003, 10:36
Originally posted by Eyecannon
I have an AXP 1600+ at ~1400Mhz (166 x 8.5) and with motion 6, VHQ 4, B frames, CM, no qpel, and H.263, I get 10-15 fps which sounds alot better than what some of you with faster systems are getting. Exchange h.263 with mpeg, and turn qpel ON.
After that, report again! I suppose you'll get lil'modest then ...
:)
Didée
Mole
31st October 2003, 11:19
If your RAM is PC2100, then I'm afraid it's running at it's max.
If you'll attempt any OC, you'll have to get faster RAM.
Eyecannon
31st October 2003, 20:17
Originally posted by Mole
If your RAM is PC2100, then I'm afraid it's running at it's max.
If you'll attempt any OC, you'll have to get faster RAM.
That is not necessarily true at all... RAM can often run faster than its rated speed. Of course, it may not.
Fox Mulder
17th November 2003, 10:50
Originally posted by Eyecannon
That is not necessarily true at all... RAM can often run faster than its rated speed. Of course, it may not.
I have my PC2100(DDR266) RAM working at 290 Mhz(DDR).
Mole
17th November 2003, 15:11
Of course it's possible to run the RAM at higher than rated speed, but in order to do so, memory timings has to be relaxed. I'd rather run it at CAS2 and optimal timings than CAS2.5 or 3.
If you have set your memory speed async with your FBS speed, you'll actually hurt performance more than you gain.
It's advisable to use same speed for both FBS and memory speed.
xixi2000
18th November 2003, 11:18
AMD XP1700+ overclocked to 2400+(166*12=2G) nforce2 512m DDR333,use xvid_amd.dll
1-pass VHQ1,2-pass VHQ4 average 20+ FPS
Mole
18th November 2003, 15:44
I thought you're not supposed to change the VHQ value between passes??
Sharktooth
18th November 2003, 16:04
Overclocking is an art.
BTW the new athlons (with barton core) can be easily overclocked to an incredible level.
For example my barton 2600+ (1909Mhz - 166Mhz x 11.5 - 1.65V) is rock stable at 2400Mhz - 200Mhz x 12 - 1.85V without special cooling (copper heatsink + 6000 RPM fan at about 50°C).
It could go higher but with water cooling only.
If you wanna overclock one of those damn mofos DONT FORGET TO UPGRADE THE PSU (at least 450 Watts)...
xixi2000
19th November 2003, 01:19
Originally posted by Mole
I thought you're not supposed to change the VHQ value between passes??
I think, you have never tried?
vBulletin® v3.8.11, Copyright ©2000-2026, vBulletin Solutions Inc.