[SCM] calf/master: + Framework: do not use inline assembler on non-x86 archs
js at users.alioth.debian.org
js at users.alioth.debian.org
Tue May 7 15:39:17 UTC 2013
The following commit has been merged in the master branch:
commit 86d9ece13c74e8a4e519616659babada74109e0f
Author: Krzysztof Foltman <wdev at foltman.com>
Date: Wed Feb 4 00:19:12 2009 +0000
+ Framework: do not use inline assembler on non-x86 archs
diff --git a/src/calf/primitives.h b/src/calf/primitives.h
index 0102b3f..7d665b7 100644
--- a/src/calf/primitives.h
+++ b/src/calf/primitives.h
@@ -457,9 +457,13 @@ T sine_table<T,N,Multiplier>::data[N+1];
/// fast float to int conversion using default rounding mode
inline int fastf2i_drm(float f)
{
- volatile int v;
- __asm ( "flds %1; fistpl %0" : "=m"(v) : "m"(f));
- return v;
+#ifdef __X86__
+ volatile int v;
+ __asm ( "flds %1; fistpl %0" : "=m"(v) : "m"(f));
+ return v;
+#else
+ return (int)nearbyintf(f);
+#endif
}
/// Convert MIDI note to frequency in Hz.
--
calf audio plugins packaging
More information about the pkg-multimedia-commits
mailing list