add wacky random shift so I can generate some zeros (without the optimizer knowing)
so I can test passing a 0 to SkCLZ()
git-svn-id: http://skia.googlecode.com/svn/trunk@8904 2bbb7eff-a529-9590-31e7-b0007b416f81
diff --git a/tests/MathTest.cpp b/tests/MathTest.cpp
index ca860e4..4c768d1 100644
--- a/tests/MathTest.cpp
+++ b/tests/MathTest.cpp
@@ -22,6 +22,9 @@
SkRandom rand;
for (int i = 0; i < 1000; ++i) {
uint32_t mask = rand.nextU();
+ // need to get some zeros for testing, but in some obscure way so the
+ // compiler won't "see" that, and work-around calling the functions.
+ mask >>= (mask & 31);
int intri = SkCLZ(mask);
int porta = SkCLZ_portable(mask);
REPORTER_ASSERT(reporter, intri == porta);