"Rotate left word _immediate_ then AND with Mask" The compiler must actually know the constant value. Declaring it const seems to work.

This commit is contained in:
Steve Checkoway
2005-08-19 18:53:34 +00:00
parent 15d263b379
commit 55b586e0e5
+2 -2
View File
@@ -287,13 +287,13 @@ template<> inline word32 rotrMod<word32>(word32 x, unsigned int y)
# include <ppc_intrinsics.h>
#endif
template<> inline word32 rotlFixed<word32>(word32 x, unsigned int y)
template<> inline word32 rotlFixed<word32>(word32 x, const unsigned int y)
{
assert(y < 32);
return y ? __rlwinm(x,y,0,31) : x;
}
template<> inline word32 rotrFixed<word32>(word32 x, unsigned int y)
template<> inline word32 rotrFixed<word32>(word32 x, const unsigned int y)
{
assert(y < 32);
return y ? __rlwinm(x,32-y,0,31) : x;