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

Unified Diff: Source/core/layout/LayoutAnalyzer.h

Issue 1318713003: Make classes and structures in core/layout fast-allocated. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 years, 4 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 | « Source/core/layout/HitTestRequest.h ('k') | Source/core/layout/LayoutBlockFlow.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/layout/LayoutAnalyzer.h
diff --git a/Source/core/layout/LayoutAnalyzer.h b/Source/core/layout/LayoutAnalyzer.h
index 944bbd7e9ff73d5efadb06058cdd47cce067d0cc..f70cd441980902d39232748a05db9d39fa0590c9 100644
--- a/Source/core/layout/LayoutAnalyzer.h
+++ b/Source/core/layout/LayoutAnalyzer.h
@@ -6,6 +6,9 @@
#define LayoutAnalyzer_h
#include "platform/LayoutUnit.h"
+#include "wtf/Allocator.h"
+#include "wtf/FastAllocBase.h"
+#include "wtf/Noncopyable.h"
#include "wtf/PassRefPtr.h"
namespace blink {
@@ -18,6 +21,8 @@ class TracedValue;
// Usage:
// LayoutAnalyzer::Scope analyzer(*this);
class LayoutAnalyzer {
+ WTF_MAKE_FAST_ALLOCATED(LayoutAnalyzer);
+ WTF_MAKE_NONCOPYABLE(LayoutAnalyzer);
public:
enum Counter {
LayoutBlockWidthChanged,
@@ -45,6 +50,7 @@ public:
static const size_t NumCounters = 21;
class Scope {
+ STACK_ALLOCATED();
public:
explicit Scope(const LayoutObject&);
~Scope();
@@ -55,6 +61,7 @@ public:
};
class BlockScope {
+ STACK_ALLOCATED();
public:
explicit BlockScope(const LayoutBlock&);
~BlockScope();
« no previous file with comments | « Source/core/layout/HitTestRequest.h ('k') | Source/core/layout/LayoutBlockFlow.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698