Bug 26567

Summary: [V8] Upstream V8 bindings code generator.
Product: WebKit Reporter: Dimitri Glazkov (Google) <dglazkov>
Component: WebCore Misc.Assignee: Dimitri Glazkov (Google) <dglazkov>
Status: RESOLVED FIXED    
Severity: Normal CC: eric, sam
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: All   
OS: All   
Attachments:
Description Flags
Upstream V8 code generator, v1.
sam: review-
Upstream V8 code generator, v2.
none
Upstream V8 code generator, v2.1. sam: review+

Dimitri Glazkov (Google)
Reported 2009-06-19 19:42:11 PDT
Whoop, there it is. Basically, I haven't gone making any style changes to CodeGeneratorV8.pm, trying to land this as-is for now. It's very hard to make changes on both sides of the stream. I added ParseParents method (and $parentsOnly param) to existing code, which is not used by JSC. In V8, it is used to find out whether the interface inherits from Node, which is a long story ... Please don't hurt me. I don't want to do any more Perl. Ever again. Actually, I have lots of work slated in Perl, trying to shave some hair off this beast and bring it as close to JSC bindings generator as possible.
Attachments
Upstream V8 code generator, v1. (74.66 KB, patch)
2009-06-19 19:44 PDT, Dimitri Glazkov (Google)
sam: review-
Upstream V8 code generator, v2. (77.61 KB, patch)
2009-06-22 14:21 PDT, Dimitri Glazkov (Google)
no flags
Upstream V8 code generator, v2.1. (77.43 KB, patch)
2009-06-22 14:26 PDT, Dimitri Glazkov (Google)
sam: review+
Dimitri Glazkov (Google)
Comment 1 2009-06-19 19:44:10 PDT
Created attachment 31586 [details] Upstream V8 code generator, v1. WebCore/ChangeLog | 13 + WebCore/bindings/scripts/CodeGenerator.pm | 31 + WebCore/bindings/scripts/CodeGeneratorV8.pm | 2206 +++++++++++++++++++++++++++ WebCore/bindings/scripts/IDLParser.pm | 4 + 4 files changed, 2254 insertions(+), 0 deletions(-)
Sam Weinig
Comment 2 2009-06-19 22:33:39 PDT
Comment on attachment 31586 [details] Upstream V8 code generator, v1. r-. There a couple of style issues that need to be taken care of such as 2 space indentation instead of 4 and commented out code. I would also like an explanation as to why the parent traversal stuff is necessary for v8 and not JSC.
Eric Seidel (no email)
Comment 3 2009-06-20 01:06:44 PDT
Yay! Finally! :)
Sam Weinig
Comment 4 2009-06-20 14:12:04 PDT
It would also be useful to have a rundown of all the v8 specific extended attributes and why they are necessary and where they create divergence from the JSC bindings.
Dimitri Glazkov (Google)
Comment 5 2009-06-20 19:46:41 PDT
(In reply to comment #4) > It would also be useful to have a rundown of all the v8 specific extended > attributes and why they are necessary and where they create divergence from the > JSC bindings. Will do that and reconcile them. I suspect V8 bindings do some unholy things using attributes not for purposes intended. At this point, I know that [Replaceable] is used that way, but not much else. Is that ok if this patch doesn't include this documentation? I'll put a FIXME and start a bug on that?
Dimitri Glazkov (Google)
Comment 6 2009-06-22 14:21:47 PDT
Created attachment 31672 [details] Upstream V8 code generator, v2. WebCore/ChangeLog | 16 + WebCore/bindings/scripts/CodeGenerator.pm | 35 + WebCore/bindings/scripts/CodeGeneratorV8.pm | 2192 +++++++++++++++++++++++++++ WebCore/bindings/scripts/IDLParser.pm | 4 + 4 files changed, 2247 insertions(+), 0 deletions(-)
Dimitri Glazkov (Google)
Comment 7 2009-06-22 14:26:12 PDT
Created attachment 31674 [details] Upstream V8 code generator, v2.1. WebCore/ChangeLog | 16 + WebCore/bindings/scripts/CodeGenerator.pm | 35 + WebCore/bindings/scripts/CodeGeneratorV8.pm | 2189 +++++++++++++++++++++++++++ WebCore/bindings/scripts/IDLParser.pm | 4 + 4 files changed, 2244 insertions(+), 0 deletions(-)
Dimitri Glazkov (Google)
Comment 8 2009-06-22 14:26:45 PDT
Styling issues addressed, comment about ParseParents added.
Sam Weinig
Comment 9 2009-06-22 17:36:02 PDT
Comment on attachment 31674 [details] Upstream V8 code generator, v2.1. r=me
Dimitri Glazkov (Google)
Comment 10 2009-06-22 21:36:42 PDT
Note You need to log in before you can comment on or make changes to this bug.