src/compiler/translator/UtilsHLSL.cpp


Log

Author Commit Date CI Message
Olli Etuaho 59f9a641 2015-08-06T20:38:26 Remove EOpInternalFunctionCall It's cleaner to mark internal functions by using the TName class, similarly to TIntermSymbol. TEST=angle_unittests BUG=angleproject:1116 Change-Id: I12a03a3dea42b3fc571fa25a1b11d0161f24de72 Reviewed-on: https://chromium-review.googlesource.com/291621 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Olli Etuaho <oetuaho@nvidia.com>
Olli Etuaho f5cfc8df 2015-08-06T16:36:39 Track whether a name is internal to ANGLE in a separate class The AST contains identifiers in a few different places: besides symbols, there are also function names, which show up in function signatures and function calls. Any of these can be coming either from the original shader or from inside ANGLE. A class that encapsulates a string and its internalness will be useful for implementing a unified way of handling all names in shader translation. Start implementing this by splitting the functionality out of TSymbol. TEST=angle_unittests BUG=angleproject:1116 Change-Id: I0a1b5936dcccd0d5fc1c0c13c712102fbfff2a79 Reviewed-on: https://chromium-review.googlesource.com/291280 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Olli Etuaho <oetuaho@nvidia.com>
Olli Etuaho 214c2d8e 2015-04-27T14:49:13 Separate invariance from qualifiers ESSL3 makes it possible to combine invariant with several more different qualifiers. To avoid combinatorial explosion of the qualifier enum, track invariance with a separate boolean. TEST=WebGL conformance tests, angle_unittests BUG=angleproject:987 Change-Id: I0c6629e5ca2ded06db9ac9e5bab2fb6480299a5a Reviewed-on: https://chromium-review.googlesource.com/267662 Reviewed-by: Olli Etuaho <oetuaho@nvidia.com> Tested-by: Olli Etuaho <oetuaho@nvidia.com>
Jamie Madill 9b82084f 2015-02-12T10:40:10 Fix HLSL varying struct linking. We would always expand a struct name to always include its symbol ID. This fixes the workaround to only affect scoped structs. We can leave global structs, which are by definition uniquely named, without decorating them with a symbol ID. This fixes several tests in dEQP's shader.linkage.varying.struct. Re-land with GLSL translator bug fixed. BUG=angle:910 Change-Id: I23a932bd1dadea5e9aafabde697e6a2af9a43f2b Reviewed-on: https://chromium-review.googlesource.com/249134 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Zhenyao Mo <zmo@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill b960cc4a 2015-02-12T15:33:20 Revert "Allow varying structs to match between stages." This patch has a bug which breaks the GLSL to GLSL translator. See broken GPU FYI bot builds on the Chromium waterfall: http://build.chromium.org/p/chromium.gpu.fyi/builders/Win7%20Release%20%28NVIDIA%29/builds/13074 This reverts commit 489ffc4d69656c2dbfdbe07e3fa6e38baeb3e072. Change-Id: I8241c6d658f4f31af91b89af1141d3d778ff7c70 Reviewed-on: https://chromium-review.googlesource.com/249131 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 489ffc4d 2015-02-11T16:33:07 Allow varying structs to match between stages. We would always expand a struct name to always include its symbol ID. This workaround fixed scoped structs with the same name. It would also block any possiblity of linking the structs successfully. Instead we can use the workaround only on inner-scoped structs, and leave global structs, which are by definition uniquely named, as they are. This fixes several tests in dEQP's shader.linkage.varying.struct. BUG=angle:910 Change-Id: I81b8dadc7ea493152aff0c44d607114eaaabb142 Reviewed-on: https://chromium-review.googlesource.com/247242 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill d5512cd4 2014-07-10T17:50:08 Collect shader outputs and interface block information. This paves the way for returning ES3-specific info from the shader translator with the new query methods. BUG=angle:466 Change-Id: Ib13cdb604854cdf11e9dc00dd94f18eadc946561 Reviewed-on: https://chromium-review.googlesource.com/206770 Tested-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Zhenyao Mo <zmo@chromium.org>
Jamie Madill 8daaba15 2014-06-13T10:04:33 Split OutputHLSL structure code into new module. Refactoring patch only. BUG=angle:466 Change-Id: I2c57096e1e24574e7de3d35d608645fde3b0c681 Reviewed-on: https://chromium-review.googlesource.com/203730 Tested-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Zhenyao Mo <zmo@chromium.org> Reviewed-by: Nicolas Capens <nicolascapens@chromium.org>
Jamie Madill 033dae67 2014-06-18T12:56:28 Move OutputHLSL utility methods to other files. OutputHLSL was become a large, unweildy file. Some were also useful to other classes, even on the GL back-end, but were inacessible. Refactoring patch only. BUG=angle:466 Change-Id: Id216147122ca105c6ccdf0ba0c5f6c5038726965 Reviewed-on: https://chromium-review.googlesource.com/203459 Reviewed-by: Zhenyao Mo <zmo@chromium.org> Reviewed-by: Nicolas Capens <nicolascapens@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>