1
0
mirror of https://sourceware.org/git/glibc.git synced 2025-07-30 22:43:12 +03:00

Avoid performance penalty in sparc optimized memcpy/memset.

fmovd clears the current exception field in the %fsr, fsrc2
does not and therefore runs more efficiently on some cpus.

	* sysdeps/sparc/sparc64/memcpy.S: Use fsrc2 to move 64-bit
	values between float registers.
	* sysdeps/sparc/sparc64/memset.S: Likewise.
	* sysdeps/sparc/sparc64/multiarch/memcpy-niagara2.S: Likewise.
This commit is contained in:
David S. Miller
2012-05-31 14:19:30 -07:00
parent fed806c3af
commit f230c29b40
4 changed files with 54 additions and 47 deletions

View File

@ -109,16 +109,16 @@ ENTRY(memset)
membar #StoreStore | #LoadStore
andcc %o3, 0xc0, %g5
and %o2, 0x3f, %o2
fmovd %f0, %f2
fmovd %f0, %f4
fsrc2 %f0, %f2
fsrc2 %f0, %f4
andn %o3, 0xff, %o3
fmovd %f0, %f6
fsrc2 %f0, %f6
cmp %g5, 64
fmovd %f0, %f8
fmovd %f0, %f10
fmovd %f0, %f12
fsrc2 %f0, %f8
fsrc2 %f0, %f10
fsrc2 %f0, %f12
brz,pn %g5, 10f
fmovd %f0, %f14
fsrc2 %f0, %f14
be,pn %icc, 2f
stda %f0, [%o0 + 0x00] %asi
cmp %g5, 128