Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(9)

Unified Diff: include/core/SkFixed.h

Issue 281143002: Always inline SkFloatToFixed_arm. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 6 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: include/core/SkFixed.h
diff --git a/include/core/SkFixed.h b/include/core/SkFixed.h
index b5987fc208f3ec811fb08d9693670ee90a28eb85..a16adacccf2476a1213052d7602aa161ac663f3e 100644
--- a/include/core/SkFixed.h
+++ b/include/core/SkFixed.h
@@ -107,9 +107,10 @@ static inline SkFixed SkFixedCos(SkFixed radians) {
#if defined(SK_CPU_ARM)
/* This guy does not handle NaN or other obscurities, but is faster than
- than (int)(x*65536)
+ than (int)(x*65536). When built on Android with -Os, needs forcing
+ to inline or we lose the speed benefit.
*/
- inline SkFixed SkFloatToFixed_arm(float x)
+ SK_ALWAYS_INLINE SkFixed SkFloatToFixed_arm(float x)
{
int32_t y, z;
asm("movs %1, %3, lsl #1 \n"
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698