src/tests


Log

Author Commit Date CI Message
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>
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 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>
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>
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>
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>
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>
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>
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>
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>
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>
Jamie Madill 8dc27f99 2018-11-29T11:45:44 Use packed enum for DrawElementsType. The packing and unpacking take a few extra instructions. But it completely obviates the need for any switches in the validation code. Speed is slightly faster or the similar depending on the back-end. Also add gl_angle_ext.xml to GL entry point generator inputs. This was missing and would cause the code generation to miss certain changes. Bug: angleproject:2985 Change-Id: I1ea41a71db71135000166ead8305ec42d22ff7b3 Reviewed-on: https://chromium-review.googlesource.com/c/1351729 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Shahbaz Youssefi 5f01324f 2018-11-26T12:41:12 Vulkan: Allow descriptor pool to allocate different types The internal shaders know exactly what mix of resources they use, so with this change they can make one allocation of multiple types. Bug: angleproject:2958 Change-Id: Ia6f03672b95af4be9618a2f5eeb41ef1c027e810 Reviewed-on: https://chromium-review.googlesource.com/c/1351116 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Yizhou Jiang 7310da33 2018-11-05T14:40:01 Implement GetMultismaplefvANGLE and SampleMaskiANGLE of texture multisample extension This patch adds GetMultismaplefvANGLE and SampleMaskiANGLE api. TEST=TextureMultisampleTest.CheckSamplePositions* TEST=NegativeTextureMultisampleTest.Negtive* BUG=angleproject:2275 Change-Id: Ib1e8b856059229bbe88328a28cf2a892f4673214 Reviewed-on: https://chromium-review.googlesource.com/c/1319252 Commit-Queue: Yizhou Jiang <yizhou.jiang@intel.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 2c0d6a94 2018-11-28T14:03:58 WebGL: Fix DrawElements test and remove size check. Also optimizes the DrawElements validation to remove redundant tests. Also make some more validation WebGL-specific. Bug: angleproject:2979 Change-Id: I2d5c3094ed86ebadbc572e46b8ae105431f7ae68 Reviewed-on: https://chromium-review.googlesource.com/c/1343139 Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Austin Eng 3b7c9d09 2018-11-21T18:09:05 Change offsets in MultiDrawElements* entrypoints to match glMultiDrawElements This patch changes arguments for MultiDrawElements and MultiDrawElementsInstanced from from GLsizei *offsets to const* GLvoid* indices. Bug: chromium:890539 Change-Id: I2124cf2daeaa6af0f889f3c46aa2b8c77be200a6 Reviewed-on: https://chromium-review.googlesource.com/c/1352591 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Kai Ninomiya <kainino@chromium.org> Commit-Queue: Austin Eng <enga@chromium.org>
Jamie Madill 4f6592fa 2018-11-27T16:37:45 Remove gl::Error. Removes several TODOs. Only egl::Error remains. Also slightly decreases binary size. Bug: angleproject:2491 Change-Id: I3a9d1c22eb0884ca9e37362463fddd0083faf826 Reviewed-on: https://chromium-review.googlesource.com/c/1337462 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Yuly Novikov <ynovikov@chromium.org>
Jamie Madill e0472f3d 2018-11-27T16:32:45 Slight refactor to ErrorStrings.h. Allows for better readability. Also sort the error strings by ID. Bug: angleproject:2957 Change-Id: Ib3900a4c90507ac84496fd5ff916417eb768667b Reviewed-on: https://chromium-review.googlesource.com/c/1337461 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Yuly Novikov <ynovikov@chromium.org>
Jamie Madill 752d220a 2018-11-27T13:29:48 Use flat enum for PrimitiveMode. The GLenum was already mostly packed. There were just a few missing values because of the exclusion of things like GL_QUADS and GL_POLYGON from GLES. Also update the PackedEnumMap initialization to take an intializer. The initializer is a list of key/values which is much more robust to changes in the packed map. Improves draw call speed slightly as there is no conversion needed any more for the mode enum. Bug: angleproject:2966 Change-Id: Icae658272c6234f29335f6a57a63cf341cf5b2a0 Reviewed-on: https://chromium-review.googlesource.com/c/1346529 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Geoff Lang 11bfe6fa 2018-11-27T13:24:22 Supress RobustResourceInitTestES3.MaskedStencilClearBuffer on Linux OpenGL This test flakes on many platforms. BUG=angleproject:2408 BUG=angleproject:2407 Change-Id: I9e8ff8aedc02962656c1a336c3f34191920ae8c7 Reviewed-on: https://chromium-review.googlesource.com/c/1352222 Commit-Queue: Geoff Lang <geofflang@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill b980c563 2018-11-27T11:34:27 Reformat all cpp and h files. This applies git cl format --full to all ANGLE sources. Bug: angleproject:2986 Change-Id: Ib504e618c1589332a37e97696cdc3515d739308f Reviewed-on: https://chromium-review.googlesource.com/c/1351367 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Qin Jiajia 6494c415 2018-11-05T15:46:04 ES31: Add swizzle support in SSBO (Part 1) This patch adds the swizzle process if the swizzle node is the last node in ssbo access chain. Bug: angleproject:1951 Change-Id: Iecc95baa45e8cc40be9111a15398c7e858bfb99e Reviewed-on: https://chromium-review.googlesource.com/c/1341234 Commit-Queue: Jiajia Qin <jiajia.qin@intel.com> Reviewed-by: Geoff Lang <geofflang@chromium.org>
James Darpinian 471b8d4c 2018-11-21T15:37:47 WebGL, D3D: Forbid multiple TF outputs in one buffer Implementing a WebGL spec change: https://github.com/KhronosGroup/WebGL/pull/2658 Fixes WebGL 2 conformance test: conformance2/transform_feedback/same-buffer-two-binding-points.html Also applying the change to D3D backends because they can't support multiple transform feedback outputs in one buffer. Bug: chromium:866089 Change-Id: I8d7eda14225c13efb7ca1ed974239332be4e79a6 Reviewed-on: https://chromium-review.googlesource.com/c/1347749 Commit-Queue: James Darpinian <jdarpinian@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Geoff Lang 7198ebc4 2018-11-22T14:36:06 GL: Work around Qualcomm sRGB ReadPixels driver bug. When calling glReadPixels on unsized sRGB textures, the data returned is not linearized. Using sized sRGB formats works around this problem. Fix SRGBTextureTest assuming that unsized SRGB formats work in ES3. BUG=angleproject:2977 Change-Id: I413c888ca0c3564ecdc364f3ea693e75ed4f8d6d Reviewed-on: https://chromium-review.googlesource.com/c/1343138 Reviewed-by: Tobin Ehlis <tobine@google.com> Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Geoff Lang <geofflang@chromium.org>
Geoff Lang 617103ed 2018-11-22T13:18:05 GL: Implement GL_NV_fence on top of GLsync objects. When ANGLE exposes an ES2 context, there is often no way to create fence objects because GL_NV_fence is not available. BUG=882580 Change-Id: Ic18539e0243317a188545f3945f6b33d3401f1a8 Reviewed-on: https://chromium-review.googlesource.com/c/1348769 Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Geoff Lang <geofflang@chromium.org>
Qin Jiajia 15992bef 2018-11-22T09:35:49 Update deqp31 test expectations Below deqp cases already pass: dEQP-GLES31.functional.layout_binding.ubo.* dEQP-GLES31.functional.shaders.builtin_functions.*compute* BUG=angleproject:1951, angleproject:2759, angleproject:2619 Change-Id: I5541840462b792e83b4745c50e3c3d2c94db7745 Reviewed-on: https://chromium-review.googlesource.com/c/1347750 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jiajia Qin <jiajia.qin@intel.com>
Geoff Lang 6aab06e0 2018-11-20T14:04:11 Don't allow unary operators on void types. BUG=900058 Change-Id: Ice8976ddd9cbc9c90162cf7fae2b8f91ddcfcef3 Reviewed-on: https://chromium-review.googlesource.com/c/1344590 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Commit-Queue: Geoff Lang <geofflang@chromium.org>
Geoff Lang ab130438 2018-11-20T14:09:50 Skip SetUp and TearDown in VulkanCommandBufferPerfTest if its flaky. BUG=angleproject:2923 Change-Id: Id201efa09bcc67d4e40154e2362bf4b78ffd5652 Reviewed-on: https://chromium-review.googlesource.com/c/1344591 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Geoff Lang <geofflang@chromium.org>
Jamie Madill 35fd3063 2018-11-20T10:02:48 Use xxHash for faster hash map lookups. This most strongly affects the Vulkan back-end which uses a hash map to cache VkPipelines. It also should speed up some parts of the D3D11 back-end. Bug: angleproject:2522 Change-Id: I10801654f043abce17339c30d7bf62bc8644e49c Reviewed-on: https://chromium-review.googlesource.com/c/1316889 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 0e604f9f 2018-11-19T21:33:25 ANGLE Perf Test fixes. Includes the following fixes: * Removes obsolete global variable. * Disables trace event collection when trace events disabled. * Fixes calibrated steps getting stuck after first test. * Scale calibrated steps with actual time after glFinish. Should fix a few crashes and timeouts with the perf tests. Bug: angleproject:2923 Change-Id: I9ba1c042dee31cf2400ccbeedca0d497ed52fb12 Reviewed-on: https://chromium-review.googlesource.com/c/1343677 Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Qin Jiajia b81ff9e6 2018-10-26T17:20:50 ES31: Add std430 encoder. Bug: angleproject:1951 Change-Id: I5e469ee5f13604102b0ee268d5bf9f5ac4809ecd Reviewed-on: https://chromium-review.googlesource.com/c/1278098 Commit-Queue: Jiajia Qin <jiajia.qin@intel.com> Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Jamie Madill 8a0fb48a 2018-11-19T11:53:36 Vulkan: Suppress functional.shaders.invariance.* on NV. Bug: angleproject:2976 Change-Id: If38669ca13297b17d55c03c977f4028cb03f6f34 Reviewed-on: https://chromium-review.googlesource.com/c/1342421 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jamie Madill e4634a13 2018-11-14T09:54:35 Apply code formatting. Several files were formatted by the code generation script. Bug: angleproject:2957 Change-Id: I8a5cbf2c17297a3644686004a8981ab2305c1ada Reviewed-on: https://chromium-review.googlesource.com/c/1334428 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Shahbaz Youssefi c30f45d3 2018-11-12T16:37:59 Vulkan: Rename PipelineDesc/Cache to Graphics& PipelineDesc describes a Vertex-Fragment pipeline and PipelineCache (not to be confused with vk::PipelineCache) implements a cache of such pipeline objects. In preparation for Compute support, these data structures are prefixed with Graphics. Bug: angleproject:2959 Change-Id: I9181586fb946b787216ca0b2ad6340f90c3ab55f Reviewed-on: https://chromium-review.googlesource.com/c/1333971 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Geoff Lang 3e92206b 2018-11-15T11:26:29 Allow querying of all draw buffer states on the default framebuffer. Because the default framebuffer isn't tied to a specific context, its drawbuffer state vector was only of size 1. It is still valid to query up to GL_MAX_DRAW_BUFFERS through so a special case is added when the drawbuffer is larger than the state vector. BUG=angleproject:2965 Change-Id: Ib49570df67e59e93932a7e916fe72f2e71c29939 Reviewed-on: https://chromium-review.googlesource.com/c/1337453 Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Commit-Queue: Geoff Lang <geofflang@chromium.org>
Jamie Madill 666818ea 2018-11-14T09:54:33 Use angle::Result in front-end (Part 8) Refactors the gl::Texture class and a few related methods. Also reduces binary size by up to 4k. Bug: angleproject:2491 Change-Id: Ib9a69d7f507b0dce35abb17b90532f812bf43214 Reviewed-on: https://chromium-review.googlesource.com/c/1291845 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Yuly Novikov <ynovikov@chromium.org>
Jamie Madill f3acb8c1 2018-11-14T16:24:25 Retool perf test running. This change does a few things involving the way we run the perf tests: - Perf test runner can capture different metrics Useful for capturing the new "nanoSecPerIteration" metric. - Removes the "score" metric We'll move to the new time-based metrics. These new metrics are scaled correctly with iteration counts. - Runs three trials per perf test This gives more measurements per test. Each trial is approximately one second. First the perf tests set a fixed number of iterations after calibrating the number of steps that we can run in one second. After that the three trials are run. This should give more stable results. - Apply more CPU stabilization on Windows Use SetPriorityClass to apply more CPU priority. Also upgrade SetThreadPriority to the highest level. - Always build the Vulkan command buffer test This catches build regressions more easily. We still skip the test on non-Android platforms. Bug: angleproject:2923 Change-Id: I7da234c5af07775ba4a232bb8d65e0138ee7073f Reviewed-on: https://chromium-review.googlesource.com/c/1330262 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Yuly Novikov <ynovikov@chromium.org>
Frank Henigman 1934b786 2018-11-09T17:21:42 Refactor instancing tests. Replace a lot of code with one function that can do all the tests and do them with any divisor and number of instances. BUG=angleproject:2672 Change-Id: I4f7f59d17dad234c524e485d9baa3117fcbb57bd Reviewed-on: https://chromium-review.googlesource.com/c/1330309 Commit-Queue: Frank Henigman <fjhenigman@chromium.org> Reviewed-by: Yuly Novikov <ynovikov@chromium.org>
Geoff Lang ccad5e33 2018-11-14T11:01:16 GL: Work around driver returning negative GL_MAX_SERVER_WAIT_TIMEOUT GL_MAX_SERVER_WAIT_TIMEOUT is only allowed to be positive, ensure that with a std::max. BUG=angleproject:2961 Change-Id: I8dd66df24d35c8ae81038d6d9cd0bad0d51f1a80 Reviewed-on: https://chromium-review.googlesource.com/c/1335889 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Geoff Lang <geofflang@chromium.org>
Shahbaz Youssefi f87bd3dc 2018-11-08T00:30:30 Vulkan: Implement EXT_texture_filter_anisotropic Bug: angleproject:2901 Change-Id: If05b4a5270ac1c0bebc3fc854b2aff710e554ce1 Reviewed-on: https://chromium-review.googlesource.com/c/1325730 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Yuly Novikov <ynovikov@chromium.org>
Shahbaz Youssefi 092481ad 2018-11-08T00:25:50 Vulkan: prepare for ES3 This makes ES3_VULKAN() pass the instantiability test, allowing it to be specified in end2end tests. Bug: angleproject:2950 Change-Id: Ife70a22fb8193f9eebe64bec491a24b47bc76939 Reviewed-on: https://chromium-review.googlesource.com/c/1325729 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Jamie Madill d1a55e39 2018-11-13T17:00:25 Expand dEQP-GLES3 suppressions. These were missing a few suppressions for prior bugs. Going to run this config on the CQ. Bug: chromium:822310 Change-Id: I758d8823ff8b1ab347212426d73c6dad1bb6de39 Reviewed-on: https://chromium-review.googlesource.com/c/1334431 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Shahbaz Youssefi 0864a7ac 2018-11-07T15:50:15 Vulkan: Enable end2end tests for ES2_VULKAN everywhere Used a script to find test files that have more ES2_OPENGL() invocations than ES2_VULKAN(), and added ES2_VULKAN() to those. There may be false negatives. Bug: angleproject:1578 Change-Id: I938eb3571c909879e9276b355a9f1d324880f99a Reviewed-on: https://chromium-review.googlesource.com/c/1324350 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
jchen10 cd47a379 2018-11-11T11:08:16 Add SH_INIT_SHARED_VARIABLES flag This option is used to initialize shared variables to zero at the beginning of shader execution to avoid compute shaders being able to read undefined values that could be coming from another webpage or application. It's implemented by declaring variables with initial value for HLSL. For GLSL, it's not allowed to use declaraction initializer for shared variables, so we need to explicitly assign them to zero at the beginning of main(). This implementation is only for HLSL. Bug: chromium:898030 Change-Id: Ic5906500bf4a35cd9a071923f82f32c5e2991be3 Reviewed-on: https://chromium-review.googlesource.com/c/1330310 Commit-Queue: Jie A Chen <jie.a.chen@intel.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Tim Van Patten 29843628 2018-11-01T17:26:51 Fix failing dEQP EGL tests. dEQP-EGL.functional.query_surface.simple.pbuffer#rgb888_depth_stencil dEQP-EGL.functional.query_surface.simple.pbuffer#rgb888_depth_stencil dEQP-EGL.functional.query_surface.simple.pbuffer#rgb888_depth_no_stencil dEQP-EGL.functional.query_surface.simple.pbuffer#rgb888_no_depth_no_stencil dEQP-EGL.functional.query_surface.simple.pbuffer#rgb565_depth_stencil dEQP-EGL.functional.query_surface.simple.pbuffer#rgb565_depth_no_stencil dEQP-EGL.functional.query_surface.simple.pbuffer#rgb565_no_depth_no_stencil dEQP-EGL.functional.query_surface.simple.pbuffer#rgba8888_no_depth_no_stencil dEQP-EGL.functional.query_surface.simple.pbuffer#rgba8888_depth_no_stencil dEQP-EGL.functional.query_surface.simple.pbuffer#rgba8888_depth_stencil dEQP-EGL.functional.negative_api#choose_config dEQP-EGL.functional.negative_api#swap_interval Bug: angleproject:2546 Change-Id: Ie80e3ee3c65f330d2030b4d7da59cb964e4ea0a5 Reviewed-on: https://chromium-review.googlesource.com/c/1313233 Commit-Queue: Tim Van Patten <timvp@google.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Qin Jiajia 48f63f90 2018-10-26T17:20:50 ES31: add row major matrix support (part 2) This patch implements read/write vector data in matrix or matrix data directly in a shader storage block with row_major qualifier. Bug: angleproject:1951 Change-Id: Id7847e2245b09414709361412a95c4dd84b9ee97 Reviewed-on: https://chromium-review.googlesource.com/c/1304019 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jiajia Qin <jiajia.qin@intel.com>
Shahbaz Youssefi 50bf0429 2018-11-01T23:43:52 Vulkan: add depth-only or stencil-only tests These tests make sure that a depth- or stencil-only format that is emulated with a depth/stencil one does not affect clear/draw in such a way that it would expose the hidden aspect. By nature of the emulation, it's not trivial to read back the hidden aspect. This test simply makes sure the hidden aspect doesn't affect rendering, but is not a definitive test of correctness. Bug: angleproject:2815 Change-Id: I158937faa019487f6fa08154406c152753a1934b Reviewed-on: https://chromium-review.googlesource.com/c/1314188 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Yuly Novikov <ynovikov@chromium.org>
Qin Jiajia 5d2dfa46 2018-11-03T09:28:17 ES31: Add array of arrays support in SSBO Bug: angleproject:1951 Change-Id: I5e92b75a59a3ab24a34b827ae6f968961b8bea49 Reviewed-on: https://chromium-review.googlesource.com/c/1317376 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Jiajia Qin <jiajia.qin@intel.com>
Yizhou Jiang 2fa2147f 2018-11-06T15:52:33 Enable texture multisample extension on ES3 D3D Update maxIntegerSamples, maxDepthTextureSamples and maxColorTextureSamples if the extension is enabled on ES 3.0. TEST=TextureMultisampleTest.* TEST=NegativeTextureMultisampleTest.Negtive* BUG=angleproject:2275 Change-Id: I8c215f990ff5d93611b1bc89de9a43f3d392e8d4 Reviewed-on: https://chromium-review.googlesource.com/c/1319251 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jiajia Qin <jiajia.qin@intel.com> Commit-Queue: Yizhou Jiang <yizhou.jiang@intel.com>
Shahbaz Youssefi d856ca48 2018-10-31T16:55:12 Vulkan: add clear test for emulated stencil or depth formats S8_UINT and D24_UNORM_X8_UINT are the only formats currently that are single-aspect and are possibly emulated with a packed depth-stencil format if it's not supported. A flag to FeaturesVk has been added as a way to force this behavior for the sake of testing. This test is added to ensure the correct clear algorithm is used for this case. Additionally, this case is detected and the other aspect is forcefully cleared to 0 whenever the original aspect is cleared. Bug: angleproject:2815 Change-Id: Ief3039d66bbf46468213b9e3224f7cc7541c3a2e Reviewed-on: https://chromium-review.googlesource.com/c/1312453 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Qin Jiajia 743899de 2018-10-19T13:53:28 ES31: Implement MAX_SHADER_STORAGE_BLOCK_SIZE Bug: angleproject:1951 Change-Id: I6353e6ed10a8b441bfbebc10fa6a07cde1cae7d8 Reviewed-on: https://chromium-review.googlesource.com/c/1317377 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jiajia Qin <jiajia.qin@intel.com>
Shahbaz Youssefi 905ee082 2018-10-26T16:16:34 Vulkan: Fix cleanup race condition on Context destroy In Context::onDestroy(), e7b3fe21866454bd3ea983acede162d34ae03dd8 had moved surface deletion first which down the line caused RendererVk::finish() to be called. bf7b95db6b6f039f6c8797f1f4b930d46a761828 however made surface deletion unnecessary, which means finish was never called. This commit adds an explicit finish in Context::onDestroy(). In truth, the wait is only necessary until all command buffers submitted for this particular context have finished. This optimization is deferred to a possible future work. Bug: angleproject:2811 Change-Id: I56e6c88d3b4a6ec73f70d80d7775a0c85be651ea Reviewed-on: https://chromium-review.googlesource.com/c/1302838 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Austin Eng 1bf18ce9 2018-10-19T15:34:02 Implement GL_ANGLE_multi_draw This patch adds entrypoints glMultiDrawArraysANGLE, glMultiDrawElementsANGLE, glMultiDrawArraysInstancedANGLE, annd glMultiDrawElementsInstancedANGLE Bug: chromium:890539 Change-Id: Ic9c374c53892460f44ca6e73a253b78473ac2dff Reviewed-on: https://chromium-review.googlesource.com/c/1282268 Reviewed-by: Kai Ninomiya <kainino@chromium.org> Commit-Queue: Austin Eng <enga@chromium.org>
Yuly Novikov 37297a4f 2018-11-02T17:04:26 Don't build VulkanCommandBufferPerfTest on Linux Since it's flaky Bug: angleproject:2945 Change-Id: Iac7b465ae1ebefbde3b23267c6974209de664362 Reviewed-on: https://chromium-review.googlesource.com/c/1315836 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Yuly Novikov <ynovikov@chromium.org>
Geoff Lang 1590fcc4 2018-11-01T12:44:39 Add a spec and tests for GL_ANGLE_memory_size. Change the data type of buffer memory sizes to 64 bit integers. BUG=892288 Change-Id: I10e07b86f2ccc0cb61c8d7ee0d439e00d5eb8d3a Reviewed-on: https://chromium-review.googlesource.com/c/1312244 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Geoff Lang <geofflang@chromium.org>
James Clarke 99d0463c 2018-09-20T12:12:43 Windows: add support for SpriteVisuals as a native window type. Enable SpriteVisuals to work along side HWNDs so that Angle rendered content can be hosted with Windows::UI::Composition APIs or XamlIslands in desktop Win32 applications. Includes a whitebox test, verified Win7 compatibility For more info see: https://docs.google.com/document/d/1ggv6H-aK1a3pXNMTtMF6h0Bv0rulIeBpBxBBCJYR6Zs/edit?usp=sharing Bug: angleproject:2947 Change-Id: Id005739553be2a6268cd4543f1b07aaf89760422 Reviewed-on: https://chromium-review.googlesource.com/c/1236844 Commit-Queue: James Clarke <james.clarke@microsoft.com> Commit-Queue: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill caeb1e89 2018-11-01T18:13:22 Vulkan: Allow unlimited simultaneous descriptor sets. This changes the fixed array into a STL vector. Instead of storing Descriptor Pools by value we now store them by pointer. This allows the vector to resize without changing the address of the Descriptor Pool. Also enables some more Vulkan perf tests that were crashing before. Bug: angleproject:2938 Change-Id: I8a88d5315b941c4f54205a9957e2834fe02ada84 Reviewed-on: https://chromium-review.googlesource.com/c/1311395 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Tobin Ehlis <tobine@google.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Yizhou Jiang c0b6c639 2018-09-06T15:02:04 Implement GetTexLevelParameter api of texture multisample extension This patch adds GetTexLevelParameterivANGLE and GetTexLevelParameterfvANGLE. TEST=TextureMultisampleTest.GetTexLevelParameter* TEST=NegativeTextureMultisampleTest.Negtive* BUG=angleproject:2275 Change-Id: Id702ba31df36ab65f46b697d480b5bf01b87e360 Reviewed-on: https://chromium-review.googlesource.com/c/1295830 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Yizhou Jiang <yizhou.jiang@intel.com>
Shahbaz Youssefi 2197dc52 2018-10-30T11:29:58 Vulkan: Implement masked depth & stencil clear This commit also adds tests for clearing depth and stencil with mask/scissor. Bug: angleproject:2540 Change-Id: I30dd840afd6cdd4e3a38c50fcba4c8623513ceb0 Reviewed-on: https://chromium-review.googlesource.com/c/1307585 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Jamie Madill 6bf09284 2018-10-31T13:45:32 Scale down a slow index buffer perf test. This test was slow enough that running 20k iterations might have been causing a timeout on the Nexus 5. Bug: angleproject:2923 Change-Id: I03f6e95135d8c521e6ef3e81bc9a4b0dfd7f19df Reviewed-on: https://chromium-review.googlesource.com/c/1310693 Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Qin Jiajia d60e42f8 2018-10-25T16:33:16 ES31: add row major matrix support (part 1) This is the first patch to enable row major matrix suppot in series. This patch ensures that we can get correct location when we load/store data from matrix. Currently, only scalar data load/store works well. mat2x3 data The location of data[x][y] will be: data.offset + x * scalarStride + y * matrixStride //row_major data.offset + x * matrixStride + y * scalarStride //column_major Bug: angleproject:1951 Change-Id: I5bd7bad7d293219ba610f18eeafc56e70e36de43 Reviewed-on: https://chromium-review.googlesource.com/c/1304017 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Jiajia Qin <jiajia.qin@intel.com>
Jamie Madill 557a1ee4 2018-10-30T17:26:24 Make perf tests faster in correctness-only mode. When running with "--one-frame-only" we can also skip the test warmup. Also we can reduce the internal iteration count to 1 to make the tests as fast as possible. Bug: angleproject:2923 Change-Id: I2f82ae0dd237767ea7b15074e459ed1094ba9943 Reviewed-on: https://chromium-review.googlesource.com/c/1308737 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Shahbaz Youssefi 9a79c889 2018-10-29T17:08:42 Run DifferentStencilMasks tests This test was added and referenced, but was actually never added to the list of files to be compiled. The most recent validation work has been regarding WebGL. This test verifies the behavior when different stencil masks are set for front and back faces, which is unsupported in D3D and disallowed in WebGL. In the interest of running the test on all back ends, and that the validation was modified last to improve WebGL support, the test runs in WebGL compatibility mode. Bug: chromium:806557 Change-Id: I7615b9fc18d4203ed342e23881bea6bdd9b3864c Reviewed-on: https://chromium-review.googlesource.com/c/1306256 Reviewed-by: Kai Ninomiya <kainino@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Jamie Madill 3402d523 2018-10-30T15:14:52 Try to reduce variance in angle_perftests. This change does a few things: - make perf test runner script print % variation instead of stddev This makes it a bit more clear how much variance there is. - stabilize CPU in the render perf tests Setting a thread affinity and priority should stop from switching cores during the run. Hopefully can prevent background noise from changing the test results. - warm up the benchmark with a few iterations This should hopefully make the test results a bit more stable. - output a new normalized perf result value The new result is normalized against the number of iterations. So it should hopefully be stable even if the number of iterations is changed. - increases the iteration count in the draw call perf tests. These tests were completely dominated by SwapBuffers time. Increasing the iterations per step means we actually are bottlenecked on CPU time instead. Bug: angleproject:2923 Change-Id: I5ee347cf93df239ac33b83dc5effe4c21e066736 Reviewed-on: https://chromium-review.googlesource.com/c/1303679 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Yuly Novikov <ynovikov@chromium.org>
Jamie Madill 0ea96210 2018-10-30T15:14:51 Vulkan: Enable more perf tests. Also fixes the check for the correct UINT index extension that wasn't available on Vulkan. Also includes a workaround for the mock ICD not implementing buffer state for index ranges. Bug: angleproject:2923 Change-Id: Iab35809d15f890525a9e658d4148272c46cf1320 Reviewed-on: https://chromium-review.googlesource.com/c/1308733 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Frank Henigman af9dd608 2018-10-29T22:58:56 Fix UpdateAttribBindingByVertexAttribDivisor test. Test should clear before drawing. With the clears added it became apparent the second draw wasn't working because an attrib was left in instanced mode after the first draw. BUG=angleproject:2672 Change-Id: I6c3ee7302d24babb80a9b9affcf357145bb03dcb Reviewed-on: https://chromium-review.googlesource.com/c/1306822 Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Frank Henigman <fjhenigman@chromium.org>
Tobin Ehlis 0da64b5e 2018-10-29T08:54:59 Add build-id to tests for Android This allows Android Studio to correctly match debug symbols. Change-Id: I2bd15e11162d57a3c2cee4434afe6d4831581c25 Reviewed-on: https://chromium-review.googlesource.com/c/1304135 Commit-Queue: Tobin Ehlis <tobine@google.com> Reviewed-by: Courtney Goeltzenleuchter <courtneygo@google.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Shahbaz Youssefi 25224e78 2018-10-22T11:56:02 Vulkan: add GPU trace events RendererVk now tries, as best as it can, to match the CPU and GPU timers on init as well as every finish(). A clock-sync event is generated for each such synchronization point. RendererVk::traceGpuEvent() is a new function that, given a command buffer, performs timestamp queries corresponding to GPU events. These queries are read back when done, without incurring GPU bubbles, at which point an event is generated with that timestamp. Bug: angleproject:2908 Change-Id: I08d7d11ff9f8ad6c9f9a9899767c9cd746d0623e Reviewed-on: https://chromium-review.googlesource.com/c/1296954 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Yuly Novikov <ynovikov@chromium.org>
Brandon Jones 4a22f4b0 2018-10-23T14:36:47 ES31: Add atomic_uint support to HLSL translator This is the first commit in a series to enable atomic counter buffers. Adds support for atomic counters to the GLSL->HLSL translator using RWByteAddressBuffer. Bug: angleproject:1729 Test: angle_end2end_tests Change-Id: I3b7e08f9256dc9bdbcc02ad8910040f2bc14aeac Reviewed-on: https://chromium-review.googlesource.com/c/1291329 Commit-Queue: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Qin Jiajia 8edb7188 2018-10-10T15:54:23 ES31: Add structure field member support in SSBO This patch adds the structure field member support in SSBO. To support it, below things are done: 1. Calculate the offset and arrayStride in SSBO structure. 2. Support array of arrays translation. Bug: angleproject:1951 Change-Id: If8f233e6388d5bb905e78c39a85112d394298138 Reviewed-on: https://chromium-review.googlesource.com/c/1278097 Commit-Queue: Jiajia Qin <jiajia.qin@intel.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Austin Eng 7cf9cd24 2018-10-09T15:27:32 Add flags to shader translator to emulate gl_DrawID Adds support for translating gl_DrawID for implementation of GL_ANGLE_multi_draw. Currently the change only supports and allows emulation of the draw id using a uniform variable named `gl_DrawID`. This uniform is mapped in the translated shader to a hashed name that does not use the gl_ namespace Bug: chromium:890539 Change-Id: I08a246ca911e88e733ccdf22f1ed69dcae948e05 Reviewed-on: https://chromium-review.googlesource.com/c/1271957 Commit-Queue: Austin Eng <enga@chromium.org> Reviewed-by: Kai Ninomiya <kainino@chromium.org>
Till Rathmann b8543630 2018-10-02T19:46:14 Support GL_OES_texture_border_clamp Added support for GL_TEXTURE_BORDER_COLOR and GL_CLAMP_TO_BORDER in OpenGL/OpenGLES, Direct3D9 and Direct3D11 backends. For integer textures in OpenGLES3 contexts these additional entry points are available now: void glTexParameterIivOES(enum target, enum pname, const int *params); void glTexParameterIuivOES(enum target, enum pname, const uint *params); void glGetTexParameterIivOES(enum target, enum pname, int *params); void glGetTexParameterIuivOES(enum target, enum pname, uint *params); void glSamplerParameterIivOES(uint sampler, enum pname, const int *params); void glSamplerParameterIuivOES(uint sampler, enum pname, const uint *params); void glGetSamplerParameterIivOES(uint sampler, enum pname, int *params); void glGetSamplerParameterIuivOES(uint sampler, enum pname, uint *params); BUG=angleproject:2890 TEST=angle_end2end_tests.TextureBorderClamp* Change-Id: Iee3eeb399d8d7851b3b30694ad8f21a2111f5828 Reviewed-on: https://chromium-review.googlesource.com/c/1257824 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Shahbaz Youssefi a390ebd9 2018-10-18T13:04:40 Add compiler printf attribute to relevant functions Relands 27a472c60 with reinterpret_cast changed to C-style cast to support types that are pointers on some platforms and integers on others. This commit includes fixes to undefined behavior caught by this attribute. The following changes have been made: - 0x%0.8p is changed to %016 PRIxPTR. Both 0 and . have undefined behavior with p. Additionally, %p already prints 0x with both gcc and clang. This results in a small output change: void *x = (void *)0x1234; void *y = (void *)0x1234567890abcdef; printf("|%0.8p|\n", x); printf("|%0.8p|\n", y); printf("|%016" PRIxPTR "|\n", (uintptr_t)x); printf("|%016" PRIxPTR "|\n", (uintptr_t)y); prints: |0x00001234| |0x1234567890abcdef| |0x0000000000001234| |0x1234567890abcdef| - %d used for GLintptr, GLsizeiptr, EGLTime and EGLnsecsANDROID is changed to %llu and the relevant argument is cast to unsigned long long. This is due to these types being typedefs to unknown types (on Linux for example, these are unsigned long, and my guess would be unsigned long long on Windows where long is 32 bits). - %llu is used for GLuint64, which could be unsigned long (as is on Linux). Those arguments are cast to unsigned long long. - %p is used for some EGLNative types, but those types may not be a pointer. Those arguments are cast to uintptr_t and printed as above. Bug: angleproject:2928 Change-Id: Idf9f705c3d00f69e41e7603453016276a2e13a64 Reviewed-on: https://chromium-review.googlesource.com/c/1300913 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Jamie Madill e9503ae9 2018-10-25T17:55:04 Revert "Add compiler printf attribute to relevant functions" This reverts commit 27a472c601aa542f48ca5944fb769e2971a0594f. Reason for revert: Causing failures on 32-bit Linux configs: https://logs.chromium.org/logs/chromium/buildbucket/cr-buildbucket.appspot.com/8931673733828416640/+/steps/compile/0/stdout ../../third_party/angle/src/libGLESv2/entry_points_egl.cpp:257:11: error: reinterpret_cast from 'EGLNativeWindowType' (aka 'unsigned long') to 'uintptr_t' (aka 'unsigned int') is not allowed reinterpret_cast<uintptr_t>(win), reinterpret_cast<uintptr_t>(attrib_list)); ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ../../third_party/angle/src/common/debug.h:230:112: note: expanded from macro 'EVENT' #define EVENT(message, ...) gl::ScopedPerfEventHelper scopedPerfEventHelper("%s" message "\n", __FUNCTION__, ##__VA_ARGS__); ^~~~~~~~~~~ ../../third_party/angle/src/libGLESv2/entry_points_egl.cpp:314:11: error: reinterpret_cast from 'EGLNativePixmapType' (aka 'unsigned long') to 'uintptr_t' (aka 'unsigned int') is not allowed reinterpret_cast<uintptr_t>(pixmap), reinterpret_cast<uintptr_t>(attrib_list)); ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Original change's description: > Add compiler printf attribute to relevant functions > > This commit includes fixes to undefined behavior caught by this > attribute. The following changes have been made: > > - 0x%0.8p is changed to %016 PRIxPTR. Both 0 and . have undefined behavior with > p. Additionally, %p already prints 0x with both gcc and clang. This > results in a small output change: > > void *x = (void *)0x1234; > void *y = (void *)0x1234567890abcdef; > > printf("|%0.8p|\n", x); > printf("|%0.8p|\n", y); > > printf("|%016" PRIxPTR "|\n", reinterpret_cast<uintptr_t>(x)); > printf("|%016" PRIxPTR "|\n", reinterpret_cast<uintptr_t>(y)); > > prints: > > |0x00001234| > |0x1234567890abcdef| > |0x0000000000001234| > |0x1234567890abcdef| > > - %d used for GLintptr, GLsizeiptr, EGLTime and EGLnsecsANDROID is > changed to %llu and the relevant argument is cast to unsigned long > long. This is due to these types being typedefs to unknown types (on > Linux for example, these are unsigned long, and my guess would be > unsigned long long on Windows where long is 32 bits). > - %llu is used for GLuint64, which could be unsigned long (as is on > Linux). Those arguments are cast to unsigned long long. > - %p is used for some EGLNative types, but those types may not be a > pointer. Those arguments are cast to uintptr_t and printed as above. > > Bug: angleproject:2928 > Change-Id: I63e9e998c72701ce8582f1ebf25d6374be9090e4 > Reviewed-on: https://chromium-review.googlesource.com/c/1289232 > Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> > Reviewed-by: Yuly Novikov <ynovikov@chromium.org> TBR=ynovikov@chromium.org,jmadill@chromium.org,syoussefi@chromium.org Change-Id: I4f3cea64977bee9f889db6c995371bd2bbc6d81b No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: angleproject:2928 Reviewed-on: https://chromium-review.googlesource.com/c/1299480 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Shahbaz Youssefi 27a472c6 2018-10-18T13:04:40 Add compiler printf attribute to relevant functions This commit includes fixes to undefined behavior caught by this attribute. The following changes have been made: - 0x%0.8p is changed to %016 PRIxPTR. Both 0 and . have undefined behavior with p. Additionally, %p already prints 0x with both gcc and clang. This results in a small output change: void *x = (void *)0x1234; void *y = (void *)0x1234567890abcdef; printf("|%0.8p|\n", x); printf("|%0.8p|\n", y); printf("|%016" PRIxPTR "|\n", reinterpret_cast<uintptr_t>(x)); printf("|%016" PRIxPTR "|\n", reinterpret_cast<uintptr_t>(y)); prints: |0x00001234| |0x1234567890abcdef| |0x0000000000001234| |0x1234567890abcdef| - %d used for GLintptr, GLsizeiptr, EGLTime and EGLnsecsANDROID is changed to %llu and the relevant argument is cast to unsigned long long. This is due to these types being typedefs to unknown types (on Linux for example, these are unsigned long, and my guess would be unsigned long long on Windows where long is 32 bits). - %llu is used for GLuint64, which could be unsigned long (as is on Linux). Those arguments are cast to unsigned long long. - %p is used for some EGLNative types, but those types may not be a pointer. Those arguments are cast to uintptr_t and printed as above. Bug: angleproject:2928 Change-Id: I63e9e998c72701ce8582f1ebf25d6374be9090e4 Reviewed-on: https://chromium-review.googlesource.com/c/1289232 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Yuly Novikov <ynovikov@chromium.org>
Qin Jiajia 672267fc 2018-10-19T17:01:17 ES31: Fix that asuint can't accept bool value This change fixes below errors: error X3013: 'asuint': no matching 1 parameter intrinsic function error X3013: Possible intrinsic functions are: error X3013: asuint(double, out uint x, out uint y) error X3013: asuint(float|half|int|uint) When we store a boolean value, we should cast it to uint firstly. Then do the store. Bug: angleproject:1951 Change-Id: I8931e540d701ef72bb82846496c698acef1ba1fb Reviewed-on: https://chromium-review.googlesource.com/c/1295831 Commit-Queue: Jiajia Qin <jiajia.qin@intel.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Qin Jiajia 19603b9e 2018-10-18T17:25:33 ES31: Allow function call, unary, ternary operators in SSBO When we meet function call, unary or ternary operator in SSBO access chain, we should transfer the process of them to OutputHLSL. Bug: angleproject:1951 Change-Id: I740940ac4eee4c5ed52239f14b1d32b1f9cf9385 Reviewed-on: https://chromium-review.googlesource.com/c/1290470 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Jiajia Qin <jiajia.qin@intel.com>
Yizhou Jiang 7818a85c 2018-09-06T15:02:04 Implement GL_ANGLE_texture_multisample API part Support GL_ANGLE_texture_multisample extension. This patch adds enums of multisampled texture and texStorage2DMultisampleANGLE API. TEST=angle_end2end_tests.exe --gtest_filter=TextureMultisampleTest* TEST=angle_end2end_tests.exe --gtest_filter=NegativeTextureMultisampleTest.Negtive* BUG=angleproject:2275 Change-Id: I2cab997edc33aa2d0be6082381545335423f64e0 Reviewed-on: https://chromium-review.googlesource.com/c/804613 Commit-Queue: Yizhou Jiang <yizhou.jiang@intel.com> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill ae108bd1 2018-10-18T15:00:38 Use angle::Result in front-end (Part 5) Refactors gl::Buffer and implementation. Bug: angleproject:2491 Change-Id: Ic6860dac2faf33067965e7117ea8e98dc6a8dc7a Reviewed-on: https://chromium-review.googlesource.com/c/1283310 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Shahbaz Youssefi acd39d18 2018-10-18T14:45:21 Vulkan: Enable 16bpp texture tests Possibly fixed in 6c6be2cef6c1a8d7a37712aa36d2ef5a1c3990c0. Bug: angleproject:2649 Bug: angleproject:2656 Change-Id: I0ab97e2d828b6b8643a68ab9b28fc0ccd8f08c48 Reviewed-on: https://chromium-review.googlesource.com/c/1289350 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Shahbaz Youssefi c2b576d9 2018-10-12T14:45:34 Vulkan: Implement GL_EXT_disjoint_timer_query - QueryVk::queryCounter() and relevant utils are implemented for the sake of Timestamp queries. - TimeElapsed queries are implemented using two Timestamp queries. Bug: angleproject:2885 Change-Id: Id181bd97f5a24e7e96b3ea1b819483227e64daf0 Reviewed-on: https://chromium-review.googlesource.com/c/1276806 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 4163c014 2018-10-18T10:25:25 Skip Texture2DArrayCopy.UnsignedByteFormats on D3D11. This test appears to be flaky. Bug: angleproject:2896 Change-Id: Ib0c0ac9ab170edf0f31506f847307bee9b78f770 Reviewed-on: https://chromium-review.googlesource.com/c/1286913 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Joonatan Saarhelo 945dea36 2018-10-17T20:49:06 Clamp glClearDepthf and glDepthRangef BUG=angleproject:2884 Change-Id: Ib1867fbd4c2ea3c3b29d2f987d384762f5851e8f Reviewed-on: https://chromium-review.googlesource.com/c/1276585 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Yuly Novikov 25843dd6 2018-10-16T17:30:48 Align memory access in Copy32FixedTo32FVertexData Bug: angleproject:2895 Change-Id: Idfe379e34c4f165b91babcb1990df28fa151d807 Reviewed-on: https://chromium-review.googlesource.com/c/1286373 Commit-Queue: Yuly Novikov <ynovikov@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 4024e217 2018-10-17T14:53:29 perftests: Record trace events to JSON file. This allows us to view the timeline of events in the trace event browser. We can extend this to do GPU timestamp queries and analyze when work is actually in flight. The trace is enabled in standalone ANGLE only using the flag --enable-trace with angle_perftests. You can also optionally specify the trace output file with --trace-file <blah>. The default file is ANGLETrace.json. Bug: angleproject:2781 Change-Id: I871f28545d9bf18220b55aaf69e9554dcb4c834d Reviewed-on: https://chromium-review.googlesource.com/c/1259763 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Shahbaz Youssefi 6f1dc51b 2018-10-04T14:36:04 Vulkan: Use a specialized macro for wrapped vulkan calls Vulkan wrapper functions are fairly straightforward. They call the Vulkan function and return immediately. The specialized macros introduced in this commit take care of the final return for brevity of the warpper. Additionally, this commit gets rid of ANGLE_EMPTY_STATEMENT in favor of the more robust macro definition using do {} while (0). Bug: none Change-Id: Ia7c68962d1aeee2c06ef210122b345b1a2e54f08 Reviewed-on: https://chromium-review.googlesource.com/c/1262020 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Takuto Ikuta c20ead32 2018-10-17T16:27:32 Remove unused lambda capture This is a preparation CL to remove -Wno-unused-lambda-capture warning suppression. Bug: chromium:681136 Change-Id: Ib5c1c4eeeed3b7406ede2dea33066c54e5fc3da0 Reviewed-on: https://chromium-review.googlesource.com/c/1286172 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 78bcd2be 2018-10-16T15:05:20 Vulkan: Fix deleting in-use descriptor sets. Sequences of many frames with uniform updates could lead to a bug where we attempt to delete descriptor sets that are still in use. To trigger the bug we need to write enough uniform data to trigger a descriptor set to be freed. This would correctly trigger refresh sets in the Program. But if there was a second program idle in the background that also allocated descriptors from the old pool, the bug would manifest. Fix this by storing a shared handle to the descriptor pool in the Program. The dynamic descriptor pool won't recycle descriptor pools internally unless there are zero outstanding references to the pool. We could also improve this in a resource sharing situation by keeping a single shared dynamic descriptor pool per share group. Includes a contribution from tobine@google.com that adds a test to cover the bug. Bug: angleproject:2863 Change-Id: Id585b85f33f8cfa3772ceff3af512d1e4fb0b75a Reviewed-on: https://chromium-review.googlesource.com/c/1271919 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Qin Jiajia 1d8a783c 2018-10-09T13:59:56 Re-land: "ES31: Add vector and matrix support in SSBO for D3D" Re-land skips ProgramInterfaceTestES31.GetProgramInterface/ES3_1_D3D11 to pass the bots. In fact, ProgramInterfaceTestES31.GetProgramInterface/ES3_1_D3D11 is not a regression. The reverted CL added more SSBO features and triggered the failure. To enable ProgramInterfaceTestES31.GetProgramInterface/ES3_1_D3D11, we should support SSBO in render pipeline. This needs to bind SSBO to UAV registers in link time instead of compile time since output variables also occupies the UAVs. Let's enable this test when we support SSBO in render pipeline. Currently, we shouldn't block the SSBO implementation in some common features. Bug: angleproject:1951 Change-Id: Ic339e8327e79335e6db1d86bedf0072635976f5f Reviewed-on: https://chromium-review.googlesource.com/c/1282277 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jiajia Qin <jiajia.qin@intel.com>
Jamie Madill a8a25d17 2018-10-16T15:06:08 Vulkan: Update Android expectations. Bug: angleproject:2606 Bug: angleproject:2609 Bug: angleproject:2895 Change-Id: Iab71cfff2317d7283db69c3f8c82db8d94f7cafc Reviewed-on: https://chromium-review.googlesource.com/c/1283854 Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Frank Henigman d633b156 2018-10-04T23:34:31 Get rid of VertexFormatType. The enum VertexFormatType is redundant with angle::FormatID. The Vulkan back end has already eschewed VertexFormatType, this change updates the D3D back ends. BUG=angleproject:2531 Change-Id: I67ea2203ca80be828f4c757a37810fe67a279364 Reviewed-on: https://chromium-review.googlesource.com/c/1263899 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Frank Henigman <fjhenigman@chromium.org>
Jiawei Shao a1ac3fe8 2018-10-10T12:29:31 ES31: Support textureGather[Offset] on int/uint formats on D3D11 This patch implements the translation of textureGather[Offset] on integer and unsigned integer format textures on D3D11. According to MSDN, Gather[Red|Green|Blue|Alpha] can be used on integer and unsigned integer format textures with float texture coordinates: https://docs.microsoft.com/en-us/windows/desktop/direct3dhlsl/dx-graphics-hlsl-to-gather Currently the dEQP tests on TextureGather[Offset] on cube map textures in integer or unsigned formats still cannot pass. This issue is under investigation. Bug: angleproject:2826 Test: dEQP-GLES31.functional.texture.gather.basic.2d.* dEQP-GLES31.functional.texture.gather.basic.2d_array.* dEQP-GLES31.functional.texture.gather.offset.min_required_offset.2d.* dEQP-GLES31.functional.texture.gather.offset.min_required_offset.2d_array.* dEQP-GLES31.functional.texture.gather.offset.implementation_offset.2d.* dEQP-GLES31.functional.texture.gather.offset.implementation_offset.2d_array.* Change-Id: If049dc395fb17cd34dec902630e3a1154e5d4806 Reviewed-on: https://chromium-review.googlesource.com/c/1271926 Commit-Queue: Jiawei Shao <jiawei.shao@intel.com> Reviewed-by: Geoff Lang <geofflang@chromium.org>