summaryrefslogtreecommitdiffstats
path: root/sys/i386
diff options
context:
space:
mode:
authorbde <bde@FreeBSD.org>1999-01-09 13:43:09 +0000
committerbde <bde@FreeBSD.org>1999-01-09 13:43:09 +0000
commit2616cfa856e38baf5cd8a677da514b87e17304d6 (patch)
treeadfda5597222a9a77d433f003ca6c1283b76e9e2 /sys/i386
parent4c2d702e3a374bf88400dcc51a081cb840be21ea (diff)
downloadFreeBSD-src-2616cfa856e38baf5cd8a677da514b87e17304d6.zip
FreeBSD-src-2616cfa856e38baf5cd8a677da514b87e17304d6.tar.gz
Removed buggy, `#if 0'ed asm version of translate_bytes() instead of
fixing it. See rev.1.22 of ../sound/audio.c for fixes. When both the C version and the asm version are inlined, and everything is cached, the asm version is 1.75 times slower than the C version on P5's. On K6's, it is only 1.25 times slower.
Diffstat (limited to 'sys/i386')
-rw-r--r--sys/i386/isa/snd/sound.c18
1 files changed, 0 insertions, 18 deletions
diff --git a/sys/i386/isa/snd/sound.c b/sys/i386/isa/snd/sound.c
index f8b5cfb..6a5a92d 100644
--- a/sys/i386/isa/snd/sound.c
+++ b/sys/i386/isa/snd/sound.c
@@ -1505,7 +1505,6 @@ change_bits(mixer_tab *t, u_char *regval, int dev, int chn, int newval)
* full-duplex)
*/
-#if 1
void
translate_bytes (u_char *table, u_char *buff, int n)
{
@@ -1517,22 +1516,5 @@ translate_bytes (u_char *table, u_char *buff, int n)
for (i = 0; i < n; ++i)
buff[i] = table[buff[i]];
}
-#else
-/* inline */
-void
-translate_bytes (const void *table, void *buff, int n)
-{
- if (n > 0) {
- __asm__ ( " cld\n"
- "1: lodsb\n"
- " xlatb\n"
- " stosb\n"
- " loop 1b\n":
- : "b" (table), "c" (n), "D" (buff), "S" (buff)
- : "bx", "cx", "di", "si", "ax");
- }
-}
-
-#endif
#endif /* NPCM > 0 */
OpenPOWER on IntegriCloud