- 28 May, 2019 3 commits
-
-
Nicolas Capens authored
Our lookup key for generated sampling functions was only using the sampler and image view descriptors into account. The same descriptors can be used in various different sampling instructions, so we need to also make that part of the lookup key. Bug: b/129523279 Change-Id: I325aa5571191e4ffc69214c2d13d431d21316fed Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31949 Presubmit-Ready: Nicolas Capens <nicolascapens@google.com> Reviewed-by:
Ben Clayton <bclayton@google.com> Tested-by:
Nicolas Capens <nicolascapens@google.com> Kokoro-Presubmit: kokoro <noreply+kokoro@google.com>
-
Nicolas Capens authored
Z was only being interpolated when the Position builtin is used (which isn't valid for fragment shaders) and/or when there's a depth buffer present. Instead interpolate it when FragCoord is being used. Bug: b/133325267 Tests: dEQP-VK.draw.inverted_depth_ranges.* Change-Id: I0567084b6f7bb054bd864545fa34acc52c8ac3d6 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31848 Presubmit-Ready: Nicolas Capens <nicolascapens@google.com> Kokoro-Presubmit: kokoro <noreply+kokoro@google.com> Tested-by:
Nicolas Capens <nicolascapens@google.com> Reviewed-by:
Chris Forbes <chrisforbes@google.com>
-
SwiftShader Regression Bot authored
Change-Id: Ia954596bcd7e6c206240fbf6cef7dd30731c3a99 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31847 Kokoro-Presubmit: kokoro <noreply+kokoro@google.com> Reviewed-by:
Ben Clayton <bclayton@google.com> Tested-by:
Ben Clayton <bclayton@google.com>
-
- 27 May, 2019 3 commits
-
-
Alexis Hetu authored
Texture dimensions larger than SHRT_MAX (32767) were not supported by SwiftShader. Used integers instead of shorts to store texture sizes to increase the maximum texture size to INT_MAX (2147483647). Tests: dEQP-VK.memory.pipeline_barrier.host_write_uniform_texel_buffer.* Tests: dEQP-VK.memory.pipeline_barrier.transfer_dst_uniform_texel_buffer.* Bug b/133429305 Change-Id: I7913f5f4c1f933889e74c57851a837ad7982f87a Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31989Reviewed-by:
Nicolas Capens <nicolascapens@google.com> Tested-by:
Alexis Hétu <sugoi@google.com> Kokoro-Presubmit: kokoro <noreply+kokoro@google.com>
-
Alexis Hetu authored
vk::destroy was crashing for vk::Fence after: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31988 Reverted that change and fixed it in VkObject.cpp to make sure the result of the cast is always equal to the allocated memory. Bug: b/117835459 Change-Id: I831625418fc83503329e833d48d9765b75d83b80 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31990Tested-by:
Alexis Hétu <sugoi@google.com> Presubmit-Ready: Alexis Hétu <sugoi@google.com> Reviewed-by:
Antonio Maiorano <amaiorano@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com> Kokoro-Presubmit: kokoro <noreply+kokoro@google.com>
-
Antonio Maiorano authored
Fence has a second base class with virtual functions, but its first base does not. In "static VkResult Create(...), when assigning the handle via: *outObject = *object; since this is code run in the context of the first base class, the address returned is offset by sizeof the vtable pointer from the second base class (8 bytes on x64). Problem is that the Cast overload for Fence does a simple reinterpret_cast of this stored pointer back to Fence*, without the offset being taken into account. The fix is to simply first cast the stored pointer back to the first base class type, and then static_cast it to the derived Fence type. Bug: b/117835459 Change-Id: Ieb2856320e996a5ad5d9e69aad5e01cfaee1cd9e Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31988Reviewed-by:
Nicolas Capens <nicolascapens@google.com> Reviewed-by:
Alexis Hétu <sugoi@google.com> Tested-by:
Antonio Maiorano <amaiorano@google.com> Kokoro-Presubmit: kokoro <noreply+kokoro@google.com>
-
- 24 May, 2019 7 commits
-
-
Ben Clayton authored
As requested here: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31841/1#message-24da63454b89e5d545f3b686f2470c8d2392ee61 Change-Id: I76500807933b565fb13f30268c47c7caa4be7c69 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31843Tested-by:
Ben Clayton <bclayton@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com> Kokoro-Presubmit: kokoro <noreply+kokoro@google.com>
-
Ben Clayton authored
We were assuming the condition was the same width as the lhs and rhs types - it can also be a scalar even if the result is not. Bug: b/133440380 Change-Id: Ib0e971af426b71030a097838295b07bb6e4261e0 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31841Reviewed-by:
Chris Forbes <chrisforbes@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com> Tested-by:
Ben Clayton <bclayton@google.com> Kokoro-Presubmit: kokoro <noreply+kokoro@google.com>
-
Sean Risser authored
The BUILD.gn files used to ignore the platform entirely. All that was necessary was to point them at the proper include directory for Mac. Bug chromium:966543 Change-Id: I755a432cc7d01ce094d7191fd48d0702d8a1ae3e Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31889 Presubmit-Ready: Sean Risser <srisser@google.com> Reviewed-by:
Alexis Hétu <sugoi@google.com> Tested-by:
Sean Risser <srisser@google.com> Kokoro-Presubmit: kokoro <noreply+kokoro@google.com>
-
SwiftShader Regression Bot authored
Change-Id: I8017db3f860c111143835e8ccb73c712489ede0c Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31842 Kokoro-Presubmit: kokoro <noreply+kokoro@google.com> Reviewed-by:
Ben Clayton <bclayton@google.com> Tested-by:
Ben Clayton <bclayton@google.com>
-
Ben Clayton authored
"Buffer updates performed with vkCmdUpdateBuffer first copy the data into command buffer memory when the command is recorded (which requires additional storage and may incur an additional allocation), and then copy the data from the command buffer into dstBuffer when the command is executed on a device." Bug: b/133127573 Bug: b/118619338 Bug: b/118383648 Change-Id: I8ba9bcdd6bf9e5b4f7e181c6fc379595a1d32e2a Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31839 Presubmit-Ready: Ben Clayton <bclayton@google.com> Tested-by:
Ben Clayton <bclayton@google.com> Reviewed-by:
Chris Forbes <chrisforbes@google.com> Kokoro-Presubmit: kokoro <noreply+kokoro@google.com>
-
Chris Forbes authored
I had made a bad assumption earlier that these would choose the correct operation based on signedness. That's not the case -- LLVM has separate Max/UMax and Min/UMin RMW operations. Test: dEQP-VK.glsl.atomic_operations.* Change-Id: I92a9e56011c4ef8ac658a826c480b16f65d0704d Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31909 Kokoro-Presubmit: kokoro <noreply+kokoro@google.com> Reviewed-by:
Ben Clayton <bclayton@google.com> Tested-by:
Chris Forbes <chrisforbes@google.com> Presubmit-Ready: Chris Forbes <chrisforbes@google.com>
-
Chris Forbes authored
Test: dEQP-VK.glsl.440.linkage.varying.component.vert_in.ivec2.as_int_int_unused Change-Id: I6e8da5863cfcee722dd4cf202810ddc505f76a65 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31890Tested-by:
Chris Forbes <chrisforbes@google.com> Presubmit-Ready: Chris Forbes <chrisforbes@google.com> Kokoro-Presubmit: kokoro <noreply+kokoro@google.com> Reviewed-by:
Ben Clayton <bclayton@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com>
-
- 23 May, 2019 23 commits
-
-
Ben Clayton authored
Tests: dEQP-VK.draw.basic_draw.* Change-Id: I609e22601c4aae1bdebaca6d42d33754cfaa57bb Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31840 Presubmit-Ready: Ben Clayton <bclayton@google.com> Tested-by:
Ben Clayton <bclayton@google.com> Reviewed-by:
Alexis Hétu <sugoi@google.com> Reviewed-by:
Chris Forbes <chrisforbes@google.com> Kokoro-Presubmit: kokoro <noreply+kokoro@google.com>
-
Ben Clayton authored
Fixes a whole lot of leak-detector warnings. Bug: b/133399620 Change-Id: I4f35150712dd2035a84c16d06ca75a4eba2c3c69 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31836Tested-by:
Ben Clayton <bclayton@google.com> Kokoro-Presubmit: kokoro <noreply+kokoro@google.com> Reviewed-by:
Alexis Hétu <sugoi@google.com>
-
Ben Clayton authored
SpirvRoutine holds reactor fields which must not outlive the scope of the reactor mutex. While the routine was not directly referenced outside of ComputeProgram::generate(), the destructor of the SpirvRoutine's rr::Variables was touching reactor, leading to data races. Bug: b/133127573 Change-Id: I854e079efdc0ef2d5b1ae67f014fe7148ad8f892 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31838 Presubmit-Ready: Ben Clayton <bclayton@google.com> Tested-by:
Ben Clayton <bclayton@google.com> Reviewed-by:
Chris Forbes <chrisforbes@google.com> Kokoro-Presubmit: kokoro <noreply+kokoro@google.com>
-
Ben Clayton authored
We were only passing them to the compiler. These should go to the linker as well. Bug: b/133127573 Change-Id: Ifc02a2c17a164f30c80311fd17d2a6311e3d5cba Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31817Reviewed-by:
Nicolas Capens <nicolascapens@google.com> Tested-by:
Ben Clayton <bclayton@google.com> Kokoro-Presubmit: kokoro <noreply+kokoro@google.com>
-
Ben Clayton authored
Hide all the error-prone synchronization logic in the class, and expose a documented API. This should have no impact on behavior - it was authored to make it harder to break things in the future. That said, it appears to fix a whole bunch of flakes with the dEQP query tests. Bug: b/133127573 Change-Id: I5c30b79b9b1cd36dba1fa2d3c34af0f5bd62772a Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31816 Kokoro-Presubmit: kokoro <noreply+kokoro@google.com> Reviewed-by:
Chris Forbes <chrisforbes@google.com> Reviewed-by:
Alexis Hétu <sugoi@google.com> Tested-by:
Ben Clayton <bclayton@google.com>
-
Saman Sami authored
Change-Id: I767fe366bb3484b2f21db61c9fd964172c5b0537 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31908Reviewed-by:
Saman Sami <samans@chromium.org> Reviewed-by:
Ben Clayton <bclayton@google.com> Presubmit-Ready: Saman Sami <samans@chromium.org> Tested-by:
Saman Sami <samans@chromium.org>
-
Alexis Hetu authored
Resolve must occur in linear space. Bug b/119620965 Change-Id: I5c7c7c45a1448f44c702969e34e580dc299df70a Test: dEQP-VK.renderpass.suballocation.multisample_resolve.* Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31871Tested-by:
Alexis Hétu <sugoi@google.com> Presubmit-Ready: Alexis Hétu <sugoi@google.com> Kokoro-Presubmit: kokoro <noreply+kokoro@google.com> Reviewed-by:
Chris Forbes <chrisforbes@google.com>
-
Ben Clayton authored
Bug: b/133127573 Change-Id: I0915cd5f90b75d2bb97152a6b1083755ad14c8b3 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31815Reviewed-by:
Nicolas Capens <nicolascapens@google.com> Reviewed-by:
Alexis Hétu <sugoi@google.com> Tested-by:
Ben Clayton <bclayton@google.com>
-
Ben Clayton authored
We call the constructor, so make sure we also call the destructor. Prevents non-POD inner fields from being deallocated without a destructor call before being freed. Change-Id: Ibf1291619f0ab4c7f7761a80a045d605fa9cbd53 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31813Tested-by:
Ben Clayton <bclayton@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com> Kokoro-Presubmit: kokoro <noreply+kokoro@google.com>
-
Ben Clayton authored
Bug: b/133127573 Change-Id: I834939c708dcb1a075b397a919fa63c5aec652f5 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31593Reviewed-by:
Nicolas Capens <nicolascapens@google.com> Tested-by:
Ben Clayton <bclayton@google.com> Kokoro-Presubmit: kokoro <noreply+kokoro@google.com>
-
Ben Clayton authored
Replace sw::MutexLock with std::mutex. Replace use of sw::Thread with std::thread. helgrind seems to take objection to the init Event. AtomicInt remains as a wrapper around std::atomic<int> as it provides an 'operator=' and 'std::atomic& operator=( const std::atomic& )' is deleted. This change is to reduce the amount of code I have to verify while looking for synchronization issues. Bug: b/133127573 Change-Id: I8cbe38c918298ffafaf59fe25b0ff258670f9a99 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31812Reviewed-by:
Nicolas Capens <nicolascapens@google.com> Tested-by:
Ben Clayton <bclayton@google.com> Kokoro-Presubmit: kokoro <noreply+kokoro@google.com>
-
Ben Clayton authored
If we don't do this then calls to StorePhi() will assume the instruction belongs to the wrong block. Bug: b/133212545 Change-Id: If8436dcc677847a86fd629d6354e437ef46ba048 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31833 Kokoro-Presubmit: kokoro <noreply+kokoro@google.com> Tested-by:
Ben Clayton <bclayton@google.com> Reviewed-by:
Chris Forbes <chrisforbes@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com>
-
Ben Clayton authored
In this particular case, I do not see the issue described in b/133135427 to ever happen here - however helgrind seems to find this questionable, and unless this is causing a noticable performance impact I think we should err on the side of caution. Bug: b/133135427 Change-Id: I1e5fa02ed28b6146f8a6044999f92b141e001e13 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31810Tested-by:
Ben Clayton <bclayton@google.com> Reviewed-by:
Chris Forbes <chrisforbes@google.com> Kokoro-Presubmit: kokoro <noreply+kokoro@google.com>
-
Ben Clayton authored
Bug: b/133135427 Change-Id: Iadb691c7b0b957a494b57a8a5046a58a6b42180c Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31809Tested-by:
Ben Clayton <bclayton@google.com> Reviewed-by:
Chris Forbes <chrisforbes@google.com> Reviewed-by:
Alexis Hétu <sugoi@google.com> Kokoro-Presubmit: kokoro <noreply+kokoro@google.com>
-
Ben Clayton authored
As we destruct the Queue now, there's no need to have a shared_ptr indirection. This makes Renderer part of the vk::Queue allocation. Bug: b/133127573 Change-Id: I9ea0d427752689e73346e0da950144832d908a2e Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31685Tested-by:
Ben Clayton <bclayton@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com> Reviewed-by:
Alexis Hétu <sugoi@google.com> Kokoro-Presubmit: kokoro <noreply+kokoro@google.com>
-
Ben Clayton authored
We were never destructing VkQueues, but were freeing the underlying memory. Bug: b/133127573 Change-Id: Id6d9f615428073adad7267dd1bd48ced17f1b433 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31592Tested-by:
Ben Clayton <bclayton@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com> Reviewed-by:
Alexis Hétu <sugoi@google.com> Kokoro-Presubmit: kokoro <noreply+kokoro@google.com>
-
Ben Clayton authored
Don't (ab)use vk::Fence for its start() finish() events. sw::WaitGroup shares the same interface, so use that. Allows vk::Fence to have its destructor deleted again. Bug: b/133127573 Change-Id: I747ea6965bf85343c720235083b309d8b855a950 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31684Tested-by:
Ben Clayton <bclayton@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com> Reviewed-by:
Alexis Hétu <sugoi@google.com>
-
Ben Clayton authored
Bug: b/133127573 Change-Id: I0ce0164de401524014eb295547b899f24f437e21 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31683Tested-by:
Ben Clayton <bclayton@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com> Kokoro-Presubmit: kokoro <noreply+kokoro@google.com>
-
Ben Clayton authored
This is implemented by sw::WaitGroup, and vk::Fence. The goal here is to abstract the underlying implementation of the task tracker. We currently (ab)use vk::Fence for queue tracking when a sw::WaitGroup could be used. This also allows us to implement a task logger in the future that can show what's inflight at any time. Bug: b/133127573 Change-Id: I0177b26e7577ffd5cb687a5105a69a22070a7ac6 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31682Tested-by:
Ben Clayton <bclayton@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com> Kokoro-Presubmit: kokoro <noreply+kokoro@google.com>
-
Ben Clayton authored
This change fixes the ASAN issue as described in b/133135427. Reproduction case: ./build/vk-unittests --gtest_repeat=-1 --gtest_filter=ComputeParams/SwiftShaderVulkanBufferToBufferComputeTest.Memcpy/0 Bug: b/133127573 Bug: b/133135427 Bug: swiftshader:130 Change-Id: I06fbf10ab042160e8ca481f2afaa30d4f676dc75 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31681 Kokoro-Presubmit: kokoro <noreply+kokoro@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com> Reviewed-by:
Chris Forbes <chrisforbes@google.com> Tested-by:
Ben Clayton <bclayton@google.com>
-
Ben Clayton authored
A synchronization primitive borrowed from golang: https://golang.org/pkg/sync/#WaitGroup Bug: b/133127573 Change-Id: Id3ec093c0de478cfe16fad4d064cf2c26288acf7 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31680Reviewed-by:
Nicolas Capens <nicolascapens@google.com> Tested-by:
Ben Clayton <bclayton@google.com> Kokoro-Presubmit: kokoro <noreply+kokoro@google.com>
-
Ben Clayton authored
Simplify to a single implementation across all platforms. Document the class and members. Also add: • Constructor with event type and initial state • clear() method. • wait() method with timeout. • operator bool(). Bug: b/133127573 Change-Id: I612dc8a1011aaa2cfa50f40c59849323348b3054 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31679 Kokoro-Presubmit: kokoro <noreply+kokoro@google.com> Reviewed-by:
Antonio Maiorano <amaiorano@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com> Tested-by:
Ben Clayton <bclayton@google.com>
-
SwiftShader Regression Bot authored
Change-Id: I372351c769f8da843acc097927ed2abf872259b0 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31835 Kokoro-Presubmit: kokoro <noreply+kokoro@google.com> Reviewed-by:
Ben Clayton <bclayton@google.com> Tested-by:
Ben Clayton <bclayton@google.com>
-
- 22 May, 2019 4 commits
-
-
Hernan Liatis authored
Error happened while moving code from android tree to swiftshader tree. Whoops! Change-Id: Ie7085f8e6d54b2b11547bb6a38348c20140beae9 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31868Reviewed-by:
Nicolas Capens <nicolascapens@google.com> Tested-by:
Hernan Liatis <hliatis@google.com>
-
Ben Clayton authored
Using 'volatile' does not make anything thread safe. Shuts up a bunch of TSAN errors. Bug: b/133127573 Change-Id: I90b708ac53824de91c316f61f137ecca34087047 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31830 Kokoro-Presubmit: kokoro <noreply+kokoro@google.com> Tested-by:
Ben Clayton <bclayton@google.com> Reviewed-by:
Chris Forbes <chrisforbes@google.com>
-
Ben Clayton authored
Don't bake the string into the printf format, use a '%s' and pass the string as a parameter. Change-Id: I47be05383637caaa81a93d19623ff39c47988df3 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31429Tested-by:
Ben Clayton <bclayton@google.com> Kokoro-Presubmit: kokoro <noreply+kokoro@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com>
-
Ben Clayton authored
Tests: dEQP-VK.draw.basic_draw.draw_indirect.* Tests: dEQP-VK.draw.basic_draw.draw_indexed_indirect.* Bug: b/133127573 Change-Id: Ie64ae58d352d0fab23a0ce8811ce95c024e59367 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31687Tested-by:
Ben Clayton <bclayton@google.com> Reviewed-by:
Alexis Hétu <sugoi@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com> Reviewed-by:
Chris Forbes <chrisforbes@google.com> Kokoro-Presubmit: kokoro <noreply+kokoro@google.com>
-