Differed Procedure Calls?

M

Muddle

Have a laptop that I never used to have a problem viewing DVD's on. If
the external power supply is plugged in DPC's spike their CPU usage
every couple of minutes and the video hesitates till DPC's returns to
normal. If the power supply is unplugged and the laptop is running off
the battery DPC's behaves, but the battery never lasts long enough to
watch an entire DVD. What do you'all think could be the problem, power
supply or motherboard.
 
A

Andrew McLaren

Muddle said:
Have a laptop that I never used to have a problem viewing DVD's on. If
the external power supply is plugged in DPC's spike their CPU usage

Hi Bernie

I think that's actually "Deferred Procedure Calls" :)

There's no simple answer to your question. DPC behaviour will be
determined by a combination of many factors: motherboard, chipset,
graphics card, whether you have a multiproc system or not, what version
of video driver is installed, and what devices are generating ISRs and DPCs.

But, in general terms ... if the laptop used to be able to show DVDs
okay, and now you have this problem with DVDs, then we'd have to ask:
"What changed"? Did you install an updated driver? New firmware? new
codec? etc, etc.

There aren't many things you can tweak to change the DPC rate, as such.
More likely, it's a by-product of behaviour in a kernel-mode driver,
probably the video driver. So, make sure you have the latest and
greatest driver for your laptop's graphics card. Plus all the usual
"health and efficiency" steps for maintaining a machine.

How are you determining that DPCs are spiking? 3rd party tools aren't
always very reliable; Perfmon is the best tool for accurate tracking of
DPCs. It would also help to know exactly what model of laptop you are
using, what its specs are and what version of video driver is installed.
Even with that info, there might not be a clear answer; but there's more
chance than with the pretty vague problem description we have so far.

Cheers,

Andrew
 
M

Muddle

Andrew said:
Hi Bernie

I think that's actually "Deferred Procedure Calls" :)

There's no simple answer to your question. DPC behaviour will be
determined by a combination of many factors: motherboard, chipset,
graphics card, whether you have a multiproc system or not, what version
of video driver is installed, and what devices are generating ISRs and
DPCs.

But, in general terms ... if the laptop used to be able to show DVDs
okay, and now you have this problem with DVDs, then we'd have to ask:
"What changed"? Did you install an updated driver? New firmware? new
codec? etc, etc.

There aren't many things you can tweak to change the DPC rate, as such.
More likely, it's a by-product of behaviour in a kernel-mode driver,
probably the video driver. So, make sure you have the latest and
greatest driver for your laptop's graphics card. Plus all the usual
"health and efficiency" steps for maintaining a machine.

How are you determining that DPCs are spiking? 3rd party tools aren't
always very reliable; Perfmon is the best tool for accurate tracking of
DPCs. It would also help to know exactly what model of laptop you are
using, what its specs are and what version of video driver is installed.
Even with that info, there might not be a clear answer; but there's more
chance than with the pretty vague problem description we have so far.

Cheers,

Andrew

Perfmon is what I'm using. It's a Sony PCG-GRZ660 with an ATI Mobility
Radeon 7500, Pentium 4 2.40GHz 2.39GHz, 1.00 GB RAM. Service Pack 3 and
all updates installed. It has the only updated video driver ever
offered by Sony and ATI for the graphics card installed and all other
applicable Sony drivers are updated. All unused hardware has been
disabled, it has Soundblaster USB audio, Logitech USB mouse, Sony USB
external DVD +- RW drive, USB HP scanner and printers. I've installed
and rolled back drivers for everything possible. As I've said the only
thing that appears to change the behavior of DPC's is to unplug the
external pwer supply. If I do that DPC's behaves and the system works
fine until the battery runs down. My next step would probably be to
reinstall the Operating system, which I haven't done since I purchased
it about seven or eight years ago.
 
A

Andrew McLaren

Muddle said:
Perfmon is what I'm using. It's a Sony PCG-GRZ660 with an ATI Mobility
Radeon 7500, Pentium 4 2.40GHz 2.39GHz, 1.00 GB RAM. Service Pack 3 and
all updates installed. It has the only updated video driver ever

Ah-ha. Okay, thanks, that's useful info ...

The ATI Mobility Radeon has a power-management capability, which ATI
call "PowerPlay" (see http://ati.amd.com/products/pdf/powerplaywp2.pdf
for details). When a laptop is running on battery, the Mobility Radeon
GPU and driver can adjust for low power. You probably won't see any
discernible difference in the quality of the video output, but the video
subsystem won't be hammering as hard as when the machine is running on
mains power. My guess is that in the low power battery state, the video
driver generates fewer interrupts, and hence fewer DPCs are being queued
for the system.

