Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(147)

Issue 1864044: Refactored the way symbol tables are initialized and stored. This was done in... (Closed)

Can't Edit
Can't Publish+Mail
Start Review
Created:
14 years, 4 months ago by Alok Priyadarshi
Modified:
14 years, 4 months ago
Reviewers:
kbr1, dgkoch
CC:
angleproject-review_googlegroups.com
Base URL:
http://angleproject.googlecode.com/svn/trunk/
Visibility:
Public.

Description

Refactored the way symbol tables are initialized and stored. This was done in response to the addition of EShSpec. Symbol table entries depend on three things - language, spec (not now but may eventually), and built-in resources. We used to build two global symbol-tables - one for each language. During each compile, one of the symbol table was copied and resource-specific stuff was added. I have moved the symbol table to TCompiler that gets initilized when compiler is created and reused for each compile. This makes it much cleaner and extensible in case a spec requires special entries to be added to the symbol table. PS: Sorry for the long CL, but all of it needed to be done in one CL. I have verified that everything still compiles and passes all conformance tests.

Patch Set 1 #

Total comments: 6

Patch Set 2 : '' #

Total comments: 9

Patch Set 3 : '' #

Unified diffs Side-by-side diffs Delta from patch set Stats (+599 lines, -666 lines) Patch
M include/GLSLANG/ShaderLang.h View 2 chunks +1 line, -2 lines 0 comments Download
M samples/translator/translator.cpp View 1 2 5 chunks +56 lines, -50 lines 0 comments Download
M src/compiler/Initialize.h View 1 2 1 chunk +9 lines, -10 lines 0 comments Download
M src/compiler/Initialize.cpp View 1 2 3 chunks +424 lines, -426 lines 0 comments Download
M src/compiler/ShHandle.h View 1 2 chunks +11 lines, -4 lines 0 comments Download
M src/compiler/ShaderLang.cpp View 1 2 8 chunks +79 lines, -145 lines 0 comments Download
M src/compiler/SymbolTable.h View 5 chunks +6 lines, -15 lines 0 comments Download
M src/libGLESv2/Shader.cpp View 2 chunks +13 lines, -14 lines 0 comments Download

Messages

Total messages: 7
Alok Priyadarshi
14 years, 4 months ago (2010-07-22 22:22:45 UTC) #1
kbr1
http://codereview.appspot.com/1864044/diff/1/6 File src/compiler/Initialize.cpp (right): http://codereview.appspot.com/1864044/diff/1/6#newcode22 src/compiler/Initialize.cpp:22: TString BuiltInFunctionsCommon() If this isn't exported in the header ...
14 years, 4 months ago (2010-07-22 23:01:15 UTC) #2
Alok Priyadarshi
http://codereview.appspot.com/1864044/diff/1/6 File src/compiler/Initialize.cpp (right): http://codereview.appspot.com/1864044/diff/1/6#newcode22 src/compiler/Initialize.cpp:22: TString BuiltInFunctionsCommon() On 2010/07/22 23:01:15, kbr1 wrote: > If ...
14 years, 4 months ago (2010-07-23 16:16:28 UTC) #3
kbr1
This generally looks good to me but I haven't studied how the compiler and symbol ...
14 years, 4 months ago (2010-07-23 18:34:10 UTC) #4
Alok Priyadarshi
Hope this helps. My CL mainly moves the per-process symbol-table to the compiler. This eliminates ...
14 years, 4 months ago (2010-07-23 18:54:20 UTC) #5
dgkoch
Look reasonable, other than my specific comments. Daniel http://codereview.appspot.com/1864044/diff/6001/7002 File samples/translator/translator.cpp (right): http://codereview.appspot.com/1864044/diff/6001/7002#newcode77 samples/translator/translator.cpp:77: switch ...
14 years, 4 months ago (2010-07-26 13:28:30 UTC) #6
Alok Priyadarshi
14 years, 4 months ago (2010-07-26 18:08:52 UTC) #7
http://codereview.appspot.com/1864044/diff/6001/7002
File samples/translator/translator.cpp (right):

http://codereview.appspot.com/1864044/diff/6001/7002#newcode77
samples/translator/translator.cpp:77: switch (FindLanguage(argv[0])) {
I removed lang variable instead. It was not being used anywhere.

http://codereview.appspot.com/1864044/diff/6001/7003
File src/compiler/Initialize.cpp (left):

http://codereview.appspot.com/1864044/diff/6001/7003#oldcode585
src/compiler/Initialize.cpp:585: case EShLangFragment:
On 2010/07/26 13:28:30, dgkoch wrote:
> I'd prefer if the dFdx/dFdy/fwidth operators were left here (although still
> commented out) as the OES_standard_derivatives extension is something that
would
> potentially be useful for an ES2/webgl implementation.

Done.

http://codereview.appspot.com/1864044/diff/6001/7003
File src/compiler/Initialize.cpp (right):

http://codereview.appspot.com/1864044/diff/6001/7003#newcode361
src/compiler/Initialize.cpp:361: s.append(TString("vec4 ftransform();"));
On 2010/07/26 13:28:30, dgkoch wrote:
> should probably comment this line out.  ftransform() isn't valid for ES2/webgl

Done.
Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b