>> is hooked at vector 0x30
this holds true only for single CPU systems. IRQ handling in SMP on IA32 is
managed by the local apic, and it uses a completly different scheme. Refere
to Intel manuals, programing the local apic topic, to understand the issue.
> IoConnectInterrupt()
IoConntectInterrupt wont let you connect to timer interrupt.
> be portable for Win2K, XP, and future versions without using inline
assembly.
safe IDT hooking , especially in SMP is hard to accomplish. Almost all safe
schemes I know can break compatibility in future Nt versions, except one,
but which I profoundly dislike.
> KeSetTimerEx()
Unfortunatley , you wont gain much using this API. the timer DPC routine is
fired into an arbitrary thread context , leaving you very few chanches to
access the thread’s registers, as they where at interrupt time.
Kernel mode profiling is almost imposible to write whithout intrusive
routines. Your safest bet is still interrupt hooking, or using advanced
profiling techniques with the help of the local apic. As for how to collect
the data, I would suggest a circular buffer.
----- Original Message -----
From: “David 'T”
To: “NT Developers Interest List”
Sent: Thursday, July 18, 2002 11:48 PM
Subject: [ntdev] Re: How to retrieve EIP/PC from DPC routine?
> Mark and Dan,
>
> Both of you are correct in what I’m trying to do. For Win2k, the timer
> is hooked at vector 0x30 (I’ll need to verify later what it is for WinXP
> but I’ll assume at the moment it’s the same - please correct me if I’m
> wrong).
> How then would you suggest collecting that data? I would like to get
> away from touching the IDT and would like this to be portable for Win2K,
> XP, and future versions without using inline assembly.
> I thought it would be a cleaner implementation using the KeSetTimerEx()
> API and access the EIP from my registered DPC routine.
> Or is there a way for me to connect directly to that vector using
> IoConnectInterrupt(). This is an application driver, and from looking at
> the DDK, this API seems to be geared more towards real hardware.
> Thank you for your help.
>
> David “T”
>
>
> —
> You are currently subscribed to ntdev as: xxxxx@rdsor.ro
> To unsubscribe send a blank email to %%email.unsub%%
>