Re: shark and kernel/driver profiling
Re: shark and kernel/driver profiling
- Subject: Re: shark and kernel/driver profiling
- From: Andrew Gallatin <email@hidden>
- Date: Tue, 27 Feb 2007 15:27:36 -0500 (EST)
Rick Altherr writes:
>
> Shark doesn't use the .sym file. It uses the actual kext on disk
> along with information about where it was loaded that we retrieve
> from the running kernel. However, I have noticed sometimes that
Cool!
> using the kext search path doesn't work. The guaranteed way to get
> kext symbols is to make sure the kext is build with -g and is _not_
> stripped later. Then, put it in /System/Library/Extensions and load
> it using kextload with either the bundle id or the full path in /
> System/Library/Extensions. If that doesn't work, then I'd need to
> see the driver. Thankfully, I've already seen it once, since I was
> sent 2 of those cards to run some throughput testing a while back.
I tried and I was not able to make it work, even using -g -O0 built
driver, running from /S/L/E. According to ktrace, I see it open and
mmap my driver's binary:
<...>
313 Shark CALL lstat(0xb05deaee,0xb05df750)
313 Shark NAMI "/System/Library/Extensions/myri10ge.kext/Contents/MacOS/myri10ge"
313 Shark RET lstat 0
313 Shark CALL access(0xb05df3be,0x4)
313 Shark NAMI "/System/Library/Extensions/myri10ge.kext/Contents/MacOS/myri10ge"
313 Shark RET access 0
313 Shark CALL open(0x5fa8260,0,0)
313 Shark NAMI "/System/Library/Extensions/myri10ge.kext/Contents/MacOS/myri10ge"
313 Shark RET open 9
313 Shark CALL fstat(0x9,0xb05df5f0)
313 Shark RET fstat 0
313 Shark CALL mmap(0,0x144934,0x1,0x1,0x9,0)
313 Shark RET mmap 100683776/0x6005000
313 Shark CALL close(0x9)
313 Shark RET close 0
313 Shark CALL lstat(0xb05deaee,0xb05df750)
313 Shark NAMI "/System/Library/Extensions/IONetworkingFamily.kext/Contents/MacOS/IONetworkingFamily"
<...>
If you're interested in taking this further, I've left the kext at
http://www.myri.com/staff/gallatin/shark/myri10ge.kext.tgz
I ran a "script" of rebuilding the driver, and saved
the logfile here:
http://www.myri.com/staff/gallatin/shark/build.log
> Also, are you a Leopard seed candidate?
When failing to get symbols, I was running 10.4.8 on a MacPro.
But I do have acccess to seeds. In fact, I'm (happily) running a
trivial dtrace script on 9A303 (9.0.0d4) right now which is showing me
the information I want (mainly because it does not truncate unknown
address to page boundaries). I realize this is a bit stale, but I
haven't had time to download the latest for a while...
Thanks,
Drew
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Darwin-kernel mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden