instrumenting kernel functions by name
William Cohen
wcohen@redhat.com
Tue Mar 15 04:15:00 GMT 2005
One of the things that I found that can be done with this module is find
out which functions are doing interprocessor interrupts. I know that
OProfile uses some interprocessor interrupts to configure the
performance monitoring hardware. The example below demonstrates.
# /sbin/insmod kprobe_where_funct.ko funct_name=smp_call_function
# opcontrol --start
do some stuff then shutdown OProfile
# opcontrol --shutdown
# /sbin/rmmod kprobe_where_funct
Output in /var/log/messages.
Mar 16 09:45:13 slingshot kernel: oprofile: using NMI interrupt.
Mar 16 09:45:47 slingshot kernel: STP: kprobe unregistered
Mar 16 09:45:47 slingshot kernel: STP: smp_call_function() called 59 times.
Mar 16 09:45:47 slingshot kernel: STP: smp_call_function point break down.
Mar 16 09:45:47 slingshot kernel: STP: 0xc016088c, 48
Mar 16 09:45:47 slingshot kernel: STP: invalidate_bh_lrus+0x1b/0x26
Mar 16 09:45:47 slingshot kernel: STP: 0xc0115e9b, 4
Mar 16 09:45:47 slingshot kernel: STP: flush_tlb_all+0x1b/0x26
Mar 16 09:45:47 slingshot kernel: STP: 0xc014768b, 2
Mar 16 09:45:47 slingshot kernel: STP: smp_call_function_all_cpus+0x29/0x3b
Mar 16 09:45:47 slingshot kernel: STP: 0xe0a7dd43, 1
Mar 16 09:45:47 slingshot kernel: STP: nmi_setup+0x2f/0x7a [oprofile]
Mar 16 09:45:47 slingshot kernel: STP: 0xe0a7dd5f, 1
Mar 16 09:45:47 slingshot kernel: STP: nmi_setup+0x4b/0x7a [oprofile]
Mar 16 09:45:47 slingshot kernel: STP: 0xe0a7de9b, 1
Mar 16 09:45:47 slingshot kernel: STP: nmi_start+0x18/0x25 [oprofile]
Mar 16 09:45:47 slingshot kernel: STP: 0xe0a7dedb, 1
Mar 16 09:45:47 slingshot kernel: STP: nmi_stop+0x18/0x23 [oprofile]
Mar 16 09:45:47 slingshot kernel: STP: 0xe0a7de4f, 1
Mar 16 09:45:47 slingshot kernel: STP: nmi_shutdown+0x22/0x3b [oprofile]
-Will
More information about the Systemtap
mailing list