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

Unified Diff: src/opts/SkBitmapProcState_opts_arm.cpp

Issue 719213008: SkColorTable locking serves no purpose anymore. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: oops Created 6 years 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 | « src/images/SkImageEncoder_argb.cpp ('k') | src/opts/SkBitmapProcState_opts_mips_dsp.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/opts/SkBitmapProcState_opts_arm.cpp
diff --git a/src/opts/SkBitmapProcState_opts_arm.cpp b/src/opts/SkBitmapProcState_opts_arm.cpp
index 8f24c39a2e178bfc301457a8e1fcc76e4c7c2c58..4a84aee85f030f286e8ab105f24d89637e7f3a28 100644
--- a/src/opts/SkBitmapProcState_opts_arm.cpp
+++ b/src/opts/SkBitmapProcState_opts_arm.cpp
@@ -30,7 +30,7 @@ void SI8_D16_nofilter_DX_arm(const SkBitmapProcState& s,
SkASSERT(s.fInvType <= (SkMatrix::kTranslate_Mask | SkMatrix::kScale_Mask));
SkASSERT(SkPaint::kNone_FilterLevel == s.fFilterLevel);
- const uint16_t* SK_RESTRICT table = s.fBitmap->getColorTable()->lock16BitCache();
+ const uint16_t* SK_RESTRICT table = s.fBitmap->getColorTable()->read16BitCache();
const uint8_t* SK_RESTRICT srcAddr = (const uint8_t*)s.fBitmap->getPixels();
// buffer is y32, x16, x16, x16, x16, x16
@@ -104,8 +104,6 @@ void SI8_D16_nofilter_DX_arm(const SkBitmapProcState& s,
src = srcAddr[*xx++]; *colors++ = table[src];
}
}
-
- s.fBitmap->getColorTable()->unlock16BitCache();
}
void SI8_opaque_D32_nofilter_DX_arm(
@@ -121,7 +119,7 @@ void SI8_opaque_D32_nofilter_DX_arm(const SkBitmapProcState& s,
SkASSERT(s.fInvType <= (SkMatrix::kTranslate_Mask | SkMatrix::kScale_Mask));
SkASSERT(SkPaint::kNone_FilterLevel == s.fFilterLevel);
- const SkPMColor* SK_RESTRICT table = s.fBitmap->getColorTable()->lockColors();
+ const SkPMColor* SK_RESTRICT table = s.fBitmap->getColorTable()->readColors();
const uint8_t* SK_RESTRICT srcAddr = (const uint8_t*)s.fBitmap->getPixels();
// buffer is y32, x16, x16, x16, x16, x16
@@ -184,8 +182,6 @@ void SI8_opaque_D32_nofilter_DX_arm(const SkBitmapProcState& s,
: "memory", "cc", "r4", "r5", "r6", "r7", "r8", "r9", "r10", "r11"
);
}
-
- s.fBitmap->getColorTable()->unlockColors();
}
#endif // !defined(SK_CPU_ARM64) && SK_ARM_ARCH >= 6 && !defined(SK_CPU_BENDIAN)
« no previous file with comments | « src/images/SkImageEncoder_argb.cpp ('k') | src/opts/SkBitmapProcState_opts_mips_dsp.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698