Messages in this thread | | | Date | Fri, 14 Nov 2008 17:02:57 +0100 | From | Eric Dumazet <> | Subject | Re: Oprofile : need to adjust PC by 16 bytes |
| |
Andi Kleen a écrit : > On Fri, Nov 14, 2008 at 04:25:51PM +0100, Eric Dumazet wrote: >> Very strange results on my Intel E5450 CPU >> >> I found that I have to bias regs->ip by 16 bytes in order to have >> correct profiling. > > Can you expand a bit how you determined if the profile is right or wrong? > > -Andi > >
opannotate -a vmlinux > FILE
And check results.
With the patch I get :
c041d270 <dst_release>: /* dst_release total: 16523 1.2978 */ 252 0.0198 :c041d270: push %ebp 654 0.0514 :c041d271: test %eax,%eax :c041d273: mov %esp,%ebp 47 0.0037 :c041d275: mov %eax,%edx 42 0.0033 :c041d277: je c041d289 <dst_release+0x19> :c041d279: mov $0xffffffff,%eax 3 2.4e-04 :c041d27e: lock xadd %eax,0x80(%edx) 14766 1.1598 :c041d286: dec %eax 1 7.9e-05 :c041d287: js c041d28b <dst_release+0x1b> 53 0.0042 :c041d289: pop %ebp 705 0.0554 :c041d28a: ret :c041d28b: mov $0x10e,%edx :c041d290: mov $0xc0561ed5,%eax :c041d295: call c022d1a0 <warn_on_slowpath> :c041d29a: pop %ebp :c041d29b: ret :c041d29c: lea 0x0(%esi),%esi
This results please me : The cost is right after the "lock xadd" as expected.
Without patch, all addresses were off by 16 bytes.
On dst_release() it was on the call on warn_on_slowpath(), and I am pretty sure it is not possible at all this WARN_ON is hit
-- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
| |