- 22 Jan, 2021 2 commits
-
-
Nicolas Capens authored
The first devices with M1 'Apple Silicon' AArch64 processors were launched with macOS 11.0, so it's safe to increase the target OS beyond the 10.11 support level needed by Chrome. This helps enable C++17 by addressing the lack of aligned heap allocation support in previous macOS versions: third_party/marl/include/marl/pool.h:236:27: error: aligned deallocation function of type 'void (void *, std::align_val_t) noexcept' is only available on macOS 10.14 or newer src/Vulkan/VkPipeline.hpp:83:10: error: aligned deallocation function of type 'void (void *, std::align_val_t) noexcept' is only available on macOS 10.14 or newer C++17 invokes aligned new/delete because of our use of alignas(16) for types like sw::float4, which is used for member fields in sw::DrawCall::BatchData and vk::GraphicsState. While this could be addressed by using custom new/delete operators for these classes (and classes which in turn use them as members), misalignment is just a minor performance issue, so we can leave things as-is and work around it with a build flag (note 16-byte alignment is needed for some vectors accessed in Reactor code, but that's handled for those individual cases). Bug: b/174843857 Change-Id: Iaa40a3ac6aa7d12c088bf93a55803d8146bd289c Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/52068Reviewed-by:
Antonio Maiorano <amaiorano@google.com> Tested-by:
Nicolas Capens <nicolascapens@google.com> Commit-Queue: Nicolas Capens <nicolascapens@google.com> Kokoro-Result: kokoro <noreply+kokoro@google.com>
-
Ben Clayton authored
* changes: Update src/Pipeline/SpirvShaderInstructions.inl Update SPIR-V Tools to f37547c73 Squashed 'third_party/SPIRV-Tools/' changes from b0e22d28f5e..f37547c73a9 Update SPIR-V Headers to 8bb2420b4 Squashed 'third_party/SPIRV-Headers/' changes from 104ecc356c1..8bb2420b44a Mend git merge history for SPIRV-Headers and SPIRV-Tools Mend git merge history for SPIRV-Headers and SPIRV-Tools Revert 9dff6a3b to mend git merge history for SPIRV-Headers and SPIRV-Tools Squashed 'third_party/SPIRV-Tools/' changes from a61d07a7276..b0e22d28f5e Squashed 'third_party/SPIRV-Headers/' changes from 7845730cab6..104ecc356c1
-
- 21 Jan, 2021 16 commits
-
-
Ben Clayton authored
for SPIRV-Tools update Bug: b/123642959 Change-Id: I6c21b03ddb5f04e20fb72c0e6b280ca9caaf1f7b
-
Ben Clayton authored
Changes: f37547c73a9 spirv-val: Add Vulkan EXT builtins (#4115) 1bd539b9bfc Support pending Intel extensions (#4116) 56f8ed48efd Validate Sampled=1 for Vulkan ImageQuerySizeLod, ImageQueryLevels, ImageQueryLod (#4103) e25db023c47 spirv-val: Add Vulkan Memory Scope VUs (#4106) 8383bd5d6f2 Migrate all Kokoro build scripts over to use the docker VM image (#4114) ee39b5db5f1 spirv-val: Add Vulkan Addressing Model check (#4107) 9150cd441f4 Remove WebGPU support (#4108) b2cfc5d1cec spirv-val: Vulkan atomic storage class (#4079) cec658c1160 Avoid integrity check failures caused by propagating line instructions (#4096) b1507d0d2ba Linker usability improvements (#4084) 7bbe1a31641 Revert "Generate differentiated error codes for buffer oob checking (#4097)" (#4100) c32277c0ba0 Generate differentiated error codes for buffer oob checking (#4097) f3ccb633dfd use std::string::empty() to test for emptiness (#4098) ad77ed7a8d5 spirv-val: Label standalone Vulkan VUID (#4091) aa005e8bd43 spirv-val: Add Vulkan decroation VUID (#4090) 4ed1f4fce9e Fix binding number calculation in desc sroa (#4095) af3a3d481f6 Build deps: dump ini from 1.3.5 to 1.3.7 in tools/sva (#4092) 94d1a80159e spirv-val: Add Vulkan FP Mode VUID (#4088) 6d05ed8410b spirv-val: Fix Vulkan image sampled check (#4085) 37c03859de9 spirv-val: Add Vulkan ForwardPointer VUID (#4089) d630e5f8c10 spirv-val: Add Vulkan ImageTexelPointer format check (#4087) 1bb80d2778a spirv-val: Add Vulkan Group Operation VUID (#4086) 17ffa89097b spirv-val: Add first StandAlone VUID 04633 (#4077) 8f4b35c332e spirv-val: Add Subgroup VUIDs (#4074) 4e31fdd4aa1 spirv-fuzz: Fix OpPhi handling in DuplicateRegionWithSelection (#4065) ad898cb9498 validation: validate return type of OpImageRead (#4072) 305caff2ebb validation: tighter validation of multisampled images (#4059) a0370efd589 validate OpTypeImage Sampled values for environemnts (#4064) 09d1fea5890 Force using Python 3 git-sync-deps (#4067) 7170218b8de validate StorageImageMultisampled capability (#4062) 3b85234542c spirv-val: Add last TessLevelOuter and TessLevelInner VUID (#4055) 171290703a6 spirv-val: Add last ClipDistance and CullDistance VUID (#4054) 1a6b4053fa0 spirv-val: Add last ViewportIndex and Layer VUID (#4053) 9df5225e672 spirv-val: Add last Position VUID (#4052) 862d44a86ed Allow forward pointer to be used in types generally (#4044) bda102d7a76 opt: Run DCE when SPV_KHR_shader_clock is used (#4049) b27b1afd12d Update CHANGES to include latest ray tacing fixes. cd050786621 Take new (raytracing) termination instructions into account. (#4050) 21f7c5675da Start SPIRV-Tools v2020.7 4c2f34a5048 Finalize SPIRV-Tools v2020.6 c9c1f54330d Update CHANGES 10e0ae7946c Do run DCE if SPV_KHR_ray_query is used. (#4047) 84546647a0d Update CHANGES c1d5a045f6f Change ref_analysis to RefAnalysis to follow coding standards. (#4045) c502a15f25c Handle 8-bit index in elim dead member (#4043) 32573bb2168 Add validation support for the ray tracing built-in variables (#4041) 7046c05d2fb Add texel buffer out-of-bounds checking instrumentation (#4038) cf2d1e7afcd Update spirv-header deps (#4040) 1299436c8f1 Reject SPIR-V that applies void to OpUndef, OpCopyObject, OpPhi (#4036) 2c458414c08 BuildModule: optionally avoid adding new OpLine instructions (#4033) a79aa038ec1 Remove prototype for unimplemented method (#4031) Commands: ./third_party/update-spirvtools.sh Bug: b/123642959 Change-Id: Ic6136d02f11f153a36ab9b9bb8019b4b18b3b5f3 -
Ben Clayton authored
f37547c73a9 spirv-val: Add Vulkan EXT builtins (#4115) 1bd539b9bfc Support pending Intel extensions (#4116) 56f8ed48efd Validate Sampled=1 for Vulkan ImageQuerySizeLod, ImageQueryLevels, ImageQueryLod (#4103) e25db023c47 spirv-val: Add Vulkan Memory Scope VUs (#4106) 8383bd5d6f2 Migrate all Kokoro build scripts over to use the docker VM image (#4114) ee39b5db5f1 spirv-val: Add Vulkan Addressing Model check (#4107) 9150cd441f4 Remove WebGPU support (#4108) b2cfc5d1cec spirv-val: Vulkan atomic storage class (#4079) cec658c1160 Avoid integrity check failures caused by propagating line instructions (#4096) b1507d0d2ba Linker usability improvements (#4084) 7bbe1a31641 Revert "Generate differentiated error codes for buffer oob checking (#4097)" (#4100) c32277c0ba0 Generate differentiated error codes for buffer oob checking (#4097) f3ccb633dfd use std::string::empty() to test for emptiness (#4098) ad77ed7a8d5 spirv-val: Label standalone Vulkan VUID (#4091) aa005e8bd43 spirv-val: Add Vulkan decroation VUID (#4090) 4ed1f4fce9e Fix binding number calculation in desc sroa (#4095) af3a3d481f6 Build deps: dump ini from 1.3.5 to 1.3.7 in tools/sva (#4092) 94d1a80159e spirv-val: Add Vulkan FP Mode VUID (#4088) 6d05ed8410b spirv-val: Fix Vulkan image sampled check (#4085) 37c03859de9 spirv-val: Add Vulkan ForwardPointer VUID (#4089) d630e5f8c10 spirv-val: Add Vulkan ImageTexelPointer format check (#4087) 1bb80d2778a spirv-val: Add Vulkan Group Operation VUID (#4086) 17ffa89097b spirv-val: Add first StandAlone VUID 04633 (#4077) 8f4b35c332e spirv-val: Add Subgroup VUIDs (#4074) 4e31fdd4aa1 spirv-fuzz: Fix OpPhi handling in DuplicateRegionWithSelection (#4065) ad898cb9498 validation: validate return type of OpImageRead (#4072) 305caff2ebb validation: tighter validation of multisampled images (#4059) a0370efd589 validate OpTypeImage Sampled values for environemnts (#4064) 09d1fea5890 Force using Python 3 git-sync-deps (#4067) 7170218b8de validate StorageImageMultisampled capability (#4062) 3b85234542c spirv-val: Add last TessLevelOuter and TessLevelInner VUID (#4055) 171290703a6 spirv-val: Add last ClipDistance and CullDistance VUID (#4054) 1a6b4053fa0 spirv-val: Add last ViewportIndex and Layer VUID (#4053) 9df5225e672 spirv-val: Add last Position VUID (#4052) 862d44a86ed Allow forward pointer to be used in types generally (#4044) bda102d7a76 opt: Run DCE when SPV_KHR_shader_clock is used (#4049) b27b1afd12d Update CHANGES to include latest ray tacing fixes. cd050786621 Take new (raytracing) termination instructions into account. (#4050) 21f7c5675da Start SPIRV-Tools v2020.7 4c2f34a5048 Finalize SPIRV-Tools v2020.6 c9c1f54330d Update CHANGES 10e0ae7946c Do run DCE if SPV_KHR_ray_query is used. (#4047) 84546647a0d Update CHANGES c1d5a045f6f Change ref_analysis to RefAnalysis to follow coding standards. (#4045) c502a15f25c Handle 8-bit index in elim dead member (#4043) 32573bb2168 Add validation support for the ray tracing built-in variables (#4041) 7046c05d2fb Add texel buffer out-of-bounds checking instrumentation (#4038) cf2d1e7afcd Update spirv-header deps (#4040) 1299436c8f1 Reject SPIR-V that applies void to OpUndef, OpCopyObject, OpPhi (#4036) 2c458414c08 BuildModule: optionally avoid adding new OpLine instructions (#4033) a79aa038ec1 Remove prototype for unimplemented method (#4031) git-subtree-dir: third_party/SPIRV-Tools git-subtree-split: f37547c73a981bcf3f8b1a471e3000e606dd41a8
-
Ben Clayton authored
Changes: 8bb2420b44a Merge pull request #176 from MrSidims/private/MrSidims/OtherExtensions 0dd29fb93ac Apply suggestions to Intel extensions PR b690b3e2174 Update generated files f9797ef9c1b Add SPV_INTEL_long_constant_composite extension 8987518da9e Add SPV_INTEL_loop_fuse extension 3fad4b35436 Add SPV_INTEL_fpga_cluster_attributes and SPV_INTEL_fp_fast_math_mode b6be746fc77 Update SPV_INTEL_fpga_loop_controls extension ad00ca3b55b Update SPV_INTEL_kernel_attributes extension 0c290562414 Update SPV_INTEL_function_pointers extension ea791133ee4 Upstream SPV_INTEL_float_controls2 extension 24e9c63e6dd Upstream SPV_INTEL_vector_compute extension 2b76471587f Upstream SPV_INTEL_fpga_memory_accesses extension 0e756817218 Upstream SPV_INTEL_io_pipes extension ef87dd18967 Upstream SPV_INTEL_variable_length_array extension e202eb89141 Upstream SPV_INTEL_usm_storage_classes extension a001134e417 Upstream SPV_INTEL_arbitrary_precision_integers extensions 7669e05273b Upstream SPV_INTEL_inline_assembly extension d5035de3d31 Upstream SPV_INTEL_fpga_buffer_location extension f027d53ded7 Merge pull request #184 from dgkoch/dkoch_remove_hittkhr bdd2aa34c45 remove HitTKHR Commands: ./third_party/update-spirvheaders.sh Bug: b/123642959 Change-Id: I21d11818df5a17704b930408b509f1ca3cfdefbc -
Ben Clayton authored
8bb2420b44a Merge pull request #176 from MrSidims/private/MrSidims/OtherExtensions 0dd29fb93ac Apply suggestions to Intel extensions PR b690b3e2174 Update generated files f9797ef9c1b Add SPV_INTEL_long_constant_composite extension 8987518da9e Add SPV_INTEL_loop_fuse extension 3fad4b35436 Add SPV_INTEL_fpga_cluster_attributes and SPV_INTEL_fp_fast_math_mode b6be746fc77 Update SPV_INTEL_fpga_loop_controls extension ad00ca3b55b Update SPV_INTEL_kernel_attributes extension 0c290562414 Update SPV_INTEL_function_pointers extension ea791133ee4 Upstream SPV_INTEL_float_controls2 extension 24e9c63e6dd Upstream SPV_INTEL_vector_compute extension 2b76471587f Upstream SPV_INTEL_fpga_memory_accesses extension 0e756817218 Upstream SPV_INTEL_io_pipes extension ef87dd18967 Upstream SPV_INTEL_variable_length_array extension e202eb89141 Upstream SPV_INTEL_usm_storage_classes extension a001134e417 Upstream SPV_INTEL_arbitrary_precision_integers extensions 7669e05273b Upstream SPV_INTEL_inline_assembly extension d5035de3d31 Upstream SPV_INTEL_fpga_buffer_location extension f027d53ded7 Merge pull request #184 from dgkoch/dkoch_remove_hittkhr bdd2aa34c45 remove HitTKHR git-subtree-dir: third_party/SPIRV-Headers git-subtree-split: 8bb2420b44af3c514480e63ac24439044706b583
-
Ben Clayton authored
https://swiftshader-review.googlesource.com/c/SwiftShader/+/50749 squashed together the changes from two `git subtree pull` commands (for SPIRV-Headers and SPIRV-Tools), which resulted in a change with a single parent. `git subtree` expects a merge commit with a single set of `git-subtree-*` metadata tags. The squash resulted in a change description with two sets of these, confusing `git subtree` even further. The process to fix this is probably not the easiest, but the first one I found that works: # Rollback to the parent change of 50749 git checkout 43bb60e1 # Perform the subtree pull again for SPIRV-Headers (to 104ecc356) git subtree pull --prefix third_party/SPIRV-Headers https://github.com/KhronosGroup/SPIRV-Headers 104ecc356c1bea4476320faca64440cd1df655a3 --squash -m "Update SPIR-V Headers" # Note the second parent of the merge for the SPIRV-Headers (Merge: 43bb60e1 ded361b4) git show -1 # Perform the subtree pull again for SPIRV-Tools (to b0e22d28f) git subtree pull --prefix third_party/SPIRV-Tools https://github.com/KhronosGroup/SPIRV-Tools b0e22d28f5ec891d6b256703575d08fce4228bd9 --squash -m "Update SPIR-V Tools" # Note the second parent of the merge for the SPIRV-Tools (Merge: a00ce432a9d bdb9eea9) git show -1 # Jump back to master git checkout origin/master # Revert 50749 git revert 9dff6a3b # Re-merge the squashed update change for SPIRV-Headers git merge -Xsubtree="third_party/SPIRV-Headers" ded361b4 # Re-merge the squashed update change for SPIRV-Tools **this change** git merge -Xsubtree="third_party/SPIRV-Tools" bdb9eea9 Bug: b/174239232 Change-Id: I51ff23aa3b8a96ce45ada7f5f14f196196a236c3
-
Ben Clayton authored
https://swiftshader-review.googlesource.com/c/SwiftShader/+/50749 squashed together the changes from two `git subtree pull` commands (for SPIRV-Headers and SPIRV-Tools), which resulted in a change with a single parent. `git subtree` expects a merge commit with a single set of `git-subtree-*` metadata tags. The squash resulted in a change description with two sets of these, confusing `git subtree` even further. The process to fix this is probably not the easiest, but the first one I found that works: # Rollback to the parent change of 50749 git checkout 43bb60e1 # Perform the subtree pull again for SPIRV-Headers (to 104ecc356) git subtree pull --prefix third_party/SPIRV-Headers https://github.com/KhronosGroup/SPIRV-Headers 104ecc356c1bea4476320faca64440cd1df655a3 --squash -m "Update SPIR-V Headers" # Note the second parent of the merge for the SPIRV-Headers (Merge: 43bb60e1 ded361b4) git show -1 # Perform the subtree pull again for SPIRV-Tools (to b0e22d28f) git subtree pull --prefix third_party/SPIRV-Tools https://github.com/KhronosGroup/SPIRV-Tools b0e22d28f5ec891d6b256703575d08fce4228bd9 --squash -m "Update SPIR-V Tools" # Note the second parent of the merge for the SPIRV-Tools (Merge: a00ce432a9d bdb9eea9) git show -1 # Jump back to master git checkout origin/master # Revert 50749 git revert 9dff6a3b # Re-merge the squashed update change for SPIRV-Headers ** this change ** git merge -Xsubtree="third_party/SPIRV-Headers" ded361b4 # Re-merge the squashed update change for SPIRV-Tools git merge -Xsubtree="third_party/SPIRV-Tools" bdb9eea9 Bug: b/174239232 Change-Id: Ibab851eb610b1448193f57a628eb95bdb58057ee
-
Ben Clayton authored
https://swiftshader-review.googlesource.com/c/SwiftShader/+/50749 squashed together the changes from two `git subtree pull` commands (for SPIRV-Headers and SPIRV-Tools), which resulted in a change with a single parent. `git subtree` expects a merge commit with a single set of `git-subtree-*` metadata tags. The squash resulted in a change description with two sets of these, confusing `git subtree` even further. The process to fix this is probably not the easiest, but the first one I found that works: # Rollback to the parent change of 50749 git checkout 43bb60e1 # Perform the subtree pull again for SPIRV-Headers (to 104ecc356) git subtree pull --prefix third_party/SPIRV-Headers https://github.com/KhronosGroup/SPIRV-Headers 104ecc356c1bea4476320faca64440cd1df655a3 --squash -m "Update SPIR-V Headers" # Note the second parent of the merge for the SPIRV-Headers (Merge: 43bb60e1 ded361b4) git show -1 # Perform the subtree pull again for SPIRV-Tools (to b0e22d28f) git subtree pull --prefix third_party/SPIRV-Tools https://github.com/KhronosGroup/SPIRV-Tools b0e22d28f5ec891d6b256703575d08fce4228bd9 --squash -m "Update SPIR-V Tools" # Note the second parent of the merge for the SPIRV-Tools (Merge: a00ce432a9d bdb9eea9) git show -1 # Jump back to master git checkout origin/master # Revert 50749 git revert 9dff6a3b # Re-merge the squashed update change for SPIRV-Headers git merge -Xsubtree="third_party/SPIRV-Headers" ded361b4 # Re-merge the squashed update change for SPIRV-Tools git merge -Xsubtree="third_party/SPIRV-Tools" bdb9eea9 Bug: b/174239232 Change-Id: I0b498184493f0fcb00b1684182b6a89076a5cca0
-
Ben Clayton authored
b0e22d28f5e spirv-fuzz: Fix facts arising from CompositeConstruct (#4034) 5ffa320feee spirv-fuzz: Do not flatten conditionals that create synonyms (#4030) cd590fa3341 Update MeshShadingNV dependencies (and land Ray tracing updates) (#4028) 671914c28e8 Fix buffer oob instrumentation for matrix refs (#4025) 1f2fcddd396 spirv-opt: Set parent when adding basic block (#4021) f686518cee7 spirv-opt: properly preserve DebugValue indexes operand (#4022) 1cda495274b Use less stack space when validating Vulkan builtins (#4019) git-subtree-dir: third_party/SPIRV-Tools git-subtree-split: b0e22d28f5ec891d6b256703575d08fce4228bd9
-
Ben Clayton authored
104ecc356c1 Merge pull request #180 from dneto0/issue-179 93effe16473 MeshShadingNV enables builtins PrimitiveId, Layer, and ViewportIndex 4de110ce1c7 Merge pull request #182 from dgkoch/khr_rt_final 6323756078a de-alias/reassign OpIgnoreIntersectionKHR/OpTerminateRayKHR 928a192ee62 Raytracing and Rayquery updates for final eb5e409129c Updated headers for new trace/executeCallable and acceleration structure cast. 5ab5c96198f Reserve additional loop control bit for Intel extension (NoFusionINTEL) (#175) 793f9199bed Add EmbarkStudios/rust-gpu to vendor list. (#174) git-subtree-dir: third_party/SPIRV-Headers git-subtree-split: 104ecc356c1bea4476320faca64440cd1df655a3
-
Nicolas Capens authored
Previously the return value of the function called through the Pointer<Byte> argument was not returned from the rr::Call(). This change implements proper support for both non-void and void returning function signatures. This change also adds a unit test which demonstrates the use of a 'trampoline', which makes use of the new non-void indirect call. Bug: b/175830790 Change-Id: I100588c6319d0c45797c48a068e1e46fa9f441ba Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/51308 Presubmit-Ready: Nicolas Capens <nicolascapens@google.com> Kokoro-Result: kokoro <noreply+kokoro@google.com> Tested-by:
Nicolas Capens <nicolascapens@google.com> Reviewed-by:
Antonio Maiorano <amaiorano@google.com>
-
Antonio Maiorano authored
RoutineT::getEntry() now returns the actual function pointer type, rather than void*. Also rename "callable" to "function", since a callable is a function- like object (like RoutineT), while getEntry() returns a C function. Bug: b/143479561 Change-Id: I879b7f9aa13d05d31390596e5e0c5b23f7f80d7d Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/51968 Presubmit-Ready: Nicolas Capens <nicolascapens@google.com> Reviewed-by:
Antonio Maiorano <amaiorano@google.com> Kokoro-Result: kokoro <noreply+kokoro@google.com> Tested-by:
Nicolas Capens <nicolascapens@google.com>
-
SwiftShader Regression Bot authored
Reactor backend: Subzero Change-Id: I713149fb04740c8addec729d4c41a9109a05dcca Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/52008Reviewed-by:
Alexis Hétu <sugoi@google.com> Tested-by:
Nicolas Capens <nicolascapens@google.com> Kokoro-Result: kokoro <noreply+kokoro@google.com>
-
Nicolas Capens authored
When enabling C++17, LLVM uses std::shared_mutex instead of its own implementation. On macOS it requires version 10.12 (Sierra), while Chrome must still support 10.11. However, we don't need LLVM as Reactor backend, except for ARM64, but Mac devices with such CPU have a more recent OS version. llvm-10.0/llvm/include/llvm/Support/RWMutex.h:100:8: error: 'shared_mutex' is unavailable: introduced in macOS 10.12 Bug: b/174843857 Change-Id: Ie24095aa17d22072cfb9d655b87252cbea5209d0 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/52030Reviewed-by:
Antonio Maiorano <amaiorano@google.com> Tested-by:
Nicolas Capens <nicolascapens@google.com>
-
Nicolas Capens authored
The legacy PixelProcessor and VertexProcessor classes for OpenGL ES contain member fields with types like float4, which require 16-byte alignment. This isn't guaranteed by the compiler until C++17. On macOS, this also requires OS support, which was added in version 10.14 (Mojave), while Chrome still has to support macOS 10.11. src/Renderer/PixelProcessor.cpp:75:18: error: aligned deallocation function of type 'void (void *, std::align_val_t) noexcept' is only available on macOS 10.14 or newer Overriding new and delete for these classes allows us to use our custom allocator which guarantees alignment. Note that the Renderer class already used the same approach. Also note that this hasn't caused issues before because these fields aren't actually accessed by instructions which demand alignment. However, it's still good for performance and to align with the intent (pun intended). Bug: b/174843857 Change-Id: Ia5de5f6fe67a4f54805cdde3fed565c30b9318a8 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/52029Reviewed-by:
Antonio Maiorano <amaiorano@google.com> Tested-by:
Nicolas Capens <nicolascapens@google.com>
-
Nicolas Capens authored
Updates build files to specify using the C++17 standard. Add a usage of the C++17 exclusive [[maybe_unused]] attribute as a test. Also unconditionally use <filesystem> in Reactor unit tests. C++17 deprecates things like std::unary_function<>, which were present in Subzero's LLVM headers, but the functionality was unused so it has been deleted. Bug: b/174843857 Bug: b/155971541 Change-Id: Ib167726535399b0b12751a3d93feaa9db762cd5d Signed-off-by:
Nicolas Capens <capn@google.com> Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/51948Tested-by:
Nicolas Capens <nicolascapens@google.com> Reviewed-by:
Antonio Maiorano <amaiorano@google.com> Kokoro-Result: kokoro <noreply+kokoro@google.com>
-
- 20 Jan, 2021 4 commits
-
-
Sean Risser authored
This extension allows users to pass depthstencil attachments that vkCmdResolveImage will resolve to in addition to its other resolve operations. Only the mandatory resolve modes "VK_RESOLVE_MODE_SAMPLE_ZERO_BIT" and "VK_RESOLVE_MODE_NONE" are supported. It's trivial to support both independent resolve modes since we must resolve depth and stencil attachments separately due to how depth and stencil attachments are stored internally. Change-Id: I0f8ff7cddca5f5acbac1d991b11f0a4447956784 Bug: b/167558951 Test: dEQP-VK.renderpass2.depth_stencil_resolve.* Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/48808Tested-by:
Sean Risser <srisser@google.com> Commit-Queue: Sean Risser <srisser@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com> Kokoro-Result: kokoro <noreply+kokoro@google.com>
-
Antonio Maiorano authored
This will allow us to reuse this code across unit tests and benchmarks. Bug: b/176981107 Change-Id: Ie5ea3708cb959dbd0189658b42f01bad998ae94a Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/51869Reviewed-by:
Nicolas Capens <nicolascapens@google.com> Tested-by:
Antonio Maiorano <amaiorano@google.com> Commit-Queue: Antonio Maiorano <amaiorano@google.com> Kokoro-Result: kokoro <noreply+kokoro@google.com>
-
Antonio Maiorano authored
* Move utility classes into separate hpp/cpp files * Move utility functions into Util.hpp/cpp Bug: b/176981107 Change-Id: If9046f12080f1eb09378586673d871867a836a1b Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/51868 Kokoro-Result: kokoro <noreply+kokoro@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com> Tested-by:
Antonio Maiorano <amaiorano@google.com> Commit-Queue: Antonio Maiorano <amaiorano@google.com>
-
Nicolas Capens authored
The SPIR-V 'EarlyFragmentTests' execution mode requires performing additional per-fragment tests prior to fragment shader execution, even if depth values computed by the shader would otherwise affect them: https://www.khronos.org/registry/vulkan/specs/1.1/html/vkspec.html#shaders-fragment-earlytest Bug: b/140302392 Change-Id: If5d836a35ee9cfc758243b34fad1222d1b0f1085 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/51888 Presubmit-Ready: Nicolas Capens <nicolascapens@google.com> Tested-by:
Nicolas Capens <nicolascapens@google.com> Kokoro-Result: kokoro <noreply+kokoro@google.com> Reviewed-by:
Alexis Hétu <sugoi@google.com>
-
- 19 Jan, 2021 1 commit
-
-
David 'Digit' Turner authored
This CL adds a Posix-based implementation for the VK_KHR_external_memory_fd Vulkan extension, using the SysV shm_open() / shm_unlink() API to create the shared memory region. The Linux backend still uses memfd-based regions which are easier to create, and because Android does not provide shm_open() intentionally [1]. [1] https://android.googlesource.com/platform/ndk/+/4e159d95ebf23b5f72bb707b0cb1518ef96b3d03/docs/system/libc/SYSV-IPC.TXT Bug: b/140419396 Tests: dEQP-VK.* Change-Id: Ibbb23c3af59e81f76e41a0e71281f6d1a8b07c01 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/41408Reviewed-by:
Nicolas Capens <nicolascapens@google.com> Tested-by:
Yilong Li <liyl@google.com> Commit-Queue: Nicolas Capens <nicolascapens@google.com> Kokoro-Result: kokoro <noreply+kokoro@google.com>
-
- 18 Jan, 2021 2 commits
-
-
Antonio Maiorano authored
* Identify members that are owning handles with a comment * Reorder these members in creation order * Reorder explicit destruction of these members in reverse order in destructors * Replace raw pointers with unique_ptrs, but call reset explicitly in destructors to maintain reverse destruction order * Define VULKAN_HPP_NO_NODISCARD_WARNINGS to future-proof for C++17 and up * Remove vestigial vk::UniqueShaderModule and vk::UniquePipeline usage Bug: b/176981107 Change-Id: Ia090be98c2f8ed47701dfc92388547985e5c57b4 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/51829Tested-by:
Antonio Maiorano <amaiorano@google.com> Kokoro-Result: kokoro <noreply+kokoro@google.com> Commit-Queue: Antonio Maiorano <amaiorano@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com>
-
SwiftShader Regression Bot authored
Reactor backend: Subzero Change-Id: I0e14ea808524eea31d4c12aa501cd2e98e445521 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/51768Reviewed-by:
Alexis Hétu <sugoi@google.com> Tested-by:
Nicolas Capens <nicolascapens@google.com> Kokoro-Result: kokoro <noreply+kokoro@google.com>
-
- 15 Jan, 2021 2 commits
-
-
Alexis Hetu authored
It is legal for a shader to not declare BuiltInPosition. This cl adds logic to use 0 for all position components when the position builtin is not present and then keeps executing the rest of the shader normally. Bug: b/176161380 Change-Id: I1b4637b813d3d30958e2db655d299603d625c20a Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/51808 Commit-Queue: Alexis Hétu <sugoi@google.com> Tested-by:
Alexis Hétu <sugoi@google.com> Presubmit-Ready: Alexis Hétu <sugoi@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com>
-
Antonio Maiorano authored
This filename is output in the emitted asm files when ENABLE_RR_EMIT_ASM_FILE is enabled, but on Windows, it was always "<unknown>". Fixed this by splitting out the name by backslash as well. Bug: b/174358505 Change-Id: Ie5386fa50fd8a6aa43a48bc6fa5fcf987936aacf Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/51750 Kokoro-Result: kokoro <noreply+kokoro@google.com> Tested-by:
Antonio Maiorano <amaiorano@google.com> Commit-Queue: Antonio Maiorano <amaiorano@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com>
-
- 14 Jan, 2021 2 commits
-
-
Antonio Maiorano authored
Found these leaks using AppVerifier on Windows. Bug: b/176981107 Change-Id: I89cbfc02e6adf0ea2a54cf80501fbbb3d0867964 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/51748Reviewed-by:
Alexis Hétu <sugoi@google.com> Tested-by:
Antonio Maiorano <amaiorano@google.com> Commit-Queue: Antonio Maiorano <amaiorano@google.com>
-
SwiftShader Regression Bot authored
Reactor backend: LLVM Change-Id: I4590357d7c1eac21c570cbcbdeffa0f4de6d70cd Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/51208Tested-by:
Nicolas Capens <nicolascapens@google.com> Reviewed-by:
Alexis Hétu <sugoi@google.com>
-
- 13 Jan, 2021 5 commits
-
-
Antonio Maiorano authored
This change was originally started by capn@, which added texture sampling to the Triangle benchmarks. I finished up this change with the following changes and fixes: * Implement a correct fill texture to white using copyBufferToImage. * Add Buffer class to wrap vk::Buffer and vk::DeviceMemory. * Add support for using a VK_EXT_headless_surface Window, which is the default on non-Windows platforms for now. On Windows, can be forced to use this by defining USE_HEADLESS_SURFACE = 1. * Fix out of bounds access because renderPassBeginInfo.clearValueCount was set to 2 instead of 1. * Fix illegal access to destructed ArrayRef in call to commandBuffers[i].bindVertexBuffers. * Make it build and run on Linux (fix compilation errors and use aforementioned headless surface mode) Bug: b/176981107 Change-Id: If82496315e77a062c024766863a1ca01e6b424f9 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/51668 Kokoro-Result: Antonio Maiorano <amaiorano@google.com> Tested-by:
Antonio Maiorano <amaiorano@google.com> Commit-Queue: Antonio Maiorano <amaiorano@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com>
-
Antonio Maiorano authored
This implements the extension defined here: https://www.khronos.org/registry/vulkan/specs/1.2-extensions/man/html/VK_EXT_headless_surface.html This extension is useful for tests/benchmarks as it provides a way to create a platform-agnostic Surface with Swapchain, etc., instead of having to create an non-visible framebuffer. Bug: b/176981107 Change-Id: Iad1e55ed7a4e32cebf7577d9d88a9aed4b6f7a20 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/51589Tested-by:
Antonio Maiorano <amaiorano@google.com> Kokoro-Result: kokoro <noreply+kokoro@google.com> Commit-Queue: Antonio Maiorano <amaiorano@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com>
-
Jason Macnak authored
Eventually, this should probably be fetched from the gralloc buffer metadata using Gralloc4::Get(android::gralloc4::MetadataType_Dataspace) Bug: b/147316305 Bug: b/175132241 Test: launch Cuttlefish w/ SwANGLE Test: cts -m CtsGraphicsTestCases -t MediaVulkanGpuTest#testMediaImportAndRendering Change-Id: Ie991380d2d27e7a540ffe37cfc81109618f2d507 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/51688 Presubmit-Ready: Jason Macnak <natsu@google.com> Reviewed-by:Nicolas Capens <nicolascapens@google.com> Tested-by:
Jason Macnak <natsu@google.com> Commit-Queue: Jason Macnak <natsu@google.com>
-
Nicolas Capens authored
Bug: b/176981107 Change-Id: Ifab91e61ceb74c5b6caf62b8f9f1abbd8fef9e01 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/45848Reviewed-by:
Antonio Maiorano <amaiorano@google.com> Kokoro-Result: kokoro <noreply+kokoro@google.com> Tested-by:
Nicolas Capens <nicolascapens@google.com> Commit-Queue: Nicolas Capens <nicolascapens@google.com>
-
Nicolas Capens authored
When the homogeneous w coordinate is near 0, the projected x or y coordinates (after viewport and subpixel scaling) may be larger than what's representable by 32-bit signed integers. On x86 this produces the "indefinite" integer value 0x80000000. This negative value is returned even for positive inputs. This causes the back-face culling calculations to reject triangles which are in fact visible. This change addresses that by introducing the rr::RoundIntClamped() function, which guarantees that very large positive floating-point values are converted to a positive integer value near INT_MAX. Note that the Vulkan spec states that "[the determination whether the triangle is back-facing or front-facing] is made based on the sign of the (clipped or unclipped) polygon’s area computed in framebuffer coordinates." Thus the alternative of performing culling using the unprojected coordinates would have to take negative viewport dimensions into account, and may not produce the same results as sub-pixel snapped coordinates. Adjust back-face culling of wireframe triangles to use the same calculations as solid triangles. Bug: b/177382194 Change-Id: Ice8493d4cfd164638f091bf5a39b5396d65458e2 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/51648Tested-by:
Nicolas Capens <nicolascapens@google.com> Reviewed-by:
Alexis Hétu <sugoi@google.com>
-
- 11 Jan, 2021 3 commits
-
-
Sean Risser authored
Members of classes that are declared as static constexpr are not defined as part of their declaration. Thus they must be defined elsewhere. And they can't be defined in the header file, or there will be multiple definitions for each file that includes the header. So define these contexprs in Constants.cpp Bug: b/177220369 Change-Id: I9ffc63867948bc72061ddb8b0b586a46d840196c Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/51628 Kokoro-Result: kokoro <noreply+kokoro@google.com> Reviewed-by:
Alexis Hétu <sugoi@google.com> Tested-by:
Sean Risser <srisser@google.com> Commit-Queue: Sean Risser <srisser@google.com>
-
Sean Risser authored
This extension allows the host to reset query pools without the use of vkCmdResetQueryPool. Bug: b/169602655 Tests: dEQP-VK.query_pool.occlusion_query.* Change-Id: I20a121d30ff5c39dc9df0a803c3f054ff217e5dc Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/51309 Kokoro-Result: kokoro <noreply+kokoro@google.com> Tested-by:
Sean Risser <srisser@google.com> Commit-Queue: Sean Risser <srisser@google.com> Reviewed-by:
Alexis Hétu <sugoi@google.com>
-
Sean Risser authored
This extension allows users to query and specify different usages for the main image and the stencil. SwiftShader does not use an image's usage for non-debug purposes outside of vkGetPhysicalDeviceImageFormatProperties2. This applies to separate stencil usage as well. Bug: b/176098507 Tests: dEQP-VK.pipeline.sampler.separate_stencil_usage.* Tests: dEQP-VK.renderpass.suballocation.multisample.separate_stencil_usage.* Tests: dEQP-VK.renderpass2.suballocation.multisample.separate_stencil_usage.* Change-Id: Iea74a9fa0de8cdcc51bdc613cdc0754e0f327fd5 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/51368Tested-by:
Sean Risser <srisser@google.com> Commit-Queue: Sean Risser <srisser@google.com> Kokoro-Result: kokoro <noreply+kokoro@google.com> Reviewed-by:
Nicolas Capens <nicolascapens@google.com>
-
- 10 Jan, 2021 1 commit
-
-
Nicolas Capens authored
It only contained the now trivial OpcodeName() implementation. Since the SpirvShaderInstructions.cpp file already contains other SPIR-V opcode utility functions, move it there. Also make this function return a pointer to a constant char string, to avoid needless std::string construction. Bug: b/145351270 Change-Id: Iacfc887566b0a9057f37391ad52d43cdca912308 Signed-off-by:
Nicolas Capens <capn@google.com> Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/51448 Kokoro-Result: kokoro <noreply+kokoro@google.com> Tested-by:
Nicolas Capens <nicolascapens@google.com> Reviewed-by:
Alexis Hétu <sugoi@google.com>
-
- 08 Jan, 2021 2 commits
-
-
Nicolas Capens authored
It's only used for compilation, so don't hang on to it for the entire lifetime of the routine. Likewise the dylib reference can be local. Bug: b/177024837 Change-Id: I261e877f983aa3ec52ef61dc6976da75a4fd5efb Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/51588Tested-by:
Nicolas Capens <nicolascapens@google.com> Reviewed-by:
Antonio Maiorano <amaiorano@google.com> Kokoro-Result: kokoro <noreply+kokoro@google.com>
-
Nicolas Capens authored
It's only used for mangling the names of our generated functions during Routine construction, so don't hang on to it for the entire lifetime of the routine. Also, don't set Function attributes during routine compilation, set them at creation. Bug: b/177024837 Change-Id: I974b10430bced5d59f51e54426f7ee0aa8c96ca2 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/51569 Kokoro-Result: kokoro <noreply+kokoro@google.com> Tested-by:
Nicolas Capens <nicolascapens@google.com> Reviewed-by:
Antonio Maiorano <amaiorano@google.com>
-