Bug 1480499 - Add profiler label frame to gfxUserFontEntry::LoadPlatformFont with the OTHER category r?mstange draft
authorNazım Can Altınova <canaltinova@gmail.com>
Fri, 03 Aug 2018 15:15:24 +0200
changeset 826302 de5b3aca9543b8648c98360cadf4b9d0a11eb048
parent 826273 484dc9b59dcaaedc039e5a851cdd6a997f713429
push id118281
push userbmo:canaltinova@gmail.com
push dateFri, 03 Aug 2018 13:16:03 +0000
reviewersmstange
bugs1480499
milestone63.0a1
Bug 1480499 - Add profiler label frame to gfxUserFontEntry::LoadPlatformFont with the OTHER category r?mstange MozReview-Commit-ID: 49eCKAMxy3I
gfx/thebes/gfxUserFontSet.cpp
--- a/gfx/thebes/gfxUserFontSet.cpp
+++ b/gfx/thebes/gfxUserFontSet.cpp
@@ -699,16 +699,17 @@ gfxUserFontEntry::SetLoadState(UserFontL
     mUserFontLoadState = aLoadState;
 }
 
 MOZ_DEFINE_MALLOC_SIZE_OF_ON_ALLOC(UserFontMallocSizeOfOnAlloc)
 
 bool
 gfxUserFontEntry::LoadPlatformFont(const uint8_t* aFontData, uint32_t& aLength)
 {
+    AUTO_PROFILER_LABEL("gfxUserFontEntry::LoadPlatformFont", OTHER);
     NS_ASSERTION((mUserFontLoadState == STATUS_NOT_LOADED ||
                   mUserFontLoadState == STATUS_LOAD_PENDING ||
                   mUserFontLoadState == STATUS_LOADING) &&
                  mFontDataLoadingState < LOADING_FAILED,
                  "attempting to load a font that has either completed or failed");
 
     gfxFontEntry* fe = nullptr;