src/tests/gl_tests/AtomicCounterBufferTest.cpp


Log

Author Commit Date CI Message
Tobin Ehlis 99bd10b7 2019-11-18T15:18:30 Vulkan:Disable AtomicCounterBuffer tests on Vulkan These tests were incorrectly turned on for Vulkan during the recent test macro refactor. Bug: angleproject:4125 Change-Id: I36940209e4223182e4810c30b0d0098d4abf0222 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1922591 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Courtney Goeltzenleuchter <courtneygo@google.com> Commit-Queue: Tobin Ehlis <tobine@google.com>
Tobin Ehlis 1a01b4b3 2019-11-11T16:41:07 Refactor end2end test macros This is a foundational CL to enabling the end2end tests on swiftshader. Refactored infrastructure with new ANGLE_INSTANTIATE_TEST_ES* macros that will run tests over all various combinations of all platforms for different ES versions. Just skipping failing tests initially to get the refactor landed. Bug: angleproject:4081 Bug: angleproject:4092 Change-Id: I017f6c3267179e49b6ae08cc7488096b423dcdb5 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1904635 Commit-Queue: Tobin Ehlis <tobine@google.com> Reviewed-by: Courtney Goeltzenleuchter <courtneygo@google.com>
Shahbaz Youssefi d53944cc 2019-08-09T12:09:32 Disable AtomicCounterBuffer tests on Vulkan If a shard executes a Vulkan test first, it sets the window's pixel format to something that the gl backend doesn't agree with. This causes subsequent OpenGL tests to all fail, and eventually leads to a crash. This disables AtomicCounterBuffer tests on Vulkan so that every shard starts with some OpenGL test first (note that AtomicCounterBuffer is alphabetically the first test suite). Bug: angleproject:3738 Change-Id: Ifc32e7884e53ec2a10eb939cf23e5db7fa66f8b0 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1745359 Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Shahbaz Youssefi c9ba782a 2019-08-05T16:14:22 Vulkan: Support atomic counter array of arrays Previously, it was assumed that a function argument is either AC or AC[i], and it was converted to AC or AC+i respectively. The code is changed to support any number of dimensions and subscripts, using array size information from AC's type. If AC is an array of array (atomic_uint AC[N][M][R]), the following index calculations are done. AC -> AC.arrayIndex AC[i] -> AC.arrayIndex + i*M*R AC[i][j] -> AC.arrayIndex + i*M*R + j*R AC[i][j][k] -> AC.arrayIndex + i*M*R + j*R + k A test is added to exercise these various forms of indexing: AtomicCounterBufferTest31.AtomicCounterArrayOfArray Bug: angleproject:3566 Change-Id: I1e181a7363463d1d0ee4916f35006ed7c58e0f7c Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1739488 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Tim Van Patten <timvp@google.com>
Shahbaz Youssefi c13ca2af 2019-07-17T15:46:29 Vulkan: Allow more than one atomic counter buffer binding dEQP assumes there are more than one atomic counter buffers available. This is technically not a requirement by the standard, but nevertheless could be what applications expect as well. This change adds support for multiple atomic counter buffer bindings. This is done by declaring an array of storage buffers for the atomic counter buffers (instead of declaring only one) and passing the (binding, offset) pair around to functions instead of just the offset. The atomic counter is found by indexing `binding` into the storage buffer array first before indexing `offset` into its `uint[]`. ProgramVk's default uniform collection is also fixed not to include atomic counter uniforms. A remaining issue is that atomic counter buffer offsets don't have alignment requirements in GLES, but Vulkan does for storage buffers. Similar to emulated transform feedback buffer offsets, these should be sent to the shader through uniform values. This will be done in a follow up change. Bug: angleproject:3566 Change-Id: I5600225c24c38f1a8ecf5c64388073055733197d Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1707931 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Shahbaz Youssefi a0d010ab 2019-08-01T11:05:21 Disable atomic counter buffer tests on AMD/Windows/GL Second attempt at fixing this bot: https://ci.chromium.org/p/chromium/builders/ci/Win10%20FYI%20x64%20Release%20%28AMD%20RX%20550%29 Bug: angleproject:3738 Change-Id: I8e8626cc911df9dae82c542b2dde8696f10e49bc Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1731130 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Xinghua Cao eb06814d 2019-07-03T17:17:45 Correct barriers of glMemoryBarrier in test cases Some test cases use wrong barriers when calling glMemoryBarrier. Bug: angleproject:2280 Change-Id: I0750c1eba84ed8af32091f7ecd5bdbd2b32fd397 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1687591 Reviewed-by: Jiajia Qin <jiajia.qin@intel.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Xinghua Cao <xinghua.cao@intel.com>
Shahbaz Youssefi 557e3853 2019-07-24T18:16:18 Vulkan: Disable atomic counter buffer tests on AMD/Windows A likely driver bug is causing the subsequent OpenGL test to fail. Bug: angleproject:3738 Change-Id: I6ee5e9e7298a2adb3069a6e14ac83453fa34b50f Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1716056 Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Shahbaz Youssefi b82d8633 2019-07-15T11:23:08 Vulkan: Atomic counter buffer support Vulkan doesn't treat atomic counters especially, and they are emulated with atomic access to storage buffers. A single atomic counter buffer binding per pipeline is supported. All the atomic counters identify an offset within this buffer. The shader is modified to include a storage buffer definition with `uint counters[];` as the only field. A compiler pass replaces atomic counter definitions with variables that hold the corresponding offset parameter, as well as changing atomic_uint types to just uint (as the offset). Where an atomic counter variable is used, it is replaced with the offset variable (plus the array index, if array). At the same time, built-in `atomicCounter*` functions are replaced with a corresponding `atomic*` function and `memoryBarrierAtomicCounter` is replaced with `memoryBarrierBuffer`. Bug: angleproject:3566 Change-Id: Iefb3d47de6a5cb3072bfa0cb94a46ac6a886d369 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1704635 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Tim Van Patten <timvp@google.com>
Enrico Galli c1c9fb1b 2018-10-18T11:41:50 ES31: Add atomic counter buffer support to D3D11 renderer Adds support for atomic counters to the D3D11 renderer using UAV. Bug: angleproject:1729 Test: angle_end2end_tests Change-Id: I2904ba62644685b7d91f7475bd80a81ae414993b Reviewed-on: https://chromium-review.googlesource.com/c/1451259 Commit-Queue: Geoff Lang <geofflang@chromium.org> Reviewed-by: Geoff Lang <geofflang@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>
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>
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>
Olli Etuaho 5804dc8e 2018-04-13T14:11:46 Refactor GL tests to use a shader library Instead of having the same simple shaders repeated over and over in the test code, reuse a single shader library. BUG=angleproject:2474 TEST=angle_end2end_tests Change-Id: I13f8ca8c0125e6d30f1761639bf8c3f69e0e77d2 Reviewed-on: https://chromium-review.googlesource.com/1012078 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
jchen10 05c31dae 2017-07-18T16:11:39 ES31: Enable atomic counter for GL backend This simply translates the offset qualifier and synchronizes the buffer binding state for GL translator and renderer. BUG=angleproject:1729 TEST=angle_end2end_tests:AtomicCounterBufferTest31 Change-Id: Ib8424918478ae4c47049d5856ea20ef022f12913 Reviewed-on: https://chromium-review.googlesource.com/575913 Commit-Queue: Geoff Lang <geofflang@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
jchen10 eaef1e5e 2017-06-13T10:44:11 Link atomic counters to buffers Gather counters from each shader and group them according the layout qualifier 'binding' into each buffer. BUG=angleproject:1729 TEST=angle_end2end_tests:AtomicCounterBufferTest Change-Id: I8d0cd0d2bf65be37c035b0e1540481c8bee0bae4
Jiajia Qin 6eafb04c 2016-12-27T17:04:07 ES31: Add GL_ATOMIC_COUNTER_BUFFER_BINDING binding point BUG=angleproject:1729 TEST=dEQP-GLES31.functional.state_query.integer.atomic_counter* dEQP-GLES31.functional.state_query.indexed.atomic_counter* angle_end2end_tests:AtomicCounterBufferTest Change-Id: I059c4e22e04cedec9134ec9f631de33f77b1fbe2 Reviewed-on: https://chromium-review.googlesource.com/430959 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>