Discussion:
App Verifier crawls
(too old to reply)
Stan
2008-02-27 01:26:01 UTC
Permalink
Hi All,

App verifier makes our program crawl.

The process that takes about 3 seconds at 100% cpu utilization without
App verifier, is not finishing after an hour with App Verifier.

The process does a bunch of xml parsing and dynamic memory allocations.

When App Verifier is enabled, our process eats up all the ram, and just
sits there with 100% cpu usage.

Is this expected?

Is multi threading the cause? Out process has a couple of background threads,
one of which does the heavy lifting, while the others are doing pretty light
operations. There are 4 threads total.

thanks,

stan
Prasad Kakulamarri [MSFT]
2008-03-06 17:46:02 UTC
Permalink
Hi Stan,
AppVerifier does cause some overhead. The overhead in terms of memory usage
(when Heaps check enabled) is more than the perf overhead. But, it should not
cause the behavior you are seeing. Please attach a debugger to your app and
see what the threads are doing. Please let us know if you need further help.

Thanks,
Prasad
Post by Stan
Hi All,
App verifier makes our program crawl.
The process that takes about 3 seconds at 100% cpu utilization without
App verifier, is not finishing after an hour with App Verifier.
The process does a bunch of xml parsing and dynamic memory allocations.
When App Verifier is enabled, our process eats up all the ram, and just
sits there with 100% cpu usage.
Is this expected?
Is multi threading the cause? Out process has a couple of background threads,
one of which does the heavy lifting, while the others are doing pretty light
operations. There are 4 threads total.
thanks,
stan
Stan
2008-03-07 01:21:02 UTC
Permalink
Hi Prasad,

the threads are doing what they are supposed to be doing, just much much
slower than normal. There are about 10 threads each of them
doing some processing that involves heap memory allocation and deallocation.

Normally this process takes a few seconds, but with App Verifier, it just
keeps chugging. Nothing is "stuck", the processing keeps going, just
very very slowly.

here is a stack from one of the threads, the others are very similar:

ntkrnlpa.exe!ExAllocatePoolWithTag+0x96b
ntkrnlpa.exe!PoShutdownBugCheck+0x34a8
ntkrnlpa.exe!KeSynchronizeExecution+0x16c
ntdll.dll!KiFastSystemCallRet
vfbasics.dll+0x658a
vfbasics.dll+0x7449
MSVCR71D.dll!lock+0x3b
MSVCR71D.dll!malloc_dbg+0x7a
MSVCR71D.dll!malloc+0x19
Common.dll!operator new+0xd
Common.dll!pcd::XmlElement::Parse+0x353
Common.dll!pcd::XmlElement::ReadValue+0x1e5
Common.dll!pcd::XmlElement::Parse+0x294
Common.dll!pcd::XmlElement::ReadValue+0x1e5
Common.dll!pcd::XmlElement::Parse+0x294
Common.dll!pcd::XmlElement::ReadValue+0x1e5
Common.dll!pcd::XmlElement::Parse+0x294
Common.dll!pcd::XmlElement::ReadValue+0x1e5
Common.dll!pcd::XmlElement::Parse+0x294
Common.dll!pcd::XmlElement::ReadValue+0x1e5
Common.dll!pcd::XmlElement::Parse+0x294
Common.dll!pcd::XmlElement::ReadValue+0x1e5
Common.dll!pcd::XmlElement::Parse+0x294
Common.dll!pcd::XmlDocument::Parse+0x194
Common.dll!pcd::XmlDocument::Parse+0xc6
Common.dll!pcd::Serializable::getXmlDoc+0x3c
Common.dll!pcd::Serializable::deserialize+0xaf
Enumerator.dll!pcd::Enumerator::enumerateModule+0x405
Common.dll!pcd::threadFunctionWrapper+0x5c
MSVCR71D.dll!beginthreadex+0x196
vfbasics.dll+0x544f
KERNEL32.dll!GetModuleFileNameA+0x1b4

Common.dll and Enumerator.dll are our libraries. everything else
is either windows or App Verifier code. This thread is parsing
an xml document and creating objects on the heap for an in-memory
database.

It seems like a "contention" issue for the malloc()/free() methods.

thanks,

stan
Post by Prasad Kakulamarri [MSFT]
Hi Stan,
AppVerifier does cause some overhead. The overhead in terms of memory usage
(when Heaps check enabled) is more than the perf overhead. But, it should not
cause the behavior you are seeing. Please attach a debugger to your app and
see what the threads are doing. Please let us know if you need further help.
Thanks,
Prasad
Post by Stan
Hi All,
App verifier makes our program crawl.
The process that takes about 3 seconds at 100% cpu utilization without
App verifier, is not finishing after an hour with App Verifier.
The process does a bunch of xml parsing and dynamic memory allocations.
When App Verifier is enabled, our process eats up all the ram, and just
sits there with 100% cpu usage.
Is this expected?
Is multi threading the cause? Out process has a couple of background threads,
one of which does the heavy lifting, while the others are doing pretty light
operations. There are 4 threads total.
thanks,
stan
Loading...