Log

Author Commit Date CI Message
Jamie Madill 33bb7c42 2017-09-09T23:32:51 ProgramD3D: Use more UniformTypeInfo. Instead of storing a type GLenum, store a pointer into the type info table. This makes looking up some values a bit easier. Also includes some micro-optimizations. Improves the score of the uniforms micro-benchmark by about 12.4% on a local Windows 10 machine. BUG=angleproject:1390 Change-Id: I35f7f1c7bb3cf2c62d737b494dc56ff61ea2d1fb Reviewed-on: https://chromium-review.googlesource.com/659221 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill a9459dbc 2017-09-09T23:32:52 Fix EXTERNAL and 2D_ARRAY sampler type info. The type info tables were incorrectly using some information. This bug was uncovered after trying to use the tables more. BUG=angleproject:1390 Change-Id: I5eae01f51269bab05746a14bd3caabb614be210a Reviewed-on: https://chromium-review.googlesource.com/659220 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jamie Madill 0e7f1736 2017-09-09T23:32:50 D3D: Only scan cached shader executable lists once. Any time we would query ProgramD3D for a particular vertex or pixel shader, we would iterate over all the cached shaders of the program looking for the matching input or output layout signature. This change makes it so we only compute the index of the matching shader once, and subsequent calls will re-use the shader index. This should speed up the draw call benchmarks. Also include a fix to the Serial class that initializes a Serial value to an invalid sentinel value. This ensures that comparing any other Serial (including another invalid serial) to the invalid serial will return not-equals. BUG=angleproject:1155 Change-Id: I7d913bf08d0bedf6155eae0661b2a5fa94565cc9 Reviewed-on: https://chromium-review.googlesource.com/648730 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill eb335950 2017-09-09T23:32:49 D3D11: Only update swizzles after a state change. Triggers the swizzle update whenever a new texture is bound, or when a subImage call triggers a swizzle cache update. BUG=angleproject:1387 Change-Id: Ia2a82126a621d8a643f715ea7e4a9c35b97e0a18 Reviewed-on: https://chromium-review.googlesource.com/648729 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill af4ffe0a 2017-09-09T23:32:48 D3D11: Implement dirty bits for texture updates. BUG=angleproject:1387 Change-Id: I5f759c3dc60b53a5d4f8a1dd1f4a1d3d5330bfda Reviewed-on: https://chromium-review.googlesource.com/648487 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill 92515f44 2017-09-09T23:32:48 Move swizzling and program update to StateManager11. This makes it in a centralized location where it can work with dirty bits. BUG=angleproject:1387 Change-Id: I3bfeb53c265d1679f6b8556941c1d9d77747aa24 Reviewed-on: https://chromium-review.googlesource.com/648486 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill 39967e4e 2017-09-09T23:32:47 GL: Use dirty bits for texture and sampler bindings. In StateManagerGL, use the texture, sampler and program binding dirty bits to set a dirty bool that is checked once per draw call. This completes the GL back-end texture dirty bits. BUG=angleproject:1387 Change-Id: I619a89bf98ded5e55353f6ca44e814605f7ce492 Reviewed-on: https://chromium-review.googlesource.com/648055 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill 06ef36b9 2017-09-09T23:32:46 Add top-level state sync for Samplers. This also reformats the Sampler class to use a shared state struct with the implementation. It removes the call to sync the sampler state from the StateManagerGL::setGenericShaderState method, since it should all be handled at the front-end now. Also rename 'syncImplState' to 'syncState' methods. BUG=angleproject:1387 Change-Id: I5f0219b719aee99aaaa486ec188b2af0c9128e6a Reviewed-on: https://chromium-review.googlesource.com/648054 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill 81c2e253 2017-09-09T23:32:46 Add top-level dirty bits for texture and samplers. These will have to be fleshed out in the back-ends. Also currently uses a single bit for all the bindings, and we can extend this to more fine-grained updates in the future. This patch implements top-level updates for texture completeness. Sampler completeness caches are removed from the Texture class, and replaced by a cache in the gl::State class. The State class also keeps a channel binding to the bound textures so it can be notified when textures might change from complete <-> incomplete. In future CLs we skip updating back-ends if texture state doesn't change. BUG=angleproject:1387 Change-Id: If580b4851303c86f3240e62891f5f6047eefb6a2 Reviewed-on: https://chromium-review.googlesource.com/648053 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jamie Madill ef97c613 2017-09-09T23:34:18 Roll GYP for VS2017 project support. Also includes a ToLower string helper for a VS2017 warning fix. https://chromium.googlesource.com/external/gyp.git/+log/aae1e3efb50786df2..c6f471687407bf28d BUG=angleproject:1569 Change-Id: Iaf8a091a24d937db3adb242f05c8a5c9d2b03b0f Reviewed-on: https://chromium-review.googlesource.com/659219 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Frank Henigman <fjhenigman@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Martin Radev 1aa66bc7 2017-09-06T14:53:23 Add ANGLE_multiview sample The patch adds a sample which makes use of the ANGLE_multiview extension to draw the same scene to two views each having its own camera matrix. BUG=angleproject:2062 TEST=angle_end2end_tests Change-Id: I4b765a189047bf219a05e98b032ad95efbb36905 Reviewed-on: https://chromium-review.googlesource.com/655166 Commit-Queue: Martin Radev <mradev@nvidia.com> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill 6f0c17c7 2017-09-08T13:05:06 Update docs to mention Win 10 SDK is required. Uncovered this after reports to the Google group. Also fix a minor documentation issue with Windows store. BUG=angleproject:1944 BUG=angleproject:1255 Change-Id: Ib4fc784a818cf65e280630db483987cc01366994 Reviewed-on: https://chromium-review.googlesource.com/657881 Reviewed-by: Jamie Madill <jmadill@chromium.org>
Olli Etuaho ec3a9cbb 2017-09-07T12:18:01 Only support GL_OVR_multiview extension variant The WebGL spec proposal was changed so that only GL_OVR_multiview extension name is supported, instead of having two variants OVR_multiview and OVR_multiview2. We're only supporting the WebGL version of the shader extension, so we drop compiler support for GL_OVR_multiview2. Shader restrictions were also removed from the WebGL spec, so no special validation for how ViewID_OVR gets used is needed. Tests that were testing for the shader restrictions are either removed or changed from negative tests to positive tests. BUG=angleproject:1669 TEST=angle_unittests Change-Id: I83f92b879376d41b727b5aca419fd75fb6f53477 Reviewed-on: https://chromium-review.googlesource.com/654608 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
Martin Radev 15c3406a 2017-09-07T17:10:09 Restructure InstanceID initialization to fix HLSL warning This patch casts gl_InstanceID to uint before doing division by the number of views to circumvent the HLSL compiler's warning on performance degradation. BUG=angleproject:2062 TEST=angle_end2end_tests Change-Id: I326530ee112f34f82becdec5239edd5054c4104f Reviewed-on: https://chromium-review.googlesource.com/655298 Commit-Queue: Martin Radev <mradev@nvidia.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Yuly Novikov 95644f92 2017-09-07T20:58:49 Make ScopedIgnorePlatformMessages work Maybe not the most elegant way, but I'd like to get the bot green. BUG=angleproject:2122 Change-Id: Ib8f92034a8f42a42efd18c94a3623948490b7911 Reviewed-on: https://chromium-review.googlesource.com/656717 Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Commit-Queue: Yuly Novikov <ynovikov@chromium.org>
Yuly Novikov 1de29aba 2017-09-07T18:07:23 Skip MultiviewRenderTest.FlatInterpolation on Win Intel D3D11 MultiviewRenderTest.FlatInterpolation/ES3_D3D11_force_geom_shader_layered MultiviewRenderTest.FlatInterpolation/ES3_D3D11_force_geom_shader_side_by_side fail on Win10 Intel HD 630. BUG=angleproject:2062 Change-Id: I1a0c19b89f0813efe7eef5c64dc510ad750916f9 Reviewed-on: https://chromium-review.googlesource.com/656047 Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Commit-Queue: Yuly Novikov <ynovikov@chromium.org>
Jamie Madill fe8b5989 2017-09-07T17:00:18 Program: Fixed unreferenced Samplers. The calculation for unreferenced was incorrect - it checked the 'used' flag of the uniform location, but if samplers started at index zero, all the unused uniforms were to be considered valid samplers. Instead, initialize the uniform index to INVALID_INDEX. This bug was uncovered after doing work on the Texture dirty bits. BUG=angleproject:1387 Change-Id: I5e404e367caed38368bcc0e581699ae2c911bcc9 Reviewed-on: https://chromium-review.googlesource.com/655930 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Corentin Wallez e98e16ea 2017-08-25T14:55:20 Update gpu_test_expectations and use angle_gpu_info_util This is to have the new "OS" for MacOS Sierra. Several types were introduced in angle_config.h to minimize the angle-mods.patch to make it easier to update in the future. BUG=angleproject:2137 Change-Id: I7a98c5cb48d424f83eb39763eba0e51852a9b98f Reviewed-on: https://chromium-review.googlesource.com/636202 Commit-Queue: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill 218ffc49 2017-09-07T11:32:59 SwapChain11: Create SRV copy texture lazily. We would allocate this texture for devices that don't need it. Instead do this lazily. This was showing up in the profiles for the MotionMark benchmark, possibly due to re-creating the surface. BUG=angleproject:1155 Change-Id: I28b5eda29e21899fc8afef054e1b8063e3cc2e00 Reviewed-on: https://chromium-review.googlesource.com/655479 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jamie Madill 3667dbd6 2017-09-07T12:48:42 D3D11: Cache multisample resolve texture. This was showing up in profiles of the MotionMark benchmark, possibly due to re-creating the canvas many times. BUG=angleproject:1155 Change-Id: Id857b89770b846881fb381f7c3ab70c07b924271 Reviewed-on: https://chromium-review.googlesource.com/655478 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jamie Madill 3ed60424 2017-09-07T11:32:52 Test using the same texture with multiple samplers. This covers a regression introduced with texture dirty bits. BUG=angleproject:1387 Change-Id: Ic8112718c185298ef54ec5a6f6ed2cd519e010d6 Reviewed-on: https://chromium-review.googlesource.com/653586 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Martin Radev fca78130 2017-09-06T13:51:39 Extend multiview perf tests to cover all extension code paths The ANGLE_multiview extension can be supported with three possible code paths - through view being selected in the vertex shader on D3D and OpenGL, and through the view being selected in the geometry shader on D3D only. This patch extends the multi-view performance tests to benchmark these three different code paths. BUG=angleproject:2062 TEST=angle_end2end_tests Change-Id: I443e4db64a95eede1142718a43a095ee5a03738c Reviewed-on: https://chromium-review.googlesource.com/652466 Commit-Queue: Martin Radev <mradev@nvidia.com> Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Olli Etuaho <oetuaho@nvidia.com>
Geoff Lang a0d38875 2017-09-06T15:32:03 Don't create SRVs for multisampled depth stencil textures in FL10.0. Renderer11::createRenderTarget already fixed this issue but it also is exposed in SwapChain11::resetOffscreenDepthBuffer now that multisampled surfaces are supported in ANGLE. BUG=angleproject:2136 Change-Id: I978666ebc1bb3db14ddf69954d7eb750391bf7a8 Reviewed-on: https://chromium-review.googlesource.com/653779 Commit-Queue: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Martin Radev 7cadfcc7 2017-09-07T16:38:57 Change ANGLE_multiview's enum values The enums introduced by the ANGLE_multiview extension are changed to use the values reserved specifically for ANGLE. BUG=angleproject:2062 TEST=angle_end2end_tests Change-Id: Ib668f2e0e9022442a432b1a04050aeb2ff82a3d1 Reviewed-on: https://chromium-review.googlesource.com/654864 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Martin Radev <mradev@nvidia.com>
Martin Radev 61e710b6 2017-09-05T11:59:52 GL: Optimize multi-view layered Clear* commands Until this patch multi-view layered framebuffers used to be cleared by attaching a single layer of each attachment to a framebuffer and calling the Clear* command for that internal framebuffer. According to the GL 4.1+ specifications, Clear* commands clear all of the layers of an attached 2D texture array. If all of the layers are active for a multi-view layered framebuffer, then we can directly call the corresponding Clear* command instead of iterating over each layer and clearing it. BUG=angleproject:2062 TEST=angle_end2end_tests Change-Id: Ie4dfd9fff47715b502f358272bfc47c0373c4e91 Reviewed-on: https://chromium-review.googlesource.com/649209 Commit-Queue: Martin Radev <mradev@nvidia.com> Reviewed-by: Olli Etuaho <oetuaho@nvidia.com>
Martin Radev c1d4e550 2017-08-21T12:01:10 D3D11: Select view in vertex shader View selection can happen in the vertex shader through the optional feature VPAndRTArrayIndexFromAnyShaderFeedingRasterizer. BUG=angleproject:2062 TEST=angle_end2end_tests Change-Id: Iaf65685e04f828b0936295fea867f6f6cbe69bee Reviewed-on: https://chromium-review.googlesource.com/628419 Commit-Queue: Martin Radev <mradev@nvidia.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Corentin Wallez 630d558f 2017-09-06T12:45:38 TextureRectangleTest: Fix RAII ignore lifetime BUG=angleproject:2122 Change-Id: Ia51c139197e1b90e54505278d301ae8ac7dab53d Reviewed-on: https://chromium-review.googlesource.com/653240 Commit-Queue: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Geoff Lang cecab592 2017-09-06T11:13:39 Don't use native D3D11.1 formats unless they support enough samples. The MSDN documentation states that BGRA4, RGB5A1 and RGB565 should all support 4 samples with DXGI 1.2 and D3D11.1 but some drivers appear to not have full support. Fall back to RGBA8 render targets when the driver cannot support at least 4 samples for ES3 feature levels. BUG=761489 Change-Id: I6bcd417700f1188945e8032ca6a64c4fbb2bc8a8 Reviewed-on: https://chromium-review.googlesource.com/652828 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Geoff Lang <geofflang@chromium.org>
Kenneth Russell 8cf8f7b0 2017-09-06T10:00:14 Remove linux_angle_chromeos_rel_ng from default bots. This trybot was broken during the removal of the Linux ChromiumOS Builder from chromium.gpu.fyi and is blocking all ANGLE CQ jobs. BUG=762377 TBR=dpranke@chromium.org, jmadill@chromium.org NOTRY=true Change-Id: Ibc3ccf3af842ee8b040014732d179573f286afad Reviewed-on: https://chromium-review.googlesource.com/653244 Commit-Queue: Kenneth Russell <kbr@chromium.org> Reviewed-by: Kenneth Russell <kbr@chromium.org>
Martin Radev 74a0000f 2017-07-11T11:27:09 Request a D3D11.1 device and D3D11.3 context The patch extends Renderer11 so that a D3D11.1 device and D3D11.3 context can be created. This is necessary for using the D3D11.3 feature called VPAndRTArrayIndexFromAnyShaderFeedingRasterizer. BUG=angleproject:2062 BUG=angleproject:2145 TEST=angle_end2end_tests Change-Id: I84c761b2897d7d911686f5b6d79cb93e233015a0 Reviewed-on: https://chromium-review.googlesource.com/591448 Reviewed-by: Geoff Lang <geofflang@chromium.org>
Corentin Wallez 1a1ae0f8 2017-09-05T15:11:06 SystemInfo: Find primary with EnumDisplayDevices Without DXGI, EnumDisplayDevices is the only way to get the primary device. Previously the code would work on most configs with a combination of AMD, Intel and NVIDIA GPUs but would fail on more esoteric system. Like our try bots that have Matrox GPUs. BUG=angleproject:1874 BUG=angleproject:2137 Change-Id: Ie2dfbb559001ccad2fd5b8a8fd6436e0fba9d003 Reviewed-on: https://chromium-review.googlesource.com/651629 Reviewed-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill ad6e2b6a 2017-09-03T16:28:29 D3D11: Fix memory allocation in markLevelDirty. This would drastically slow down some framebuffer updates. BUG=angleproject:1155 Change-Id: Ibff428c49bd5127a101bce46cc1df355f4542ccf Reviewed-on: https://chromium-review.googlesource.com/649986 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill 7d1f5c60 2017-09-02T15:32:15 Sync dirty objects before Context dirty bits. This allows the dirty objects to notify the context if something needs to be communicated down to the ContextImpl. In this case it means a dirty Texture can notify the Context that it needs to re-apply texture bindings. BUG=angleproject:1387 Change-Id: I162115e51112d1c27c0dab621d1b3d14446af96d Reviewed-on: https://chromium-review.googlesource.com/648052 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jamie Madill 8693bdb8 2017-09-02T15:32:14 Add a few missing dirty bit cases. Discovered some of these while investigating Texture dirty bits. BUG=angleproject:1387 Change-Id: I8b170462bfd283e4b0f9d47b7f7ddbaa7957914d Reviewed-on: https://chromium-review.googlesource.com/648051 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Corentin Wallez 7d738e26 2017-09-05T12:02:10 Disable platform message when expecting OOM BUG=angleproject:2122 Change-Id: I99eed52b1f12004f0bab3f94bd3acddda8dafd69 Reviewed-on: https://chromium-review.googlesource.com/650526 Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Corentin Wallez <cwallez@chromium.org>
Jiajia Qin 8a7b3a0c 2017-08-25T16:05:48 Reland 'Remove IndexRange retrieving in validation' This change adds GL_KHR_robust_buffer_access_behavior support. The old change is in https://chromium-review.googlesource.com/c/angle/angle/+/607413 BUG=755897, angleproject:1393, angleproject:1463 Change-Id: I04a1132c3ae8d3a766194df61c4ff7bf0b084f03 Reviewed-on: https://chromium-review.googlesource.com/640750 Commit-Queue: Geoff Lang <geofflang@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Martin Radev 72b4e1e5 2017-08-31T15:42:56 D3D11: Add support for multiview layered rendering A branch is added in the geometry shader to select either the viewport, or texture layer which is being rendered to based on the value of a uniform in the driver constant buffer. Using this approach there is no need for separate programs for side-by-side and layered rendering. BUG=angleproject:2062 TEST=angle_end2end_tests Change-Id: I66701164ff02a851c13695d5409f8ad350534e69 Reviewed-on: https://chromium-review.googlesource.com/645547 Commit-Queue: Martin Radev <mradev@nvidia.com> Reviewed-by: Olli Etuaho <oetuaho@nvidia.com>
Dirk Pranke b5c5fb1b 2017-09-02T15:17:46 Remove linux_chromium_chromeos_ozone_rel_ng from the CQ. We're removing this bot as redundant now in Chromium. Change-Id: I35f00bff4e62780609f869c447839aa48b74b46c R: jmadill@chromium.org Bug: crbug.com/743212 Reviewed-on: https://chromium-review.googlesource.com/648654 Reviewed-by: Jamie Madill <jmadill@chromium.org>
Corentin Wallez 487653b1 2017-09-01T17:17:55 Don't divide in the validation of DrawElements BUG=angleproject:1671 Change-Id: I58dd30d0aaffd1a776aa14a04011cbdd72181bf2 Reviewed-on: https://chromium-review.googlesource.com/648356 Commit-Queue: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 6ab833ad 2017-09-01T16:37:53 Add more comparators to Optional.h. BUG=angleproject:1387 Change-Id: If3fc67f99716b2e5e6a8b0ffd139a07a06cdcab8 Reviewed-on: https://chromium-review.googlesource.com/648050 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jamie Madill 134f93d1 2017-08-31T17:11:00 D3D: Small optimizations to uniform updates. Uses more of the type info table for updates. Also special-case clamping when uniform count == 1. Improves the speed of the d3d11 uniform stress test by ~20%. BUG=angleproject:1390 Change-Id: I6707c67db84c94a28b1519b0bbee5d28fe38b189 Reviewed-on: https://chromium-review.googlesource.com/646828 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Corentin Wallez edd5981f 2017-08-07T14:36:41 TextureRectangleTest: allow OOM on max size test. BUG=2122 Change-Id: I82bed7215142b62b321c9676972386b74a9efa92 Reviewed-on: https://chromium-review.googlesource.com/604211 Commit-Queue: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang fb2a871c 2017-09-01T10:07:36 Work around VC++ 2017 compiler bug A code-gen bug was found in 15.3.2 (VC++ 2017 Update 3.2) that causes test failures due to one loop being skipped. Attempts to disable optimizations for just the affected function failed so optimizations must be disabled at the end of the source file, which seems to cause all template functions and compiler generated functions to have optimizations disabled. A VS bug has been filed and cross-linked. BUG=759402 Change-Id: Ida765a47234a63bad48e6a4e910f3b82919d6be9 Reviewed-on: https://chromium-review.googlesource.com/647313 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Geoff Lang <geofflang@chromium.org>
Jamie Madill f00f7ffe 2017-08-31T14:39:15 Add a Uniform type info table. Currently most uniform type info is determined by switching on the uniform type. Some values are computed from other values, which can result in three or more switch statements plus some multiplies or other math. This patch attempts to improve the speed by pre computing necessary values into constant static tables. Improves performance by about 7% in a uniform stress test. BUG=angleproject:1390 Change-Id: I29bef259a17f6d6536171ade4950e2d712bfd39c Reviewed-on: https://chromium-review.googlesource.com/643791 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Geoff Lang bb6e6643 2017-08-21T10:57:15 Implement EGL_surfaceless_context for Android/ChromeOS and optimize eglMakeCurrent BUG=angleproject:1651 Change-Id: I13c1a669d83098e22c0d7fb003d13beacc20c4ae Reviewed-on: https://chromium-review.googlesource.com/623947 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Commit-Queue: Geoff Lang <geofflang@chromium.org>
Olli Etuaho bb2bbfbb 2017-08-24T15:43:33 Refactor GLSL array length method parsing This prepares for accepting arbitrary expressions as the "this" node of the array length method. BUG=angleproject:2142 TEST=angle_unittests Change-Id: I728adb6e76d2779dedbabfaeec7d096872e0d00d Reviewed-on: https://chromium-review.googlesource.com/633945 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
Jamie Madill 561ed3ae 2017-08-31T16:48:09 D3D: Keep a single dirty bit for uniforms. This simplifies uniform management in D3D11. It will also facilitate further optimizations. Improves performance in a uniforms stress test by ~13% on a test machine. (UniformsBenchmark.Run/d3d11_null_400_vec4) BUG=angleproject:1390 Change-Id: Iba2c15d420396aa8fb4e8c451cba2b4dde7b4b77 Reviewed-on: https://chromium-review.googlesource.com/623930 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jamie Madill 851edac7 2017-08-31T14:41:47 GLES3: Use more compact entry point style. This migrates to the new generation style used in GLES2. BUG=angleproject:1309 Change-Id: I43e9d33a0d7c5b1786452895855ff2bfbf82f139 Reviewed-on: https://chromium-review.googlesource.com/638311 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jamie Madill fa08cae7 2017-08-31T14:39:13 Make perf_test_runner Python 2.7 and 3 compatible. BUG=None Change-Id: I915c99f21dc879a8e63955cd6a3dd892d05bbf5f Reviewed-on: https://chromium-review.googlesource.com/646590 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jamie Madill be5e2ec3 2017-08-31T13:28:28 Remove uniform memory copy from GL front-end. This moves the uniform query to the back-end. In D3D, this requires a bit more redesign, especially for matrix uniforms. Gives about a 10% speed improvement in the GL/NULL uniforms stress test on Windows (UniformsBenchmark.Run/gl_null_400_vec4). BUG=angleproject:1390 Change-Id: Idac22a77118e9e94d2f28c585e31ff0bc785ba94 Reviewed-on: https://chromium-review.googlesource.com/623929 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Olli Etuaho 6ee26d7a 2017-08-31T14:23:20 Fix linking of non-existent XFB varyings with gl_ prefix Non-existent XFB varyings with the gl_ prefix used to pass linking on the D3D11 backend. On a debug build they would cause an assert. Fix these issues. BUG=angleproject:2141 TEST=angle_end2end_tests Change-Id: Iecc3d03823d02700d6b28c44d77df7a2f9e70a5b Reviewed-on: https://chromium-review.googlesource.com/645747 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
Olli Etuaho c634a637 2017-05-18T14:09:49 Remove webgl_ prefix from emulated function names The prefix is unnecessary now that user-defined names are prefixed in both GLSL and HLSL output. Removing the prefix makes compiler output a bit simpler to read. BUG=angleproject:2038 TEST=angle_unittests Change-Id: I9ffc508f50d6146a2d85798875c88e2c385b83fe Reviewed-on: https://chromium-review.googlesource.com/508730 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
Corentin Wallez af11b53a 2017-08-30T15:51:36 FramebufferNULL::readPixels: write pixels for tests BUG=602737 Change-Id: I8c24985358dcd297cb437c501b7a3944e36d98de Reviewed-on: https://chromium-review.googlesource.com/644210 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Corentin Wallez <cwallez@chromium.org>
Martin Radev e49058e7 2017-08-31T15:43:43 D3D11: Enable multiview performance tests The patch adds D3D11 as a testable platform to the multiview performance tests. BUG=angleproject:2062 TEST=angle_perftests Change-Id: I2266073860fd53f546ce9a414bc343b582c77f70 Reviewed-on: https://chromium-review.googlesource.com/645849 Reviewed-by: Olli Etuaho <oetuaho@nvidia.com> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Commit-Queue: Corentin Wallez <cwallez@chromium.org>
Olli Etuaho 855d964b 2017-05-17T14:05:06 Prefix user-defined names in GLSL output Now user-defined names are prefixed by _u in GLSL output in case name hashing is not on. Internal names such as names of temporary variables created in AST transformations are written out as such. This makes handling of internal function names and internal variable names consistent. It also removes the possibility of name conflicts between user-defined names and internal names in case name hashing is not on. In the same vein, it makes it safe to use GLSL reserved words that are not reserved in ESSL as variable names in case name hashing is not on. This also makes the GLSL output more consistent with how names are handled in HLSL output. Name hashing code is shared between VariableInfo and OutputGLSLBase to ensure names are handled consistently in both. The name that's used in the shader source for a given interface variable is written out to ShaderVariable::mappedName. An exception needs to be made for identifiers close to the length limit, since adding any prefix would take them over the limit. But they can be just written out as such, since we don't have any builtins or ANGLE internal variables that have as long names and could create a conflict. BUG=angleproject:2139 BUG=angleproject:2038 TEST=angle_unittests, angle_end2end_tests, WebGL conformance tests Change-Id: Id6ed052c4fab2d091227dc9a3668083053b67a38 Reviewed-on: https://chromium-review.googlesource.com/507647 Commit-Queue: Olli Etuaho <oetuaho@nvidia.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Martin Radev ced5c86c 2017-08-17T16:05:29 D3D11: Handle multi-view Draw* calls Because the ANGLE_multiview extension uses instancing to multiply geometry for each view, Draw* calls with an active multiview program have to be handled in the follwing way: 1) Convert non-instanced Draw calls to their instanced versions. 2) Multiply the number of instances in an instanced Draw call by the number of views. The patch also applies the viewport offsets to the viewport and scissor rectangle and propagates the computed viewports and scissors to the D3D11 runtime. BUG=angleproject:2062 TEST=angle_end2end_tests Change-Id: I8b4295c95c2cc0c1046c67e1fb1a782a46703292 Reviewed-on: https://chromium-review.googlesource.com/618331 Commit-Queue: Martin Radev <mradev@nvidia.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Martin Radev 0abb7a2a 2017-08-28T15:34:45 Update multiview state on program executable change Relinking the active program can change its number of views and the state has to be correspondingly adjusted. BUG=angleproject:2062 TEST=angle_end2end_tests Change-Id: I20102a428d7566a8cec5d81eeaa55980665812f4 Reviewed-on: https://chromium-review.googlesource.com/637994 Commit-Queue: Martin Radev <mradev@nvidia.com> Reviewed-by: Olli Etuaho <oetuaho@nvidia.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill d28758de 2017-08-30T15:32:48 D3D11: Re-enable updateVertexBuffer dirty bits. In some cases, when the app would call glBufferSubData to do a small data update in an existing vertex buffer, the sync code would not flush out the data to the native D3D11 buffer from the temporary staging buffer. Fix this problem by notifying the VertexArray11 class when buffer data is updated. Note that in the future we can improve this by using a different update notification for when the buffer data changes and when the underlying storage changes. For now take a very broad approach. BUG=angleproject:1156 Change-Id: I2e0fabc97c1f1d5a14d609247e61c602e9a5a85f Reviewed-on: https://chromium-review.googlesource.com/644208 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jamie Madill 57ae8c16 2017-08-30T12:14:29 GLES3: Auto-generate entry points source. Lots of incidental fixes to formatting and naming. Adds specific default return type overloads for ClientWaitSync and GetUniformBlockIndex. BUG=angleproject:1309 Change-Id: Id67cbc0b19fc2cb94c859ab8390f1ff36b1bbd25 Reviewed-on: https://chromium-review.googlesource.com/637203 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jiawei Shao e8ef2bc4 2017-08-29T13:38:57 Add compile error on using inputs with interpolation qualifier as l-value This patch intends to fix a compile error in ANGLE GLSL compiler when parsing an expression with inputs which has interpolation qualifiers ('flat', 'smooth' and 'centroid'). The compiler should report a compile error when a shader input with interpolation qualifier is used as a l-value. BUG=angleproject:2140 TEST=angle_unittests Change-Id: I7c059d53bf001ac31d34519a98e5289797833ce7 Reviewed-on: https://chromium-review.googlesource.com/640075 Commit-Queue: Olli Etuaho <oetuaho@nvidia.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Martin Radev 7c2e6a96 2017-08-28T11:13:16 Do not forward multi-view fields to backend on detach The patch fixes an unexposed bug in FramebufferGL which would pass an incorrect multi-view state to StateManagerGL on texture detachment. The bug is not exposed because upon a subsequent syncing step the correct state is queried and restored from the framebuffer state. BUG=angleproject:2062 TEST=angle_end2end_tests Change-Id: Ie0e783c53e87497b3673ef87ab9c53c3c04054a7 Reviewed-on: https://chromium-review.googlesource.com/636369 Commit-Queue: Martin Radev <mradev@nvidia.com> Reviewed-by: Olli Etuaho <oetuaho@nvidia.com> Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Martin Radev 1ba9b85a 2017-08-29T14:08:41 HLSL: Declare gl_ViewID_OVR as fragment input if extension is enabled Previously a pixel shader would have gl_ViewID_OVR as input only if it were used in it. However, in a case with a user-specified varying and no usage of gl_ViewID_OVR in the pixel shader, a link-time error would occur whenever the geometry and pixel shaders were to be linked as the order of parameters in the signatures would not match. The patch addresses this by always having gl_ViewID_OVR declared as pixel shader input if the OVR_multiview(2) shader extension is enabled. The patch does not provide any tests because draw commands are not yet supported at this stage. BUG=angleproject:2062 TEST=angle_end2end_tests Change-Id: Ia154fd53cbf3847cfaf0504e4ec44632b9cd5327 Reviewed-on: https://chromium-review.googlesource.com/641151 Commit-Queue: Martin Radev <mradev@nvidia.com> Reviewed-by: Olli Etuaho <oetuaho@nvidia.com> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill 77d4d4da 2017-08-29T17:31:32 D3D11: Temporarily disable vertex array dirty bits. In some cases we could end up with bufferSubData updates being left in staging buffers during a draw call. Currently we rely on InputLayoutCache::applyVertexBuffers to flush all pending buffer updates, but this could be done in VertexArray11::syncState, or even in the draw call sync state. BUG=angleproject:1156 BUG=chromium:759403 Change-Id: I7019425f874414bf5857b825ddae7e022750c759 Reviewed-on: https://chromium-review.googlesource.com/642057 Reviewed-by: Jamie Madill <jmadill@chromium.org>
Brandon Jones ed5b46f1 2017-07-21T08:39:17 Add additional ES2 and WebGL 1.0 Validation Adds validation for various cases. Adds corresponding unit tests. Change-Id: I9451d286bcf2d6fa32de495e5d0bdec1eb5c955d Reviewed-on: https://chromium-review.googlesource.com/633157 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jamie Madill 2e29b13d 2017-08-28T17:22:11 Fix some default return values in auto-gen. We don't generally test for the default return values of function calls that have validation errors, but the auto-gen script might not have been returning things correctly. For GLint values, default to returning -1 instead of zero. BUG=angleproject:1309 Change-Id: I736b5a7ef9b50ca1509087fe933c4a4e526531d8 Reviewed-on: https://chromium-review.googlesource.com/636522 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Olli Etuaho b79b3f96 2017-07-21T14:23:21 Assign symbol ids in RemoveDynamicIndexing Assign consistent symbol ids to out base, index and value nodes that get created in RemoveDynamicIndexing. Some utility functions in RemoveDynamicIndexing have also now become unnecessary now that there are better generic helpers and node constructors. BUG=angleproject:1490 TEST=angle_unittests, angle_end2end_tests Change-Id: I98891e448b85d51518dbf3156ec93f9661def57e Reviewed-on: https://chromium-review.googlesource.com/580954 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
JiangYizhou 3db4072a 2017-08-28T17:59:13 Skip end2end test case due to failure on D3D Intel GPU Test case FramebufferTest_ES31.RenderingLimitToDefaultFBOSizeWithNoAttchments failed on Intel gpu on D3D. BUG=angleproject:1594 Change-Id: Icda5179513b697b41aeb39bffad23fdb1977b55f Reviewed-on: https://chromium-review.googlesource.com/637750 Commit-Queue: Geoff Lang <geofflang@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Martin Radev 14b2126e 2017-08-25T13:54:37 Relax multi-view end-point validation on detach Passing invalid arguments to the multi-view end-points should not generate an error if a texture is being detached from the framebuffer. BUG=angleproject:2062 TEST=angle_end2end_tests Change-Id: I22e1ed13b64db046724031d0189612d5e111dcac Reviewed-on: https://chromium-review.googlesource.com/635166 Commit-Queue: Martin Radev <mradev@nvidia.com> Reviewed-by: Olli Etuaho <oetuaho@nvidia.com> Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Olli Etuaho 39e78122 2017-08-29T14:34:22 Fix assert when linking nonexistent transform feedback varying linkValidateTransformFeedback needs to be run after packing varyings, since it relies on nonexistent varyings being already handled. BUG=angleproject:2141 TEST=angle_end2end_tests on debug Change-Id: I6178348f05a19070a2d17caf90f732df9eb06b9d Reviewed-on: https://chromium-review.googlesource.com/641152 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
Jamie Madill 54164b0c 2017-08-28T15:17:37 Add getUniform impl methods. This will let us remove some of the uniform data management code in the GL front-end, and simplify the GL back-end. It will also enable us to implement uniform data more efficiently in the D3D11 back-end, and probably Vulkan back-end later. This also implements a new impl method for the ProgramGL class to flag optimized-out uniforms as no longer used, post-link. This is important because otherwise the optimized uniforms get assigned valid locations, and then the getUniform calls are expected to succeed. We also use a workaround for uniform value queries for the GL back-end. It seems as though some drivers (seen on NVIDIA and AMD) may not properly clamp to the maximum representable integer value when querying out-of-range floating point values. Work around this by always calling the driver with the proper type and then casting the value in ANGLE. BUG=angleproject:1390 Change-Id: I03dc2382e7af52455c356a2bf3971a4d1bd46ec6 Reviewed-on: https://chromium-review.googlesource.com/616785 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill ff161f83 2017-08-26T23:49:10 Fix EP generation event output format for uint. This should be %u not %d. BUG=angleproject:1309 Change-Id: I1fe1b8df9ea4f9123fc05e9ff58afa1f7723692c Reviewed-on: https://chromium-review.googlesource.com/636521 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jamie Madill a42a4e5e 2017-08-28T14:02:12 D3D11: Copy external offscreen texture when required. In some cases ANGLE gets an external back buffer texture for our SwapChain11 class, and in some of these cases we get an offscreen texture that can't be used as a shader resource. The becomes a problem for some copy operations that use a shader to convert texture formats. Work around this problem by making a shadow copy of the texture that has sampling enabled - it is possible to use CopyResource to copy between them. BUG=chromium:752917 Change-Id: Ib757949d3d06295a118b055bf37311f820f7149c Reviewed-on: https://chromium-review.googlesource.com/638551 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jamie Madill 16daadba 2017-08-26T23:34:31 GLES3: Auto-generate entry point header. BUG=angleproject:1309 Change-Id: I40e3580c99df44338dfd1d06677e80fd0c57853e Reviewed-on: https://chromium-review.googlesource.com/636520 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jamie Madill 9696d073 2017-08-26T23:19:57 Clean up the ES3 entry points for auto-generation. Removes some unnecessary includes, and moves some validatoinfunctions to the ES3-only file. BUG=angleproject:1309 Change-Id: I3b274014c48f6f39b5e67223987c91fbc5b4d390 Reviewed-on: https://chromium-review.googlesource.com/636519 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jamie Madill 70b5bb00 2017-08-28T13:32:37 Rename gl::FenceSync to gl::Sync. The spec refers to Sync objects, FenceSyncs being a subtype. The motivation for this fix is to clear up the FenceSync_ entry point for auto-generation. BUG=angleproject:1309 Change-Id: I94c440476d701628575e7a3eea68b6dd110f41c3 Reviewed-on: https://chromium-review.googlesource.com/636516 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jamie Madill 3ef140a9 2017-08-26T23:11:21 Finish refactoring the rest of the ES3 entry points. BUG=angleproject:747 Change-Id: I3da02120bfff5f33f15a5a9dd45ec99fd654425f Reviewed-on: https://chromium-review.googlesource.com/636518 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jamie Madill 7f0c5a4b 2017-08-26T22:43:26 Refactor sync EPs (plus one extra). More entry point validation refactor for auto-gen. BUG=angleproject:747 Change-Id: I9462a28838df3f265e1401f66c838cc5a73d511f Reviewed-on: https://chromium-review.googlesource.com/636517 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jiawei Shao 7e1197e0 2017-08-24T15:48:38 Fix crash when indexing unsupported interface blocks by variable This patch intends to fix a compiler crash when indexing an unsupported interface blocks. We should not use UNREACHABLE() here because the compiler will continue parsing when this kind of error is generated. Instead, we use an ASSERT to ensure the compile error must have been reported before when the parsing reaches here. BUG=chromium:758159 Change-Id: I4bc63316d156d51f721123fe963106d1e81d8d32 Reviewed-on: https://chromium-review.googlesource.com/631797 Reviewed-by: Olli Etuaho <oetuaho@nvidia.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Martin Radev 97577623 2017-08-28T11:31:06 Fix assertion failure in CollectVariables.cpp The built-in gl_Layer can occur in the AST in cases in which either GL_OVR_multiview or GL_OVR_multiview2 is enabled. BUG=angleproject:2062 TEST=angle_end2end_tests Change-Id: I7409b2712c715c3898c33300b7e5689e347742f0 Reviewed-on: https://chromium-review.googlesource.com/636367 Reviewed-by: Olli Etuaho <oetuaho@nvidia.com> Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
Martin Radev 18b75bad 2017-08-15T15:50:40 D3D11: Handle Clear* commands for layered framebuffers According to the ANGLE_multiview spec, Clear* commands only affect the range of attached layers to the multi-view layered framebuffer. The patch extends ImageIndex so that the range of attached layers is tracked and a render target view can be created with that range of texture array slices attached. The special case of scissored clears for depth and stencil attachments is handled by instancing the same number of quads as there are views and selecting the layer within a geometry shader. BUG=angleproject:2062 TEST=angle_end2end_tests Change-Id: Ibea248b980513f83d918652030a72c62c7ecd88b Reviewed-on: https://chromium-review.googlesource.com/632256 Commit-Queue: Martin Radev <mradev@nvidia.com> Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 12e957f8 2017-08-26T21:42:26 Refactor uniform block and other query EPs. Also some minor fixes to validation and error messages. BUG=angleproject:747 Change-Id: I4f97a45c2d39a8deec2255620e5cc2bcb8cad7b9 Reviewed-on: https://chromium-review.googlesource.com/637126 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jamie Madill f0dcb8b5 2017-08-26T19:05:13 Refactor transform feedback EPs. BUG=angleproject:747 Change-Id: I4891966cd7b3d478980202e795742e15dd1dcb01 Reviewed-on: https://chromium-review.googlesource.com/637125 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jamie Madill d7576737 2017-08-26T18:49:50 Refactor VAO entry points. This also touches the extension EPs for ES2. BUG=angleproject:747 Change-Id: Iaa04d97465e518f6b0496e64bc7a737914709b8f Reviewed-on: https://chromium-review.googlesource.com/637124 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jamie Madill c8c95817 2017-08-26T18:40:09 Refactor uniform matrix entry points. This should also slightly speed up some of the validation. BUG=angleproject:747 BUG=angleproject:1390 Change-Id: I60735e2773788aef3f535bf7d3d8cd27bc4df5b1 Reviewed-on: https://chromium-review.googlesource.com/637123 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jamie Madill f0e0449e 2017-08-26T15:28:42 Format ES3 query entry points. Also refactor some query extension entry points. BUG=angleproject:747 Change-Id: I5a8a3b2616a3872b5645a655641ec9c12739f804 Reviewed-on: https://chromium-review.googlesource.com/636062 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jamie Madill ff325f1b 2017-08-26T15:06:05 Refactor ES3 uniform entry points. This should improve validation speed slightly because it allows us to move the ES3-only check into the ES3-only code, and make it a bit simpler. BUG=angleproject:747 BUG=angleproject:1390 Change-Id: I41f9ffef1c6a552fde924e62e481831f07b1503a Reviewed-on: https://chromium-review.googlesource.com/636061 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Kenneth Russell ef661517 2017-08-26T11:13:04 Add ANGLE dEQP trybots to default set of tryservers. These trybots -- for Win, Linux, and Android -- are all working now per https://chromium-review.googlesource.com/636294 . Make them run for all ANGLE CLs so that the dEQP tests can be removed from the others. This will allow the dEQP bots' compiler configuration to ultimately diverge from the other bots'. BUG=727437 TBR=geofflang@chromium.org Change-Id: I90ffcd358dfa888b77ecf718727d809c486170c7 Reviewed-on: https://chromium-review.googlesource.com/636759 Reviewed-by: Kenneth Russell <kbr@chromium.org> Commit-Queue: Kenneth Russell <kbr@chromium.org>
JiangYizhou 511937d9 2017-08-03T15:41:29 ES3.1: Implement framebuffer default parameters for d3d part. Set framebuffer default params with glFramebufferParameteri and glGetFramebufferParameteriv, keep framebuffer default parameters in cache for query. The es 3.1 spec section 9.2 states that, "If there are no attachments , rendering will be limited to a rectangle having a lower left of (0, 0) and an upper right of (width, height), where width and height are the framebuffer object's default width and height." If the Framebuffer has no color attachment and the default width or height is smaller than the current viewport, use the smaller of the two sizes. BUG=angleproject:1594 TEST=dEQP-GLES31.functional.state_query.framebuffer_default.framebuffer_default* TEST=dEQP-GLES31.functional.fbo.completeness.no_attachments TEST=dEQP-GLES31.functional.fbo.no_attachments.* TEST=angle_end2end_tests --gtest_filter=FramebufferTest_ES31.* Change-Id: I8041fd655161390acf115efa08ce0f04b10810a0 Reviewed-on: https://chromium-review.googlesource.com/609414 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jiawei Shao d27f5c8d 2017-08-23T09:38:08 ES31: Implement GL_OES_geometry_shader built-ins in GLSL compiler This patch intends to implement all built-in constants, variables and functions defined in OpenGL ES 3.1 extension GL_OES_geometry_shader in ANGLE GLSL compiler. 1. Add all built-in constants defined in GL_OES_geometry_shader. 2. Add built-in functions EmitVertex() and EndPrimitive() required in Geometry Shader. 3. Add built-in variables gl_PrimitiveIDIn and gl_InvocationID to Geometry Shader. 4. Add built-in variables gl_PrimitiveID and gl_Layer to both Geometry Shader and Fragment Shader when GL_OES_geometry_shader is enabled. BUG=angleproject:1941 TEST=angle_unittests Change-Id: I92821553ed0efee2ccb77fead6e065e7799819d0 Reviewed-on: https://chromium-review.googlesource.com/627670 Commit-Queue: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Martin Radev 3c25ad07 2017-08-22T17:36:53 Enable all multiview rendering tests for layered framebuffers The patch restructures the tests in MultiviewDrawTests.cpp, so that all rendering tests can be instantiated for side-by-side and layered framebuffers. BUG=angleproject:2062 TEST=angle_end2end_tests Change-Id: I2c32fd3bd57b6afd1eb8d6cedb2d1b88b9fd6525 Reviewed-on: https://chromium-review.googlesource.com/627918 Commit-Queue: Martin Radev <mradev@nvidia.com> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill 335d67b8 2017-08-24T14:57:44 Fixes to the Uniforms Perf benchmark. Fix the REPEAT test, and add a D3D11 and OpenGL null test. BUG=angleproject:1390 Change-Id: I491cbc9f9201ef85aeb9f70138a276078220b26d Reviewed-on: https://chromium-review.googlesource.com/623928 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jamie Madill 2c1183bb 2017-08-24T10:36:01 Fix compile on non C++14 configs. The WrappedArray move constructor was not contexpr under c++11 rules. New code was introduced when fixing D3D11 runtime warnings. BUG=angleproject:2025 Change-Id: Ie322d9fa3db36f320b7a9ef5048a23c31c153ad1 Reviewed-on: https://chromium-review.googlesource.com/633911 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jamie Madill 41013bdd 2017-08-24T14:07:33 Perf script runner Python 3 compatibility. No code changes in ANGLE, just a perf test runner fix. BUG=angleproject:1155 Change-Id: If49c58da26f9224e09f292689b2d74f7e129a844 Reviewed-on: https://chromium-review.googlesource.com/633786 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Corentin Wallez c1346fba 2017-08-24T16:11:26 Revert "Remove IndexRange retrieving in validation" This reverts commit 59d9da089580afac175ff5f1a932b987c9d194d6. Reason for revert: <INSERT REASONING HERE> Original change's description: > Remove IndexRange retrieving in validation > > This change can improve the performance of drawElements which uses > the path without translation. > Paste a set of mean data (repeated 30) for reference on Intel skylake > Win10 desktop. > DrawElementsPerfBenchmark.Run/d3d11: > before after > mean: 13644.4666667 -> mean: 13887.8333333 > DrawElementsPerfBenchmark.Run/d3d11_index_buffer_changed: > before after > mean: 45.8 -> mean: 46.3666666667 > > BUG=755897, angleproject:1393 > > Change-Id: I11f5db25445346958dfef52b1d23df5483cda32f > Reviewed-on: https://chromium-review.googlesource.com/607413 > Reviewed-by: Geoff Lang <geofflang@chromium.org> > Reviewed-by: Jamie Madill <jmadill@chromium.org> > Commit-Queue: Jamie Madill <jmadill@chromium.org> TBR=geofflang@chromium.org,jmadill@chromium.org,jiajia.qin@intel.com Change-Id: I4b00af2c32af36aa978ac2fddcf7514134497cf3 No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: 755897, angleproject:1393 Reviewed-on: https://chromium-review.googlesource.com/633296 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Commit-Queue: Corentin Wallez <cwallez@chromium.org>
Olli Etuaho e080387e 2017-08-23T15:30:23 Refactor array element type checks Remove checks that would never fail, and refactor the functions into more self-contained checks. For example, it doesn't make sense to check the qualifier from the part of the type that doesn't contain the qualifier. This prepares for adding the parsing of arrays of arrays. BUG=angleproject:2125 TEST=angle_unittests Change-Id: I1144bee35d2b04c7cb22e2bb7e17307298e35f8c Reviewed-on: https://chromium-review.googlesource.com/629016 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
Qin Jiajia 59d9da08 2017-08-09T16:59:17 Remove IndexRange retrieving in validation This change can improve the performance of drawElements which uses the path without translation. Paste a set of mean data (repeated 30) for reference on Intel skylake Win10 desktop. DrawElementsPerfBenchmark.Run/d3d11: before after mean: 13644.4666667 -> mean: 13887.8333333 DrawElementsPerfBenchmark.Run/d3d11_index_buffer_changed: before after mean: 45.8 -> mean: 46.3666666667 BUG=755897, angleproject:1393 Change-Id: I11f5db25445346958dfef52b1d23df5483cda32f Reviewed-on: https://chromium-review.googlesource.com/607413 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jamie Madill abf66fb3 2017-08-23T11:58:27 D3D11: Use dirty bits for applyVertexBuffers. If the vertex array has any dirty or dynamic attribs, we must do an update. Similarly, if a prior state change has left the vertex state invalidated, we do an update. For instance, a program change means we need a new input layout. If there was no such invalidation or dirtyness we can skip the call to InputLayoutCache. This improves the performance of the draw call benchmark (with no state changes) by about 50% on the D3D11 null driver. Increases the frames per second count of the aquarium demo with the passthrough command buffer by about 25% on a test machine. BUG=angleproject:1156 Change-Id: I8381999029f5b1912030a3342e96285a58f95e82 Reviewed-on: https://chromium-review.googlesource.com/616784 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill e3d8628d 2017-08-22T11:50:01 D3D11: Split input layout and VB application. This will enable future optimizations that only update either the applied vertex buffers or the input layout independenty. It also makes debugging a bit easier since we can force an update of the vertex buffer or input layout to diagnose potential state sync bugs. BUG=angleproject:1156 Change-Id: Ib375561528da539e136ff4fd02398b03c9caabb7 Reviewed-on: https://chromium-review.googlesource.com/627077 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Olli Etuaho 96f6adfa 2017-08-16T11:18:54 Add support for arrays of arrays in AST processing Data concerning arrays of arrays is added in TType. Parsing arrays of arrays and support for arrays of arrays in TPublicType are still left to be implemented later. ShaderVariable interface for arrays of arrays is also left to be implemented later. We rely on existing test coverage to make sure that arrays of arrays are not accidentally exposed. BUG=angleproject:2125 TEST=angle_unittests, angle_end2end_tests, angle_deqp_gles31_tests Change-Id: Ie17d5ac9b8d33958e9126dc0fb40bf1c81ddeec9 Reviewed-on: https://chromium-review.googlesource.com/616146 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
Martin Radev 5e424fae 2017-08-09T16:25:36 Handle Clear* commands for layered framebuffers The patch adds support for clearing the layers of 2D array textures attached to a multi-view framebuffer. According to the ANGLE_multiview spec, the layers which are outside of the range [baseViewIndex; baseViewIndex + numViews) should remain unmodified. Because the native Clear* commands clear all of the layers, a workaround is implemented which creates a FBO, attaches a single layer from all multi-view attachments and clears the contents. BUG=angleproject:2062 TEST=angle_end2end_tests Change-Id: Ibf711d02046233eed16bdd3f9c96fc38f82ed0a8 Reviewed-on: https://chromium-review.googlesource.com/615242 Commit-Queue: Martin Radev <mradev@nvidia.com> Reviewed-by: Olli Etuaho <oetuaho@nvidia.com> Reviewed-by: Geoff Lang <geofflang@chromium.org>