src/tests


Log

Author Commit Date CI Message
Jamie Madill 0cbfa586 2018-02-15T14:45:41 Vulkan: Implement basic Renderbuffer attachments. Creating an ImageView for color Renderbuffers allows us to render to them in a RenderPass. We will also need additional functionality to support depth/stencil Renderbuffers. Bug: angleproject:2347 Change-Id: I5d4f7d8242ad4fbca38cb08c0cf6b43edca57c8f Reviewed-on: https://chromium-review.googlesource.com/922456 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Frank Henigman <fjhenigman@chromium.org> Reviewed-by: Yuly Novikov <ynovikov@chromium.org>
Olli Etuaho e80825ef 2018-02-16T10:24:53 Simplify built-in function node initialization Built-ins with no math op associated with them now have the op code EOpCallBuiltInFunction set. This makes initializing built-in function nodes simpler, since they can always get the op code from the function symbol. We also no longer look for functions in inner scopes, only from the global scope and from built-in functions. BUG=angleproject:2267 TEST=angle_unittests Change-Id: I55a2642f34bb3c8b8f13183c95fa509ec3b9cfdb Reviewed-on: https://chromium-review.googlesource.com/923724 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
Frank Henigman 17448956 2017-01-05T15:48:26 Vulkan: vertex attributes in client memory. Support vertex data stored in client memory passed to glVertexAttribPointer. Only GL_FLOAT data is supported at this time. Includes a simple test. BUG=angleproject:1683 Change-Id: I3bc0cdefe02b02c046b0e85822019a0f1762235e Reviewed-on: https://chromium-review.googlesource.com/425137 Commit-Queue: Frank Henigman <fjhenigman@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill f618c9e5 2018-02-15T14:45:40 Vulkan: Add depth/stencil surfaces. This change lets us create egl::Surfaces from a D24S8 config. This is a bit hacky, because the spec only mandates 24 -or- 32 bit depth support, but not both or either individually. Will need follow-up work for proper EGL config setup. A single depth buffer is allocated for the entire set of swapchain images and is used with each. This also might be a problem if we're rendering to multiple frames at the same time. We'll likely have to revisit this in the future as well. This adds a new RenderTargetVk to the SurfaceVk class which points to the Depth/Stencil image. Since ImageViews must refer to either the depth or stencil, but not both, we'll need to address this when we get to implementing depth/stencil texture reads in shaders. Bug: angleproject:2357 Change-Id: Ibed0eed7e1d0efb272758dbfc79fa2c5aa93997f Reviewed-on: https://chromium-review.googlesource.com/919761 Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Yuly Novikov f3803d4f 2018-02-14T18:29:27 Fix standalone Linux build Need to include gtest before X11 to avoid defines conflict BUG=angleproject:2348 Change-Id: If758c53fb5ef010506f13165186110f00c099e07 Reviewed-on: https://chromium-review.googlesource.com/919687 Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Commit-Queue: Yuly Novikov <ynovikov@chromium.org>
Jamie Madill 12eb3d74 2018-02-14T12:34:45 Vulkan: Implement basic Renderbuffer creation. Bug: angleproject:2347 Change-Id: I56edfde2dbc020d5c792cc4f107aa4b9d6b71840 Reviewed-on: https://chromium-review.googlesource.com/905895 Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Reviewed-by: Luc Ferron <lucferron@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Luc Ferron ee305913 2018-02-14T13:50:38 AngleWrangle: Suppress newly introduced flakyness Flakyness noticed there: https://ci.chromium.org/buildbot/tryserver.chromium.angle/mac_angle_rel_ng/ https://ci.chromium.org/buildbot/chromium.gpu.fyi/Mac%20FYI%20Release%20%28Intel%29/ Introduced in: https://chromium-review.googlesource.com/c/angle/angle/+/913108 Change-Id: I9cbd76c0472d023005ded9f957b304a4a769c619 Reviewed-on: https://chromium-review.googlesource.com/919547 Commit-Queue: Luc Ferron <lucferron@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Geoff Lang 8170eab7 2017-09-21T13:59:04 D3D: Implement robust resource init for Surfaces. BUG=angleproject:2107 BUG=angleproject:2317 Change-Id: I22260e1093dc6c09e4627c62a95ca4088c99e951 Reviewed-on: https://chromium-review.googlesource.com/678480 Commit-Queue: Geoff Lang <geofflang@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Yunchao He 9550c603 2018-02-13T14:47:05 Code refactoring for end2end tests. This change: 1) uses the new style ANGLE_SKIP_TEST_IF to skip tests. 2) replaces compile-time definition for OSX to skip tests by run-time function IsOSX() to skip tests, in order to align with ANGLE_SKIP_TEST_IF. 3) fixes a couple of typos. BUG=angleproject:2005 Change-Id: I5af77d82257536b9eb79e26afa502f5b91ff6d31 Reviewed-on: https://chromium-review.googlesource.com/915861 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Luc Ferron 2900c3be 2018-02-09T16:02:41 Vulkan: Add culling rasterization states tests and invert front face Bug: angleproject:2352 Change-Id: I0ac83f3173d22a2ee8bc98d2fd7bfa1875d46b8c Reviewed-on: https://chromium-review.googlesource.com/912358 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Luc Ferron <lucferron@chromium.org>
Luc Ferron d50537a7 2018-02-07T17:02:08 Vulkan: Texture caps map We are generating the caps map using various bits from the results of vkGetPhysicalDeviceFormatProperties. This contains all the information required to fill out "renderable", "texturable" and "filterable". Later we'll need to read from vkGetPhysicalDeviceImageFormatProperties as well to get the sampleCounts. The tests for now are not very meaningful since they use the same logic as the caps code to build the expected results, however as soon as we'll add the hard-coded list of mandatory texture caps, the test will be a good validator that we are not breaking anything. We only check the optimal set of flags since it is the most restrictive set. isTexturable = flags contain VK_FORMAT_FEATURE_SAMPLED_IMAGE_BIT isFilterable = flags contain VK_FORMAT_FEATURE_SAMPLED_IMAGE_FILTER_LINEAR_BIT isRenderable = flags contain VK_FORMAT_FEATURE_COLOR_ATTACHMENT_BIT OR VK_FORMAT_FEATURE_DEPTH_STENCIL_ATTACHMENT_BIT Bug: angleproject:2348 Change-Id: I9da0712190d2678d7e377d6fcd4ca83d23eefd38 Reviewed-on: https://chromium-review.googlesource.com/908712 Commit-Queue: Luc Ferron <lucferron@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill b79f0351 2018-02-12T13:13:53 Add test for scissored clear. This simple test will be used to debug the Vulkan back-end's basic scissored clear functionality. Bug: angleproject:2356 Change-Id: I4bed68740ac57b3cc61f2dfe9164081b05bc31b3 Reviewed-on: https://chromium-review.googlesource.com/914230 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Brandon Jones f0d3b901 2018-02-08T08:57:14 Enable Multisample Sources in copyImageInternal For D3D11 This enables the copyTexImage2D and copyTexSubImage2D to handle multisampled source through through the blit path. We attempt to use a cached texture as an intermediate to resolve to, or create a new texture if there's a mismatch. The resolved texture is sent through blit11::copyTexture as normal. BUG:angleproject:2316 Change-Id: Ie3490b45b1a368300ee13fe5a0b35dc3920364ff Reviewed-on: https://chromium-review.googlesource.com/911889 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Geoff Lang <geofflang@chromium.org>
Jiawei Shao 4ed05da2 2018-02-02T14:26:15 ES31: Add link validation on geometry shader itself This patch intends to support program link validation on geometry shader itself. A link error should occur when linking a program with a geometry shader that lacks input primitive or output primitive or the declaration of 'max_vertices'. This patch also adds the support of linking a program with geometry shader in angle_end2end_tests. BUG=angleproject:1941 TEST=angle_end2end_tests dEQP-GLES31.functional.shaders.linkage.es31.geometry.varying.rules.unspecified_* Change-Id: I25fb08514753102f5dd3ab86211c05d2ca4fd185 Reviewed-on: https://chromium-review.googlesource.com/898842 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 30414789 2018-02-12T15:16:02 Revert "GLES1: Link against angle_util_static instead of angle_util." This reverts commit da91c9a6d86c9ecd21c6ac724cf9576d7ee310d2. Reason for revert: Causes undefined behaviour in linker. Original change's description: > GLES1: Link against angle_util_static instead of angle_util. > > Attempting to work around missing .so on linux bots. > > BUG=angleproject:2303 > > Change-Id: I7fabad308afd420987369b460c13c00781113605 > Reviewed-on: https://chromium-review.googlesource.com/909028 > Reviewed-by: Geoff Lang <geofflang@chromium.org> > Commit-Queue: Geoff Lang <geofflang@chromium.org> TBR=geofflang@chromium.org,lfy@google.com # Not skipping CQ checks because original CL landed > 1 day ago. Bug: angleproject:2303 Change-Id: I8d3f3d9bd618d9604cec0f02424f788cab25b3f9 Reviewed-on: https://chromium-review.googlesource.com/913550 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Lingfeng Yang <lfy@google.com> Commit-Queue: Geoff Lang <geofflang@chromium.org>
Yunchao He 2f23f35a 2018-02-11T22:11:37 Clean up end2end tests for Intel OSX. BUG=angleproject:2205 BUG=angleproject:2041 BUG=angleproject:2155 Change-Id: I26bcbb63e147787cd342ec80a86d60cf230be4c9 Reviewed-on: https://chromium-review.googlesource.com/913108 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Yuly Novikov 6108b766 2018-02-08T18:17:43 Remove angle::Library and its usages No longer needed after https://chromium-review.googlesource.com/513519 Loading libGLESv2 interferes with API tracing tools BUG=angleproject:1892,angleproject:2343 Change-Id: I2ccbc99377d75d107fd644301402c52466dded21 Reviewed-on: https://chromium-review.googlesource.com/910094 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Yuly Novikov <ynovikov@chromium.org>
Luc Ferron f8be756e 2018-02-06T15:59:11 Vulkan: Implement blend states and add a simple test for it Bug: angleproject:2346 Change-Id: I462a2cb29ceda5563f48b4a3cc1d0aa20f4a49fc Reviewed-on: https://chromium-review.googlesource.com/907169 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Geoff Lang ed04619a 2018-02-08T14:57:14 Fix typo in bug link. BUG=angleproject:2205 Change-Id: I7ff1c3d0bb380c73c07dad0a30a4a4a19c17e397 Reviewed-on: https://chromium-review.googlesource.com/909577 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Geoff Lang <geofflang@chromium.org>
Geoff Lang bb514004 2017-04-28T14:08:38 Request RGBA8 configs by default for gtest dEQP. Previously, dEQP would just use the first config returned which was RGBA4 which is not very representitive of what our users would request. BUG=angleproject:2337 BUG=angleproject:1095 BUG=angleproject:2222 Change-Id: I5c9defc7ce1feaa49407557b88d9bb6b98571771 Reviewed-on: https://chromium-review.googlesource.com/490726 Reviewed-by: Luc Ferron <lucferron@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Geoff Lang <geofflang@chromium.org>
Geoff Lang 06b95582 2018-02-08T13:48:44 Re-supress VerifyMax*UniformVectors on Ozone Intel. BUG=angleproject:2205 Change-Id: Icff414dc7a521205fd3e39af4652b0fdef1cb900 Reviewed-on: https://chromium-review.googlesource.com/909291 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Geoff Lang <geofflang@chromium.org>
Geoff Lang da91c9a6 2018-02-08T11:46:39 GLES1: Link against angle_util_static instead of angle_util. Attempting to work around missing .so on linux bots. BUG=angleproject:2303 Change-Id: I7fabad308afd420987369b460c13c00781113605 Reviewed-on: https://chromium-review.googlesource.com/909028 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Geoff Lang <geofflang@chromium.org>
Yunchao He 8e5ba8bb 2018-02-05T17:52:27 Clean up end2end tests for Intel Linux platform. Removed tests can pass on Intel Linux Desktop (Intel KabyLake, Ubuntu 17.04) with system default mesa and latest upstream mesa. BUG=angleproject:2205 BUG=chromium:680631 Change-Id: Ie3f0f34b9708a7dab81f66d9ec83a469658deee7 Reviewed-on: https://chromium-review.googlesource.com/901382 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org>
JiangYizhou 5420cb2a 2018-01-24T10:09:22 Suppress Intel specific deqp test cases Test deqp cases on Windows D3D and Linux on Intel HD 630. Add failed or crashed test cases to expectation files. BUG=801323 BUG=angleproject:2349 Change-Id: I495874f5e1841f6c7ce0f59224ed0da9465546ce Reviewed-on: https://chromium-review.googlesource.com/900708 Commit-Queue: Geoff Lang <geofflang@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill 0e65454d 2018-02-07T14:50:06 Vulkan: Fix circular dependency with resource updates. The old implementation would try to keep recording draw commands to the same framebuffer write operation even if the vertex array buffer data changed. This would lead to a broken dependency graph. Fix this by forcing any current render operations to create a new node in this case, giving a correct command graph. Old design: - render (creates a CommandBufferNode A) - update buffer (creates a CommandBufferNode B which happens after A) - render (to CommandBuffer A, and gives a circular dependency with B) New design - render (CommandBufferNode A) - update buffer (CommandBufferNode B, happens after A) - render (CommandBufferNode C, happens after B) This also renames some methods to try to clarify them. Bug: angleproject:2350 Change-Id: I6559bed4ed3f58f68771662422c5bef6a505282b Reviewed-on: https://chromium-review.googlesource.com/907416 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Frank Henigman <fjhenigman@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Geoff Lang 469708e7 2018-02-07T16:54:15 Add expectations for gles1 conformance tests. Mark all tests as failing until they are running on the bots. BUG=angleproject:2303 Change-Id: If9dfccd4a433ab039a1993c8e5a351b55532a0c8 Reviewed-on: https://chromium-review.googlesource.com/907630 Commit-Queue: Geoff Lang <geofflang@chromium.org> Reviewed-by: Lingfeng Yang <lfy@google.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Luc Ferron 00155d58 2018-02-06T10:48:47 Vulkan: Implement scissor test and add a simple test for it Bug: angleproject:2338 Change-Id: I699189fcd41feca1656c8553fdf4c1078421524d Reviewed-on: https://chromium-review.googlesource.com/904861 Commit-Queue: Luc Ferron <lucferron@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Olli Etuaho fbb1c792 2018-01-19T16:26:59 Store symbol names as a ImmutableString This will enable compile-time initialization of built-in symbols as well as reducing copying strings. Most of the code that deals with names is changed to use ImmutableString where it makes sense to avoid conversions. The lexer/parser now allocate const char pointers into pool memory instead of allocating TStrings. These are then converted to ImmutableString upon entering TParseContext. BUG=angleproject:2267 TEST=angle_unittests, angle_end2end_tests Change-Id: I244d6271ea1ecf7150d4f89dfa388a7745a1150c Reviewed-on: https://chromium-review.googlesource.com/881561 Commit-Queue: Olli Etuaho <oetuaho@nvidia.com> Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Luc Ferron ceb7190b 2018-02-05T15:18:47 Vulkan: Fix bug in reuse of vertex input bindings Fix bug that used previously used vertex bindings. Now we use the current program mask to only initialize the vulkan pipeline with the active vertex input bindings. + adjust dEQP expectations Bug: angleproject:2334 Change-Id: Ie6176eee99f87dc7a95f664d28e8312b9cb274bc Reviewed-on: https://chromium-review.googlesource.com/902434 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Luc Ferron <lucferron@chromium.org>
Olli Etuaho bfeed4dd 2018-02-06T16:39:29 Add a compiler perf test shader to stress traversers Add a compiler perf test that's targeted at AST traversers. It triggers many traversers that mutate the AST and run multiple iterations particularly on the HLSL backend. BUG=angleproject:827 TEST=angle_perftests Change-Id: I75d89e8ae0fd7959f2c7fbb133c13ccde22abc37 Reviewed-on: https://chromium-review.googlesource.com/904622 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
Luc Ferron b5420664 2018-02-02T10:03:22 Add end2end test for GL_TRIANGLE_FAN in SimpleOperationTest Bug: angleproject:2334 Change-Id: Idb4d651ade139372f40d690e523c43b20e859a5e Reviewed-on: https://chromium-review.googlesource.com/899024 Commit-Queue: Luc Ferron <lucferron@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Luc Ferron 22294b04 2018-02-02T10:03:22 Add end2end tests for GL_LINES and GL_LINE_STRIP + Small refactoring in SimpleOperationTest.cpp to share the vertex/fragment shaders for all the tests. + Adjust deqp gles2 expectations to include dEQP-GLES2.functional.draw.draw_arrays.lines.single_attribute Bug: angleproject:2328 Change-Id: I7cab84b7914f503537eb5bfabb7ed58002e19846 Reviewed-on: https://chromium-review.googlesource.com/899046 Commit-Queue: Luc Ferron <lucferron@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Yunchao He 14cb42c0 2018-01-24T14:11:19 Clean up passed end2end tests on Intel Linux platforms. Only one end2end test still fail for ANGLE issue 1346. BUG=angleproject:1346 Change-Id: Ibeefe600b21b6ae2056e304d18a8fc4071a48cbe Reviewed-on: https://chromium-review.googlesource.com/882294 Reviewed-by: Jiajia Qin <jiajia.qin@intel.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Geoff Lang 64d065e2 2018-02-03T12:26:19 Update dEQP expectations. BUG=angleproject:1487 BUG=angleproject:1442 Change-Id: Ib0913eb446a903199dafcd379c8dc0b9b969b8c0 Reviewed-on: https://chromium-review.googlesource.com/900555 Reviewed-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang edcd1134 2018-02-03T10:28:52 Update dEQP expectations. BUG=angleproject:2341 BUG=angleproject:1442 BUG=angleproject:2324 BUG=angleproject:1941 BUG=angleproject:2342 BUG=angleproject:2137 Change-Id: I9e8fc45d6f3eb8cfc02513602898583af3f79eba Reviewed-on: https://chromium-review.googlesource.com/900547 Reviewed-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill 23c107e8 2018-01-30T09:54:39 Roll dEQP 455d82c60b0...5bc346ba2. Inclues several new ES 3.1 and EGL test sets. https://android.googlesource.com/platform/external/deqp/+log/455d82c60b0..5bc346ba2d5 Bug: angleproject:2319 Bug: angleproject:1961 Bug: angleproject:1028 Bug: angleproject:2320 Bug: angleproject:2321 Bug: angleproject:2329 Bug: angleproject:2330 Change-Id: I26bfb11a41073e94ecc75d20b07055eb4e946d43 Reviewed-on: https://chromium-review.googlesource.com/703159 Reviewed-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang c7295f4d 2018-02-01T13:05:25 Vulkan: Add dEQP ES2 expectations. Only run the info tests for now, skip everything else. Rename angle-vk config to angle-vulkan BUG=angleproject:2161 Change-Id: I0a57f1f8fbfa9d27c2c376d38685184622f0779b Reviewed-on: https://chromium-review.googlesource.com/896552 Commit-Queue: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Olli Etuaho 95ed1947 2018-02-01T14:01:19 Add a class for function lookups Using a purpose-built class for function lookups instead of using a combination of TFunction and a struct container for the this node and arguments makes the code clearer. BUG=angleproject:2267 TEST=angle_unittests Change-Id: I3f345d836abeaa7f84cc46b4b840fd06c7e2e1a7 Reviewed-on: https://chromium-review.googlesource.com/897363 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
Luc Ferron 5c5d7dee 2018-02-01T14:45:54 Remove test restrictions on dEQP gles3 texture.compressedtexsubimage* tests Bug: angleproject:2327 Change-Id: I60ab5ba9d356e2720102c2166e2446002a8b674b Reviewed-on: https://chromium-review.googlesource.com/898066 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Luc Ferron <lucferron@chromium.org>
Jiajia Qin 8efd1268 2017-12-19T09:32:55 ES31: Add max combined interface blocks validation BUG=angleproject:1951 Change-Id: I9223964fa84cee3888fb7f5949c3e098fe2aa2b0 Reviewed-on: https://chromium-review.googlesource.com/890818 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Olli Etuaho 1776fd08 2018-01-31T11:46:52 Make use of CreateBoolNode in traversers This is just refactoring to clean up some duplicate code. A new test is added to make sure this doesn't break UnfoldShortCircuitAST. BUG=angleproject:1490 TEST=angle_unittests Change-Id: I108e646f71ba631cbd5dad2055b64e6a30159742 Reviewed-on: https://chromium-review.googlesource.com/894207 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
Geoff Lang 15443eba 2018-01-31T16:41:53 Fix angle_gles1_conformance_tests compilation in Chromium. BUG=angleproject:2303 Change-Id: If22dd174d2a7b50b1416fa760494e99bbc813985 Reviewed-on: https://chromium-review.googlesource.com/894839 Reviewed-by: Lingfeng Yang <lfy@google.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Geoff Lang <geofflang@chromium.org>
Jamie Madill 61d5325e 2018-01-31T14:49:24 D3D9: Improve varying packing failure mode. D3D9 has a special limitation on varying packing, where each variable takes up a full register width, and cannot share space with other packed varyings. A bug was counting registers incorrectly on D3D9. Fix this by introducing a new limitation exposed to the ANGLE front-end via the gl::Limitations structure. Now varying packing will fail correctly in the ANGLE linking front-end with a more descriptive error message, as such: "Could not pack varying blah" "Note: Additional non-conformant packing restrictions are enforced on D3D9." Also change the packing so that input built-in variables are counted towards varying limits (e.g. gl_PointSize), except for gl_Position. On D3D9 we don't pack gl_PointSize, since it is used in a special extra PSIZE register. Also update some tests to be more robust. Bug: chromium:804799 Change-Id: I9027266a8b66a28626f038f259bff42ebf09dcd2 Reviewed-on: https://chromium-review.googlesource.com/889898 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
jchen10 191a84a8 2018-01-31T16:09:45 Fix VK_NOT_READY for vkAcquireNextImageKHR The error was not handled, as is the cause for the bug. So far we'd better wait until a valid image index is ready. BUG=angleproject:2301 Change-Id: I49a5545d0f2e0cf6cfbb3f604ab0602f8a131d12 Reviewed-on: https://chromium-review.googlesource.com/895402 Commit-Queue: Yuly Novikov <ynovikov@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Yuly Novikov <ynovikov@chromium.org>
Qin Jiajia 9bf55527 2018-01-29T13:56:23 Fix the incorrect calculation for MAX_NAME_LENGTH The old implementation forgot to consider the instance array situation. This change will use unified method to calculate the interface block's MAX_NAME_LENGTH. It also removes some cases which have already passed from expectation files. BUG=angleproject:1920 TEST=angle_end2end_tests *program_interface_query.uniform_block.resource_list.block_array* *program_interface_query.shader_storage_block.resource_list.block_array* Change-Id: I6ef53951487e6366d69ecaa43e4df6824baad042 Reviewed-on: https://chromium-review.googlesource.com/890386 Commit-Queue: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Geoff Lang 513bc77d 2018-01-29T15:50:24 Vulkan: Allow dEQP to create Vulkan displays. BUG=angleproject:2161 Change-Id: Ia2d4b4edcf9a40621573f124d14147224bbd8431 Reviewed-on: https://chromium-review.googlesource.com/891803 Commit-Queue: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Geoff Lang 13fd988c 2018-01-29T15:47:38 Vulkan: Add the Vulkan API to gpu_test_expectations. BUG=angleproject:2161 Change-Id: I7eda4d654cd0c0bc55ff344c5927d738ce592fe4 Reviewed-on: https://chromium-review.googlesource.com/891839 Commit-Queue: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Yunchao He 6969132c 2018-01-30T10:40:08 ES31: update deqp tests for renderbuffer integer formats. These deqp tests were fixed by this change: https://chromium-review.googlesource.com/c/angle/angle/+/878021. BUG=angleproject:2315 Change-Id: Ib0c73bdd3cc1dde554c8e30286c08f92d4f90fd2 Reviewed-on: https://chromium-review.googlesource.com/892402 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jamie Madill efb5a5c8 2018-01-29T15:56:59 Vulkan: Fix swaps done right after a clear. We were missing a dependency insertion between the Framebuffer and its attachments, only during clear operations. Also renames a few methods to make them more consistent. Bug: angleproject:2264 Change-Id: Ic3af5b34b6de900ea2cc1b765f8d3d69f7f9a131 Reviewed-on: https://chromium-review.googlesource.com/891985 Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jamie Madill 5dd4ad89 2018-01-29T13:53:43 Vulkan: Add a perf test for the Pipeline cache. This micro-benchmark can be used to measure the performance impact of changing the Pipeline cache. For instance, we can check if changing the size of the hash key affects performance significantly. Also updates the build files so angle_perftests can see vulkan.h, and makes the Vulkan headers an explicit source set. This test currently shows that a lot of time is spent in PMurmurHash, with some time also spent in memcmp. Bug: angleproject:2163 Change-Id: Ie8bb3e31d58590f373d28cbbb59f7e372b80cc29 Reviewed-on: https://chromium-review.googlesource.com/884882 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Jiawei Shao 881b7bfa 2017-12-25T11:18:37 ES31: Refactor link mismatch error log This patch intends to refactor the structure of logging link mismatch errors to meet the new GLES 3.1 program link requirements and support linking program with geometry shader. This patch is mainly focusing on the following 4 issues: 1. There are totally 14 places that log the link mismatch errors in almost same format. 2. A temporary string is created (STRUCT_NAME.FIELD_NAME) before checking a field of a block, which is of no use if link succeeds. 3. LinkValidateVariablesBase needs to know "shaderTypes" if we support geometry shader based on current structure. Since uniforms are checked in the range of the whole program, it is unnecessary to know in which shader a uniform is defined if link succeeds. 4. GLES 3.1 regards varyings with same location but different names as matched, so it isn't enough to log errors only by one name. This patch can solve all these issues by the following 3 changes: 1. Replace "infoLog" and "variableNames" by "mismatchedFieldName" (the complete field name if the mismatch occurs on a field of a struct or block). 2. Use enum LinkMismatchError as the return value of all linkValidate* functions to reflect the detail of the link mismatch error. 3. Log all the link mismatch errors by InfoLog::logLinkMismatch where we can get shader types instead of passing them into linkValidate* functions. BUG=angleproject:1941, angleproject:2144 TEST=angle_end2end_tests Change-Id: I3ed876d61f812cc7a45a6a3c5fec0b4a88b9cc2c Reviewed-on: https://chromium-review.googlesource.com/844215 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Olli Etuaho 1436d434 2018-01-24T14:38:22 Add a simple compiler perf test The perf test initializes the compiler once and then translates the same shader to HLSL, GLSL or ESSL repeatedly. There are three variations of the test compiling different shaders. One is a real-world shader. BUG=angleproject:2267 TEST=angle_perftests Change-Id: Ie07b67d7548d105c4c93dff3b6196233d83b5b8c Reviewed-on: https://chromium-review.googlesource.com/883784 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
Jamie Madill 17e3d2d5 2018-01-24T16:07:48 Vulkan: Add draw call perf test with a state change. Bug: angleproject:2163 Change-Id: I3976af162ee669d0c98625fc69efb7fbd02c7e45 Reviewed-on: https://chromium-review.googlesource.com/883611 Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Reviewed-by: Frank Henigman <fjhenigman@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Geoff Lang aba14ff5 2018-01-15T14:55:03 Add GLES1 conformance tests. BUG=angleproject:2303 Change-Id: I5955485e2392c573125bd8785ece103a9607f7d1 Reviewed-on: https://chromium-review.googlesource.com/867311 Commit-Queue: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Lingfeng Yang <lfy@google.com>
Olli Etuaho 68981eb5 2018-01-23T17:46:12 Track parameter qualifiers of functions in call nodes We now add a reference to TFunction to all TIntermAggregate nodes where it is possible, including built-in ops. We also make sure that internal TFunctions added in traversers have correct parameter qualifiers. This makes TLValueTrackingTraverser much simpler. Instead of storing traversed functions or looking up builtin functions from the symbol table, determining which function parameters are out parameters can now be done simply by looking it up from the function symbol associated with the aggregate node. Symbol instances are no longer deleted when a symbol table level goes out of scope, and TFunction destructor no longer clears the parameters. They're all either statically allocated or pool allocated, so this does not result in leaks. TEST=angle_unittests BUG=angleproject:2267 Change-Id: I57e5570da5b5a69a98a8778da3c2dc82b6284738 Reviewed-on: https://chromium-review.googlesource.com/881324 Commit-Queue: Olli Etuaho <oetuaho@nvidia.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Luc Ferron 1b1a8640 2018-01-23T15:12:01 Support correct validation for samplerParameterf with GL_TEXTURE_MAX_ANISOTROPY_EXT Bug: angleproject:2072 Change-Id: I3e0b63f2a63e8769e3eab2be3aa0403317ed0707 Reviewed-on: https://chromium-review.googlesource.com/881707 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Luc Ferron <lucferron@google.com>
Luc Ferron adcf0ae6 2018-01-24T08:27:37 Replace all NULL with nullptr Bug: angleproject:1695 Change-Id: Ide0591ffdad5815385a4d805b320a32533bcc03a Reviewed-on: https://chromium-review.googlesource.com/883681 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Luc Ferron <lucferron@google.com>
Yunchao He c081020c 2018-01-22T09:48:48 ES3.1: multisample renderbuffer can support interger format. BUG=angleproject:2315 Change-Id: I3ef289a6043745c822e1c9b0a1b363ac81292c4c Reviewed-on: https://chromium-review.googlesource.com/878021 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Geoff Lang <geofflang@chromium.org>
Yuly Novikov 49886899 2018-01-23T21:18:27 Skip TextureCOMPRESSEDRGB8ETC2ImplicitAlpha1 on Mac NVIDIA GL Also TextureCOMPRESSEDSRGB8ETC2ImplicitAlpha1. Flaky on Mac Experimental Retina Release (NVIDIA) bot. BUG=angleproject:2190 Change-Id: Iad620808db3977625ccd7221f6c3eb7a453802e9 Reviewed-on: https://chromium-review.googlesource.com/882391 Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Commit-Queue: Yuly Novikov <ynovikov@chromium.org>
Olli Etuaho d66e1939 2018-01-17T11:36:24 Allow creating EGL pbuffers from typeless D3D textures A new extension EGL_ANGLE_d3d_typeless_texture_client_buffer is added that allows creating EGL pbuffers from typeless D3D textures. The extension increases the flexibility of the API compared to plain EGL_ANGLE_D3D_texture_client_buffer. The colorspace for the created EGL pbuffer can be set by using the EGL_GL_COLORSPACE attribute. Internally this sets the ANGLE format of the buffer. There are new ANGLE formats that are used specifically for typeless textures, separate ones for SRGB and linear views into the D3D textures. The extension is only supported on the D3D11 backend of ANGLE. BUG=angleproject:2300 TEST=angle_white_box_tests Change-Id: I6a6cb873d2cc0dca0b7f18a0f2cd35e7bafcb7d8 Reviewed-on: https://chromium-review.googlesource.com/873917 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
Yuly Novikov 4e36db8c 2018-01-19T17:35:33 Skip FindMSBAndFindLSBCornerCases on Android OpenGLES Due to a bug in Adreno N5X Oreo driver BUG=angleproject:2304 Change-Id: I209d9b227557571f45a93aa68a003378e12402a1 Reviewed-on: https://chromium-review.googlesource.com/876995 Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Commit-Queue: Yuly Novikov <ynovikov@chromium.org>
Qin Jiajia a08d410d 2018-01-11T13:37:14 Fixed ssbo end2end tests failure The array stride is implementation-dependent if the storage layout is not standard layout. So this change will use std140 as the layout to fix the bug. BUG=767240,angleproject:2255 Change-Id: I21de52ebad6d27783eeade63d6fac81c0842085d Reviewed-on: https://chromium-review.googlesource.com/861313 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Olli Etuaho b60d30f7 2018-01-16T12:31:06 Make TVariable type immutable This enables using constexpr types for built-in variables and some of the variables created in AST transformations. BUG=angleproject:2267 TEST=angle_unittests Change-Id: Ie85b3c9872a071a7c023ced013b14ad91cff7cee Reviewed-on: https://chromium-review.googlesource.com/868134 Commit-Queue: Olli Etuaho <oetuaho@nvidia.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Olli Etuaho fa886975 2018-01-18T19:24:54 Fix handling array constructor statements in HLSL output Array constructors that are used as a statement by themselves need to be pruned from the AST before writing HLSL output. This fixes an assert in OutputHLSL. BUG=angleproject:2307 TEST=angle_unittests Change-Id: Ib49461a4be173f3856f5a264ac0af8d818a61798 Reviewed-on: https://chromium-review.googlesource.com/874691 Commit-Queue: Olli Etuaho <oetuaho@nvidia.com> Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Olli Etuaho 2c9cc8b6 2018-01-09T16:13:02 Don't duplicate symbol type information in AST nodes Function prototype nodes and symbol nodes already refer to symbols that have type information, so the type doesn't need to be copied to the TInterm* AST node classes. Now type is only stored in those AST node classes that represent other types of expressions. They use a new TIntermExpression base class for this. Since now we may use the TType from builtin symbols directly instead of copying it, building the mangled names of types in the correct memory pool is also required. The code now realizes the types of built-in variables when they get added to the symbol table. BUG=angleproject:2267 TEST=angle_unittests Change-Id: Ic8d7fc912937cb8abb1e306e58c63bb9c146aae9 Reviewed-on: https://chromium-review.googlesource.com/857005 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
Xinghua Cao b745f172 2018-01-09T16:10:02 Add more test cases for bindImageTexture Add cases that bindImageTexture binds a single layer of a two-dimensional array, three-dimensional, or cube map texture. BUG=angleproject:1987 TEST=angle_end2end_tests.ComputeShaderTest.* Change-Id: I75883ef05c509100e5164a5add69167a41203101 Reviewed-on: https://chromium-review.googlesource.com/856320 Commit-Queue: Geoff Lang <geofflang@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 2aaa7b4e 2018-01-12T17:17:27 Add GLES1 targets and stub entry points. * Create a new libGLESv1_CM target. * Merge all autogenerated extension entry points into one file. * Allow creation of ES1 contexts. BUG=angleproject:2306 Change-Id: I446258363a96a3c37d657089dd7c1cff0fa3cf78 Reviewed-on: https://chromium-review.googlesource.com/865718 Commit-Queue: Geoff Lang <geofflang@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Olli Etuaho ceffd20c 2018-01-08T16:39:45 Set colorspace of D3D pbuffers according to DXGI format When a EGL pbuffer is created based on a D3D SRGB texture using EGL_ANGLE_d3d_texture_client_buffer, SRGB conversions are performed as if it was an SRGB surface. The value of EGL_GL_COLORSPACE now reflects that correctly. If the pbuffer is bound to a texture and used as a framebuffer attachment, querying GL_FRAMEBUFFER_COLOR_ATTACHMENT also reflects that correctly. The behavior is the same on both the D3D backend, where there is no native interop involved, and on the GL backend using WGL_NV_DX_interop(2). There are a few limitations on the GL backend that relies on native interop: 1. SRGB conversion for textures created this way can't be disabled using the GL_FRAMEBUFFER_SRGB_EXT toggle that's exposed in ANGLE through EXT_sRGB_write_control. This is now documented in the EGL_ANGLE_d3d_texture_client_buffer spec. On the D3D backend this is not a problem since EXT_sRGB_write_control is not supported either way. 2. Creating a pbuffer out of a D3D11 texture with the format DXGI_FORMAT_B8G8R8A8_UNORM_SRGB does not work, even though it was listed as one of the supported formats in the EGL_ANGLE_d3d_texture_client_buffer spec. It's now mentioned that support for this format is optional. BUG=angleproject:2300 TEST=angle_white_box_tests Change-Id: I70ee0646680805e4469291a5b2ce59e92fda009e Reviewed-on: https://chromium-review.googlesource.com/866743 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
Olli Etuaho ea22b7a5 2018-01-04T17:09:11 Constant fold array indexing and comparison A virtual function to get the constant value of an AST node is added to TIntermTyped. This way a constant value can be retrieved conveniently from multiple different types of nodes. TIntermSymbol nodes pointing to a const variable can return the value associated with the variable, constructor nodes can build a constant value from their arguments, and indexing nodes can index into a constant array. This enables constant folding operations on constant arrays, while making sure that large amounts of data are not duplicated in the output shader. When folding an operation makes sense, the values of the arguments can be retrieved by using the new TIntermTyped::getConstantValue(). When folding an operation would result in duplicating data, the AST can just be left to be written out as is. For example, if the code contains a constant array of arrays, indexing into individual elements of the inner arrays can be folded, but indexing the top level array is left in place and not replaced with duplicated array literals. Constant folding is supported for indexing and comparisons of arrays. In case constant arrays are only referenced through foldable operations, the variable declarations will be pruned from the AST by the RemoveUnreferencedVariables step. BUG=angleproject:2298 TEST=angle_unittests Change-Id: I5b3be237b7e9fdba56aa9bf0a41b691f4d8f01eb Reviewed-on: https://chromium-review.googlesource.com/850973 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
Qin Jiajia cd3acf67 2017-12-05T16:27:25 ES31: Update block members static use BUG=angleproject:1920 TEST=angle_end2end_tests Change-Id: I90bcd3bf5a078623b3a739615fbc7b157b6fb94c Reviewed-on: https://chromium-review.googlesource.com/808144 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Commit-Queue: Corentin Wallez <cwallez@chromium.org>
Jamie Madill 2cc2a727 2018-01-09T17:21:54 common: Add aligned memory allocator. This will be useful for the Vulkan pipeline state cache. This cache wants to pack the pipeline description very carefully into a specific number of bits, using the "alignas" keyword. Using this keyword requires an aligned allocator, which we can lift from Chromium's base/memory submodule. Also includes a unittest copied from Chrome. Bug: angleproject:2163 Change-Id: I25976be4610636db3f43552bba23d823f5a49a24 Reviewed-on: https://chromium-review.googlesource.com/837944 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Frank Henigman <fjhenigman@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Olli Etuaho ea78d2bb 2018-01-09T12:55:27 Prune unreferenced variables with a constructor initializer Treat aggregate constructors as having no side effects, which enables pruning declarators that have a constructor initializer. Some logic in RemoveUnreferencedVariables is fixed to make this work correctly for structs. The bugs were previously not exposed since constructors were treated as having side effects, but now that those can be pruned the logic needs to be correct. BUG=angleproject:2298 TEST=angle_unittests Change-Id: I6fbe61a9e82065196baa29c200bf556fc21d8962 Reviewed-on: https://chromium-review.googlesource.com/856499 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
Jiang 0e1224c8 2017-12-26T14:11:15 fix bug for querying sample positions on D3D BUG=angleproject:2290 TEST=dEQP-GLES31.functional.texture.multisample.samples_*.sample_position TEST=TextureMultisampleTestES31.CheckSamplePositions* Change-Id: If8b74c16d5c104215456e35b8922279be972cee3 Reviewed-on: https://chromium-review.googlesource.com/844062 Commit-Queue: Geoff Lang <geofflang@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Olli Etuaho 0690e1aa 2017-12-21T20:51:38 Add a workaround to clamp gl_FragDepth NVIDIA OpenGL drivers at least up to version 388.59 don't clamp gl_FragDepth when it is written to a floating point depth buffer. This bug is now worked around by clamping gl_FragDepth in the shader if it is statically used. BUG=angleproject:2299 TEST=angle_end2end_tests on NVIDIA Change-Id: I61589b2b0dd2813c4901a157c8d37e470063773c Reviewed-on: https://chromium-review.googlesource.com/840842 Commit-Queue: Olli Etuaho <oetuaho@nvidia.com> Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Yuly Novikov 47c9888c 2018-01-08T15:01:11 Skip SimpleOperationTest.DrawQuadAndSwap on Linux Intel Vulkan Was flaky. BUG=angleproject:2301 Change-Id: Id71cf6c43e133810c64535bbde494d12546b0adc Reviewed-on: https://chromium-review.googlesource.com/854978 Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Yuly Novikov <ynovikov@chromium.org>
Corentin Wallez 4a66ef3d 2018-01-05T05:01:27 Add a test for gl_FragDepth clamping with float depth The clamping doesn't happen on NVIDIA so this is a test that will confirm a follow-up compiler workaround patch works properly. BUG=angleproject:2299 Change-Id: I006b522d014e29d2a5e634dfb9cf827ee3bc0536 Reviewed-on: https://chromium-review.googlesource.com/852252 Commit-Queue: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Olli Etuaho <oetuaho@nvidia.com>
Xinghua Cao 08a8ec88 2017-12-27T13:31:11 ES31: Support bindImageTexture on Texture3D/Texture2DArray/TextureCube for compute shaders on D3D BUG=angleproject:1987 TEST=angle_end2end_tests.ComputeShaderTest.* Change-Id: I075296ac3b6796a334929699c16f2399d7915e51 Reviewed-on: https://chromium-review.googlesource.com/844063 Commit-Queue: Geoff Lang <geofflang@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Olli Etuaho 765924f0 2018-01-04T12:48:36 Fold ternary and comma ops only after parsing is done In case folding a ternary op or a comma op would change the qualifier of the expression, the folding is deferred to a separate traversal step. After this there are no more cases where the type of a TIntermSymbol node needs to differ from the type of the variable it is referring to. There are still some cases where some parts of TIntermSymbol type are changed while keeping the TVariable type the same though, like when assigning array size to gl_PerVertex nodes or sanitizing qualifiers of struct declarations. BUG=angleproject:2267 TEST=angle_unittests, angle_end2end_tests Change-Id: I1501c8d361f5f765f43ca810d1b7248d9e2c5986 Reviewed-on: https://chromium-review.googlesource.com/850672 Commit-Queue: Olli Etuaho <oetuaho@nvidia.com> Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Jiawei Shao e9d7f2d1 2017-12-26T15:35:30 ES31: Skip dEQP tests geometry_shading.vertex_transform_feedback.* This patch labels geometry_shading.vertex_transform_feedback.* as "SKIP" instead of "FAIL" to fix some failures in dEQP tests. OpenGL ES 3.1 extension GL_EXT_geometry_shader requires additional validations on transform feedback, which hasn't been implemented in ANGLE, so geometry_shading.vertex_transform_feedback.* fail just after beginTransformfeedback(). As endTransformfeedback() isn't called in dEQP function resetStateES(): 1. An error occurs in this function when trying to clear transform feedback. 2. Some of the tests afterwards also fail because it isn't allowed to change active program by useProgram() when transform feedback is on. So it is better to skip these tests before ANGLE supports these new features. BUG=angleproject:1941 Change-Id: I8834f71e6a655f18118ee4ecf26f4118da6de2f1 Reviewed-on: https://chromium-review.googlesource.com/843955 Commit-Queue: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Jiajia Qin <jiajia.qin@intel.com> Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Jamie Madill f3e23295 2018-01-04T18:19:21 EGL: Expose NULL driver device selection. This makes the device type selection part of the ANGLE platform extension. We currently support NULL driver selection on all available back-ends (although on the NULL back-end, it already has no device type). Optionally we could expose certain features of this as separate extensions. This currently also supports the old hidden enum, until we can update Chrome and consolidate to the new exposed official enum. Bug: angleproject:2159 Change-Id: I85d0811098e644e8192c207673af9e18ed7c1da2 Reviewed-on: https://chromium-review.googlesource.com/846021 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill fa920ebb 2018-01-04T11:45:50 Entry Points: Auto-generate extensions EPs. This is partially complete - it is missing the auto-gen for custom ANGLE and Chromium extensions that aren't present in gl.xml. We can upstream some of these extensions, but will also need to make custom handling for some extensions that are too volatile or under- specced to upstream to Khronos. This also tweaks some of the Context method names to match what the auto-generator expects. It also updates some TexStorage entry points. Also includes a specialized error return value for glTestFenceNV. Also removes the TexImage3DOES entry point which was neither used nor accessible to the application. Bug: angleproject:2263 Change-Id: I3667c22b1b15f84ab4c7dfecb5745aaf73d11e76 Reviewed-on: https://chromium-review.googlesource.com/846420 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Jiawei Shao 02f15239 2017-12-27T10:10:28 Clear error logs when starting a new link process This patch intends to fix a bug in logging link errors. OpenGL ES requires glGetProgramInfoLog return a string that contains information about last link or validation attempt on a program object (GLES 2.0 Chapter 6.1.8, GLES 3.0 Chapter 6.1.12). So all the link error logs should be cleared when a new link process is begun. This patch also removes several redundant allocations of mLazyStream in ProgramD3D::compileProgramExecutables. Calling "<<" on InfoLog objects will initialize its member mLazyStream from heap, so we will skip using "<<" if there is actually nothing to output. BUG=angleproject:2295 TEST=angle_end2end_tests Change-Id: Ib81fffd3d05919a8ebccd9145ff780548ca86a70 Reviewed-on: https://chromium-review.googlesource.com/848324 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 36937a64 2018-01-03T14:03:44 Revert "Enable depth buffer to workaround driver bug on Intel windows" This reverts commit 63ba357c093954d2bc475867e1296fbf5afc1d37. Reason for revert: May be causing Windows GPU.FYI bot failures. https://ci.chromium.org/buildbot/chromium.gpu.fyi/Win10%20Release%20%28Intel%20HD%20630%29/1443 maps_pixel_test on Intel GPU: Unexpected Failures: * gpu_tests.maps_integration_test.MapsIntegrationTest.Maps_maps webgl2_conformance_tests on Intel GPU: Unexpected Failures: * gpu_tests.webgl_conformance_integration_test.WebGLConformanceIntegrationTest.WebglConformance_deqp_functional_gles3_fboinvalidate_default * gpu_tests.webgl_conformance_integration_test.WebGLConformanceIntegrationTest.WebglConformance_deqp_functional_gles3_fboinvalidate_sub Bug: chromium:798757 Original change's description: > Enable depth buffer to workaround driver bug on Intel windows > > Rendering with depth buffer disabled and stencil buffer enabled > leads to memory leak if we set viewport a large size on Intel > windows platforms. So we enable depth buffer if stencil buffer > is enabled to workaround this issue. > > TEST=gl_test.exe --gtest_filter=GLClearFramebufferTestWithParam/GLClearFramebufferTest.ClearDepthStencil/0 > TEST=conformance/rendering/rendering-stencil-large-viewport.html > TEST=RenderStencilBufferTest.DrawWithLargeViewport/ES3_D3D11 > > BUG=782317 > > Change-Id: Idb185db296f13e3fa897534514e198651a56439f > Reviewed-on: https://chromium-review.googlesource.com/809574 > Commit-Queue: Jamie Madill <jmadill@chromium.org> > Reviewed-by: Jamie Madill <jmadill@chromium.org> TBR=zmo@chromium.org,geofflang@chromium.org,jmadill@chromium.org,kbr@chromium.org,cwallez@chromium.org,yunchao.he@intel.com,jiajia.qin@intel.com,xinghua.cao@intel.com,bryan.bernhart@intel.com,yizhou.jiang@intel.com,yang.gu@intel.com # Not skipping CQ checks because original CL landed > 1 day ago. Bug: 782317 Change-Id: I7e29da683b22fd4640c230598c7b220cfae6a177 Reviewed-on: https://chromium-review.googlesource.com/848133 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Olli Etuaho 8b5e8fdb 2017-12-15T14:59:15 Replace remaining usage of TName with TSymbol TName used to contain just a subset of the information stored in TSymbol. It makes more sense to use TSymbol directly instead of converting it to TName. This also improves type safety a bit by making some functions only take in TVariable or TFunction instead of the more generic TName. BUG=angleproject:2267 TEST=angle_unittests Change-Id: Icb46923c25d33ebbbbc06ddc487da25957dda771 Reviewed-on: https://chromium-review.googlesource.com/829143 Commit-Queue: Olli Etuaho <oetuaho@nvidia.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
jchen10 910a3daf 2017-11-15T09:40:11 ES31 program query: support TRANSFORM_FEEDBACK_VARYING TRANSFORM_FEEDBACK_VARYING corresponds to the set of output variables in the last non-fragment stage of program that would be captured when transform feedback is active. The resources enumerated by this query are listed as specified by the most recent call to TransformFeedbackVaryings before the last call to LinkProgram. This mainly collects these resources for query. BUG=angleproject:1920 TEST=angle_end2end_tests:ProgramInterfaceTest* dEQP-GLES31.functional.program_interface_query.transform_feedback_varying.* Change-Id: I0655b12c6d82cef1b44d4ca57ea55bb60d1f78fb Reviewed-on: https://chromium-review.googlesource.com/770450 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
JiangYizhou 63ba357c 2017-12-06T10:25:40 Enable depth buffer to workaround driver bug on Intel windows Rendering with depth buffer disabled and stencil buffer enabled leads to memory leak if we set viewport a large size on Intel windows platforms. So we enable depth buffer if stencil buffer is enabled to workaround this issue. TEST=gl_test.exe --gtest_filter=GLClearFramebufferTestWithParam/GLClearFramebufferTest.ClearDepthStencil/0 TEST=conformance/rendering/rendering-stencil-large-viewport.html TEST=RenderStencilBufferTest.DrawWithLargeViewport/ES3_D3D11 BUG=782317 Change-Id: Idb185db296f13e3fa897534514e198651a56439f Reviewed-on: https://chromium-review.googlesource.com/809574 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Olli Etuaho 4728bdc8 2017-12-20T17:51:08 Unify looking for symbols with a specific name in the AST Keep only one traverser for looking up symbol nodes by name instead of having two largely identical ones. BUG=angleproject:2267 TEST=angle_unittests Change-Id: I36e906258180e22b7b1353cab79d90266d99fa0e Reviewed-on: https://chromium-review.googlesource.com/836895 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
Jiawei Shao 492b5f51 2017-12-13T09:39:27 ES31: Support struct arrays as Geometry Shader inputs This patch adds the support of struct arrays as valid geometry shader user-defined inputs. Struct arrays are accepted as geometry shader inputs to match the vertex shader outputs that are also declared as structs. BUG=angleproject:1941 TEST=angle_unittests Change-Id: I0b5d545b10e9dda576a1c96d7c93ec2450611e9e Reviewed-on: https://chromium-review.googlesource.com/823622 Commit-Queue: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Olli Etuaho bed35d76 2017-12-20T16:36:26 Don't query names of empty symbols This makes it possible to return a reference from TSymbol::name() instead of a pointer. This is safer since it completely avoids the possibility of a nullptr dereference. An assert is making sure that the function is not being called for empty symbols. BUG=angleproject:2267 TEST=angle_unittests Change-Id: I44279f65989dbb828322843fc0216ba84d91dedf Reviewed-on: https://chromium-review.googlesource.com/836894 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
Olli Etuaho b8cb939f 2017-12-20T14:23:19 Fix tracking variables in folded ternary operators The result of folding a ternary operator may be a TIntermSymbol node where the qualifier doesn't match the qualifier of the variable that the node is referring to. Get the qualifier from the variable instead of directly from TIntermSymbol when collecting variables in CollectVariables or when tracking referenced variables in OutputHLSL. BUG=angleproject:2288 TEST=angle_unittests, angle_end2end_tests Change-Id: If294a7fe9dca50f2ebcea3feff887e72a521d395 Reviewed-on: https://chromium-review.googlesource.com/836893 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
Olli Etuaho f095799b 2017-12-22T11:10:04 Fix accessing the name of a nested struct definition When generating an error message about the struct nesting limit, the code should make sure that the struct definitions are not nested. While nested struct definitions by themselves are also an error, they're not a syntax error so parsing will continue after encountering them. This fixes a regression from commit: Don't allocate name strings for empty symbols. BUG=chromium:797156 TEST=angle_unittests Change-Id: I4149fbe874c0e7ec90e690aec078ccaf7313eab0 Reviewed-on: https://chromium-review.googlesource.com/842643 Commit-Queue: Olli Etuaho <oetuaho@nvidia.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Olli Etuaho b6af22b5 2017-12-15T14:05:44 Store TVariable* in TIntermSymbol instead of storing id This is an intermediate step to only storing a TVariable * in TIntermSymbol instead of copying the name. This makes it possible to get a constant value out of a TIntermSymbol without doing a symbol table lookup. BUG=angleproject:2267 TEST=angle_unittests Change-Id: Ibff588241a4ad4ac330063296273288b20a072c9 Reviewed-on: https://chromium-review.googlesource.com/829142 Commit-Queue: Olli Etuaho <oetuaho@nvidia.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Qin Jiajia 62fcf62a 2017-11-30T16:16:12 ES31: Add DispatchComputeIndirect suport for OpenGL backend BUG=angleproject:2270 TEST=dEQP-GLES31.functional.compute.indirect_dispatch.* Change-Id: Id062a80188b2a37f28833aaae8e6d31bac382276 Reviewed-on: https://chromium-review.googlesource.com/802763 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Yuly Novikov c6faa974 2017-12-20T19:50:10 Skip UniformBufferTest.SimpleBindingChange on Mac NVIDIA GL Unskip UniformBufferTest.SimpleBufferChange, which was skipped by mistake instead of this test in https://chromium-review.googlesource.com/833287 BUG=angleproject:2287 Change-Id: Id79821b26ad38ed07d1193b717ad222df3bb58fe Reviewed-on: https://chromium-review.googlesource.com/838262 Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Commit-Queue: Yuly Novikov <ynovikov@chromium.org>
Xinghua Cao 26143fdd 2017-11-01T18:19:05 ES31: Support bindImageTexture on Texture2D for compute shaders on D3D BUG=angleproject:1987 TEST=angle_end2end_tests Change-Id: I3b0afb441a41dbd7f204b1d1bba7884c8d203ce1 Reviewed-on: https://chromium-review.googlesource.com/749004 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
JiangYizhou 10d41397 2017-12-18T18:13:36 Fix addDummyTextureNoRenderTarget workaround memory leak Add dummy attachment in FramebufferD3D as a private member and release the dummy attchment in destory of FramebufferD3D. BUG=angleproject:2282 TEST=FramebufferTest_ES31.RenderingLimitToDefaultFBOSizeWithNoAttachments/ES3_1_D3D11 TEST=dEQP-GLES31.functional.fbo.no_attachments.* Change-Id: I3a17282ef132185fbc25f4076f624e53661d4b20 Reviewed-on: https://chromium-review.googlesource.com/831847 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Xinghua Cao 89c422ad 2017-11-29T18:24:20 ES31: Support memoryBarrier and memoryBarrierRegion APIs BUG=angleproject:2280 TEST=dEQP-GLES31.functional.compute.basic.image_barrier_single dEQP-GLES31.functional.compute.basic.image_barrier_multiple dEQP-GLES31.functional.compute.basic.ssbo_cmd_barrier_single dEQP-GLES31.functional.compute.basic.ssbo_cmd_barrier_multiple dEQP-GLES31.functional.synchronization.* Change-Id: If14debab21247dc4b446e86d1642fbc9376b6dd7 Reviewed-on: https://chromium-review.googlesource.com/798803 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Olli Etuaho 37385e11 2017-12-19T11:50:30 Emulate tanh on HLSL This ensures mathematically correct results on large inputs. BUG=chromium:795269 BUG=angleproject:1093 TEST=dEQP-GLES3.functional.shaders.builtin_functions.precision.tanh* Change-Id: Id5ba05a3284e51a34f196b419abef0f4a41551e0 Reviewed-on: https://chromium-review.googlesource.com/832463 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
Olli Etuaho ae4dbf32 2017-12-08T20:49:00 Don't allocate name strings for empty symbols This removes unnecessary memory allocations. BUG=angleproject:2267 TEST=angle_unittests Change-Id: Ide575ea19ab2f8e9fc93092490f1352efa6024a3 Reviewed-on: https://chromium-review.googlesource.com/817415 Commit-Queue: Olli Etuaho <oetuaho@nvidia.com> Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Yuly Novikov f2afccca 2017-12-18T20:13:15 Skip UniformBufferTest.SimpleBufferChange on Mac NVIDIA GL BUG=angleproject:2287 Change-Id: I1a5895a9b5c173b221da6ac511c05d8b7d646a5d Reviewed-on: https://chromium-review.googlesource.com/833287 Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Commit-Queue: Yuly Novikov <ynovikov@chromium.org>