Title: [156232] trunk/Source/WebCore
Revision
156232
Author
[email protected]
Date
2013-09-21 11:46:09 -0700 (Sat, 21 Sep 2013)

Log Message

Don't bloat Obj-C bindings with inlined attribute retrieval.
<https://webkit.org/b/121745>

Reviewed by Anders Carlsson.

Hack bindings generator to always use getAttribute() for Objective-C.
Reduces WebCore binary size by 25120 bytes.

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (156231 => 156232)


--- trunk/Source/WebCore/ChangeLog	2013-09-21 18:25:43 UTC (rev 156231)
+++ trunk/Source/WebCore/ChangeLog	2013-09-21 18:46:09 UTC (rev 156232)
@@ -1,3 +1,13 @@
+2013-09-21  Andreas Kling  <[email protected]>
+
+        Don't bloat Obj-C bindings with inlined attribute retrieval.
+        <https://webkit.org/b/121745>
+
+        Reviewed by Anders Carlsson.
+
+        Hack bindings generator to always use getAttribute() for Objective-C.
+        Reduces WebCore binary size by 25120 bytes.
+
 2013-09-20  Darin Adler  <[email protected]>
 
         Shink attribute event listener code

Modified: trunk/Source/WebCore/bindings/scripts/CodeGeneratorObjC.pm (156231 => 156232)


--- trunk/Source/WebCore/bindings/scripts/CodeGeneratorObjC.pm	2013-09-21 18:25:43 UTC (rev 156231)
+++ trunk/Source/WebCore/bindings/scripts/CodeGeneratorObjC.pm	2013-09-21 18:46:09 UTC (rev 156232)
@@ -1232,6 +1232,12 @@
             my $getterSig = "- ($attributeType)$attributeInterfaceName\n";
 
             my ($functionName, @arguments) = $codeGenerator->GetterExpression(\%implIncludes, $interfaceName, $attribute);
+
+            # To avoid bloating Obj-C bindings, we use getAttribute() instead of fastGetAttribute().
+            if ($functionName eq "fastGetAttribute") {
+                $functionName = "getAttribute";
+            }
+
             my $getterExpressionPrefix = "$functionName(" . join(", ", @arguments);
 
             # FIXME: Special case attribute ownerDocument to call document. This makes it return the
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to