The problem seems to be back (http://forum.avast.com/index.php?topic=75108.0) but worse than ever. Copying a 10M pdf from one HD partition to another takes 50 secs and one core at 100%.
Downloading 2 pdf’s of roughly the same length causes my dual core to max out on both cores during tens of seconds resulting in a computer that is completely blocked (only the cursor moves, no window updates). Example: download the 2 pdf’s on http://www.bitsavers.org/pdf/borland/turbo_prolog/.
I was on 5.1 and just upgraded to 6.0.1125 for this problem but no change. Virus definitions 110610-0.
2 problems here:
the long scan time. Probably a bug.
avastsvc.exe consuming 100% CPU at normal priority and blocking the whole computer. Downloading is a background task. Run the scan in the background! Why run at normal priority? Why inhibit a manual priority level change (taskmgr)? The priority problem is also noticeable when the virus definitions are updated: another background task that interferes with foreground programs. That is poor design.
It’s not really “back” - your files are rather special (regarding their internal content / compression), so this is actually a different issue that has always been there.
The PDF parser will be significantly updated, hopefully during the next week - which should make even those files scan very fast.
Running AvastSvc at background priority would certainly be a bad idea. The shields work synchronously - they block the application making the request (e.g. the file manager you use to copy the files) - and release it after the scanning is done. So, the request has to be processed as soon as possible - you probably wouldn’t like to be waiting for an hour for the copy operation to finish, because the scanner (which blocks the copy operation from finishing) is running on background, and something else (a flash animation in a browser window) uses the CPU and has a higher priority than the scanner.
For the downloads, it’s very similar - it’s not avast! who’s making the downloads, but rather your browser that is requesting the data. avast! only makes a scanning proxy.
So, the request has to be processed as soon as possible - you probably wouldn't like to be waiting for an hour for the copy operation to finish, because the scanner (which blocks the copy operation from finishing) is running on background, and something else (a flash animation in a browser window) uses the CPU and has a higher priority than the scanner.
I agree. Although lower priority doesn't mean no OS time slices. You just get the remaining CPU left by higher priority processes, which can be still close to 100%.
The scanning proxy however is clearly not behaving correctly since it won't release to the OS for seconds. Asap can't mean "lock the computer until done".
Well, we’re not in the Win16 world of cooperative multitasking anymore - it’s not up to the application to “release the CPU”, but rather up to the OS to take it.
You surely manage to keep it (the CPU). We’ll blame windows, won’t we?
I checked with process explorer the thread priority for the avast thread that is locking windows: it runs at priority 10. This is THREAD_PRIORITY_HIGHEST for a process with NORMAL_PRIORITY_CLASS priority. A “normal” process runs at 8. A Flash animation thread (in firefox plugin-container.exe) runs at 8. VLC worker (streaming) threads are at 8,9 and 10 ,15 for directsound thread = THREAD_PRIORITY_TIME_CRITICAL for a normal process. Etc… No wonder avast blocks everything around, including radio over VLC, except for the mouse. Telling a preemptive OS that your thread is more important than the others is effectively not releasing the CPU. The OS takes it to give it back right away.
I understand your argument users wanting a good response time. But users don’t want to be in a situation that their computer is completely locked and can’t even cancel the operation (download, …) that is causing the problem.