Log

Author Commit Date CI Message
Shahbaz Youssefi f83a28a6 2018-12-09T03:48:34 Vulkan: Shader path for framebuffer-to-texture copy Part 1 in a series of changes to perform image copies on the GPU. Bug: angleproject:2958 Change-Id: I6264a880865c4738c0866f2dc71af63425fc4118 Reviewed-on: https://chromium-review.googlesource.com/c/1370724 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Shahbaz Youssefi d7969cdd 2019-01-02T11:53:18 Vulkan: optimize image layout transitions Removes dstAccessMask being redundantly set where `GetBasicLayoutAccessFlags()` sets the same bits. Additionally, removes setting HOST_WRITE_BIT and TRANSFER_WRITE_BIT as src access mask if new layout is SHADER_READ_ONLY_OPTIMAL. The correct src access mask will be set based on the previous layout. Additionally, specializes `GetBasicLayoutAccessFlags()` in `GetSrcLayoutAccessFlags()` and `GetDstLayoutAccessFlags()` where the access mask is set correctly (and optimally) based on whether the layout is the old or the new one. This removes a few unnecessary access masks from src (for WAR hazards), and adds a few missing access masks to dst (for RAW hazards), such as VK_ACCESS_COLOR_ATTACHMENT_READ_BIT necessary for blending. Bug: angleproject:2958 Change-Id: I5870bc99c755f0444332418f998032850825aca5 Reviewed-on: https://chromium-review.googlesource.com/c/1392397 Reviewed-by: Tobin Ehlis <tobine@google.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Jamie Madill ad398ee8 2019-01-03T13:01:08 Free OSWindow and EGLWindow through helpers. This cleans up any potential problems with allocating and freeing resources in different shared objects or DLLs. Previously we were using a dynamically linked allocation function and then calling the standard delete function. Also adds a base class helper for EGLWindow. Will base the WGL Window class on this. Needed for running ANGLE tests against native drivers. Bug: angleproject:2995 Change-Id: Ic92b447649ebb32c547605c20086c07a601842f0 Reviewed-on: https://chromium-review.googlesource.com/c/1393443 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Yuly Novikov <ynovikov@chromium.org>
Jamie Madill 9fa54eab 2019-01-02T18:38:33 Optimize and inline more validation. Previously on each draw call we were checking both the instanced and non-instanced attributes for overflow. On on-instanced draw calls we don't need to do any special checks for instanced attributes. Also we can inline more into the headers. This improves draw call performance slightly. Bug: angleproject:2966 Change-Id: Idf5861d2d9daf9fffd5c84f6a1ea5b23ac8ab713 Reviewed-on: https://chromium-review.googlesource.com/c/1390357 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Markus Tavenrath <matavenrath@nvidia.com>
Jamie Madill 4627b370 2019-01-02T18:38:32 Add gl null driver tests to DrawElements. Requires a couple tweaks to the back-end to be compatible with the null driver. Bug: angleproject:2966 Change-Id: Ia83651aabb0dd14b7d6f64152c276463a8fb28fc Reviewed-on: https://chromium-review.googlesource.com/c/1392392 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jamie Madill 904bb918 2019-01-02T16:00:02 Rename constants in blocklayout.h. This adds the "k" prefix. Bug: angleproject:3024 Change-Id: I3771a8a9d90cd5edc7173f2b3817a5f1f053bdd4 Reviewed-on: https://chromium-review.googlesource.com/c/1392399 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Bryan Bernhart 48bbc53e 2018-12-03T16:17:00 ES31: Fix for reading back initialized SSBO buffers in D3D11 If a SSBO is initialized with data, a staging buffer was created. When the data was read back, it was read from the staging buffer instead of the GPU. This patch fixes that by making the UAV buffer the latest buffer. Bug: angleproject:2990 Test: angle_end2end_tests Change-Id: I43c8c85144c74cc9b317577b7c834e3f7e347f72 Reviewed-on: https://chromium-review.googlesource.com/c/1359712 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Bryan Bernhart <bryan.bernhart@intel.com> Commit-Queue: Bryan Bernhart <bryan.bernhart@intel.com> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Shahbaz Youssefi 441649f7 2019-01-02T14:09:13 Suppress flaky Linux/Intel/OpenGL test. SimpleStateChangeTestES31.DispatchImageTextureAThenTextureBThenTextureA/ES3_1_OPENGL Bug: angleproject:3044 Change-Id: I21a4e4dadcb1dea23d3a7b2e9089e395e33dc1cd Reviewed-on: https://chromium-review.googlesource.com/c/1392398 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Jamie Madill bbdeee91 2019-01-02T09:57:49 Suppress FL 9_3 failing test. RobustBufferAccessBehaviorTest.RobustBufferAccessBehaviorTest Bug: angleproject:3042 Change-Id: I40186eeeb69ee2939844117b661209a433773db9 Reviewed-on: https://chromium-review.googlesource.com/c/1392396 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jamie Madill 04ea03e4 2019-01-01T15:14:25 Make default block member info a constant. Instead of generating a struct each time we can use a constexpr constructor to use a single representation. Bug: angleproject:3024 Change-Id: I14dec65a4f6ac9ab2f7e7af444862e4ceab88d8c Reviewed-on: https://chromium-review.googlesource.com/c/1392395 Reviewed-by: Jiajia Qin <jiajia.qin@intel.com> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Qin Jiajia 76f66954 2018-12-18T17:59:00 ES31: Fix the bug that SSBO is active but not statically used If a SSBO is active but not statically used, there will be no UAV slot is bound. So we should skip this kind of block. Bug: angleproject:1951 Change-Id: I4d813ddefcce6c31fa02701f26148eb21c00f380 Reviewed-on: https://chromium-review.googlesource.com/c/1381847 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jiajia Qin <jiajia.qin@intel.com>
Jamie Madill 0c667215 2019-01-01T14:40:36 Pass ErrorSet to ContextImpl constructor. This removes the need for the setErrorSet method. Also update some egl::Error TODO bugs. Bug: angleproject:2491 Change-Id: I0aba07c4a53b579835a88c3dacae294f752e6b17 Reviewed-on: https://chromium-review.googlesource.com/c/1392393 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jamie Madill ba319ba3 2018-12-29T10:29:33 Re-land "Load entry points dynamically in tests and samples." Fixes the Android/ChromeOS/Fuchsia builds by using consistent EGL headers. This CL adds a dynamic loader generator based on XML files. It also refactors the entry point generation script to move the XML parsing into a helper class. Additionally this includes a new GLES 1.0 base header. The new header allows for function pointer types and hiding prototypes. All tests and samples now load ANGLE dynamically. In the future this will be extended to load entry points from the driver directly when possible. This will allow us to perform more accurate A/B testing. The new build configuration leads to some tests having more warnings applied. The CL includes fixes for the new warnings. Bug: angleproject:2995 Change-Id: I5a8772f41a0f89570b3736b785f44b7de1539b57 Reviewed-on: https://chromium-review.googlesource.com/c/1392382 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jamie Madill c3dc5d48 2018-12-30T12:12:04 Merge gl::Context and gl::ContextState. This reduces the number of indrections when accessing the Extensions or Caps structures. It will provide a small speed-up to some methods. It also cleans up the code. Bug: angleproject:2966 Change-Id: Idddac70758c42c1c2b75c885d0cacc8a5c458685 Reviewed-on: https://chromium-review.googlesource.com/c/1392391 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Markus Tavenrath <matavenrath@nvidia.com>
Markus Tavenrath 957eb07f 2019-01-01T12:36:48 Remove redundant masking of the bits in angle::BitSet when using ternary operators. Bug: angleproject:3040 Change-Id: I59e69ddb27ec9c5723aff04858ac5c052e2775da Reviewed-on: https://chromium-review.googlesource.com/c/1392806 Commit-Queue: Markus Tavenrath <matavenrath@nvidia.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Markus Tavenrath cc37cbf2 2018-12-30T23:35:25 Apply several small micro-optimizations to ValidateDrawElementsCommon * Remove indirection when getting CotextState from Context * Reduce number of branches from 2 to 1 when checking for an InvalidEnum in FromGLEnum<DrawElementsType> * Provide IndexRange constructor which doesn't initialize the member variables * Reduce number of branches to 1 when checking for BasicDrawStateErrors for the fast path * Remove a few branches and reduce math cost during the buffer range check in ValidateDrawElementsCommon Bug: angleproject:2966 Change-Id: Ibdbed8a59ad9d7abce76622e9f507498e67ab997 Reviewed-on: https://chromium-review.googlesource.com/c/1392805 Commit-Queue: Markus Tavenrath <matavenrath@nvidia.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 60a50cfc 2018-12-29T16:04:05 Inline Context::DrawArrays and Context::BindBuffer. This reduces the call depth of both of these two hotspots. Reduces time spent in the CPU overhead benchmarks by about 10%. Bug: angleproject:2966 Change-Id: I5052e56dcc1dfb80274326a7f0891fafba7d6655 Reviewed-on: https://chromium-review.googlesource.com/c/1392389 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Markus Tavenrath <matavenrath@nvidia.com>
Yuly Novikov 9f088621 2018-12-29T20:46:15 Revert "Load entry points dynamically in tests and samples." This reverts commit 03923558a7103827ffec6a4d2a1453ed91f01c6f. Reason for revert: fails compilation on Android, ChromeOS and Fuchsia during roll https://chromium-review.googlesource.com/c/chromium/src/+/1392624 Original change's description: > Load entry points dynamically in tests and samples. > > This CL adds a dynamic loader generator based on XML files. It also > refactors the entry point generation script to move the XML parsing > into a helper class. > > Additionally this includes a new GLES 1.0 base header. The new > header allows for function pointer types and hiding prototypes. > > All tests and samples now load ANGLE dynamically. In the future this > will be extended to load entry points from the driver directly when > possible. This will allow us to perform more accurate A/B testing. > > The new build configuration leads to some tests having more warnings > applied. The CL includes fixes for the new warnings. > > Bug: angleproject:2995 > Change-Id: I6726d4163f7a6e54d2482f094c0a952f59702a05 > Reviewed-on: https://chromium-review.googlesource.com/c/1359516 > Commit-Queue: Jamie Madill <jmadill@chromium.org> > Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> TBR=ynovikov@chromium.org,jmadill@chromium.org,syoussefi@chromium.org Change-Id: I902bec2d733c2b879be29c02ab52a0b7d4eaa077 No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: angleproject:2995 Reviewed-on: https://chromium-review.googlesource.com/c/1392381 Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Commit-Queue: Yuly Novikov <ynovikov@chromium.org>
Jamie Madill 03923558 2018-12-29T10:29:33 Load entry points dynamically in tests and samples. This CL adds a dynamic loader generator based on XML files. It also refactors the entry point generation script to move the XML parsing into a helper class. Additionally this includes a new GLES 1.0 base header. The new header allows for function pointer types and hiding prototypes. All tests and samples now load ANGLE dynamically. In the future this will be extended to load entry points from the driver directly when possible. This will allow us to perform more accurate A/B testing. The new build configuration leads to some tests having more warnings applied. The CL includes fixes for the new warnings. Bug: angleproject:2995 Change-Id: I6726d4163f7a6e54d2482f094c0a952f59702a05 Reviewed-on: https://chromium-review.googlesource.com/c/1359516 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Jamie Madill 8c78ce4b 2018-12-16T19:14:58 Use visitor pattern for Shader Variable APIs. In many places in ANGLE we need to traverse a ShaderVariable tree. We do this to store uniform offset and other information, to flatten the tree of uniforms for the front-end, or to produce active variable lists for uniform and shader storage blocks. In each case, we would write separate tree traversal code. This patch introduces a shared visitor pattern for all of the shader variable tree traversal instances. With that get more common code. Also it is easier to write new variable traversals. ProgramD3D and ProgramLinkedResources in particular get nice simplificiations. The visitor object recieves callbacks from the traversal when entering structs, array elements, and new variables. The visitor can treat these differently depending on the use case. A common visitor that constructs full variable names is used as a base class in several places. Also moves the 'isRowMajorLayout' from sh::InterfaceBlockField to sh::ShaderVariable. This allows us to forgo using templates in several call sites. Bug: angleproject:3024 Change-Id: I472d81ec775e2eee92fb3d2eb0ca83860221ba2e Reviewed-on: https://chromium-review.googlesource.com/c/1358722 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Yuly Novikov <ynovikov@chromium.org>
Shahbaz Youssefi e321940c 2018-12-08T16:54:14 Vulkan: Move image clear functionality to UtilsVk DispatchUtilsVk is renamed to UtilsVk and the functionality in framebuffer's clearWithDraw() is moved to that class. Eventually, more fragment-shader-based internal algorithms will be added to this class as well. Bug: angleproject:2958 Change-Id: I4753c9cb3288b59cd1ed60fe7a57b9f189704322 Reviewed-on: https://chromium-review.googlesource.com/c/1369284 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Shahbaz Youssefi af4cef51 2018-12-28T16:56:47 Improve CopyTexImageTest The test is enhanced to perform the copy multiple times. Initially, the copy creates a new texture from a 16x16 framebuffer. Then, a copy is made from another 16x16 framebuffer (which should not trigger the recreation of the texture). Finally, a copy is made from a 32x32 framebuffer (which should trigger the recreation of the texture). Bug: angleproject:2958 Change-Id: Idc934d6f3d6312a2122d079309a4c2ae2608ba7f Reviewed-on: https://chromium-review.googlesource.com/c/1392388 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Xinghua Cao c5117571 2018-12-28T15:56:41 Add test case for storage buffer When storage buffer bound is unchanged and shader writes it, buffer content should also be updated. Currently, this case cannot work normally on D3D backend. Bug: angleproject:2814 TEST=angle_end2end_tests.ComputeShaderTest.StorageBufferBoundUnchanged Change-Id: I6f25b7eac84c44392befaca61a33bdf2457f29f9 Reviewed-on: https://chromium-review.googlesource.com/c/1391880 Commit-Queue: Xinghua Cao <xinghua.cao@intel.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Qin Jiajia 3f01f53c 2018-12-11T15:13:51 ES31: Add state change tests for image This change adds dirty bit state change tests for image textures. Meanwhile, syncImages related codes are removed since syncTextures will do all texture states sync. Bug: angleproject:3015 Change-Id: I9b299c86af1d589e72c08c5d7c55ac74cc7833aa Reviewed-on: https://chromium-review.googlesource.com/c/1390596 Commit-Queue: Jiajia Qin <jiajia.qin@intel.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Markus Tavenrath cb9609fe 2018-12-26T00:52:44 Optimize glDrawElements performance A call to glDrawElements results in a calling depth of up to 4 * glDrawElements * gl::Context::DrawElements * rx::ContextGL::DrawElements * VertexArrayGL::syncDrawState. Each function call has to save/restore a lot of registers which results in a stall in the prologue of rx::ContextGL::DrawElements due to memory bandwidth limitations. The main change is the function gl::Context::DrawElements being inlined to reduce the calling depth by one. In addition the call to ContextGL::syncDrawElementsState is now protected so that it gets called only if it's required. Finally a few small getter functions have been inlined where the calling code was bigger than the actual function. In total this change improves performance of the DrawElementsPerfBenchmark.Run/gl benchmark by 16%. Bug: angleproject:2966 Change-Id: I423d18452f2f5b520ab52850fda2054e1da86991 Reviewed-on: https://chromium-review.googlesource.com/c/1389988 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Markus Tavenrath <matavenrath@nvidia.com>
Raul Tambre 7f6b3674 2018-12-24T20:09:20 Disable null pointer arithmetic warnings for GLES1 conformance tests Required for the rest of Chromium to compile with the warning enabled. Bug: chromium:766891 Change-Id: Ie319df01599434011dc953532a30ad68d6a7c9a3 Reviewed-on: https://chromium-review.googlesource.com/c/1390659 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Xinghua Cao 84412860 2018-12-21T17:41:24 Set dirty for uniform on D3D backend When uniform's value had been updated, set dirty and update its content on D3D backend. Bug: angleproject:2814 TEST=angle_end2end_tests.ComputeShaderTest .UniformDirty/ES3_1_D3D11 dEQP.GLES31/functional_image_load_store_cube* dEQP.GLES31/functional_image_load_store_3d* dEQP.GLES31/functional_image_load_store_2d_array* Change-Id: Ic135c140559925fe33790475d03dc608afa92384 Reviewed-on: https://chromium-review.googlesource.com/c/1387967 Reviewed-by: Jiajia Qin <jiajia.qin@intel.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Xinghua Cao <xinghua.cao@intel.com>
Jamie Madill ae6ba9f8 2018-12-21T23:00:04 Optimize check for active not paused XFB. Local testing showed an improved score of about 2% in the most sensitive CPU overhead benchmark. Likely because of improved caching from fewer indirections. Bug: angleproject:2966 Change-Id: I5d9a4b4bcf624ab0b430bb696c4227e589cdb7a6 Reviewed-on: https://chromium-review.googlesource.com/c/1359518 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Jamie Madill 1e853266 2018-12-21T09:07:38 Cache common DrawElements states. Similar to how we cache the base common draw states. This will improve DrawElements performance. Several state checks are optimized into a single 'if' check of a cached value. Also includes a regression test for mapping the element array buffer. Bug: angleproject:2966 Change-Id: Ia6e524a58ad6b7df2e455d67733e15d324b1b893 Reviewed-on: https://chromium-review.googlesource.com/c/1357150 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Ian Elliott 52f5da43 2018-12-21T09:02:09 Also enable flipY for Vulkan 1.1 The necessary support for flipY is included in core Vulkan 1.1 so enable the feature if that's what's available. Bug: angleproject:2968 Change-Id: I6808a1a0b1ace74976a7476f77d686e137a1e747 Reviewed-on: https://chromium-review.googlesource.com/c/1387758 Commit-Queue: Ian Elliott <ianelliott@google.com> Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Ian Elliott 899c5d26 2018-12-21T13:12:50 Appropriately set VkApplicationInfo::apiVersion to 1.1 Check if the Vulkan instance version is 1.1+, and if so, set VkApplicationInfo::apiVersion to 1.1 (which signals to the validation layers that ANGLE will use Vulkan 1.1 functionality. Bug: angleproject:2968 Change-Id: I6808a1a0b1ace74976a7476f77d686e137a1e746 Reviewed-on: https://chromium-review.googlesource.com/c/1387757 Commit-Queue: Ian Elliott <ianelliott@google.com> Reviewed-by: Yuly Novikov <ynovikov@chromium.org>
Ian Elliott d50521fd 2018-12-20T12:05:14 Only enable VK_KHR_maintenance1 when available. This prevents an error in case ANGLE is run on an older Vulkan driver that does not support the VK_KHR_maintenance1 extension. Bug: angleproject:3035 Change-Id: I7e2b74bcb88bffdfc2a525a1d332eb3ef7d23d7c Reviewed-on: https://chromium-review.googlesource.com/c/1387347 Reviewed-by: Ian Elliott <ianelliott@google.com> Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Reviewed-by: Courtney Goeltzenleuchter <courtneygo@google.com> Commit-Queue: Ian Elliott <ianelliott@google.com>
Courtney Goeltzenleuchter 92b16ea2 2018-12-12T17:06:47 Re-land: Compress symbols for libraries Reintroduce commit ffda3e2985f18f4ff6e3778af8b9715109b21ad0. Android requires system libraries to include symbols to aid debugging. This CL will compress and attach the symbols from the unstripped .so and add it to the stripped .so that goes in the apk when building a release build. Fix https://crbug.com/916751 introduced by Compress symbol support CL ffda3e2985f18f4ff6e3778af8b9715109b21ad0. Bug: angleproject:2981 Change-Id: I8d3ef8e9f0ed44bdd24290f6cd56ba674b79f98c Reviewed-on: https://chromium-review.googlesource.com/c/1387344 Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Commit-Queue: Courtney Goeltzenleuchter <courtneygo@google.com>
Jamie Madill 2b35654d 2018-12-20T12:43:37 compiler: Fix const non-square matrix component mult. It seems like there weren't any dEQP tests for constant folding of nonsquare matrices component-wise multiplication. There were a couple bugs in our implementation which could lead to undefined behaviour. Fixes the code and cleans up a few style issues. Also includes a regression test. Bug: chromium:912505 Bug: chromium:912508 Change-Id: I7fb85d1404a32950fa9fe4c3bbba9edc9f38ddd1 Reviewed-on: https://chromium-review.googlesource.com/c/1387065 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Yuly Novikov <ynovikov@chromium.org>
Ian Elliott bcb78908 2018-12-19T11:46:29 Implement eglSwapBuffersWithDamage on top of VK_KHR_incremental_present Bug: angleproject:2510 Change-Id: I12b0877f787dbcb48e2890f54ba4bc8ebe8294b4 Reviewed-on: https://chromium-review.googlesource.com/c/1383373 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Commit-Queue: Ian Elliott <ianelliott@google.com>
CJ DiMeglio 96c11cc7 2018-12-19T23:04:18 Revert "Compress symbols for libraries" This reverts commit ffda3e2985f18f4ff6e3778af8b9715109b21ad0. Reason for revert: https://crbug.com/916751 Original change's description: > Compress symbols for libraries > > Android requires system libraries to include symbols to aid > debugging. This CL will compress and attach the symbols from the > unstripped .so and add it to the stripped .so that goes in the apk > when building a release build. > > Bug: angleproject:2981 > Change-Id: I51c315627b9183e49b509c27df506bf99bf45f30 > Reviewed-on: https://chromium-review.googlesource.com/c/1376270 > Commit-Queue: Courtney Goeltzenleuchter <courtneygo@google.com> > Reviewed-by: Yuly Novikov <ynovikov@chromium.org> TBR=ynovikov@chromium.org,jmadill@chromium.org,courtneygo@google.com Change-Id: Ifda891fc5257aa9c9b522bf5a20fda10142e82ad No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: angleproject:2981 Reviewed-on: https://chromium-review.googlesource.com/c/1385347 Reviewed-by: CJ DiMeglio <lethalantidote@chromium.org> Commit-Queue: CJ DiMeglio <lethalantidote@chromium.org>
Jamie Madill 6f087e9e 2018-12-19T16:10:49 Modify end2end_tests main to not import ANGLETest.h. This will allow for easier dependency management in the build files. Bug: angleproject:2995 Change-Id: Ia3464bf622b861df03c3d06bcf1b34874a9a5400 Reviewed-on: https://chromium-review.googlesource.com/c/1385025 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Courtney Goeltzenleuchter ffda3e29 2018-12-12T17:06:47 Compress symbols for libraries Android requires system libraries to include symbols to aid debugging. This CL will compress and attach the symbols from the unstripped .so and add it to the stripped .so that goes in the apk when building a release build. Bug: angleproject:2981 Change-Id: I51c315627b9183e49b509c27df506bf99bf45f30 Reviewed-on: https://chromium-review.googlesource.com/c/1376270 Commit-Queue: Courtney Goeltzenleuchter <courtneygo@google.com> Reviewed-by: Yuly Novikov <ynovikov@chromium.org>
Jamie Madill 4638dc9d 2018-12-17T13:13:49 Re-land "Load correct libGLESv2 on Linux and Mac." Re-land fixes build to ensure commit_id is built before libEGL. libEGL was implicitly loading libGLESv2 on startup. This is bad because on platforms like Linux and Mac we could sometimes use the incorrect rpath. This in turn meant we needed workarounds like using "_angle" extensions to our shared objects to get the correct loading behaviour. Fix this by loading libGLESv2 dynamically in libEGL. We build the loader automatically from egl.xml. The loader itself is lazily initialized on every EGL entry point call. This is necessary because on Linux, etc, there is no equivalent to Windows' DLLMain. We also use an EGL.h with different generation options so we have the proper function pointer types. A README is included for instructions on how to regenerate EGL.h. The entry point generation script is refactored into a helper class that is used in the loader generator. Also adds the libGLESv2 versions of the EGL entry points in the DEF file on Windows. This allows them to be imported properly in 32-bit configurations. Also fixes up some errors in ANGLE's entry point definitions. Also includes a clang-format disable rule for the Khronos headers. This CL will help us to run ANGLE tests against native drivers. Bug: angleproject:2871 Bug: chromium:915731 Change-Id: I4192a938d1f4117cea1bf1399c98bda7ac25ddab Reviewed-on: https://chromium-review.googlesource.com/c/1380511 Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jamie Madill 720ca449 2018-12-17T14:04:10 Pass GN header visibility check. This fixes a few things: * removes includes that weren't supposed to be present * scopes some compiler code into white_box_perftests * makes version.h/commit and angle_common id more visible * roll zlib to a version that passes check This should help prevent build problems from popping up in the downstream Chromium build. We could also potentially look at including gn check in our CQ recipe. Bug: chromium:915429 Change-Id: I350f543e16de13c84eb2c43260f4966d47185114 Reviewed-on: https://chromium-review.googlesource.com/c/1380771 Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Xinghua Cao 0d218da4 2018-12-17T11:53:52 Specify texture LOD in compute shader on D3D backend D3D does not define LOD in compute shader, so Sample() is not supported, try to use SampleLevel(). Bug: angleproject:2756 TEST=angle_end2end_tests.ComputeShaderTest .TextureFunction/ES3_1_D3D11 dEQP.GLES31/functional_image_load_store_2d_store* Change-Id: I63e707d2b56e807cfe766cc21bc6b0819982ce80 Reviewed-on: https://chromium-review.googlesource.com/c/1379672 Commit-Queue: Xinghua Cao <xinghua.cao@intel.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Xinghua Cao 2db5082b 2018-12-17T14:27:18 Add UAV format for GL_RGBA8I GL_RGBA8I is a supported image unit format, add its corresponding UAV format on D3D backend. Bug: angleproject:1987 TEST=dEQP.GLES31/functional_image_load_store_2d_store_rgba8i dEQP.GLES31/functional_image_load_store_2d_load_store_rgba8i Change-Id: Ib759f873c8629a644f85784a57ce141d3018e0c1 Reviewed-on: https://chromium-review.googlesource.com/c/1378888 Reviewed-by: Jiajia Qin <jiajia.qin@intel.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Xinghua Cao <xinghua.cao@intel.com>
Ian Elliott 18017ca4 2018-12-17T15:39:27 Add opt-in/out unit testing for API version below minimum Bug: angleproject:2794 Change-Id: I133ebd4afb7064e8ac461f4f7174ec59af5ea0d1 Reviewed-on: https://chromium-review.googlesource.com/c/1380716 Reviewed-by: Ian Elliott <ianelliott@google.com> Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Commit-Queue: Ian Elliott <ianelliott@google.com>
Ian Elliott 5a8d0bc2 2018-11-30T14:35:29 Remove version-1 API of A4A opt-in/out (a.k.a. feature-support utilities) Bug: angleproject:2794 Change-Id: I7f41452a37536a00d772ecd9b21125ff7459a3d6 Reviewed-on: https://chromium-review.googlesource.com/c/1357151 Reviewed-by: Courtney Goeltzenleuchter <courtneygo@google.com> Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Ian Elliott <ianelliott@google.com>
Qin Jiajia 4622905b 2018-12-10T13:31:00 ES31: Add atomic memory functions for SSBO Due to SSBO is translated to RWByteAddressBuffer in HLSL, the corresponding atomic memory functions atomic* will be translated to RWByteAddressBuffer.Interlocked*. The translation is like below: atomicAdd(instanceName.data[0], 5u); // becomes uint _ssbo_atomicAdd_uint(RWByteAddressBuffer buffer, uint loc, uint value) { uint original_value; buffer.InterlockedAdd(loc, value, original_value); return original_value; } _ssbo_atomicAdd_uint(_instanceName, 0 + 16 * 0, 5); Bug: angleproject:1951 Change-Id: If2af8bedb67a4135b443d2512d43c6058a78888d Reviewed-on: https://chromium-review.googlesource.com/c/1370676 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Commit-Queue: Jiajia Qin <jiajia.qin@intel.com>
Yuly Novikov 175d918a 2018-12-16T19:53:23 Revert "Load correct libGLESv2 on Linux and Mac." This reverts commit dd815b623e60a1e1550f328104ffcd7caf20fde1. Reason for revert: Broke https://luci-milo.appspot.com/p/chromium/builders/luci.chromium.ci/win-rel/8006 Original change's description: > Load correct libGLESv2 on Linux and Mac. > > libEGL was implicitly loading libGLESv2 on startup. This is bad > because on platforms like Linux and Mac we could sometimes use the > incorrect rpath. This in turn meant we needed workarounds like using > "_angle" extensions to our shared objects to get the correct loading > behaviour. > > Fix this by loading libGLESv2 dynamically in libEGL. We build the > loader automatically from egl.xml. The loader itself is lazily > initialized on every EGL entry point call. This is necessary because > on Linux, etc, there is no equivalent to Windows' DLLMain. > > We also use an EGL.h with different generation options so we have the > proper function pointer types. A README is included for instructions > on how to regenerate EGL.h. > > The entry point generation script is refactored into a helper class > that is used in the loader generator. Also adds the libGLESv2 versions > of the EGL entry points in the DEF file on Windows. This allows them to > be imported properly in 32-bit configurations. > > Also fixes up some errors in ANGLE's entry point definitions. Also > includes a clang-format disable rule for the Khronos headers. > > This CL will help us to run ANGLE tests against native drivers. > > Bug: angleproject:2871 > Change-Id: Id6ecf969308f17b1be4083538428c9c1a1836572 > Reviewed-on: https://chromium-review.googlesource.com/c/1370725 > Commit-Queue: Jamie Madill <jmadill@chromium.org> > Reviewed-by: Geoff Lang <geofflang@chromium.org> TBR=ynovikov@chromium.org,geofflang@chromium.org,jmadill@chromium.org Change-Id: I921b3c45435ab4f05cbc2d1c1172b4185d6257b0 No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: angleproject:2871 Reviewed-on: https://chromium-review.googlesource.com/c/1378887 Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Commit-Queue: Yuly Novikov <ynovikov@chromium.org>
Jamie Madill dd815b62 2018-12-15T10:39:00 Load correct libGLESv2 on Linux and Mac. libEGL was implicitly loading libGLESv2 on startup. This is bad because on platforms like Linux and Mac we could sometimes use the incorrect rpath. This in turn meant we needed workarounds like using "_angle" extensions to our shared objects to get the correct loading behaviour. Fix this by loading libGLESv2 dynamically in libEGL. We build the loader automatically from egl.xml. The loader itself is lazily initialized on every EGL entry point call. This is necessary because on Linux, etc, there is no equivalent to Windows' DLLMain. We also use an EGL.h with different generation options so we have the proper function pointer types. A README is included for instructions on how to regenerate EGL.h. The entry point generation script is refactored into a helper class that is used in the loader generator. Also adds the libGLESv2 versions of the EGL entry points in the DEF file on Windows. This allows them to be imported properly in 32-bit configurations. Also fixes up some errors in ANGLE's entry point definitions. Also includes a clang-format disable rule for the Khronos headers. This CL will help us to run ANGLE tests against native drivers. Bug: angleproject:2871 Change-Id: Id6ecf969308f17b1be4083538428c9c1a1836572 Reviewed-on: https://chromium-review.googlesource.com/c/1370725 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 7139b434 2018-12-14T16:57:28 Print a warning on unexpected internal errors. The error message can be dropped when converting angle::Result to egl::Error. This makes sure something is always printed when we get an unexpected error. BUG=914911 Change-Id: Icc8b06b1c13e3ea83287da5a217f4c8bc218deec Reviewed-on: https://chromium-review.googlesource.com/c/1378689 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Geoff Lang <geofflang@chromium.org>
Tim Van Patten f3075842 2018-12-13T16:50:38 Use intent-filter to enforce that only a single ANGLE APK is present In order to support multiple ANGLE builds (Google-signed, AOSP unsigned, OEM-signed), we will use intent-filter to indicate that ANGLE is installed. During CTS testing, we will verify that only a single ANGLE is installed and provides the necessary functionality. Bug: angleproject:3011 Test: Verify CTS hostside tests pass. Change-Id: I71dc3a32a4c2bd57b4bbff30bd640e7f7704ab32 Reviewed-on: https://chromium-review.googlesource.com/c/1377610 Commit-Queue: Tim Van Patten <timvp@google.com> Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Reviewed-by: Ian Elliott <ianelliott@google.com>
Yuly Novikov 9a51daf6 2018-12-14T17:32:21 Fix angle_apk build Bug: angleproject:2995 Change-Id: I277a36b58dc6e0a9268b43d89e1da46635b5e1d1 Reviewed-on: https://chromium-review.googlesource.com/c/1378691 Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Reviewed-by: Tobin Ehlis <tobine@google.com> Commit-Queue: Yuly Novikov <ynovikov@chromium.org>
Geoff Lang a7af56be 2018-12-14T14:20:28 Vulkan: Print the device id in the renderer string. Add a end2end test that prints all strings to help debug on the bots. BUG=angleproject:3026 Change-Id: Ia524a0d7dac88e55e0aa67412339e646a5564e64 Reviewed-on: https://chromium-review.googlesource.com/c/1378686 Commit-Queue: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Geoff Lang e1f742af 2018-12-14T14:17:59 GL: Clean up workaround detection. Use functions instead of macros for platform detection so compilation can be checked from any platform. Also makes the workaround detection more readable. BUG=angleproject:3026 Change-Id: I4153f0a2a6a6d5860c7b37f7cc67561895165ed1 Reviewed-on: https://chromium-review.googlesource.com/c/1378685 Commit-Queue: Geoff Lang <geofflang@chromium.org> Reviewed-by: Yuly Novikov <ynovikov@chromium.org>
Jamie Madill 70fd9b5d 2018-12-14T10:27:33 Fix compile error in angle_white_box_perftests. This seems to have slipped through our CQ coverage. Bug: angleproject:3025 Change-Id: I2975eed3026feaa39b0cb3b897821e3bfc112f43 Reviewed-on: https://chromium-review.googlesource.com/c/1378385 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jamie Madill dfaccbc0 2018-12-13T23:43:52 Clean up Windows DEF file generation. Ordinal numbers weren't necessary. It's a legacy function from Win16. Also refactor the def file generator to be much simpler. Will be helpful for adding the libGLESv2 EGL entry points to the DEF files. This will enable loading the right GLES libs on Linux and Mac once we break the link dependency of libEGL on libGLESv2. Bug: angleproject:2871 Bug: angleproject:2621 Change-Id: Ia2585323b076446af55359d875a6b67bcdc4d6f9 Reviewed-on: https://chromium-review.googlesource.com/c/1372378 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill 828c5946 2018-12-13T23:09:05 Split angle_perftests into white and black box. The black box version tests traditional GL API features. The white box version is designed to test internal classes and uses a static link against libANGLE and libGLESv2. The black box version will also be extendable to test native drivers directly instead of going through ANGLE. Bug: angleproject:2995 Change-Id: I0b672db37ed38f82157c7a1db70080ff539337ce Reviewed-on: https://chromium-review.googlesource.com/c/1359515 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Qin Jiajia 4a9f9b08 2018-12-06T17:49:39 ES31: support ssbo as the operand of unary operator Bug: angleproject:1951 Change-Id: I71c2cf2ca35d7b1fe5d14358a0749f47e223816b Reviewed-on: https://chromium-review.googlesource.com/c/1367405 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Jiajia Qin <jiajia.qin@intel.com>
Tobin Ehlis bec39877 2018-12-12T16:23:30 tests:Fix memory leak in MipmapTest Update createRGBInitData() to use/return std::vector instead of raw ptr w/ "new." This prevents potential for memory leaks. Bug: angleproject:2958 Change-Id: I4b1bb4ee293e171f56d1221a562e607ff8eb0fb3 Reviewed-on: https://chromium-review.googlesource.com/c/1375229 Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Tobin Ehlis <tobine@google.com>
Geoff Lang 91002266 2018-12-12T16:05:24 Use angle::Result and pass a context pointer to TransformFeedbackImpl BUG=angleproject:3020 Change-Id: Ib0877dd33f9a8c6ea57976642f1b904258cb6a86 Reviewed-on: https://chromium-review.googlesource.com/c/1374273 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Geoff Lang <geofflang@chromium.org>
Jamie Madill 9b02506c 2018-12-12T15:44:12 Cache valid draw modes with transform feedback. Enabling transform feedback can affect which draw modes are valid. We can use the exiting draw modes cache to save having to check the draw modes twice. We update the cached draw modes on any change to the transform feedback activity state. e.g. when transform feedback is started, or resumed. There are also spec changes that comes into effect in ES 3.2 or when EXT_geometry_shader is enabled. Again we cache these draw modes in the packed valid draw modes map. Will allow for faster validation for draw calls once the other checks for transform feedback are optimized. Also adds a new regression test. Bug: angleproject:2966 Change-Id: Iab901e45aab70980b9e631ec8383fdeadbd32368 Reviewed-on: https://chromium-review.googlesource.com/c/1357149 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Yuly Novikov <ynovikov@chromium.org>
Shahbaz Youssefi b08457df 2018-12-11T15:13:54 Vulkan: Make flushAfterVertexConversion workaround Nexus5X-specific Workaround added in 611bbaabb28cf4231ad0a138cd7bc21fe559ea02 is likely Nexus5X-specific. This commit detects the phone and enables the workaround only on that. Bug: angleproject:2958, angleproject:3009 Change-Id: I9ab230d4aa690fd92e3d2d84ad98c159128c1093 Reviewed-on: https://chromium-review.googlesource.com/c/1372445 Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Yuly Novikov 64f62f4a 2018-12-12T11:57:35 Skip external texture ImageTest tests on Ozone Since Ozone supports external target only for images created with EGL_EXT_image_dma_buf_import Bug: 914146, angleproject:2507 Change-Id: I454b26bbb7aa8ed638045dc0c9c98065c9ed76e4 Reviewed-on: https://chromium-review.googlesource.com/c/1374269 Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Commit-Queue: Yuly Novikov <ynovikov@chromium.org>
Qin Jiajia 88faa696 2018-12-03T16:22:24 ES31: Add unsized array length support in SSBO Bug: angleproject:1951 Change-Id: I10c798c62a741b156f5b614e0df0795c0e845108 Reviewed-on: https://chromium-review.googlesource.com/c/1365154 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Jiajia Qin <jiajia.qin@intel.com>
Qin Jiajia a48f26fb 2018-12-11T16:54:51 ES31: Use deepCopy to make sure that every node being used only once This patch uses deepCopy for nodes which are used more than once in the SSBO traverser. Bug: angleproject:1951 Change-Id: Ie8e03d4f595484a1e2ca0397ed30a7f484add607 Reviewed-on: https://chromium-review.googlesource.com/c/1370678 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jiajia Qin <jiajia.qin@intel.com>
Jamie Madill 3a256228 2018-12-08T09:56:39 Update ANGLE_multiview validation. Multiview transform feedback now passes if the transform feedback is paused. Also updates the relevant validation. This aligns the ANGLE_multiview validation with OVR_multivew and with the WebGL extension spec. This change allow us to combine multiple draw call validation updates into one update function. Bug: angleproject:3012 Change-Id: I2ce04edc386039134198afa1792201e03cc20490 Reviewed-on: https://chromium-review.googlesource.com/c/1357148 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Shahbaz Youssefi 611bbaab 2018-12-06T01:59:53 Vulkan: Convert vertex attributes in compute In this commit, VertexArrayVk::convertVertexBuffer() is renamed to VertexArrayVk::convertVertexBufferCpu() to explicitly show it does a CPU readback. A new VertexArrayVk::convertVertexBuffer() function is added that has the same functionality in gpu (with some assumptions, where the CPU fallback is used should those assumptions fail). Currently, the only requirement is that buffer offset/stride are divided by the component size. ConvertVertex.comp is the shader responsible for this conversion, and it implements the functionality in renderer/copyvertex.inc, minus a few functions that are not used in the Vulkan backend. Bug: angleproject:2958, angleproject:3009 Change-Id: I8ec9a5f4672509bcf7b9e352cd27663970ad4653 Reviewed-on: https://chromium-review.googlesource.com/c/1364451 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Yuly Novikov <ynovikov@chromium.org>
Geoff Lang be607ad6 2018-11-29T10:14:22 GL: Implement GL_OES_EGL_image_external and GL_OES_EGL_image_external_essl3 Chrome uses external textures as part of its hardware video decode paths on Android. BUG=angleproject:2507 Change-Id: I2af608f84a99843c99a16dcfb9fb2fa28cc8fbb6 Reviewed-on: https://chromium-review.googlesource.com/c/1361480 Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Commit-Queue: Geoff Lang <geofflang@chromium.org>
Jamie Madill f5c88e7e 2018-12-08T09:56:38 Refactor and inline DrawElements validation. This moves ValidateDrawBase into a common inline function. It also moves some checks in ValidateDrawElementsCommon into ValidateDrawElementsBase. "Base" is called from DrawElementsIndirect while "Common" is only called from non-indirect entry points. But this improves conformance because the missing checks in "Base" apply to DrawIndirect as well. In a follow-up patch many checks in "Base" will be cached into a single value. Much like what we did for ValidateDrawBase. Also inlines ValidateDrawElements which just calls through to "Common". Bug: angleproject:2966 Change-Id: Ibe0c5db25f403dd52a50dc73373ebb50cedad003 Reviewed-on: https://chromium-review.googlesource.com/c/1357147 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Yuly Novikov <ynovikov@chromium.org>
Shahbaz Youssefi 149eb33b 2018-12-08T14:53:49 Vulkan: add possibility to build subset of shaders As the number of internal shaders grow, it's helpful in development time to be able to build variations of a specific shader, instead of building everything every time. With this commit, one can do: $ python gen_vk_internal_shaders.py SubString which will result in compilation of shaders whose name matches the glob *SubString*. Bug: angleproject:2958 Change-Id: I3b18d7e32e2ec4317531a7655eb2c6148cea177b Reviewed-on: https://chromium-review.googlesource.com/c/1369285 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Yuly Novikov <ynovikov@chromium.org>
Austin Eng 153e0224 2018-12-07T13:31:31 Add gl_DrawID emulation for ESSL3 with ANGLE_multi_draw Bug: chromium:890539 Change-Id: I3d9a9429608afb454f076013f3ed844e115c56cc Reviewed-on: https://chromium-review.googlesource.com/c/1368784 Reviewed-by: Kai Ninomiya <kainino@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Austin Eng <enga@chromium.org>
Qin Jiajia 19f2f9eb 2018-12-07T15:10:48 Mark variable to call 'length()' as statically used Bug: angleproject:3008 Change-Id: I8779706c667f49fddb0a741f5bf31c4af54db3e7 Reviewed-on: https://chromium-review.googlesource.com/c/1367404 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jiajia Qin <jiajia.qin@intel.com>
Shahbaz Youssefi 7ef08391 2018-12-07T16:38:21 Vulkan: add test to verify attrib default value dirty handling Companion test to 0c2dc8c378bb288ab9ccfff078fc222d2b99b1a4. Bug: angleproject:2786 Change-Id: Idfbd557dcf6b6bf7e62821ec554bdb3138b616ab Reviewed-on: https://chromium-review.googlesource.com/c/1367750 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Shahbaz Youssefi 5c4af666 2018-12-07T06:31:00 Vulkan: unix line endings in generated shaders Bug: angleproject:3007 Change-Id: I466caa92ae337508ae284b6fb8d38f5fa3ea1042 Reviewed-on: https://chromium-review.googlesource.com/c/1366796 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Ian Elliott 33484b97 2018-12-06T14:38:59 A4A opt-in/out: add TestRuleProcess test and use a test fixture The new TestRuleProcess test tests the full rule-processing paths. The test fixture reduces code duplication. Bug: angleproject:2993 Change-Id: Ia07ea408fb771dfd1a21cc2fd4610e0e88f529ea Reviewed-on: https://chromium-review.googlesource.com/c/1366314 Commit-Queue: Ian Elliott <ianelliott@google.com> Reviewed-by: Yuly Novikov <ynovikov@chromium.org>
Shahbaz Youssefi 0c2dc8c3 2018-12-07T08:00:49 Vulkan: Fix dirty default attributes handling When invalidating default attributes, the mask to invalidate was set as the current dirty mask, but it should have been or'ed with it. The following test triggered a validation error on Linux: dEQP.GLES2/functional_default_vertex_attrib_mat4_vertex_attrib_4fv In this test, Vertex Array Bindings and Program dirty bits would set the default attrib dirty mask to all the default attributes, but the handling of Current Values dirty bits would mistakenly remove some of those dirty bits. Bug: angleproject:2786 Change-Id: Ife96621da7646102c1ce3b24e45f405e34a08b40 Reviewed-on: https://chromium-review.googlesource.com/c/1366797 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Qin Jiajia e14feaf5 2018-11-29T16:29:54 ES31: support ssbo as an argument of aggregate type BUG: angleproject:1951 Change-Id: Icaab8ffd0ee88cca22ba79a9f0d4e02c9134a169 Reviewed-on: https://chromium-review.googlesource.com/c/1349071 Commit-Queue: Jiajia Qin <jiajia.qin@intel.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 7c985f5c 2018-11-29T18:16:17 Make angle::Result an enum. This moves away from a class type to a value type. This should improve performance when using angle::Result as a return value. Previously the generated code would return a pointer instead of a value. Improves performance in the most targeted microbenchmark by 10%. In more realistic scanarios it will have a smaller improvement. Also simplifies the class implementation and usage. Includes some unrelated code generation changes. Bug: angleproject:2491 Change-Id: Ifcf86870bf1c00a2f73c39ea6e4f05ca705050aa Reviewed-on: https://chromium-review.googlesource.com/c/1356139 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill c3e3731c 2018-11-30T15:25:39 Give every validation error a constant. Makes the code more consistent and organized. Also reduces binary size by about 4k. Also refactors validation for GetBufferPointerv. Bug: angleproject:2957 Change-Id: Ib076ce936193e9840eef2499bf815489cdb48479 Reviewed-on: https://chromium-review.googlesource.com/c/1350489 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Yuly Novikov <ynovikov@chromium.org>
Shahbaz Youssefi ec06305b 2018-12-06T01:58:06 Vulkan: Add dynamic vertex buffers to graph With DynamicBuffer outputting BufferHelper objects, these objects can participate in the command graph, i.e. record commands. This means they need appropriate dependencies in the graph as well as pipeline barriers. There are a few users of DynamicBuffer for which this change should be applied to. This change covers vertex attribute buffers. Bug: angleproject:2958 Change-Id: Ic3f8e187639919aba23102bba238de9ce70e6394 Reviewed-on: https://chromium-review.googlesource.com/c/1364450 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Jamie Madill 132d15c2 2018-11-30T15:25:38 Clear uncleared textures as a dirty object. This removes the check for robust resource init from prepareForDraw. It should improve performance more when WebGL compatiblity is enabled. Also inlines Context::syncDirtyBits and Context::prepareForDraw. Reduces CPU overhead in all draw and dispatch calls up to 5%. Bug: angleproject:2966 Change-Id: I7e9009a501c0331a6140bc78678aef27e38c3df2 Reviewed-on: https://chromium-review.googlesource.com/c/1347453 Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Ian Elliott 9092bdc7 2018-12-06T09:38:15 Fix crash in A4A opt-in/out logic. The Device::match() method used to call the old ListOf<T>::match() method with ListOf<T>::front(), assuming that front() always returned a valid object reference. It did not (e.g. the default rule had a wildcarded device that had no GPU). A new ListOf<T>::match() was created (for the GPU case) that compares to ListOf<T> objects. If either/both is wildcarded, true is quickly returned. If both are not wildcarded, they will have one or more T's, and these are iterated through (one in the new method, and one by calling the old method). During rule processing, it is safe to directly call the old method for a Rule's ListOf<{Device|Application}>, and so the old method is retained. Change-Id: Iea47075c38dc45eb32e1810c4997b8cfb2fe9ec3 Reviewed-on: https://chromium-review.googlesource.com/c/1365678 Commit-Queue: Ian Elliott <ianelliott@google.com> Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Courtney Goeltzenleuchter <courtneygo@google.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Austin Eng d300548f 2018-12-05T14:04:09 Add ANGLE_multi_draw entrypoints to proc table Bug: chromium:890539 Change-Id: Iddd4b02d218ea11ccd77de139fd060bed4996bc2 Reviewed-on: https://chromium-review.googlesource.com/c/1363931 Commit-Queue: Austin Eng <enga@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Shahbaz Youssefi 8f1b7a66 2018-11-14T16:02:54 Vulkan: Add DispatchUtilsVK This class provides a set of compute-based internal utilities. Currently, buffer clear and copy are implemented. Other possibilities include more efficient mip map generation, or specialized texture operations. VertexArrayVk::updateIndexTranslation() is updated to convert the GL_UNSIGNED_BYTE index buffer to a GL_UNSIGNED_SHORT one using this class to avoid a CPU readback. The vk::Format class is augmented with a few flags (IsInt, IsUnsigned) to be able to select the appropriate shader based on the format (float, int or uint). Bug: angleproject:2958,angleproject:3003 Change-Id: Ie35519deb3c32a3da5ccf74080c70092c9287f0a Reviewed-on: https://chromium-review.googlesource.com/c/1336307 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Tim Van Patten fdccaa3a 2018-11-01T17:47:10 Enhance ANGLE for Android Developer Options Update ANGLE Developer Options Update ANGLE developer options to allow selecting the OpenGL driver (default, ANGLE, native) for each app as well as forcing ANGLE for all apps. Bug: angleproject:2962 Test: Verify the default/ANGLE/native values are saved and applied and used by the loader. Change-Id: I6737b11bc061318cf8438c8161593ca70239590f Reviewed-on: https://chromium-review.googlesource.com/c/1354101 Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Tim Van Patten <timvp@google.com>
Shahbaz Youssefi eae081c6 2018-12-03T22:32:32 Vulkan: Fix ASTC_12x12_SRGB_BLOCK support A typo in the .json file made this format unavailable. Bug: angleproject:2357 Change-Id: I3214c6d8a00d9fa731573347b06bded8fb57a918 Reviewed-on: https://chromium-review.googlesource.com/c/1359619 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Shahbaz Youssefi 96bd8fdf 2018-11-30T14:30:18 Vulkan: Fix format properties queries When querying format properties (in vk::GetFormatProperties), the mandatory feature support table was consulted to check whether a number of texture features are present. If so, the entry from that table was returned. The goal had been to speed up initialization by not issuing device queries if possible. That is, when vk::GetFormatProperties was called on a format, if it supported that select few texture features, the VkFormatProperties entry from the mandatory table would be returned. However, that function found its way to other uses (such as querying buffer format properties, or other image properties beyond the select few). As a result, when the VkFormatProperties from the mandatory table was returned, actual support for these other features was often not tested and assumed false (unless they happened to be mandatory as well). This commit reworks the format feature query functions such that the specific features to be tested are provided when querying the format properties. The mandatory table is consulted as before, and if the entry doesn't contain those features, the device is queried and the results cached. Bug: angleproject:2958 Change-Id: I28d046eb63c3bd5173468aa4cb3e4c63c83e67b1 Reviewed-on: https://chromium-review.googlesource.com/c/1357152 Reviewed-by: Tobin Ehlis <tobine@google.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Qin Jiajia 81a880aa 2018-11-12T15:53:34 ES31: support ssbo as binary operand This patch will process ssbo as compound assignment binary operand or readonly binary operand. BUG: angleproject:1951 Change-Id: I4a0da77649d719fa08e6bf4c3d9ace58dbfb7aab Reviewed-on: https://chromium-review.googlesource.com/c/1349449 Commit-Queue: Jiajia Qin <jiajia.qin@intel.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Cody Northrop 8e636443 2018-11-30T16:24:11 Generate multiple Android APKs This change moves the generation of Android APKs into a template function so it can be called multiple times with different parameters. The two packages generated only differ by package name and APK name, but this lays the framework for easy future changes. Bug: angleproject:3004 Change-Id: I6c27d379bfa5f5c2912bf04cb748983787e385ac Reviewed-on: https://chromium-review.googlesource.com/c/1361381 Commit-Queue: Cody Northrop <cnorthrop@google.com> Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Reviewed-by: Courtney Goeltzenleuchter <courtneygo@google.com> Reviewed-by: Tim Van Patten <timvp@google.com>
Shahbaz Youssefi 654b3c56 2018-12-03T21:59:35 Vulkan: Fix multi-layer image readback The buffer size did not take layer count into account. angleproject: 2828 Change-Id: I94b9294503d785d3e727422550d7e4643eed1917 Reviewed-on: https://chromium-review.googlesource.com/c/1359618 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill e3e680ca 2018-12-03T17:49:08 Remove State::syncProgramTextures. Removes the concept of the program textures dirty object. Instead we use a set of dirty bits to represent dirty texture samples. We mark certain textures dirty and update state structures whenever there is a new Texture/Program/Sampler bound, or when Texture/Program/Sampler state changes. This is in preparation for making clearing the uncleared active textures into a dirty bit as well. Also includes new dirty bit handling for texture image units. These are a GLES 3.1 feature. Bug: angleproject:2966 Change-Id: Ibb8619dd2669bb39fdbcd75e3685be9a8aeeee91 Reviewed-on: https://chromium-review.googlesource.com/c/1346649 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Jamie Madill ff03e51e 2018-12-03T17:47:38 Copy PDBs in update_canary_angle. A change in Chromium's build tools caused symbol paths to become relative. Since copying dlls no longer links back to the build directory we need to copy the PDBs as well to get debuggging symbols. Bug: angleproject:3001 Change-Id: I54d9a1d57d3c69d81d68913993653bab61fa4e65 Reviewed-on: https://chromium-review.googlesource.com/c/1358645 Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 66f0d2c1 2018-11-30T15:25:36 Make Framebuffer attachments angle::Subjects. Now that there's storage change notifications in the GL front-end we no longer need to give the back-end access to the angle::Subject. The Texture object is a special case where it has mirrored dirty bits. To keep the gl::Texture class notified of when the Impl has dirty bits we make the TextureImpl class an angle::Subject that is observed by the gl::Texture class. This will enable further dirty bits improvements. Bug: angleproject:2966 Change-Id: Id22da0926f51ff4679e58af3e62903f4d7948915 Reviewed-on: https://chromium-review.googlesource.com/c/1347670 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jamie Madill c10a023a 2018-12-03T10:13:36 Fix fuchsia build of libfeature_support. This enables the linux path for GetSystemInfo on fuchsia. Tested locally and fixes the build. Bug: angleproject:2996 Change-Id: Icc8f282a66ff43ae9c74545a9dcee2d4af8a21e0 Reviewed-on: https://chromium-review.googlesource.com/c/1358632 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Nico Weber ce0a8f3c 2018-12-03T09:06:02 List vulkan_core.h as input of generate_vulkan_layers_json.py. Since this was missing, the layer json files didn't get regenerated on vulkan rolls, leading to stale generated json files, which in turn led to incremental builds having different files in the swarming isolate than full builds. To make this type of bug harder to introduce, rewrite generate_vulkan_layers_json.py a bit: - pass in path to vulkan_core.h as an argument - also pass in the input .json / .json.in files as arguments, so that the script re-runs if a .json or .json.in input is added or removed, and in the script verify that the passed-in list matches the glob() the script did previously (this verifies that the sources list in the .gn file is up-to-date with the state on disk) - generate outputs list in gn from sources list, to make sure they're in sync - use an expicit --icd flag instead of doing `'icd' in path` - fail when failing to extract vk_version instead of silently using a default - some minor python style fixes Bug: chromium:910699,chromium:869348 Change-Id: I1e598f4566697a7f1ef56b040e52d0717f7ad075 Reviewed-on: https://chromium-review.googlesource.com/c/1358631 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Nico Weber <thakis@chromium.org>
Tom Tan 5c317537 2018-11-30T17:01:01 Don't copy d3dcompiler_47.dll when build target is Windows ARM64 Windows ARM64 was first released at 10.0.16299 which contains d3dcompiler_47.dll under %systemroot%\system32, so no need to copy it from Windows SDK. For the same reason, it is also not included as part of redistribute package for Windows ARM64. Bug: chromium:893460 Change-Id: I175ce831d800ec1f19c767fc172219f6b693fec3 Reviewed-on: https://chromium-review.googlesource.com/c/1357155 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 35cd7332 2018-12-02T12:03:33 Refactor test shader style. This change enforces a lot more consistency. We pass const char * to the Compile functions instead of std::string. Also fixes the indentation of C++11 block comments to be more consistent. Bug: angleproject:2995 Change-Id: Id6e5ea94055d8cbd420df4ea2e81b2d96cb5ce78 Reviewed-on: https://chromium-review.googlesource.com/c/1357103 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Shahbaz Youssefi 4abdf74f 2018-11-28T14:41:10 Vulkan: Add dynamic index buffers to graph With DynamicBuffer outputting BufferHelper objects, these objects can participate in the command graph, i.e. record commands. This means they need appropriate dependencies in the graph as well as pipeline barriers. There are a few users of DynamicBuffer for which this change should be applied to. This change covers index buffers. This commit includes a fix to BufferHelper::copyFromBuffer for WaW hazards. It also includes a fix for a missing pipeline barrier after BufferVk::copyToBuffer. Bug: angleproject:2958 Change-Id: I3e61af56936580b2da20c28c45defece552d9a39 Reviewed-on: https://chromium-review.googlesource.com/c/1352732 Reviewed-by: Tobin Ehlis <tobine@google.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Ian Elliott a9d579e8 2018-11-28T11:44:48 Version-2 API of the A4A opt-in/out (a.k.a. feature-support utilities) This version-2 API splits up and renames parts of the version-1 API. Some initial unit tests were added. The code is now built and tested on Linux, Windows, and Mac (in addition to Android, which is where it's being used). Memory leaks were fixed and some memory/list-management TODOs were also dealt with (associated with an Android bug). Some review items deferred. See: angleproject:2993 Bug: angleproject:2794 Bug: b/113346561 Change-Id: Iff307f9347fb05a733fe96b6774fb32d36e25590 Reviewed-on: https://chromium-review.googlesource.com/c/1291837 Reviewed-by: Ian Elliott <ianelliott@google.com> Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Commit-Queue: Ian Elliott <ianelliott@google.com>
Tobin Ehlis 317a9ebd 2018-11-29T12:51:46 Vulkan: Roll VK deps forward Roll VK Headers/Loader/ValidationLayers forward. There's a build improvement as well as many new checks. Added new source file dep, convert_to_renderpass2.cpp, used by core_ validation for added RenderPass2 checks. Also had to move glslang fwd for shader validation layer so updated from confusing upstream branch of glslang that's integrated with shaderc to the independent Khronos glslang repo. Bug: angleproject:2937 Bug: chromium:845519 Change-Id: Ifee911f061dc426404c09499e49c2f029b174d03 Reviewed-on: https://chromium-review.googlesource.com/c/1355508 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Tobin Ehlis <tobine@google.com>
Shahbaz Youssefi b51eb09f 2018-11-29T10:48:36 Vulkan: Allow bindings to compute stage Includes both binding of resources and updating push constants on the compute shader stage. Bug: angleproject:2958 Change-Id: I5686cbac81e0dd83d0e938cb40f9f9ac7d2ef48a Reviewed-on: https://chromium-review.googlesource.com/c/1355500 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Shahbaz Youssefi df8c1053 2018-11-29T11:49:45 Vulkan: Uber-shader generated code optimization Refactors code out of generated functions into a common function and simplifies assertions. Bug: angleproject:2958 Change-Id: I896c2304c3ac1e043c16f9ecf81fa8b72a6b87c0 Reviewed-on: https://chromium-review.googlesource.com/c/1355501 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>