(Each hardware interrupt triggers an Interrupt Service Routine, or ISR.
To make sure the system doesn't get bogged down in interrupts, a device
driver puts most of the required processing logic into a deferred
procedure call, or DPC, to be handled later - hence "deferred". ISRs
return quickly, and the DPC is placed in a queue for the kernel to
process as resources become available. Of course nothing is free, so
it's still possible for the DPC processing to be overwhelmed - but
that's less destabilising for overall performance, than blocking during
the actual interrupt).

The PowerPlay stuff is a combination of the ATI hardware and driver;
there's probably an option somewhere in the display driver settings to
enable or disable, or possibly tweak it. I'm not sure why this problem
has started appearing on your laptop only recently; but one possibility
is that something (or someone) has modified the PowerPlay settings and
changed the configuration. So if you can dig into those settings, you
might find the answer (some experimenting probably required).

There was an arrangement between ATI and the various laptop OEMs - Sony,
Dell, etc - that all Mobility Radeon drivers would be distributed via
the OEM, not from ATI themselves. This is in contrast to desktop Radeon
cards, which can all use the Catalyst drivers from the ATI/AMD website.
This arrangement is purely a business decision; the actual drivers
distributed by ATI work fine with Mobility Radeon chips; but the
installation program is won't install the drivers onto a laptop with a
Mobility Radeon card. The downside of this arrangement is that the
OEM-supplied drivers may be several revisions behind the current version
level - as with your Sony driver. The OEMs aren't likely to bother with
shipping an updated video driver for a laptop they sold 5 or 7 years
ago, it just isn't worth it; but the Sony-supplied driver thus misses
out on 6 years of bug fixes, optimisations etc.

I can't really tell if an updated driver will do anything to help the
problem. But if you want to experiment with an updated driver, you can
use the free "Mobility Modder" tool, to tweak the current version ATI
Catalyst drivers to install onto a Mobile Radeon laptop. Get the tool
and instructions, here:

http://www.driverheaven.net/modtool.php

To be clear: if you're sure that everything worked okay in the past,
then there may be no benefit in updated drivers; rather you need to
return the system back to the state it was in when performance was okay.
I suspect the problem is is related to power management (because of the
battery effect) so Windows power management and the ATI PowerPlay power
management would be the things to look at. But updated ATI drivers, are
also an option (unsupported by Sony or ATI, of course).

Best I can do, I'm afraid ... hope it helps!

Goo, I've never wanted to watch a DVD so badly that I'd re-install my
whole operating system :)

Andrew
 
P

Paul

Muddle said:
Perfmon is what I'm using. It's a Sony PCG-GRZ660 with an ATI Mobility
Radeon 7500, Pentium 4 2.40GHz 2.39GHz, 1.00 GB RAM. Service Pack 3 and
all updates installed. It has the only updated video driver ever
offered by Sony and ATI for the graphics card installed and all other
applicable Sony drivers are updated. All unused hardware has been
disabled, it has Soundblaster USB audio, Logitech USB mouse, Sony USB
external DVD +- RW drive, USB HP scanner and printers. I've installed
and rolled back drivers for everything possible. As I've said the only
thing that appears to change the behavior of DPC's is to unplug the
external pwer supply. If I do that DPC's behaves and the system works
fine until the battery runs down. My next step would probably be to
reinstall the Operating system, which I haven't done since I purchased
it about seven or eight years ago.

I went looking for something, to give more info about DPCs. I tried
Process Explorer at first, just to be able to set up a test case with
some DPC activity (leave a 3D game running in the background). I started
reading about "tracelog" and "tracerpt", but the problem was, I couldn't
get my hands on a version of tracelog which supported the -dpcisr option.
(Based on info on the Microsoft site, I downloaded a 1.3GB DVD iso file
for nothing, only to find in the release notes that tracelog was not
present.) There is supposed to be one for Vista that might work, but I
cannot find it.

This program appears to give much the same information. It is a little
tricky to use, until you start looking in C:\WINDOWS\system32\LogFiles\RATTV3.
The trace data collected is stored in that folder, as is the final text
output. There is an icon in the tray to control it, and you can uninstall
it when you're finished.

http://www.microsoft.com/whdc/DevTools/tools/RATT.mspx

You would start that running, before playing the DVD. It will collect
data in 3 minute chunks, and then include the information into the report.

Maybe you could collect some data before playing the DVD first, to get
a trace with some "good" data in it, to contrast to what happens
when the DVD plays. Let it run for six minutes, so the output report
has a couple chunks of data included in the trace.

Then you can play the DVD, and leave RATT running, and again look
at the log file.

But when you look at the report, it shows a "time bucket" distribution,
of response times for various pieces of software. Whether any of those
actually indicates a problem, is what I couldn't figure out. I looked
at my output, and couldn't really make any sense out of it. Maybe
you'll get a hint by using it.

Since your processor is a Pentium 4, that eliminates something like a
missing AMD dual core CPU driver or whatever, as a root cause.

