Bug 61958 - [EFL] DumpRenderTree: Add GCController, PixelDumpsupport and WorkQueueItem
Summary: [EFL] DumpRenderTree: Add GCController, PixelDumpsupport and WorkQueueItem
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Leandro Pereira
URL:
Keywords:
Depends on: 62642
Blocks:
  Show dependency treegraph
 
Reported: 2011-06-02 13:33 PDT by Leandro Pereira
Modified: 2011-06-16 11:41 PDT (History)
5 users (show)

See Also:


Attachments
Patch (10.10 KB, patch)
2011-06-02 14:03 PDT, Leandro Pereira
eric: review-
Details | Formatted Diff | Diff
Fixed patch with suggested changes. (13.02 KB, patch)
2011-06-14 06:50 PDT, Raphael Kubo da Costa (:rakuco)
no flags Details | Formatted Diff | Diff
Try to please the EWS bots. (13.83 KB, patch)
2011-06-16 10:49 PDT, Raphael Kubo da Costa (:rakuco)
no flags Details | Formatted Diff | Diff
Yet another attempt at pleasing the bots. (13.82 KB, patch)
2011-06-16 10:55 PDT, Raphael Kubo da Costa (:rakuco)
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Leandro Pereira 2011-06-02 13:33:21 PDT
[EFL] DRT: Add WorkQueueItemEfl.cpp.
Comment 1 Leandro Pereira 2011-06-02 14:03:32 PDT
Created attachment 95803 [details]
Patch
Comment 2 Leandro Pereira 2011-06-02 14:05:24 PDT
This bug was previously created to upstream WorkQueueItem only, but since it is pretty small, I'm using it to upstream other smaller DRT bits (PixelDumpSupport, GCController and WorkQueueItem).
Comment 3 WebKit Review Bot 2011-06-02 14:05:39 PDT
Attachment 95803 [details] did not pass style-queue:

Failed to run "['Tools/Scripts/check-webkit-style', '--diff-files', u'Tools/ChangeLog', u'Tools/DumpRenderTree/e..." exit_code: 1

Tools/DumpRenderTree/efl/PixelDumpSupportEfl.cpp:35:  Alphabetical sorting problem.  [build/include_order] [4]
Total errors found: 1 in 4 files


If any of these errors are false positives, please file a bug against check-webkit-style.
Comment 4 Eric Seidel (no email) 2011-06-10 12:39:19 PDT
Comment on attachment 95803 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=95803&action=review

Same comments, basically.  This is old c code, in a c++ file.  Unless EFL style strictly requires old-looking c code, with bad memory managmeent, we should move thsi all to smart pointers and modern C++ styling.

> Tools/DumpRenderTree/efl/GCControllerEfl.cpp:5
> + * Copyright (C) 2007 Eric Seidel <eric@webkit.org>
> + * Copyright (C) 2011 ProFUSION Embedded Systems
> + * Copyright (C) 2011 Samsung Electronics
> + *

I doubt you need all these copyrights.

> Tools/DumpRenderTree/efl/PixelDumpSupportEfl.cpp:45
> +    cairo_surface_t* surface;
> +    cairo_t* context;
> +    int width, height;
> +    Ewk_View_Smart_Data* smartData;
> +    Ewk_View_Private_Data* privateData;
> +

Do we really need to follow this old-C limitiation for c++ files?  I doubt you can even find a C compiler which can't handle inline declarations these days. :)

> Tools/DumpRenderTree/efl/PixelDumpSupportEfl.cpp:50
> +    context = cairo_create(surface);

No Cairo smart pointers?  The Gtk Folks might know if we have one.

> Tools/DumpRenderTree/efl/WorkQueueItemEfl.cpp:36
> +char* JSStringCopyUTF8CString(JSStringRef jsString)
> +{
> +    size_t dataSize = JSStringGetMaximumUTF8CStringSize(jsString);
> +    char* utf8 = static_cast<char*>(malloc(dataSize));
> +    JSStringGetUTF8CString(jsString, utf8, dataSize);
> +
> +    return utf8;
> +}

Woh.  so this is what youv'e been using everywhere. I thoguth it was actually part of the JS API.  We could easily use WTF::String here.  Since other ports do.  Not a requirement, but there are definitely smarter string classes to use besides char* :)
Comment 5 Raphael Kubo da Costa (:rakuco) 2011-06-14 06:50:31 PDT
Created attachment 97111 [details]
Fixed patch with suggested changes.

Thanks for the review. The attached patch should solve most of the issues you've brought up. The only downside is that we've had to create our own WorkQueueItemEfl.h (just like the Qt port does).

This patch should obsolete the previous one, I just don't have permissions to do that.
Comment 6 WebKit Review Bot 2011-06-14 06:53:40 PDT
Attachment 97111 [details] did not pass style-queue:

Failed to run "['Tools/Scripts/check-webkit-style', '--diff-files']" exit_code: 1

Total errors found: 0 in 0 files


If any of these errors are false positives, please file a bug against check-webkit-style.
Comment 7 Gyuyoung Kim 2011-06-14 09:18:48 PDT
Comment on attachment 97111 [details]
Fixed patch with suggested changes.

Attachment 97111 [details] did not pass efl-ews (efl):
Output: http://queues.webkit.org/results/8837601
Comment 8 Raphael Kubo da Costa (:rakuco) 2011-06-14 09:26:00 PDT
Looking at the error log, it does not seem to be related to this patch -- try removing WebKit/libewebkit.so.0.1.0 manually.
Comment 9 Leandro Pereira 2011-06-14 10:38:13 PDT
Comment on attachment 97111 [details]
Fixed patch with suggested changes.

I've restarted and cleaned up the EWS; cq? again.
Comment 10 Raphael Kubo da Costa (:rakuco) 2011-06-16 10:49:08 PDT
Created attachment 97463 [details]
Try to please the EWS bots.

This is essentially the same patch, but will hopefully make the EWS bots happier.
Comment 11 Raphael Kubo da Costa (:rakuco) 2011-06-16 10:49:28 PDT
CC'ing eseidel.
Comment 12 WebKit Review Bot 2011-06-16 10:50:49 PDT
Attachment 97463 [details] did not pass style-queue:

Failed to run "['Tools/Scripts/check-webkit-style', '--diff-files', u'Tools/ChangeLog', u'Tools/DumpRenderTree/e..." exit_code: 1

Tools/DumpRenderTree/efl/WorkQueueItemEfl.cpp:29:  Alphabetical sorting problem.  [build/include_order] [4]
Tools/DumpRenderTree/efl/WorkQueueItemEfl.h:39:  This { should be at the end of the previous line  [whitespace/braces] [4]
Total errors found: 2 in 5 files


If any of these errors are false positives, please file a bug against check-webkit-style.
Comment 13 Raphael Kubo da Costa (:rakuco) 2011-06-16 10:55:31 PDT
Created attachment 97465 [details]
Yet another attempt at pleasing the bots.

Oops, I thought I had run check-webkit-style before sending. *sigh*
Comment 14 Eric Seidel (no email) 2011-06-16 10:59:14 PDT
Comment on attachment 97465 [details]
Yet another attempt at pleasing the bots.

OK.
Comment 15 WebKit Review Bot 2011-06-16 11:41:22 PDT
Comment on attachment 97465 [details]
Yet another attempt at pleasing the bots.

Clearing flags on attachment: 97465

Committed r89053: <http://trac.webkit.org/changeset/89053>
Comment 16 WebKit Review Bot 2011-06-16 11:41:27 PDT
All reviewed patches have been landed.  Closing bug.