[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
CVS commit: src/sys/lib/libkern/arch/sh3
Module Name: src
Committed By: uwe
Date: Thu Aug 4 03:20:10 UTC 2011
src/sys/lib/libkern/arch/sh3: sdivsi3_i4i.S udivsi3_i4i.S
For unsignad integer division gcc used to emit a call to __udivsi3
"millicode" function that uses compiler-private ABI. Newer gcc uses
heavily tuned __udivsi3_i4i that is NOT compatible with __udivsi3
because it's expected to clobber different registers. We don't want
to link the kernel against libgcc and we don't have resources to write
heavily tuned version ourselves, so clone __udivsi3 but adjust it to
conform to the __udivsi3_i4i clobber spec.
Ditto for signed division.
You can make gcc use old routines with -mdiv=call-div1 to avoid few
extra instructions to save/restore the right registers in the signed
To generate a diff of this commit:
cvs rdiff -u -r1.18 -r1.19 src/sys/lib/libkern/arch/sh3/Makefile.inc
cvs rdiff -u -r0 -r1.1 src/sys/lib/libkern/arch/sh3/sdivsi3_i4i.S \
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Main Index |
Thread Index |