|
f3c1de36
|
2023-08-17T15:29:24
|
|
Make shader recompile while parallel linking safe
Prior to this change, Program* objects held references to Shader*
objects. This poses a problem where a shader recompile can race with a
program link, if the program link is done in parallel.
As a result, a good chunk of the link job is done serially and under the
share group lock. After this change, that is no longer a problem, and
most of the link can be made lockless/parallelized.
This change separates out the "compiled state" from the rest of the
shader state. This was already done for the front-end state (for the
sake of caching), but is also now done for the backends that need it.
The compiled state in turn is placed in a shared_ptr, and is shared with
the program. When a shader is compiled, its own shared_ptr is replaced
with a new object, leaving all programs currently compiling unaffected
and using the previous compilation results.
Once a program is linked, its references to compiled shader states is
updated.
Bug: angleproject:8297
Change-Id: Iff7094a37088fbad99c6241f1c48b0bd4c820eb2
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4791065
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Charlie Lao <cclao@google.com>
|
|
3479f4a1
|
2023-08-16T14:43:35
|
|
Move more ProgramExecutable basic type vars to mBasicDataTypeStruct
They can be just load/saved along with mBasicDataTypeStruct, no need to
do them separately:
mLinkedShaderVersions was previously only saved if
it is separate program, now it is always saved along with
mBasicDataTypeStruct, since the extra cost of a few more bytes of memcpy
is ignorable, but will make it more consistent.
mActiveUniformBlockBindings was previously updated instead of load, now
it is load (and verified with ASSERT)
mCanDrawWith was previously updated, now chnaged to load.
Bug: b/275102061
Change-Id: I4e15b955606f34966d56b1c5e3d9d2f22ddeb14d
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4786308
Reviewed-by: Roman Lavrov <romanl@google.com>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Commit-Queue: Charlie Lao <cclao@google.com>
|
|
c34f83d9
|
2023-08-16T11:53:27
|
|
Group all ProgramExecutable basic data type members into a struct
So that we can load/save with a simple memcpy.
Bug: b/275102061
Change-Id: I178404fd72b615174a7a0412ea5482ae2bea2f80
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4785567
Reviewed-by: Roman Lavrov <romanl@google.com>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Commit-Queue: Charlie Lao <cclao@google.com>
|
|
5217beb2
|
2023-08-15T13:43:12
|
|
Reland "Tightly pack LinkedUniform by using int16_t"
This is a reland of commit 152cf62b38874238095a91307e4ea9bcdedf8f46
Original change's description:
> Tightly pack LinkedUniform by using int16_t
>
> There is a check of vector size when we link uniforms and the maximum
> vector size is 4096 due to we clamp the maxUniformBlockSize to 64KB. In
> reality, if we exceeds this number, program link will take really long
> time and then hit failure. So there is no real need to keep all the
> variables in 32 bit integer. This CL changes to 16 bit integer. Further,
> sh::BlockMemberInfo and ActiveVariable data members are embeded into
> LinkedUniform struct as well so that the unused variables can be removed
> and data can be tightly packed. This also makes LinkedUniform easier to
> maintain as a simple struct with basic data types. With this change,
> LinkedUniform size is reduced from 108 bytes down to 60 bytes, 48 bytes
> reduction. Given some apps has 200-ish uniforms, this CL reduces 48
> bytes x 200 = ~9K memory just for uniforms per program (which goes
> through hash compute and decompression and file reads).
>
> Bug: b/275102061
> Change-Id: I7fae20f5b75f3239305e2094a992e3040b8c8e4c
> Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4754133
> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
> Commit-Queue: Charlie Lao <cclao@google.com>
Bug: b/275102061
Change-Id: I1cdec9407e930608d3239a104dcbf77c8d8e2113
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4791661
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Commit-Queue: Charlie Lao <cclao@google.com>
|
|
1e1c9d9d
|
2023-08-11T15:16:26
|
|
Pack and reduce Program::mProgramInput size
Right now mProgramInput is std::vector<sh::ShaderVariable>. It really
only need a subset of ShaderVariable struct. This CL adds a ProgramInput
struct so that we can add data members that actually required. This CL
also makes bools into bitfield and some variables to uint16_t to further
compact the size. This CL also groups the data memebers other than
string to basicDataTypeStruct which only contains basic data types and
the entire struct is memcpied during program binary load and save. This
not just reduces number of memcpy calls, but also improves reliability
so that when someone adds a new member into the struct, it will
automatically load/save correctly.
Bug: b/275102061
Change-Id: Ic055c986453ed46e56057a0122c9926245fef4d1
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4776267
Reviewed-by: Roman Lavrov <romanl@google.com>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Commit-Queue: Charlie Lao <cclao@google.com>
|
|
9f48f931
|
2023-08-16T06:38:15
|
|
Revert "Tightly pack LinkedUniform by using int16_t"
This reverts commit 152cf62b38874238095a91307e4ea9bcdedf8f46.
Reason for revert: Suspect cause of failure in for several Linux MSan Tests, e.g.
https://ci.chromium.org/ui/p/chromium/builders/ci/Linux%20MSan%20Tests/42403/overview
https://ci.chromium.org/ui/p/chromium/builders/ci/WebKit%20Linux%20MSAN/22174/overview
https://ci.chromium.org/ui/p/chromium/builders/ci/Linux%20MSan%20Tests/42403/overview
Original change's description:
> Tightly pack LinkedUniform by using int16_t
>
> There is a check of vector size when we link uniforms and the maximum
> vector size is 4096 due to we clamp the maxUniformBlockSize to 64KB. In
> reality, if we exceeds this number, program link will take really long
> time and then hit failure. So there is no real need to keep all the
> variables in 32 bit integer. This CL changes to 16 bit integer. Further,
> sh::BlockMemberInfo and ActiveVariable data members are embeded into
> LinkedUniform struct as well so that the unused variables can be removed
> and data can be tightly packed. This also makes LinkedUniform easier to
> maintain as a simple struct with basic data types. With this change,
> LinkedUniform size is reduced from 108 bytes down to 60 bytes, 48 bytes
> reduction. Given some apps has 200-ish uniforms, this CL reduces 48
> bytes x 200 = ~9K memory just for uniforms per program (which goes
> through hash compute and decompression and file reads).
>
> Bug: b/275102061
> Change-Id: I7fae20f5b75f3239305e2094a992e3040b8c8e4c
> Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4754133
> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
> Commit-Queue: Charlie Lao <cclao@google.com>
Bug: b/275102061
Change-Id: Id344e306307553731097f06edafc40bfeb73ff80
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4780494
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Commit-Queue: Geoff Lang <geofflang@chromium.org>
|
|
152cf62b
|
2023-08-15T13:43:12
|
|
Tightly pack LinkedUniform by using int16_t
There is a check of vector size when we link uniforms and the maximum
vector size is 4096 due to we clamp the maxUniformBlockSize to 64KB. In
reality, if we exceeds this number, program link will take really long
time and then hit failure. So there is no real need to keep all the
variables in 32 bit integer. This CL changes to 16 bit integer. Further,
sh::BlockMemberInfo and ActiveVariable data members are embeded into
LinkedUniform struct as well so that the unused variables can be removed
and data can be tightly packed. This also makes LinkedUniform easier to
maintain as a simple struct with basic data types. With this change,
LinkedUniform size is reduced from 108 bytes down to 60 bytes, 48 bytes
reduction. Given some apps has 200-ish uniforms, this CL reduces 48
bytes x 200 = ~9K memory just for uniforms per program (which goes
through hash compute and decompression and file reads).
Bug: b/275102061
Change-Id: I7fae20f5b75f3239305e2094a992e3040b8c8e4c
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4754133
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Commit-Queue: Charlie Lao <cclao@google.com>
|
|
719165c8
|
2023-08-04T12:13:37
|
|
Remove "const UniformTypeInfo *typeInfo" from struct LinkedUniform
This is a cached pointer to the const kInfoTable. There isn't much of
performance benefit to cache here compare to directly retrieve from the
table. This cached pointer is removed in this CL, which means we do not
need to update the pointer in the ProgramExecutable::load().
This and a few earlier CLs that attempt to do memcpy for entire
mUniforms reduced average frame time of blade_and_soul_revolution app
trace 3%, from 4.3359 ms to 4.2066ms on pixel 7 pro.
Bug: b/275102061
Change-Id: I6fd34d665234e3a5cc85344924049bf5b13aaa80
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4753933
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Commit-Queue: Charlie Lao <cclao@google.com>
Reviewed-by: Yuxin Hu <yuxinhu@google.com>
|
|
d1117834
|
2023-08-04T10:48:22
|
|
Simplify struct LinkedUniform a bit more
In earlier CL crrev.com/c/4740298, we added mFixedSizedData structure to
group the data memebrs that can be memcpy-able into one variable, so
that we can memcpy that. Since then, we have made entire LinkedUniform
struct memcpy-able (crrev.com/c/4750443 is doing memcpy of entire
std::vector<LinkedUniform>). Thus, there is no longer a need for
mFixedSizedData. This CL removes that.
This CL also removes isStruct and inArrayOfArrays from LinkedUniform,
since they are always false.
This CL also removes some unused APIs from LinkedUniform.
Bug: b/275102061
Change-Id: I6ead3d8f179efc0d383352f7ac0efa6bf3dc8a1b
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4753932
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Yuxin Hu <yuxinhu@google.com>
Commit-Queue: Charlie Lao <cclao@google.com>
|
|
41d27ec3
|
2023-08-03T18:06:08
|
|
load/save entire std::vector<LinkedUniform> with one call.
Now LinkedUniform is a simple data struct with only fundamental types,
we can load the entire vector at once.
Bug: b/275102061
Change-Id: I7c030677d02517f86d960de85b0e7ae2c916a26e
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4750443
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Yuxin Hu <yuxinhu@google.com>
Commit-Queue: Charlie Lao <cclao@google.com>
|
|
eff12c1e
|
2023-08-03T12:10:05
|
|
Move name and mappedName out of LinkedUniform struct
These are std::string objects. This CL moves these two data out of
LinkedUniform and into ProgramExecutable class, side by side with
mUniforms. With these two data moved out, LinkedUniform is now a simple
struct with basic data types, and I can memcpy entire vector of
uniforms.
Bug: b/275102061
Change-Id: I9ae13e7daca85f8e5f3662a4718f190bebb5f5d2
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4750442
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Yuxin Hu <yuxinhu@google.com>
Commit-Queue: Charlie Lao <cclao@google.com>
|
|
9c588180
|
2023-08-02T16:39:44
|
|
Change LinkedUniform::arraySizes from std::vector to unsigned int
We always flatten multiple dimensional arrays in the uniform to a one
dimensional array, so the arraySizes can be simplified to unsigned int
instead of a vector. With this, we can now move the arraySize into the
simple mFixedSizeData struct and the normal memcpy will cover the
load/save.
Bug: b/275102061
Change-Id: I24c026f783b755f7aa691a5db5746b6309a21227
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4735275
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Yuxin Hu <yuxinhu@google.com>
Commit-Queue: Charlie Lao <cclao@google.com>
|
|
22438ad8
|
2023-08-02T14:01:45
|
|
Embed ActiveVariable into BufferVariable and ShaderVariableBuffer
This CL embeds ActiveVariable into BufferVariable and
ShaderVariableBuffer struct instead of subclass. This allows us to
remove the virtual function of ~ActiveVariable(), which means
ActiveVariable is a simple struct with basic types and memcpy can be
used for load/save. Thus, in this CL, I also moved activeVariables to
LinkedUniform::mFixedSizeData structure and let memcpy handle the
load/save.
Bug: b/275102061
Change-Id: I8d21080cfdd72d4d22cef927d136ca428d9b12e4
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4722265
Reviewed-by: Roman Lavrov <romanl@google.com>
Commit-Queue: Charlie Lao <cclao@google.com>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
|
|
ee019f58
|
2023-08-01T17:03:24
|
|
Group fixed sized data of LinkedUniform into a struct
Most of gl::LinkedUniform struct is a basic types and can be simply
initialized with memcpy. This CL groups these together and encapsulate
them with get APIs. The load/save is now a single memcpy for the entire
fixed size data structure of basic types.
Bug: b/275102061
Change-Id: I49120c06ec941c783790ac0ecb0ee314a4234b26
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4740298
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Roman Lavrov <romanl@google.com>
Commit-Queue: Charlie Lao <cclao@google.com>
|
|
7bb13226
|
2023-08-01T12:10:44
|
|
Pack booleans inside struct LinkedUniform into bitfields
Right now every bool is load/stored as integer, which itself is a
memcpy. This CL moves them into a bitfield and load/store with one
uint32_t, thus improves efficiency of cache load/save.
Bug: b/275102061
Bug: angleproject:8223
Change-Id: Id8e8e8861c8fcbd75dbef6056e4ff6c8ad2fc4a1
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4740292
Commit-Queue: Charlie Lao <cclao@google.com>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Roman Lavrov <romanl@google.com>
|
|
79973750
|
2023-07-27T17:53:24
|
|
Let UniformLinker uses its own struct instead of LinkedUniform
UniformLinker itself needs more detailed information than the final
linked uniforms. Right now they are using the same data structure. This
CL adds a new structure for linker to use. Since the linker data
structure is temporary, we never needs to load/save from cache, we have
more freedom here to use complex data types. The benefit of separate out
intermediate structure from LinkedUniform is that it allows us to
further simplify LinkedUniform structure without change much of
ProgramLinkedResource implementation. As result of this, this CL removes
field and outerArraySizes (both are std::vector type) from
LinkedUniform.
Bug: b/275102061
Change-Id: Ic1291b51b8906ac586a2f25eb1dbbe74eae8fdc5
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4727742
Reviewed-by: Roman Lavrov <romanl@google.com>
Commit-Queue: Charlie Lao <cclao@google.com>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
|
|
f24ea41e
|
2023-07-31T11:12:44
|
|
Embed sh::ShaderVariable data member into gl::LinkedUniform
ProgramExecutable::load and save function is load/save each individual
data members. Uniform can be quite large as shown in some app traces and
this causes performance problem even when program memory has a cache
hit. This CL flattens gl::LinkedUniform structure by embedding
sh::ShaderVariable data members so that we can remove unrelated members
and also prepare for further optimization in future CLs.
Bug: b/275102061
Change-Id: I7c18cb73e359fba7cd6375b4b1635e9040ef140d
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4735152
Reviewed-by: Roman Lavrov <romanl@google.com>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Commit-Queue: Charlie Lao <cclao@google.com>
|
|
5446e87e
|
2023-07-24T16:46:56
|
|
Improve ProgramExecutable::load performance
We are calling push_back for each vector inside ProgramExecutable. This
causes c++ run time to constantly re-allocate storage and copy the
vector over to new storage, and impacts performance negatively. Since
the vector size is know when we load program from cache, this CL calls
resize to the correct size first and then update each element as we walk
over, thus reduces the vector storage reallocation. This CL reduces
blade_and_soul_revolution frame time from 4.48 ms to 4.35 ms on pixel 7
pro.
This CL also changes ProgramBinaryTest tests to use slightly more
complicated program instead of the simplest program.
Bug: b/275102061
Change-Id: I8d92117b07a9ad2d0851850e473ea1b86f9868f8
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4713685
Reviewed-by: Roman Lavrov <romanl@google.com>
Commit-Queue: Charlie Lao <cclao@google.com>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
|
|
c1ba8e6f
|
2023-06-20T16:03:20
|
|
Vulkan: Flatten shader interface variable maps
This change removes duplicate entries added in the shader shader
interface variable maps. One level of arrayness (indexed by shader
type) is removed from these maps as now there is only a single entry
per linked resource/etc.
Bug: angleproject:7220
Change-Id: Ibf2d06a0e1f68e68797c2066f36e14cb9e667f77
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4628677
Reviewed-by: Yuxin Hu <yuxinhu@google.com>
Reviewed-by: Charlie Lao <cclao@google.com>
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
|
|
24f4007b
|
2023-06-08T00:41:55
|
|
Vulkan: Use SPIR-V ids instead of names in the transformer
This change removes the SPIR-V transformer's reliance on type and
variable names. As a result:
- String hashing is removed from the info map data structure and the
SPIR-V transformer
- The ID discovery class is entirely removed
- Internal variable names have become a detail of the compiler alone
(and are no longer exposed as part of the compiler interface)
- Some front-end name tracking is removed ("parentStructMappedName",
etc)
This change also properly cleans up xfb emulation types that were
previously left over.
This change allows the SPIR-V compiler to emit user strings as-is
instead of prefixing them with `u_` leading to more readable debug
shaders. Additionally, it will make it possible not to emit debug info
at all. Both of these changes will be done in follow ups.
Bug: angleproject:7220
Change-Id: Iaa127496209a27aaae2e0d14c41b22fffb0b72a2
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4600610
Reviewed-by: Roman Lavrov <romanl@google.com>
Reviewed-by: Yuxin Hu <yuxinhu@google.com>
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
|
|
28e7adca
|
2022-12-09T00:00:00
|
|
GL: Implement clip distance state emulation
Pass the current set of enabled clip distances
to vertex shaders via an internal uniform and
dynamically set disabled elements to zero.
Bug: angleproject:7880
Change-Id: I709d31dc7ca0606decf49adf674460a941837683
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4094314
Commit-Queue: Alexey Knyazev <lexa.knyazev@gmail.com>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
|
|
2ebd5100
|
2022-08-11T10:43:32
|
|
Add gl::Context as a parameter to Shader::resolveCompile
This prepares us to access the Context's shader cache in resolveCompile
in the next commit.
Bug: angleproject:7036
Change-Id: I7995c54b290a5a48f0c8985cb56ea0048598ab2f
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3827642
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
|
|
493b5aff
|
2022-08-09T14:57:24
|
|
Vulkan: Workaround ARM bug with stencil write mask
Bug: angleproject:7556
Change-Id: I0aa17c178071cc15d8ee15f700b0c4932819c72a
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3821367
Reviewed-by: Ian Elliott <ianelliott@google.com>
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
|
|
5911243c
|
2022-07-06T15:55:28
|
|
Fix linkValidateTransformFeedback for glLinkProgram
From OpneGLES 3.2 spec. 11.1.2.1: A program will fail to link if the
count specified by TransformFeedbackVaryings is non-zero, but the
program object has no vertex, tessellation evaluation, or geometry
shader. Add check in validation to account for this.
Bug: angleproject:5557
Tests: ProgramPipelineTest32.CreateProgramWithTransformFeedbackVarying
Change-Id: Ia86cbe8e85cb6a69fd35ddc4bc6ee37b9500c78f
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3723861
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
|
|
9ea3967d
|
2022-05-22T13:06:18
|
|
Bug fix in GL_EXT_YUV_target
Shaders with multiple samplers need to account for conflicting
YUV sampler states and accordingly reevaluate them when sampler
uniforms are updated.
Tests: ImageTestES3.ProgramWithBothExternalY2YAndExternalOESSampler*
Bug: angleproject:4852
Change-Id: Ie633e62f0bbb89f217183623d4fc6ab5b3acfd81
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3661211
Reviewed-by: Trevor Black <vantablack@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: mohan maiya <m.maiya@samsung.com>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
|
|
fea19567
|
2022-05-17T17:44:06
|
|
Vulkan: Remove removeEarlyFragmentTestsOpt flag
* Removed removeEarlyFragmentTestsOptimization and the related
SPIRV transformation and variables.
* Removed mUsesEarlyFragmentTestsOptimization.
* Removed SH_EARLY_FRAGMENT_TESTS_OPTIMIZATION.
* Merged updateUsesEarlyFragmentTestsOptimization() into
updateFragmentInoutRange().
Bug: angleproject:7347
Change-Id: I7299bd4e8ab5363e5cf06eb48419d4f469106e12
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3648217
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Commit-Queue: Amirali Abdolrashidi <abdolrashidi@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Charlie Lao <cclao@google.com>
|
|
d4442f53
|
2022-04-28T15:23:19
|
|
Reset the program executable if async linking fails.
In this case, there is no exectuable to reset back to and the current
executable is filled with state that is "valid" because the program
failed to link for implementation specific reasons.
Bug: chromium:1319332
Change-Id: I1aeb4f22394a0b5d1127eb313e4d550e4fc8af66
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3615016
Reviewed-by: Lingfeng Yang <lfy@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Geoff Lang <geofflang@chromium.org>
|
|
5113ae8e
|
2022-04-29T22:42:59
|
|
Vulkan: Explicitly enable per-sample shading if `sample` used
The Vulkan spec is not explicit about the `Sample` decoration implicitly
enabling per-sample shading. While this is being corrected in the spec,
the ARM Vulkan driver does not have this implicit behavior.
A workaround is added such that the usage of the `sample` qualifier is
reported, and used to explicitly enable per-sample shading through the
API.
Bug: angleproject:6876
Change-Id: Idb8345aacdcfa45cb37fefcd30aa5405168d21e3
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3615738
Reviewed-by: Charlie Lao <cclao@google.com>
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
2d6e42fc
|
2022-04-22T14:04:21
|
|
Update Program Pipeline TODOs.
Bug: angleproject:3570
Bug: angleproject:7232
Change-Id: I0923e6b232b80ee26cb4c5788232c25a545ff87a
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3600916
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Auto-Submit: Jamie Madill <jmadill@chromium.org>
|
|
e77be663
|
2022-04-14T05:04:13
|
|
Use ProgramExecutable directly in GlslangWrapper.
Using the ProgramExecutable instead of the state means
we can deal with merged samplers and images immediately.
This will make it easier to use linear maps when indexing
program resources for descriptor sets.
Bug: angleproject:3570
Bug: angleproject:4524
Change-Id: Icd8ee9fe61730b81fafa2bdc59a2788a0d92ad12
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3580882
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Yuxin Hu <yuxinhu@google.com>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
c5271e8e
|
2022-04-04T23:28:35
|
|
Vulkan: Emulate GL_KHR_blend_equation_advanced
Based on a change by Brandon Schade <b.schade@samsung.com>
In the translator, when advanced blend is enabled, an input attachment
is added. Based on the listed advanced blend equations, emulation code
is added that performs those equations' functions. The blend equation
itself is passed through a driver uniform.
Note that the advanced blend extension only allows a single output to
use advanced blend, and that should be at location 0.
In the Vulkan backend, when advanced blend is used, the driver uniform
to select the equation is updated and normal blending is disabled.
Bug: angleproject:3586
Change-Id: Icc42e8be238d34fca149087eb9cfe616a7643a6b
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3575738
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Yuxin Hu <yuxinhu@google.com>
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
|
|
6768aff7
|
2022-04-07T23:25:08
|
|
Fix Geometry Shader Conformance Test Failure on Pixel6
Add code in shader linker stage
to check the number of AtomicCounterBuffers
against these values:
GL_MAX_VERTEX_ATOMIC_COUNTER_BUFFERS
GL_MAX_FRAGMENT_ATOMIC_COUNTER_BUFFERS
GL_MAX_COMPUTE_ATOMIC_COUNTER_BUFFERS
GL_MAX_GEOMETRY_ATOMIC_COUNTER_BUFFERS_EXT
GL_MAX_COMBINED_ATOMIC_COUNTER_BUFFERS
GL_MAX_TESS_CONTROL_ATOMIC_COUNTER_BUFFERS
GL_MAX_TESS_EVALUATION_ATOMIC_COUNTER_BUFFERS
Bug: angleproject:6918
Change-Id: If1c1d0dc2452f5aafc72d81f4f5523608810bba9
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3576629
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Ian Elliott <ianelliott@google.com>
Commit-Queue: Yuxin Hu <yuxinhu@google.com>
|
|
dd86dd15
|
2022-03-25T14:55:05
|
|
Cache outer array offset in linked uniforms.
Our current tracking would only track one array dimension. For
nested arrays the flattened parent index would be incorrect.
Update this tracking so we can use it in the Vulkan descriptor
set caching. Store this value as a separate integer member to
avoid conflicting with other back-ends.
Bug: angleproject:6776
Change-Id: Ie1a5dc3d64ccac23dffcc73684d619336cb0f0da
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3550824
Reviewed-by: Yuxin Hu <yuxinhu@google.com>
Reviewed-by: Charlie Lao <cclao@google.com>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
4e644b33
|
2022-01-22T16:17:46
|
|
Vulkan: Remove ProgramExecutableVk back-pointers.
This removes the mProgram and mProgramPipeline back-pointers from
ProgramExecutableVk. In order to fix this, we needed to refactor
the VkPipeline init functions to call through ProgramExecutableVk
only instead of passing through ProgramVk. We also needed to move
the early fragment shader optimization boolean out from Program.
This CL also fixes a few places where the early fragment test
optimization boolean wasn't properly updated.
Bug: angleproject:3570
Change-Id: Ie4c48087f6eb022e6f0a4dacc2710085165d49e1
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3408267
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Tim Van Patten <timvp@google.com>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
374e0c43
|
2022-01-20T14:04:27
|
|
ProgramPipeline: Remove mHas members.
These are no longer needed now that the excutable mirrors uniforms/
samplers/sahder buffers/etc.. Refactoring change only.
Bug: angleproject:3570
Change-Id: I768381ac64a750f04180ab824302e3550030911c
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3403047
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
0dc0dc2a
|
2021-12-30T11:35:40
|
|
Re-land: "Vulkan: Remove "fillProgramStateMap"."
This copies additional shader info like uniforms from the Program
to the Program Piplines. There is now a duplication between PPOs
and Programs. There is no additional storage required for non-PPO
Programs.
Re-land fixes fragment in/out uniform updating with PPOs.
Bug: angleproject:3570
Change-Id: I64b2db6fbc3a610f3b5e617301f94eb30d915939
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3412999
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
6a14e328
|
2022-01-25T00:49:45
|
|
Revert "Vulkan: Remove "fillProgramStateMap"."
This reverts commit 38deffe40db83836588e0cd50864945a9ddba36b.
Reason for revert: angle_end2end_tests failures on Pixel 6.
Original change's description:
> Vulkan: Remove "fillProgramStateMap".
>
> This copies additional shader info like uniforms from the Program
> to the Program Piplines. There is now a duplication between PPOs
> and Programs. There is no additional storage required for non-PPO
> Programs.
>
> Bug: angleproject:3570
> Change-Id: I5ed6c946df945aaf2f65752f797b16e7649d5584
> Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3362297
> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
> Reviewed-by: Tim Van Patten <timvp@google.com>
> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Bug: angleproject:3570
Change-Id: I3a4822c8a65d024070a9fe5df103b88a3c8333d3
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3414024
Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Commit-Queue: Yuly Novikov <ynovikov@chromium.org>
|
|
38deffe4
|
2021-12-30T11:35:40
|
|
Vulkan: Remove "fillProgramStateMap".
This copies additional shader info like uniforms from the Program
to the Program Piplines. There is now a duplication between PPOs
and Programs. There is no additional storage required for non-PPO
Programs.
Bug: angleproject:3570
Change-Id: I5ed6c946df945aaf2f65752f797b16e7649d5584
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3362297
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Tim Van Patten <timvp@google.com>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
400175d8
|
2022-01-07T14:54:03
|
|
Copy shader buffers into pipeline executables.
Bug: angleproject:3570
Change-Id: I82e4fc15aac9f60f40aae69785b24e5dc233fd78
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3371528
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Tim Van Patten <timvp@google.com>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
bd64b3ea
|
2021-12-30T13:47:09
|
|
Move pipeline uniforms into the executable.
Refactoring change only.
Bug: angleproject:3570
Change-Id: I8cfe41d86aa63d395d7da02dcc3c85a18fde553e
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3359002
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
cabc3b98
|
2021-12-30T14:33:31
|
|
Move atomic counter uniform range counter to executable.
This makes the code more consistent with the other ranges. It will
make way for future refactorings to moving more uniform code to
the executable.
Bug: angleproject:3570
Change-Id: Ie365c0e184039f813f19d3f38b401ad8a0b72120
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3359001
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Tim Van Patten <timvp@google.com>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
6d3435fd
|
2021-12-01T17:08:01
|
|
Validate SamplerFormat
We weren't validating sampler formats in ProgramExecutable validation.
Bug: chromium:1273661
Change-Id: Ida0c67c0c7169ea3f47ceb2d433bee17012a7e5e
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3312717
Reviewed-by: Charlie Lao <cclao@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Lingfeng Yang <lfy@google.com>
|
|
019ddad5
|
2021-11-04T13:22:47
|
|
Reset cache in ProgramExecutable::updateActiveSamplers.
This missing reset was causing incorrect state validation to
persist in a few instances.
Bug: chromium:1266437
Change-Id: I7ab47c81bf9f855e3ad75048f9d1aaefbc2291df
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3262477
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
4a2446c6
|
2021-10-19T11:55:17
|
|
Vulkan: Implement robust shader outputs.
In this CL we change ANGLE to pass the mask of missing shader
outputs down to pipeline creation. We then use the color mask
bits to block SwiftShader writing to unused outputs.
This fixes the undefined behaviour present in Genshin Impact.
Note that the other GLES implementations we tested don't seem
to modify outputs even if they're unused.
It was easier to mask out the color attachments in initialize
rather than set up the pipeline desc to mask out the attachments.
This was because we manipulate the color mask in a fairly complex
way before we initialize the pipeline desc.
Bug: angleproject:6566
Change-Id: Ie659fcd511cd286fa573fd25e3e6a0b9e123ebd6
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3232435
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Tim Van Patten <timvp@google.com>
|
|
3a9f18f1
|
2021-10-18T10:44:38
|
|
Refactor program pipeline handling.
In preparation for moving more code from gl::Program to
gl::ProgramExecutable so it can be shared with ProgramPipeline.
Bug: angleproject:6566
Change-Id: Icb7ecccb37ae8e0d7d5fef8968f0dd7ef6fe6150
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3226305
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
66e8faf7
|
2021-10-20T14:06:08
|
|
Remove ProgramExecutable's "isCompute" property.
This consolidates the lists of uniforms, ssbos, etc into one.
Requires a few checks to change from graphics shader stages into
all shaders.
Bug: angleproject:6596
Change-Id: Ic8f6bfc4fa295c3bea9f5f1ded11e8fbca1c3164
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3233361
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
|
|
1ca1589f
|
2021-09-13T10:56:58
|
|
Give GLES extension bools a vendor suffix.
This is in preparation for auto-generation which will give all of
these bools suffixes.
Bug: angleproject:6379
Change-Id: I7e3f6c9b644c41a2165e6bf7b62d661fd352a250
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3158503
Reviewed-by: Jonah Ryan-Davis <jonahr@google.com>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
10846073
|
2021-08-30T14:41:16
|
|
Allow image uniforms to be used in separable programs
This change updates mActiveImagesMask in ProgramExecutable
for separable programs. Previously image uniforms would only
work in the first shader stage.
Bug: angleproject:4512
Tests: ProgramPipelineTest31.ImageUniforms
Change-Id: Ib35bed94bb8fac883fd67f8bfa052186926d0ce4
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3131582
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Brandon Schade <b.schade@samsung.com>
|
|
cc52e7cd
|
2021-04-19T21:37:20
|
|
Prevent separable programs from relying on attached shaders
Previously, several linking functions were reliant on the
HasAttachedShaders interface. The information stored there has been
moved to ProgramExecutable.
Linking information such as uniforms and uniform blocks from
attached shaders is now also stored in temporary pending variables
inside ProgramExecutable.
Bug: angleproject:5506
Test: ProgramPipelineTest31.VaryingLocationMismatch*
Test: GeometryShaderTest.RecompileSeparableVSWithVaryings*
Test: ProgramBinaryES31Test.SeparableProgramLinkedUniforms*
Change-Id: I93591431959c1c4c547ada92ec358369a3417723
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2909760
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Tim Van Patten <timvp@google.com>
Commit-Queue: Brandon Schade <b.schade@samsung.com>
|
|
c664601d
|
2021-04-26T17:08:06
|
|
Allow drawing if a fragment shader isn't present
According to the OpenGL ES 3.1 spec:
7.3 PROGRAM OBJECTS
If there is no active program for the vertex or fragment shader
stages, the results of vertex and fragment shader execution will
respectively be undefined.
If there isn't an active program for only one of these shader
stages, the results of the other shader stage are still defined.
To handle this, we no longer no-op the draw call if one of these
is missing. We only no-op the draw if there's no vs.
This allows for transform feedback to be captured when there's only
a geometry and vertex shader.
Tests: KHR-GLES32.core.geometry_shader.api.program_pipeline_vs_gs_capture
Tests: KHR-GLES32.core.separable_programs_tf.geometry_active
Tests: ProgramPipelineTest31.PipelineWithoutVertexShader*
Tests: ProgramPipelineTest31.PipelineWithoutShaders*
Bug: angleproject:5579
Change-Id: If9849cc398c307232435b167ab12431fa4258201
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2906723
Commit-Queue: Brandon Schade <b.schade@samsung.com>
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
c8ee13c7
|
2021-04-02T12:19:33
|
|
Vulkan: Fix a validation bug in glBeginTransformFeedback
Add logic to check the program or the pipeline before erroring out when
validating glBeginTransformFeedeback.
Bug: angleproject:5557
Test: ProgramPipelineXFBTest31.VaryingIOBlockSeparableProgramWithXFB*
Change-Id: I0df8a8d87b3632745bc91dc2673f2fac31c6cdb1
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2743440
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Tim Van Patten <timvp@google.com>
Commit-Queue: Mohan Maiya <m.maiya@samsung.com>
|
|
323c5f24
|
2021-03-29T17:47:53
|
|
Validate PPO sampler uniforms
"Command & Conquer: Rivals" uses PPOs and was hitting the following
assert:
angle::Result ContextVk::updateActiveTextures(const gl::Context *context)
{
...
for (size_t textureUnit : activeTextures)
{
gl::Texture *texture = textures[textureUnit];
gl::TextureType textureType = textureTypes[textureUnit];
ASSERT(textureType != gl::TextureType::InvalidEnum);
This is the same assert that is generated by the test
ProgramPipelineTest31.DifferentTextureTypes which is currently being
skipped since it's known to fail.
This CL refactors sampler validation into the ProgramExecutable to allow
PPOs to take advantage of the shared code and behave correctly, since
the necessary data is already copied into the PPO's ProgramExecutable
via ProgramExecutable::updateActiveSamplers(). This also takes advantage
of the subject/observer pattern that's already established between
programs and PPOs to ensure only the PPOs that the program is a part of
are updated when a program's sampler uniforms are updated.
Bug: angleproject:3570
Bug: b/182409935
Test: ProgramPipelineTest31.DifferentTextureTypes
Change-Id: I3d34efd66dc85e7ff23a8422cb14d5f90a5f7085
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2792862
Commit-Queue: Tim Van Patten <timvp@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
|
|
fe3a9ffb
|
2021-03-17T18:05:40
|
|
Support linking PPOs without attached Shaders
The application "Command & Conquer: Rivals" uses the following pattern:
// Create and link VS, save binary data
glCreateProgram()
glAttachShader()
glLinkProgram()
glGetProgramBinary()
// Create and link FS, save binary data
glCreateProgram()
glAttachShader()
glLinkProgram()
glGetProgramBinary()
...
// Create VS, load binary data
glCreateProgram()
glProgramBinary()
// Create FS, load binary data
glCreateProgram()
glProgramBinary()
...
glUseProgramStages(GL_VERTEX_SHADER_BIT)
glUseProgramStages(GL_FRAGMENT_SHADER_BIT)
glBindProgramPipeline()
Later, when issuing the draw command that uses the PPO, the PPO must be
linked with the Programs that were loaded via binary data. Those
Programs don't have any Shaders attached, just linked. This CL adds
support for linking Programs without attached Shaders.
Bug: b/182409935
Test: ProgramPipelineTest31.ProgramBinary
Change-Id: Ic5a4776e1374322665f45fbbcbf955838d093d02
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2770685
Commit-Queue: Tim Van Patten <timvp@google.com>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
0af8cfa7
|
2021-03-17T17:43:03
|
|
Reland "Save/Load missing members"
This is a reland of b2e76cf58fc012b068aab4716a432bb8951e93e3
Always call saveLinkedStateInfo() so we fill in the necessary values
with valid data for monolithic programs also.
Original change's description:
> Save/Load missing members
>
> There are several class/struct members that are missing when a program
> is serialized/deserialized. This leads to errors when attempting to link
> programs that have been deserialized. For example, when drawing with a
> PPO that contains programs which were created with glProgramBinary().
>
> This CL adds saving/loading the missing members.
>
> Bug: b/182409935
> Change-Id: I637c6cd8c174acd6da8d51433893323a32e5d7c0
> Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2770683
> Commit-Queue: Tim Van Patten <timvp@google.com>
> Reviewed-by: Jamie Madill <jmadill@chromium.org>
> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
> Reviewed-by: Cody Northrop <cnorthrop@google.com>
Bug: b/182409935
Bug: angleproject:5793
Change-Id: I07ca8f5dfed8c0a9eac3a0defb1602d2ba021c5f
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2782189
Commit-Queue: Tim Van Patten <timvp@google.com>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
|
|
2a43f43a
|
2021-03-23T15:35:30
|
|
Revert "Save/Load missing members"
This reverts commit b2e76cf58fc012b068aab4716a432bb8951e93e3.
Reason for revert: Causing MSan failures on Linux. See bug.
Bug: chromium:1191344
Original change's description:
> Save/Load missing members
>
> There are several class/struct members that are missing when a program
> is serialized/deserialized. This leads to errors when attempting to link
> programs that have been deserialized. For example, when drawing with a
> PPO that contains programs which were created with glProgramBinary().
>
> This CL adds saving/loading the missing members.
>
> Bug: b/182409935
> Change-Id: I637c6cd8c174acd6da8d51433893323a32e5d7c0
> Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2770683
> Commit-Queue: Tim Van Patten <timvp@google.com>
> Reviewed-by: Jamie Madill <jmadill@chromium.org>
> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
> Reviewed-by: Cody Northrop <cnorthrop@google.com>
Bug: b/182409935
Change-Id: I1209257ed6bb55ba2d01d92bd3305d5e3ad6ee28
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2780015
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
b2e76cf5
|
2021-03-17T17:43:03
|
|
Save/Load missing members
There are several class/struct members that are missing when a program
is serialized/deserialized. This leads to errors when attempting to link
programs that have been deserialized. For example, when drawing with a
PPO that contains programs which were created with glProgramBinary().
This CL adds saving/loading the missing members.
Bug: b/182409935
Change-Id: I637c6cd8c174acd6da8d51433893323a32e5d7c0
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2770683
Commit-Queue: Tim Van Patten <timvp@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
|
|
907a3cee
|
2021-02-17T08:07:45
|
|
Vulkan: Add support for EXT_shader_framebuffer_fetch_non_coherent
EXT_shader_framebuffer_fetch_non_coherent is implemented using subpass
input attachments. The extension will be enabled in a follow up change
that adds required changes to the Vulkan translator.
Bug: angleproject:5454
Test: FramebufferFetchNonCoherentES31.*Vulkan
Change-Id: Ic73c66a476c4a21db5269431166a198841f1dc0c
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2598059
Commit-Queue: Mohan Maiya <m.maiya@samsung.com>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
f6784006
|
2021-02-08T16:39:04
|
|
Modify data type of ActiveTextureMask and ImageUnitMask
ActiveTextureMask and ImageUnitMask need more than 64bits. We
can now use the BitSetArray datatype and avoid the perf penalty
of using std::bitset
Bug: angleproject:3877
Tests: angle_perftests.exe --gtest_filter=TexturesBenchmark*
Change-Id: Ic82e09d1aa2c1904d06ad48ba6200f35896665ac
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2664734
Commit-Queue: Mohan Maiya <m.maiya@samsung.com>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
6cc845bb
|
2020-12-07T18:14:50
|
|
Vulkan: Add support for EXT_blend_func_extended
This implementation utilizes vulkan's dualSrcBlend
feature. Expose this extension if the underlying vulkan
backend allows the use of this feature.
Test: angle_end2end_tests --gtest_filter=EXTBlendFuncExtendedDrawTest*
Bug: angleproject:5074
Change-Id: I7d2f611df89d65e5cac35158cb5f41a0ebd58aae
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2593151
Commit-Queue: Brandon Schade <b.schade@samsung.com>
Commit-Queue: Mohan Maiya <m.maiya@samsung.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
|
|
6d86a0fe
|
2021-01-29T11:08:04
|
|
Fix mActiveImageShaderBits not updated in PPO's executable
Allows the backend to rely on this bitset always being valid, instead of
working around the bug.
Bug: angleproject:5587
Change-Id: I25e1304c0e5e34b5fc1677a819315574603ed034
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2658885
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Tim Van Patten <timvp@google.com>
|
|
b912eec5
|
2020-11-27T11:08:41
|
|
Vulkan: Support GL_EXT_tessellation_shader.
Shader translator changes done in http://crrev.com/c/2633936
Adds a new DIRTY_BIT_PATCH_VERTICES state to Context.
Supportes state query and transform feedback.
4 test suppressions remain as follow-up fixes.
Adds a new varying packing mode for a simple Vulkan rule set.
Based on work by Mohan Maiya (m.maiya@samsung.com).
Test: dEQP-GLES31.functional.tessellation.*
Bug: angleproject:3572
Change-Id: I4cad2cca30adb754fd12c83027673906541f566a
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2568234
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Mohan Maiya <m.maiya@samsung.com>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
c07ef602
|
2021-01-05T12:26:05
|
|
Vulkan: Move xfb buffer decl to translator in emulation path
This makes @@ XFB-DECL @@ empty on this path. Ultimately, this is
working towards removing both @@ XFB-DECL @@ and @@ XFB-OUT @@ macros
for both the emulation and extension paths, allowing the shaders to be
compiled at compile time rather than link time.
Bug: angleproject:3606
Change-Id: If16e9d92c419a04ecd3094481ed546d0708cdb43
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2611305
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Tim Van Patten <timvp@google.com>
|
|
d654ac9b
|
2020-12-30T12:28:41
|
|
Program: Support multiple varying packings.
Instead of using a single varying packing for all program stages,
we switch to using a varying register packing for each pair of
input/output shaders. This allows several valid use cases that use
many varying to succeed. For instance Geometry Shaders have both
an input and output varying packing. With tessellation shaders the
upper bound of valid varying packings in one Program goes up even
more.
We keep multiple varying packings at once inside a new
"ProgramVaryingPacking" class. Internally the class keeps a unique
varying mapping for each input/output interface in the program.
Separable programs with "open" interfaces are handled specially.
Fixes a bug where varying counting was artificially limited for
programs with more than two shaders.
This CL also disables GS support when we're emulating line raster
so we don't have to figure out the details on how to place the
special position varying.
Bug: angleproject:5496
Change-Id: I1f9a327c4750caef570c608d86953e9d0cc5eea3
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2606532
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Tim Van Patten <timvp@google.com>
|
|
e4497d60
|
2020-12-31T20:12:13
|
|
Program: Move more common code to ProgramLinkedResources.
Refactoring change only.
Bug: angleproject:5496
Change-Id: Ic1c8301a070e91ad28791c23831b8236058ab9ab
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2606535
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
|
|
fa449cf3
|
2021-01-06T10:02:12
|
|
Fix separable Geometry Shaders.
Was a needed fix for a new varying test.
Bug: angleproject:3571
Bug: angleproject:5496
Change-Id: I49ae69967510b7a6330ea217a0e0e19e3bebe865
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2613198
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
f6df8692
|
2020-12-09T12:46:35
|
|
Vulkan: Support XFB in non-Vertex stages.
This updates the code in several places to support Geometry and
Tessellation Evaluation shaders to output transform feedback.
Does not turn on any new tests but enables support for XFB when we
turn on GS/TS.
Bug: angleproject:3571
Bug: angleproject:3572
Change-Id: I6dcb768f2df4eeee81a4a500e999fcf16716f58f
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2581941
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
c859c0ac
|
2020-11-24T17:21:38
|
|
Batch replace std::unordered_map with angle::HashMap in src/
There are a few places that will remain std::unordered_map due to build
or run-time errors, which will need to be evaluated more closely to
determine if they should remain std::unordered_map or if there is
another Abseil data structure that would be more efficient while still
working correctly.
Bug: angleproject:4873
Change-Id: Ib04253e3ad6398e63f4cc2bfe12c0f9e57cb112b
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2558873
Commit-Queue: Tim Van Patten <timvp@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Charlie Lao <cclao@google.com>
|
|
24f64249
|
2020-11-16T17:55:02
|
|
Vulkan: Track specialization constant usage bit and feedback to ctx
Right now context does not know which specialization constant is used by
the shader. Whenever a specialization constant changes, we assume shader
program is using it, we always reach into vulkan driver to ask for a new
program. Instead we can track shader's usage of specialization constant
so that context can utilize this information to avoid recompile pipeline
program if an unused specialization constant has changed.
This CL implements the plumbing the usage bits form compiler to program
object, it does not actually utilize the usage bits to avoid unnecessary
compilation yet.
Bug: b/173461931
Change-Id: Iebc9d0638c17b1a282c8b6093ce6bae154246e57
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2542866
Reviewed-by: Ian Elliott <ianelliott@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Charlie Lao <cclao@google.com>
|
|
5b419533
|
2020-11-03T13:33:44
|
|
GL: Implement EXT_YUV_target
Add test coverage of YUV format sampling as RGB or directly as YUV and
rendering as YUV using layout(yuv).
Initializing YUV AHardwareBuffers requires Android API 29 so ANGLE must
be compiled with:
android32_ndk_api_level = 29
android64_ndk_api_level = 29
The following tests can still run with Android API 26 because they don't
need to initialize the buffer:
ImageTestES3.ClearYUVAHB
ImageTestES3.YUVValidation
Bug: angleproject:4852
Bug: b/172649538
Change-Id: I4fe9afb2a68fb827dc5a5732b213b5eb60d585ac
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2517562
Commit-Queue: Geoff Lang <geofflang@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
|
|
fa616931
|
2020-09-03T14:58:03
|
|
Mark uniform samplers in an array unused per element
https://bugs.webkit.org/show_bug.cgi?id=215630
Fix an issue with the OpenGL backend where entire arrays of
uniforms would be marked as unused if a single element was
reported as unused by the driver.
Bug: angleproject:5006
Change-Id: I9bbb75a5f113472393e8d9f1fb60a7865aa9529a
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2486540
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Commit-Queue: James Darpinian <jdarpinian@chromium.org>
|
|
98c5ff6b
|
2020-10-25T16:26:55
|
|
BinaryStream: Preserve 64-bit integer data.
Previously the code would truncate 64-bit data to fit in 32-bits.
This ran into a serialization bug when expanding a 64-bit mask.
The new blend state masks for extended range were out of range for
the 32-bit promotion that was happening before.
Also refactors how we capture bools and enums to be more consistent.
size_t is now correctly saved and loaded as 64-bits.
Bug: angleproject:5247
Change-Id: I452a98c1b0add4c0cf45493032e9310e7d8321b2
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2497561
Reviewed-by: Courtney Goeltzenleuchter <courtneygo@google.com>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
7a0faa82
|
2020-09-24T20:15:26
|
|
Revert "Pass #pragma optimize setting down to compilation."
This reverts commit 499173de1c91932ba272269cab6918bf7e8d7c11.
Reason for revert: Causes unexpected HLSL compiler errors in some
cases. See bug.
Bug: angleproject:5094
Original change's description:
> Pass #pragma optimize setting down to compilation.
>
> This will allow us to disable optimizations in the back-end. This can
> be useful both for developers and for ANGLE to disable very slow
> shader compilation on D3D11.
>
> Also apply this pragma to VerifyMaxVertexUniformVectorsWithSamplers.
> Reduces compilation time by half in local testing.
>
> Bug: angleproject:5076
> Change-Id: I64ad576e11b9cee5b41f8af0d3621570304d65c2
> Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2420749
> Commit-Queue: Jamie Madill <jmadill@chromium.org>
> Reviewed-by: Jonah Ryan-Davis <jonahr@google.com>
> Reviewed-by: Geoff Lang <geofflang@chromium.org>
TBR=geofflang@chromium.org,jonahr@google.com,jmadill@chromium.org
# Not skipping CQ checks because original CL landed > 1 day ago.
Bug: angleproject:5076
Change-Id: I733e788fe8e9421ae0af662c0eb51af1ed79dde3
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2429517
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
499173de
|
2020-09-20T10:42:56
|
|
Pass #pragma optimize setting down to compilation.
This will allow us to disable optimizations in the back-end. This can
be useful both for developers and for ANGLE to disable very slow
shader compilation on D3D11.
Also apply this pragma to VerifyMaxVertexUniformVectorsWithSamplers.
Reduces compilation time by half in local testing.
Bug: angleproject:5076
Change-Id: I64ad576e11b9cee5b41f8af0d3621570304d65c2
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2420749
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Jonah Ryan-Davis <jonahr@google.com>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
|
|
b3545b42
|
2020-07-29T16:50:53
|
|
Get storage buffers/images from ProgramExecutable
Update StateCache::updateActiveShaderStorageBufferIndices() and
StateCache::updateActiveImageUnitIndices to get the storage buffers and
image bindings from the ProgramExecutable, respectively. This requires
updating the ProgramPipeline's ProgramExecutable to build up its vector
of buffers/images from each Program's ProgramExecutable.
Bug: angleproject:4869
Test: VertexAttributeTestES31.UsePpoComputeShaderToUpdateVertexBuffer
Test: SimpleStateChangeTestES31.InvalidateThenStorageWriteThenBlendPpo
Change-Id: I68b7d23eedda910c3dcbf5f9c50b74b5e80134d8
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2327701
Commit-Queue: Tim Van Patten <timvp@google.com>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Charlie Lao <cclao@google.com>
|
|
289365fa
|
2020-06-12T17:09:13
|
|
Remove ProgramExecutable::mProgram[Pipeline]State
Remove the ProgramExecutable::mProgram[Pipeline]State pointers.
Bug: angleproject:4520
Test: Build/CQ
Change-Id: I1717e291ff9beec226bd2888e990b27d8078797c
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2243764
Commit-Queue: Tim Van Patten <timvp@google.com>
Reviewed-by: Courtney Goeltzenleuchter <courtneygo@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
ce29916b
|
2020-06-12T14:40:22
|
|
Remove mProgramState from ProgramExecutable::isCompute()
ProgramExecutable::isCompute() is being updated to no longer use
mProgramState or mProgramPipelineState, as part of the effort to remove
those members from ProgramExecutable. Functionally, things are the same
for PPOs, but Programs are being updated to use the boolean
ProgramExecutable::mIsCompute rather than checking the linked shader
stages to determine draw vs compute.
Slightly unrelated, but this CL also removes the unused function
ProgramPipeline::hasImages() which was missed in one of the earlier CLs
in this relation chain.
Bug: angleproject:4520
Test: Build/CQ
Change-Id: Ief28021310d6d0b1be5b7608a59deb87b0cf591d
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2243326
Commit-Queue: Tim Van Patten <timvp@google.com>
Reviewed-by: Courtney Goeltzenleuchter <courtneygo@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
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>
|
|
c5014259
|
2020-06-11T23:30:47
|
|
Move ProgramState::mImageBindings to ProgramExecutable
The member ProgramState::mImageBindings is being moved to
ProgramExecutable to allow ProgramExecutable::getImageBindings() to
answer the query without relying on the Program[Pipeline]State.
Bug: angleproject:4520
Test: Build/CQ
Change-Id: Ia4934c8e57b5ba49b0a399dcad7c1b324c43385d
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2241750
Reviewed-by: Courtney Goeltzenleuchter <courtneygo@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Tim Van Patten <timvp@google.com>
|
|
c117e360
|
2020-06-05T15:48:36
|
|
Move ProgramState::mSamplerBindings to ProgramExecutable
The member ProgramState::mSamplerBindings is being moved to
ProgramExecutable to allow ProgramExecutable::getSamplerBindings() to
answer the query without relying on the Program[Pipeline]State.
Bug: angleproject:4520
Test: Build/CQ
Change-Id: I0daa997424d6e2aa5172e0731da221db72063435
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2233363
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Courtney Goeltzenleuchter <courtneygo@google.com>
Commit-Queue: Tim Van Patten <timvp@google.com>
|
|
db3ef872
|
2020-05-28T20:04:06
|
|
Move ProgramState::mDefaultUniformRange to ProgramExecutable
The member ProgramState::mDefaultUniformRange is being moved to
ProgramExecutable to allow ProgramExecutable::hasDefaultUniforms() to
answer the query without relying on the Program[Pipeline]State.
Bug: angleproject:4520
Test: Build/CQ
Change-Id: Ic0d78b7193a28962b7ab6480964f8920a23bb7be
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2220776
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Courtney Goeltzenleuchter <courtneygo@google.com>
Commit-Queue: Tim Van Patten <timvp@google.com>
|
|
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>
|
|
e8b8b816
|
2020-05-19T18:58:55
|
|
Eliminate Program::mLinkResolved boolean
Since mLinkResolved boolean is always kept in sync with the presence
of mLinkingState structure, we can remove the former and replace
access with checks for the latter being nullptr.
Bug: angleproject:4644
Change-Id: Ib385b5c3881946d762ad48e6534c84d15e50f673
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2209319
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Tim Van Patten <timvp@google.com>
Commit-Queue: Rafael Cintron <rafael.cintron@microsoft.com>
|
|
d34ab323
|
2020-05-04T10:48:48
|
|
Vulkan: Save linked ProgramExecutable data
PPOs need to support drawing with Programs that failed their last
linkProgram() if they had previously successfully linked. This requires
saving the ProgramExecutable when linkProgram() succeeds, and not
overwriting it with subsequent linkProgram() calls unil the next
successful one.
To achieve this, the new member ProgramState::mLinkedExecutable will
point to the last successfully linked ProgramExecutable and
ProgramState::mExecutable will point to a new ProgramExecutable when the
next linkProgram() is attempted. If the link fails, the newly allocated
ProgramExecutable will be delete()'ed and mExecutable will point to the
previous 'good' ProgramExecutable still being tracked by
mLinkedExecutable. If it succeeds, the old mLinkedExecutable will be
delete()'ed and mLinkedExecutable will be updated to point to the ne
one.
Bug: angleproject:4514
Test: KHR-GLES31.core.sepshaderobjs.StateInteraction
Change-Id: I0677602a6d652a055404667ec9e9305fed5b4177
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2181450
Commit-Queue: Tim Van Patten <timvp@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
fecd1afc
|
2020-05-04T10:24:57
|
|
Vulkan: Move necessary members from ProgramState to ProgramExecutable
ProgramPipeline's need to be able to link Programs before drawing, even
if the Program's previous linkProgram() failed. To work towards this,
some ProgramState members are being moved to ProgramExecutable so they
can be saved when linkProgram() succeeds and not overwritten by any
subsequent linkProgram() attempts that may fail.
This also allows the second half of this change, which is to pass in the
Program's ProgramExecutable to GlslangAssignLocations() and
GlslangWrapperVk::TransformSpirV() so the values saved from the last
successful linkProgram() are used.
Bug: angleproject:4514
Test: CQ
Change-Id: I68aa429be76c0c6e1b886be09a12200217fcc7ab
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2181448
Commit-Queue: Tim Van Patten <timvp@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
12b6a82e
|
2020-04-03T18:31:22
|
|
No-Op draws when no active VS and/or FS is present
Re-land CL with WebGL fixes:
This required some extra pointer checking during validation to handle
the fact that a Program and/or ProgramExecutable may not be present when
attempting to draw. This isn't an error, just undefined behavior, which
we (eventually) treat as a no-op.
According to the OpenGL ES 3.1 spec:
7.3. PROGRAM OBJECTS
If there is no active program for the vertex or fragment shader
stages, the results of vertex and fragment shader execution will
respectively be undefined. However, this is not an error.
To handle this, if no VS or FS is present in the active Program/PPO,
we will no-op the draw command.
Bug: angleproject:3570
Test: KHR-GLES31.core.sepshaderobjs.StateInteraction
Change-Id: I70d688bf344a78cf3b4fd66c995ae03ce4b9b807
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2185156
Reviewed-by: Courtney Goeltzenleuchter <courtneygo@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Tim Van Patten <timvp@google.com>
|
|
1ab55d96
|
2020-05-06T14:45:18
|
|
Revert "No-Op draws when no active VS and/or FS is present"
This reverts commit a4b506f79e3286ffcf3a5d68f20aa97a63edab8e.
Reason for revert: WebGL crash
https://bugs.chromium.org/p/angleproject/issues/detail?id=4616
Original change's description:
> No-Op draws when no active VS and/or FS is present
>
> According to the OpenGL ES 3.1 spec:
>
> 7.3. PROGRAM OBJECTS
> If there is no active program for the vertex or fragment shader
> stages, the results of vertex and fragment shader execution will
> respectively be undefined. However, this is not an error.
>
> To handle this, if no VS or FS is present in the active Program/PPO,
> we will no-op the draw command.
>
> Bug: angleproject:3570
> Test: KHR-GLES31.core.sepshaderobjs.StateInteraction
> Change-Id: If19e9fbb1bc09fa0d490832079bb9f514eab6035
> Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2136386
> Reviewed-by: Jamie Madill <jmadill@chromium.org>
> Commit-Queue: Tim Van Patten <timvp@google.com>
TBR=timvp@google.com,jmadill@chromium.org,cclao@google.com
Change-Id: Ia24c4156ff7779b69c1f3f705f1a91cbb1c9684c
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: angleproject:3570
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2184849
Reviewed-by: Courtney Goeltzenleuchter <courtneygo@google.com>
Commit-Queue: Courtney Goeltzenleuchter <courtneygo@google.com>
|
|
a4b506f7
|
2020-04-03T18:31:22
|
|
No-Op draws when no active VS and/or FS is present
According to the OpenGL ES 3.1 spec:
7.3. PROGRAM OBJECTS
If there is no active program for the vertex or fragment shader
stages, the results of vertex and fragment shader execution will
respectively be undefined. However, this is not an error.
To handle this, if no VS or FS is present in the active Program/PPO,
we will no-op the draw command.
Bug: angleproject:3570
Test: KHR-GLES31.core.sepshaderobjs.StateInteraction
Change-Id: If19e9fbb1bc09fa0d490832079bb9f514eab6035
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2136386
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Tim Van Patten <timvp@google.com>
|
|
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>
|
|
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>
|
|
20e375eb
|
2020-03-14T20:27:09
|
|
Vulkan: Use shader stage specific barrier
Seperate vertex and fragment shader read/write with shader stage
specific barriers
Bug: angleproject:4467
Change-Id: Id18909b497b087e58d750023399943bc9d414edf
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2102957
Commit-Queue: Charlie Lao <cclao@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
68083e89
|
2020-03-04T15:55:53
|
|
Vulkan: Move cached samplers/images and has*() to ProgramExecutable
The active samplers and images are being moved from Program into
ProgramExecutable to unify interacting with them for Programs and
ProgramPipelines
Also, create some helper functions for gl::Program that ProgramExecutable can
call to make it easier for ProgramPipeline to respond to similar
queries for each of the Programs in the ProgramPipeline.
Bug: angleproject:3570
Change-Id: I0b37f1a379e56b9659d82d92f6d7a546beee11cd
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2087648
Commit-Queue: Tim Van Patten <timvp@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
7e0699a2
|
2020-02-05T17:04:06
|
|
Create the ProgramExecutable Class
The ProgramExecutable class is being created to collect data structures
that are common to both Programs and ProgramPipelines, as well as any
shared functions. This allows callers to request the current
ProgramExecutable from the State and make
Program-/ProgramPipeline-specific queries without needing to know
exactly which responded. This will also allow the necessary data
structures to only be populated and stored within the ProgramExecutable
when necessary and reused as often as necessary.
Bug: angleproject:3570
Change-Id: I101f08ab03421894667b4a426a04d2147489f0e1
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2040512
Commit-Queue: Tim Van Patten <timvp@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|