*******
Another theory you could work on, is overheating. It is possible
your processor is modern enough to support "throttling", which
is an internal response to overheating. This article demonstrates
the use of RMClock to detect throttling. Throttling might start,
if the CPU gets over 70C.

http://www.xbitlabs.com/articles/cpu/display/oc-guide_7.html

RMClock Utility 2.35
http://cpu.rightmark.org/download.shtml

If you just want to watch the CPU temperature itself, without
monitoring the throttle bit, you can use Speedfan, which
interfaces to the hardware monitor interface on the motherboard.
It probes the low speed buses on the computer, looking for
a hardware monitor (which is why the program is a little
slow to start up). Many computers have the CPU diode,
tied into the hardware monitor.

http://www.almico.com/speedfan437.exe

To verify the processor speed (which can vary due to the
use of EIST, the Enhanced Intel Speed Step), you can use
a program like CPUZ. It will update the CPU frequency at
regular intervals. When running on battery, you might
see a "low" and "high" frequency displayed in CPUZ.
The Power scheme used on battery, and on line power, is
different. When on line power, the CPU frequency can run
at full speed, depending on how the power scheme sets
things up.

http://www.cpuid.com/cpuz.php

HTH,
Paul
 
M

Muddle

Andrew said:
Ah-ha. Okay, thanks, that's useful info ...

The ATI Mobility Radeon has a power-management capability, which ATI
call "PowerPlay" (see http://ati.amd.com/products/pdf/powerplaywp2.pdf
for details). When a laptop is running on battery, the Mobility Radeon
GPU and driver can adjust for low power. You probably won't see any
discernible difference in the quality of the video output, but the video
subsystem won't be hammering as hard as when the machine is running on
mains power. My guess is that in the low power battery state, the video
driver generates fewer interrupts, and hence fewer DPCs are being queued
for the system.

(Each hardware interrupt triggers an Interrupt Service Routine, or ISR.
To make sure the system doesn't get bogged down in interrupts, a device
driver puts most of the required processing logic into a deferred
procedure call, or DPC, to be handled later - hence "deferred". ISRs
return quickly, and the DPC is placed in a queue for the kernel to
process as resources become available. Of course nothing is free, so
it's still possible for the DPC processing to be overwhelmed - but
that's less destabilising for overall performance, than blocking during
the actual interrupt).

The PowerPlay stuff is a combination of the ATI hardware and driver;
there's probably an option somewhere in the display driver settings to
enable or disable, or possibly tweak it. I'm not sure why this problem
has started appearing on your laptop only recently; but one possibility
is that something (or someone) has modified the PowerPlay settings and
changed the configuration. So if you can dig into those settings, you
might find the answer (some experimenting probably required).

There was an arrangement between ATI and the various laptop OEMs - Sony,
Dell, etc - that all Mobility Radeon drivers would be distributed via
the OEM, not from ATI themselves. This is in contrast to desktop Radeon
cards, which can all use the Catalyst drivers from the ATI/AMD website.
This arrangement is purely a business decision; the actual drivers
distributed by ATI work fine with Mobility Radeon chips; but the
installation program is won't install the drivers onto a laptop with a
Mobility Radeon card. The downside of this arrangement is that the
OEM-supplied drivers may be several revisions behind the current version
level - as with your Sony driver. The OEMs aren't likely to bother with
shipping an updated video driver for a laptop they sold 5 or 7 years
ago, it just isn't worth it; but the Sony-supplied driver thus misses
out on 6 years of bug fixes, optimisations etc.

I can't really tell if an updated driver will do anything to help the
problem. But if you want to experiment with an updated driver, you can
use the free "Mobility Modder" tool, to tweak the current version ATI
Catalyst drivers to install onto a Mobile Radeon laptop. Get the tool
and instructions, here:

http://www.driverheaven.net/modtool.php

To be clear: if you're sure that everything worked okay in the past,
then there may be no benefit in updated drivers; rather you need to
return the system back to the state it was in when performance was okay.
I suspect the problem is is related to power management (because of the
battery effect) so Windows power management and the ATI PowerPlay power
management would be the things to look at. But updated ATI drivers, are
also an option (unsupported by Sony or ATI, of course).

Best I can do, I'm afraid ... hope it helps!

Goo, I've never wanted to watch a DVD so badly that I'd re-install my
whole operating system :)

Andrew

I've often suspected the ATI drivers. I tried your suggestion with the
newest catalyst drivers to no avail. Since AMD took over ATI they've
sure made some changes. Those drivers were pesky things to rip out of
my system. Afterwards I once again reverted back to the original
drivers that came with the system. In the process of ripping out the
new catalyst drivers I've obviously done something that fixed the
problem although I can't figure out what that might be. DVD's seems to
play fine now. This is my media machine, graphics, movies, music since
a divorce. She got the Sony big screen TV and everything hooked up to it.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top