- 23 May, 2019 19 commits
-
-
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 12 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>
-
Ben Clayton authored
Remove the 'removed' condition_variable field. It is not used. Don't bother copying and unlocking before returning a field - this is not required. Bug: b/133127573 Change-Id: Ic8e29e6b6008e16b6abd043ccfa9014e203ce69a Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31678 Kokoro-Presubmit: kokoro <noreply+kokoro@google.com> Tested-by:
Ben Clayton <headlessclayton@gmail.com> Reviewed-by:
Antonio Maiorano <amaiorano@google.com> Reviewed-by:
Alexis Hétu <sugoi@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com>
-
Ben Clayton authored
This is a pure move with no changes. The goal here is to centralize the concurrent synchronization primitives, and not have them scattered around the codebase. Bug: b/133127573 Change-Id: I6abdfc34bf13ce455983610ff0c686778e0e9e4c Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31677 Kokoro-Presubmit: kokoro <noreply+kokoro@google.com> Tested-by:
Ben Clayton <headlessclayton@gmail.com> Reviewed-by:
Alexis Hétu <sugoi@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com>
-
Antonio Maiorano authored
- Use boost::stacktrace instead of libbacktrace so that we get can get callstacks on Windows as well. Note that on non-Windows, we tell boost::stacktrace to use libbacktrace. - REACTOR_EMIT_DEBUG_INFO can now be enabled on all platforms - Fix RR_LOG not building on MSVC by using __FUNCSIG__ instead of __PRETTY_FUNCTION__. - Enable CMake option REACTOR_EMIT_PRINT_LOCATION so that EmitLocation in LLVMReactorDebugInfo.cpp injects printfs with func/file/line. Sample output: rr> sw::Blitter::generate [c:\src\swiftshader\src\renderer\blitter.cpp:1303] rr> sw::Blitter::generate [c:\src\swiftshader\src\renderer\blitter.cpp:1304] rr> sw::Blitter::ComputeOffset [c:\src\swiftshader\src\renderer\blitter.cpp:1148] rr> sw::Blitter::generate [c:\src\swiftshader\src\renderer\blitter.cpp:1312] rr> sw::Blitter::generate [c:\src\swiftshader\src\renderer\blitter.cpp:1314] rr> sw::SetupRoutine::edge [c:\src\swiftshader\src\shader\setuproutine.cpp:566] Bug: b/131425026 Change-Id: Ia3b78652f4a76dcd6597ce2df61a236c4a90acc2 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/30030Tested-by:Antonio Maiorano <amaiorano@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com>
-
Antonio Maiorano authored
Includes only what's necessary for boost::stacktrace. See third_party/boost/README.md for instructions on how create/update this minimal boost version. Bug: b/131425026 Change-Id: I61643a0ba09d8b27517ec94f88c31d3a5aef09f4 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/30008Reviewed-by:
Ben Clayton <bclayton@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com> Tested-by:
Antonio Maiorano <amaiorano@google.com> Kokoro-Presubmit: kokoro <noreply+kokoro@google.com>
-
Chris Forbes authored
Device functions can be queried through GIPA. There is no device to check for enabled extensions here, so return anything that is supported. Test: dEQP-VK.wsi.* Change-Id: I3be086b4cd0ad6f5e80595aa4401a424780333d2 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31749 Presubmit-Ready: Alexis Hétu <sugoi@google.com> Reviewed-by:
Alexis Hétu <sugoi@google.com> Tested-by:
Chris Forbes <chrisforbes@google.com> Kokoro-Presubmit: kokoro <noreply+kokoro@google.com>
-
Alexis Hetu authored
If a device extension isn't enabled, then the associated extension functions shouldn't be exposed through vkGetDeviceProcAddr(). Bug b/117974925 Change-Id: I828cf9ff9d8aaf22c15a5379cfb9d93612d23360 Tests: dEQP-VK.api.version_check.entry_points Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31696 Presubmit-Ready: Alexis Hétu <sugoi@google.com> Reviewed-by:
Chris Forbes <chrisforbes@google.com> Tested-by:
Alexis Hétu <sugoi@google.com> Kokoro-Presubmit: kokoro <noreply+kokoro@google.com>
-
SwiftShader Regression Bot authored
Change-Id: I5bb5f9ead2bb92beeb67ece6e0021a7ab81dc88b Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31819 Kokoro-Presubmit: kokoro <noreply+kokoro@google.com> Reviewed-by:
Ben Clayton <bclayton@google.com> Tested-by:
Ben Clayton <bclayton@google.com>
-
Nicolas Capens authored
Change-Id: Id09bcb2b9ecfb90321ab94d3d9589055f0234252 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31769Tested-by:
Nicolas Capens <nicolascapens@google.com> Kokoro-Presubmit: kokoro <noreply+kokoro@google.com> Reviewed-by:
Alexis Hétu <sugoi@google.com>
-
- 21 May, 2019 2 commits
-
-
Saman Sami authored
gn files are tested on linux only. Test: * Built GL Swiftshader using ninja on Linux, Mac, and Windows. * Built and ran viz_unittests on Linux, Mac, and Windows. * Built Chromium ToT on Linux, Android, Mac. * Built Chromium + Vulkan Swiftshader on Linux by applying crrev.com/c/1615710 and ran viz_unittests with --enable-vulkan Bug: chromium:963988 Change-Id: Ic1529b8be0b508786863e03722acf610045a98ca Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31529Tested-by:
Saman Sami <samans@chromium.org> Reviewed-by:
Nicolas Capens <nicolascapens@google.com> Kokoro-Presubmit: kokoro <noreply+kokoro@google.com>
-
SwiftShader Regression Bot authored
Change-Id: Ie2099d22e26108d4db22130cd804fc8965852bb6 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31808Reviewed-by:
Ben Clayton <bclayton@google.com> Tested-by:
Ben Clayton <bclayton@google.com>
-
- 20 May, 2019 2 commits
-
-
Ben Clayton authored
The returned whole and frac must have the same sign as the input parameter. Tests: dEQP-VK.glsl.builtin.precision.modf.* Tests: dEQP-VK.glsl.builtin.function.common.modf.* Bug: b/126873455 Change-Id: I791891fdf46f9285e12d770e2b15b91ebfa3f0b1 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31590 Kokoro-Presubmit: kokoro <noreply+kokoro@google.com> Reviewed-by:
Chris Forbes <chrisforbes@google.com> Presubmit-Ready: Ben Clayton <bclayton@google.com> Tested-by:
Ben Clayton <bclayton@google.com>
-
SwiftShader Regression Bot authored
Change-Id: Iff3192ce8b4132c61f5b3c716627f5d1d59502ad Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31676 Kokoro-Presubmit: kokoro <noreply+kokoro@google.com> Reviewed-by:
Ben Clayton <bclayton@google.com> Tested-by:
Ben Clayton <bclayton@google.com>
-
- 19 May, 2019 2 commits
-
-
SwiftShader Regression Bot authored
Change-Id: I771c053d1d28563cf5e8c8ee13ae5d49adcd0c57 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31674 Kokoro-Presubmit: kokoro <noreply+kokoro@google.com> Reviewed-by:
Chris Forbes <chrisforbes@google.com> Tested-by:
Chris Forbes <chrisforbes@google.com>
-
Nicolas Capens authored
Vulkan 1.1 spec section 15.6.7. Scale Factor Operation, Level-of-Detail Operation and Image Level(s) Selection clarifies that the first returned parameter is the clamped LOD, rounded to the nearest integer if mipmapMode is VK_SAMPLER_MIPMAP_MODE_NEAREST, and the second parameter is the unclamped LOD with base level and sampler bias applied (we don't take maxSamplerLodBias into account, it is infinite). Bug: b/129523279 Tests: dEQP-VK.glsl.texture_functions.query.texturequerylod.* Tests: dEQP-VK.ycbcr.query.lod.* Change-Id: I4aa2f16716e1e23548b6fb3e0862e7cc442e3678 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31629 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>
-
- 18 May, 2019 3 commits
-
-
Chris Forbes authored
Previously we replicated the high bits into the low and from that point on treated these values as 16 bits. Unfortunately, that causes a snorm channel value of 0xff to yield -1/32767 rather than the expected -1/127. Bug: b/129523279 Test: dEQP-VK.image.mutable.*snorm* Change-Id: I6e329490f92562d6edac86043e80fef978682c88 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31728Reviewed-by:
Nicolas Capens <nicolascapens@google.com> Tested-by:
Chris Forbes <chrisforbes@google.com> Kokoro-Presubmit: kokoro <noreply+kokoro@google.com>
-
Antonio Maiorano authored
Bug: b/131224705 Change-Id: I7f971cd72ab623ba3798231b8b2a1b77e7744f78 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31369 Presubmit-Ready: Antonio Maiorano <amaiorano@google.com> Kokoro-Presubmit: kokoro <noreply+kokoro@google.com> Tested-by:
Antonio Maiorano <amaiorano@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com>
-
SwiftShader Regression Bot authored
Change-Id: I261d70ecdc7637c08d8cb461ea60e649472bc99e Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/31673 Kokoro-Presubmit: kokoro <noreply+kokoro@google.com> Reviewed-by:
Ben Clayton <bclayton@google.com> Tested-by:
Ben Clayton <bclayton@google.com>
-