Extend the coverage of the Custom Allocation Framework in WebCore
https://bugs.webkit.org/show_bug.cgi?id=96512
Reviewed by Eric Seidel.
Add WTF_MAKE_FAST_ALLOCATED macro to the following class/struct declarations because these
or their child classes are instantiated by operator new.
Covered by existing tests.
* Modules/websockets/WebSocketDeflateFramer.cpp:
(WebSocketExtensionDeflateFrame):
* Modules/websockets/WebSocketDeflateFramer.h:
(DeflateResultHolder):
(InflateResultHolder):
* Modules/websockets/WebSocketDeflater.h:
(WebSocketDeflater):
(WebSocketInflater):
* Modules/websockets/WebSocketHandshake.h:
(WebSocketHandshake):
* bindings/js/ScriptDebugServer.h:
(Task):
* css/CSSCalculationValue.cpp:
(CSSCalcPrimitiveValue):
* css/CSSParserMode.h:
(CSSParserContext):
* css/CSSValuePool.h:
(CSSValuePool):
* css/StyleBuilder.h:
(StyleBuilder):
* css/StylePropertyShorthand.h:
(StylePropertyShorthand):
* css/StyleResolver.cpp:
(RuleSet):
* css/StyleRule.h:
(StyleRuleBase):
(StyleRule):
* css/StyleRuleImport.h:
(StyleRuleImport):
* css/WebKitCSSKeyframeRule.h:
(StyleKeyframe):
* dom/CheckedRadioButtons.cpp:
(RadioButtonGroup):
* dom/ContextFeatures.h:
(ContextFeaturesClient):
* dom/DOMImplementation.h:
(DOMImplementation):
(XMLMIMETypeRegExp):
* dom/Document.cpp:
(ImmutableAttributeDataCacheKey):
* dom/ElementShadow.h:
(ElementShadow):
* dom/GenericEventQueue.h:
(GenericEventQueue):
* dom/IdTargetObserverRegistry.h:
(IdTargetObserverRegistry):
* dom/NamedNodeMap.h:
(NamedNodeMap):
* dom/ScopedEventQueue.h:
(ScopedEventQueue):
* dom/StyledElement.cpp:
(PresentationAttributeCacheEntry):
(PresentationAttributeCacheCleaner):
* editing/EditingStyle.cpp:
(HTMLElementEquivalent):
* editing/SpellChecker.h:
(SpellChecker):
* fileapi/ThreadableBlobRegistry.cpp:
(BlobRegistryContext):
* html/FormAssociatedElement.cpp:
(FormAttributeTargetObserver):
* html/FormController.h:
(FormController):
* html/HTMLInputElement.cpp:
(ListAttributeTargetObserver):
* html/PublicURLManager.h:
(PublicURLManager):
* html/StepRange.h:
(StepDescription):
* html/ValidationMessage.h:
(ValidationMessage):
* html/canvas/WebGLExtension.h:
(WebGLExtension):
* html/canvas/WebGLRenderingContext.cpp:
(WebCore):
(WebGLRenderingContextLostCallback):
(WebGLRenderingContextErrorMessageCallback):
* html/parser/HTMLElementStack.h:
(ElementRecord):
* html/parser/HTMLMetaCharsetParser.h:
(HTMLMetaCharsetParser):
* inspector/DOMEditor.h:
(DOMEditor):
* inspector/InjectedScriptHost.h:
(InspectableObject):
* inspector/InjectedScriptManager.h:
(InjectedScriptManager):
* inspector/InspectorCSSAgent.cpp:
(SelectorProfile):
* inspector/InspectorCounters.h:
(ThreadLocalInspectorCounters):
* inspector/InspectorDOMAgent.cpp:
(RevalidateStyleAttributeTask):
* inspector/InspectorFrontendClientLocal.cpp:
(InspectorBackendDispatchTask):
* inspector/InspectorHistory.h:
(InspectorHistory):
(Action):
* inspector/InspectorOverlay.h:
(HighlightConfig):
(InspectorOverlay):
* inspector/InspectorState.h:
(InspectorState):
* inspector/InspectorStyleSheet.cpp:
(ParsedStyleSheet):
* inspector/InspectorWorkerAgent.cpp:
(InspectorWorkerAgent::WorkerFrontendChannel):
* inspector/NetworkResourcesData.h:
(NetworkResourcesData):
(ResourceData):
* inspector/WorkerInspectorController.cpp:
* loader/EmptyClients.h:
(EmptyChromeClient):
* loader/ResourceLoadScheduler.h:
(ResourceLoadScheduler):
(HostInformation):
* loader/icon/IconDatabase.cpp:
(DefaultIconDatabaseClient):
(ClientWorkItem):
* page/ContentSecurityPolicy.cpp:
(CSPDirectiveList):
* page/ContentSecurityPolicy.h:
(ContentSecurityPolicy):
* page/FrameActionScheduler.h:
(FrameActionScheduler):
* page/MemoryInfo.cpp:
(HeapSizeCache):
* platform/CalculationValue.h:
(CalcExpressionNode):
* platform/Cursor.h:
(Cursor):
* platform/Decimal.h:
(Decimal):
* platform/Length.cpp:
(CalculationValueHandleMap):
* platform/MemoryPressureHandler.h:
(MemoryPressureHandler):
* platform/PlatformKeyboardEvent.h:
(PlatformKeyboardEvent):
* platform/ScrollAnimator.h:
(ScrollAnimator):
* platform/graphics/GlyphPageTreeNode.h:
(GlyphPageTreeNode):
* platform/graphics/GraphicsContext.h:
(GraphicsContextStateSaver):
* platform/graphics/GraphicsLayer.h:
(AnimationValue):
* platform/graphics/IntRect.h:
(IntRect):
* platform/graphics/ShadowBlur.cpp:
(ScratchBuffer):
* platform/graphics/TextRun.h:
(TextRun):
* platform/graphics/TiledBackingStoreBackend.h:
(TiledBackingStoreBackend):
* platform/graphics/WidthIterator.h:
(WidthIterator):
* platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp:
(StreamingClient):
* platform/graphics/opengl/Extensions3DOpenGL.h:
(Extensions3DOpenGL):
* platform/graphics/texmap/TextureMapper.h:
(TextureMapper):
* platform/graphics/texmap/TextureMapperGL.cpp:
(TextureMapperGLData):
* platform/graphics/texmap/TextureMapperImageBuffer.h:
(TextureMapperImageBuffer):
* platform/graphics/texmap/TextureMapperLayer.h:
(TextureMapperLayer):
* platform/image-decoders/bmp/BMPImageReader.h:
(BMPImageReader):
* platform/image-decoders/gif/GIFImageReader.h:
(GIFFrameReader):
(GIFImageReader):
* platform/image-decoders/jpeg/JPEGImageDecoder.cpp:
(JPEGImageReader):
* platform/image-decoders/png/PNGImageDecoder.cpp:
(PNGImageReader):
* platform/network/BlobRegistryImpl.h:
(BlobRegistryImpl):
* platform/network/ResourceResponseBase.h:
(CrossThreadResourceResponseDataBase):
* platform/text/TextCodecICU.h:
(ICUConverterWrapper):
* rendering/FlowThreadController.h:
(FlowThreadController):
* rendering/RenderBoxRegionInfo.h:
(RenderBoxRegionInfo):
* rendering/RenderLayer.h:
(ClipRects):
(ClipRectsCache):
* rendering/RenderLayerCompositor.h:
(RenderLayerCompositor):
* rendering/WrapShapeInfo.h:
(WrapShapeInfo):
* rendering/style/NinePieceImage.h:
(NinePieceImageData):
* rendering/svg/RenderSVGResourceFilter.h:
(FilterData):
* rendering/svg/RenderSVGResourceGradient.h:
(GradientData):
* rendering/svg/RenderSVGResourcePattern.h:
(PatternData):
* rendering/svg/SVGResources.h:
(ClipperFilterMaskerData):
(MarkerData):
(FillStrokeData):
* svg/SVGAngle.h:
(SVGAngle):
* svg/SVGLength.h:
(SVGLength):
* svg/SVGPreserveAspectRatio.h:
(SVGPreserveAspectRatio):
* svg/graphics/SVGImageCache.h:
(SVGImageCache):
* svg/properties/SVGPropertyInfo.h:
(SVGPropertyInfo):
* workers/WorkerEventQueue.h:
(WorkerEventQueue):
* xml/parser/MarkupTokenBase.h:
(DoctypeDataBase):
* xml/parser/XMLDocumentParserLibxml2.cpp:
(PendingCallbacks):
(OffsetBuffer):
* xml/parser/XMLToken.h:
(XMLDeclarationData):
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@128572 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/Source/WebCore/html/FormAssociatedElement.cpp b/Source/WebCore/html/FormAssociatedElement.cpp
index 99377df..3d88978 100644
--- a/Source/WebCore/html/FormAssociatedElement.cpp
+++ b/Source/WebCore/html/FormAssociatedElement.cpp
@@ -39,6 +39,7 @@
using namespace HTMLNames;
class FormAttributeTargetObserver : IdTargetObserver {
+ WTF_MAKE_FAST_ALLOCATED;
public:
static PassOwnPtr<FormAttributeTargetObserver> create(const AtomicString& id, FormAssociatedElement*);
virtual void idTargetChanged() OVERRIDE;
diff --git a/Source/WebCore/html/FormController.h b/Source/WebCore/html/FormController.h
index 0402b2c..265d601 100644
--- a/Source/WebCore/html/FormController.h
+++ b/Source/WebCore/html/FormController.h
@@ -73,6 +73,7 @@
}
class FormController {
+ WTF_MAKE_FAST_ALLOCATED;
public:
static PassOwnPtr<FormController> create()
{
diff --git a/Source/WebCore/html/HTMLInputElement.cpp b/Source/WebCore/html/HTMLInputElement.cpp
index 2c4c048..d1ea76c 100644
--- a/Source/WebCore/html/HTMLInputElement.cpp
+++ b/Source/WebCore/html/HTMLInputElement.cpp
@@ -80,6 +80,7 @@
#if ENABLE(DATALIST_ELEMENT)
class ListAttributeTargetObserver : IdTargetObserver {
+ WTF_MAKE_FAST_ALLOCATED;
public:
static PassOwnPtr<ListAttributeTargetObserver> create(const AtomicString& id, HTMLInputElement*);
virtual void idTargetChanged() OVERRIDE;
diff --git a/Source/WebCore/html/PublicURLManager.h b/Source/WebCore/html/PublicURLManager.h
index 55fefc3..e17e46a 100644
--- a/Source/WebCore/html/PublicURLManager.h
+++ b/Source/WebCore/html/PublicURLManager.h
@@ -47,7 +47,7 @@
class ScriptExecutionContext;
class PublicURLManager {
-
+ WTF_MAKE_FAST_ALLOCATED;
public:
static PassOwnPtr<PublicURLManager> create() { return adoptPtr(new PublicURLManager); }
void contextDestroyed()
diff --git a/Source/WebCore/html/StepRange.h b/Source/WebCore/html/StepRange.h
index 63ab756..697a7b5 100644
--- a/Source/WebCore/html/StepRange.h
+++ b/Source/WebCore/html/StepRange.h
@@ -40,6 +40,8 @@
};
struct StepDescription {
+ WTF_MAKE_FAST_ALLOCATED;
+ public:
int defaultStep;
int defaultStepBase;
int stepScaleFactor;
diff --git a/Source/WebCore/html/ValidationMessage.h b/Source/WebCore/html/ValidationMessage.h
index 2b3e765..9834427 100644
--- a/Source/WebCore/html/ValidationMessage.h
+++ b/Source/WebCore/html/ValidationMessage.h
@@ -47,7 +47,7 @@
// FIXME: We should remove the code for !validationMessageClient() when all
// ports supporting interactive validation switch to ValidationMessageClient.
class ValidationMessage {
- WTF_MAKE_NONCOPYABLE(ValidationMessage);
+ WTF_MAKE_NONCOPYABLE(ValidationMessage); WTF_MAKE_FAST_ALLOCATED;
public:
static PassOwnPtr<ValidationMessage> create(HTMLFormControlElement*);
~ValidationMessage();
diff --git a/Source/WebCore/html/canvas/WebGLExtension.h b/Source/WebCore/html/canvas/WebGLExtension.h
index c66a608..6968a02 100644
--- a/Source/WebCore/html/canvas/WebGLExtension.h
+++ b/Source/WebCore/html/canvas/WebGLExtension.h
@@ -31,6 +31,7 @@
namespace WebCore {
class WebGLExtension {
+ WTF_MAKE_FAST_ALLOCATED;
public:
// Extension names are needed to properly wrap instances in JavaScript objects.
enum ExtensionName {
diff --git a/Source/WebCore/html/canvas/WebGLRenderingContext.cpp b/Source/WebCore/html/canvas/WebGLRenderingContext.cpp
index c40ba43..24b9c33 100644
--- a/Source/WebCore/html/canvas/WebGLRenderingContext.cpp
+++ b/Source/WebCore/html/canvas/WebGLRenderingContext.cpp
@@ -375,6 +375,7 @@
};
class WebGLRenderingContextLostCallback : public GraphicsContext3D::ContextLostCallback {
+ WTF_MAKE_FAST_ALLOCATED;
public:
explicit WebGLRenderingContextLostCallback(WebGLRenderingContext* cb) : m_context(cb) { }
virtual void onContextLost() { m_context->forceLostContext(WebGLRenderingContext::RealLostContext); }
@@ -384,6 +385,7 @@
};
class WebGLRenderingContextErrorMessageCallback : public GraphicsContext3D::ErrorMessageCallback {
+ WTF_MAKE_FAST_ALLOCATED;
public:
explicit WebGLRenderingContextErrorMessageCallback(WebGLRenderingContext* cb) : m_context(cb) { }
virtual void onErrorMessage(const String& message, GC3Dint) { m_context->printGLErrorToConsole(message); }
diff --git a/Source/WebCore/html/parser/HTMLElementStack.h b/Source/WebCore/html/parser/HTMLElementStack.h
index b203ef1..873cbde 100644
--- a/Source/WebCore/html/parser/HTMLElementStack.h
+++ b/Source/WebCore/html/parser/HTMLElementStack.h
@@ -51,7 +51,7 @@
~HTMLElementStack();
class ElementRecord {
- WTF_MAKE_NONCOPYABLE(ElementRecord);
+ WTF_MAKE_NONCOPYABLE(ElementRecord); WTF_MAKE_FAST_ALLOCATED;
public:
~ElementRecord(); // Public for ~PassOwnPtr()
diff --git a/Source/WebCore/html/parser/HTMLMetaCharsetParser.h b/Source/WebCore/html/parser/HTMLMetaCharsetParser.h
index 1ee87df..436ea79 100644
--- a/Source/WebCore/html/parser/HTMLMetaCharsetParser.h
+++ b/Source/WebCore/html/parser/HTMLMetaCharsetParser.h
@@ -37,7 +37,7 @@
class TextCodec;
class HTMLMetaCharsetParser {
- WTF_MAKE_NONCOPYABLE(HTMLMetaCharsetParser);
+ WTF_MAKE_NONCOPYABLE(HTMLMetaCharsetParser); WTF_MAKE_FAST_ALLOCATED;
public:
static PassOwnPtr<HTMLMetaCharsetParser> create() { return adoptPtr(new HTMLMetaCharsetParser()); }