|
68e60a92
|
2020-06-26T11:10:07
|
|
Vulkan: Don't store transformed SPIR-V
Since the original SPIR-V is never store after being modified, we don't
need to keep the transformed SPIR-V either.
Bug: angleproject:4513
Test: CQ
Change-Id: I4b70cfa355a08107e6a27377f6258cbf9e4072be
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2270718
Commit-Queue: Tim Van Patten <timvp@google.com>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
774cd1b2
|
2020-06-25T09:15:24
|
|
Vulkan: Only transform SPIR-V once
Prior to this change, the SPIR-V would be transformed as part of
GlslangGetShaderSpirvCode() and then possibly another time afterward to
disable the early fragment test optmization (for monolithic programs) or
to update the descriptor set/binding values (for PPOs). By storing the
original SPIR-V in the ProgramVk and the transformed SPIR-V in the
ProgramExecutableVk, we can now remove the SPIR-V transformation from
GlslangGetShaderSpirvCode() and only perform it once in
ProgramInfo::initProgram() for monolithic programs and PPOs.
Bug: angleproject:4513
Test: CQ
Change-Id: I4e7240b2abe7c796c46cf531948dad0e37c1419a
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2267537
Commit-Queue: Tim Van Patten <timvp@google.com>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
7993f34d
|
2020-06-24T18:39:08
|
|
Vulkan: Store transformed SPIR-V in ProgramExecutableVk
The original SPIR-V is specific to a ProgramVk while the transformed
SPIR-V is specific to a ProgramExecutableVk. This CL keeps the original
SPIR-V in the ProgramVk::mOriginalShaderInfo and the transformed SPIR-V
in ProgramExecutableVk::mTransformedShaderInfo. This allows us to skip
an extra copy that was occurring during PPO link().
Bug: angleproject:4513
Test: CQ
Change-Id: I796dcd6bcfb2df08d9b8f1a5295b2821a4096f16
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2265484
Commit-Queue: Tim Van Patten <timvp@google.com>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
054aeeed
|
2020-06-12T11:49:03
|
|
Vulkan: Batch vkUpdateDescriptorSets calls
Right now we are making this calls multiple times as we loop through
each shader stage. Qualcomm performance validation layer warns about
this. This change will aggregate the calls into one call per dispatch.
Bug: b/158787299
Change-Id: I48aa3752f708c26ffbca2fb7947cb8bbc0f76dcd
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2243321
Commit-Queue: Charlie Lao <cclao@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Courtney Goeltzenleuchter <courtneygo@google.com>
Reviewed-by: Tim Van Patten <timvp@google.com>
|
|
2919dc6e
|
2020-06-15T18:39:39
|
|
Add immutable samplers to descriptor set layout
To support YUV conversion we need to track the use of immutable samplers
in the descriptor set layout.
Bug: b/155487768
Change-Id: Ic7dc6a08551f5125c4a519b5cfada312f95ab914
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2225423
Commit-Queue: Courtney Goeltzenleuchter <courtneygo@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Ian Elliott <ianelliott@google.com>
|
|
68fcfea3
|
2020-05-29T12:34:08
|
|
Vulkan: support format aliasing in texture images
glBindImageTexture specifies the format which should be used to
interpret the texture data and this format is independent from the
texture's own internal format. This change allows the VkImage's format
to be mutable to handle glBindImageTexture calls with different
formats.
Bug: angleproject:3885
Test: dEQP-GLES31.functional.image_load_store.*.format_reinterpret.*
Change-Id: Ia1ad762b4ccae0f510c8b4918781234fcf51c5f1
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2222610
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Commit-Queue: Tim Van Patten <timvp@google.com>
|
|
a28efb2f
|
2020-06-12T13:14:48
|
|
Remove mProgramState from ProgramExecutable::updateActiveImages()
Use of the member variable mProgramState is being removed to reduce the
circular coupling of ProgramExecutable and ProgramState.
Bug: angleproject:4520
Test: Build/CQ
Change-Id: I31d7e607fb06a374a0b0e1d35eb2a092614badf5
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2243323
Commit-Queue: Tim Van Patten <timvp@google.com>
Reviewed-by: Courtney Goeltzenleuchter <courtneygo@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
77851053
|
2020-05-26T18:14:56
|
|
Reduce dependency on ProgramExecutable::mProgram[Pipeline]State
Remove the dependency on mProgramState/mProgramPipelineState for the
following functions in ProgramExecutable:
hasUniformBuffers()
hasStorageBuffers()
hasAtomicCounterBuffers()
hasTransformFeedbackOutput()
getTransformFeedbackBufferCount()
The data structures those function were querying were recently moved
into the ProgramExecutable, so the call stack was:
ProgramExecutable -> ProgramState -> ProgramExecutable
This change updates the functions to return the results immediately.
Remaining functions to be cleaned up in later CLs:
hasDefaultUniforms()
hasTextures()
hasImages()
Bug: angleproject:4520
Test: Build/CQ
Change-Id: Ieaa041ff128e389f322745d55f688d4b07a5a23d
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2216764
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Commit-Queue: Tim Van Patten <timvp@google.com>
|
|
d10ba166
|
2020-05-19T18:00:38
|
|
Rename ProgramState::getProgramExecutable() to getExecutable()
The "Program" part of ProgramState::getProgramExecutable() is already
implied by being part of a ProgramState, so it can be removed.
Bug: angleproject:3570
Change-Id: I35ffb2af81196fa7f189f7d3a37158f5f1951141
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2209317
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Tim Van Patten <timvp@google.com>
|
|
234ea5b1
|
2020-05-05T14:44:30
|
|
Vulkan: Wrap barrier data into PipelineBarrier class
This is preparation CL without introducing any functional change. This
Cl wraps barrier data into its own class and put necessary data
structures in place. It still uses one vkCmdPipelineBarrier call.
Bug: b/155341891
Change-Id: If9c70d24873bd9b89e598acfba2eeee364f0b6c1
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2185149
Commit-Queue: Charlie Lao <cclao@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
562602a3
|
2020-05-05T12:32:56
|
|
Vulkan: Move CommandBufferHelper to vk_helpers.h
Pull CommandBufferHelper class out of ContextVk.h/cpp and move it
to vk_helpers.h/cpp. This is the natural place for it as it's a
helper class. Also, this class is planned to be the interface between
the main and worker threads so moving it to vk_helpers makes it easy
to share between Context and Renderer.
Bug: b/154030403
Change-Id: Ie5eeb864164a3787f800905ae885027834bd1a08
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2182177
Reviewed-by: Charlie Lao <cclao@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Tobin Ehlis <tobine@google.com>
|
|
f07d0072
|
2020-04-27T16:51:05
|
|
Vulkan: use fine grain stage for buffer barriers
We are using VK_PIPELINE_STAGE_ALL_COMMANDS_BIT for
mGlobalMemoryBarrierStages, which is used for both src and dst. This
will cause a full pipeline stall whenever a buffer object introduces a
barrier. This CL will let the caller pass in the specific stage it
will be used for, allowing us to track write and read stage dependencies
separately and request the corresponding barriers.
Bug: b/155122200
Change-Id: I8b8bd291a03b77d07cfbcbe7c3cda2d3771588b9
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2169014
Commit-Queue: Charlie Lao <cclao@google.com>
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
|
|
448b14bb
|
2020-04-27T13:46:08
|
|
Vulkan: Apply binding size in updateBuffersDescriptorSet.
Previously we would bind the full Vulkan buffer size in cases of
unsized arrays in storage buffers. This then would lead to problems
when binding a dynamic buffer that used sub-allocation or larger
internal sizes. Instead use the GL binding size or GL buffer size as
the size limits.
Bug: angleproject:4380
Change-Id: Ia579bfeae3b8d068813336cbd5e1babee9f4f345
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2168020
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
913f4f42
|
2020-04-15T00:54:37
|
|
Vulkan: Support VS, FS, and CS in the same PPO
This CL adds support for a Program Pipeline Object to have a VS, FS,
and CS attached to the same PPO and then using that PPO for both draw
and dispatch calls.
Bug: angleproject:3570
Test: KHR-GLES31.core.compute_shader.sso*
Change-Id: I262cdbdfd442f6db5ba2b45d1308003102b237cb
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2150078
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Courtney Goeltzenleuchter <courtneygo@google.com>
Commit-Queue: Tim Van Patten <timvp@google.com>
|
|
dee4d7a5
|
2020-04-10T10:22:56
|
|
Vulkan: Early fragment tests optimization
Checks if early fragment tests as an optimization is feasible and enable
it if we can. In the link time, if context state diagrees with
optimization (in rare case), then remove the
ExecutionModeEarlyFragmentTests sprv op code.
Bug: angleproject:4508
Change-Id: Ifbb06c0ffb050a9f3ddb16ab50362e908b4b9cf6
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2136490
Commit-Queue: Charlie Lao <cclao@google.com>
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Courtney Goeltzenleuchter <courtneygo@google.com>
|
|
405f8e7b
|
2020-02-24T17:38:10
|
|
Vulkan: Support Program Pipeline Objects
Add support for PPOs to the Vulkan back end.
Bug: angleproject:3570
Change-Id: I5403456929847c185467b008d810f31ecfcb60cc
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2072652
Commit-Queue: Tim Van Patten <timvp@google.com>
Reviewed-by: Courtney Goeltzenleuchter <courtneygo@google.com>
|
|
b387ce93
|
2020-02-21T16:05:41
|
|
Vulkan: Move ProgramInfo/ShaderInfo to ProgramExecutableVk
The classes ProgramInfo and ShaderInfo are being moved into
ProgramExecutableVk along with the ProgramVk members mDefaultProgramInfo
and mLineRasterProgramInfo. This refactor is necessary since these
members are common between ProgramVks and ProgramPipelineVks.
Bug: angleproject:3570
Change-Id: I94cdb1096c6a0c007d858135af694da58d7897ff
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2068901
Commit-Queue: Tim Van Patten <timvp@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
85c076ee
|
2020-02-20T17:54:35
|
|
Vulkan: Make mVariableInfoMap a gl::ShaderMap<>
The ShaderInterfaceVariableInfoMap information is specific to each
shader stage, since the locations are determined for each shader stage.
This change makes mVariableInfoMap a gl::ShaderMap<> to handle this,
which will make it easier to compile separable programs, determine the
variable locations, and transform the SPIR-V.
Bug: angleproject:3570
Change-Id: I28b71a37efe54bbcfe1dcd445fa03ee71e74f0a6
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2062741
Commit-Queue: Tim Van Patten <timvp@google.com>
Reviewed-by: Courtney Goeltzenleuchter <courtneygo@google.com>
|
|
abaa3573
|
2020-02-20T10:23:02
|
|
Vulkan: Only calculate variable locations once
Variable locations and descriptor set/binding values are calculated
multiple times:
- Compiling GLSL->SPIR-V
- Creating the Vulkan pipeline layout
- Updating descriptor sets
These values should instead be calculated once and reused throughout
since they won't change without recompiling the shader program.
Bug: angleproject:3570
Change-Id: I5d8767b3b2e2f741aade7fec9991eea53ee2eb98
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2067101
Commit-Queue: Tim Van Patten <timvp@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
10ade024
|
2020-02-13T18:11:54
|
|
Create the ProgramExecutableVk Class
The ProgramExecutableVk class is being created to collect data
structures that are common to both ProgramVks and ProgramPipelineVks,
as well as any shared functions. This allows callers to make
Program-/ProgramPipeline- specific queries without needing to know
exactly which responded by querying the current ProgramExecutableVk.
This will also allow the necessary data structures to only be
populated and stored within the ProgramExecutableVk when necessary
and reused as often as necessary.
A few things are being moved into this class:
- mVariableInfoMap
This information will be required to defer translating the SPIR-V
until when the vulkan pipeline layout is determined and the actual
locations are known. This will also allow removing determining
these locations twice (during GLSL->SPIR-V compilation and pipeline
layout).
- createPipelineLayout()
- update*DescriptorSet()
- Descriptor Set Layout lists
- Pipeline Layout
- Various other functions/members related to pipeplines, descriptor
sets, etc.
Bug: angleproject:3570
Change-Id: I4b5ababeafec865148783c8ffd4c15f659f4856d
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2055656
Commit-Queue: Tim Van Patten <timvp@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|