On 03/31/2010 03:13 PM, Мартин Бохниг wrote:
To avoid ambiguity: The problem is, that as far as I know the
platform-specific versions of libc are still closed src binary-only
releases. Otherwise we could of course just look at ON how they
implemented the platform-specific libc-versions.
I guess you don't exactly need source code to find out which function uses which instruction - it's right there in the library; after all, processor-specific functions are written in assembler anyway (http://cvs.opensolaris.org/source/xref/onnv/onnv-gate/usr/src/lib/libc_psr/sun4u-opl/common/memcpy.s is an example)

$ nm /platform/SUNW,Sun-Fire-T200/lib/libc_psr.so.1  | grep memcpy
[27]    |      1032|    1596|FUNC |GLOB |0    |8      |_memcpy
...
$ dis -F memcpy /platform/SUNW,Sun-Fire-T200/lib/libc_psr.so.1
disassembly for /platform/SUNW,Sun-Fire-T200/lib/libc_psr.so.1

memcpy()
    memcpy:                 8a 10 00 08  mov       %o0, %g5
    memcpy+0x4:             80 a2 a0 11  cmp       %o2, 0x11
memcpy+0x8: 08 48 00 68 bleu,pt %icc, +0x1a0 <memcpy+0x1a8>
...

$ nm /platform/SUNW,Sun-Fire-T200/lib/libc_psr.so.1  | grep str
<nothing>
(so no string functions are T200-specific, I'm guessing)
_______________________________________________
opensolaris-code mailing list
opensolaris-code@opensolaris.org
http://mail.opensolaris.org/mailman/listinfo/opensolaris-code

Reply via email to