|
e332e621
|
2019-02-14T12:53:04
|
|
D3D: Asynchronously load program binaries.
Unpack as much of the binary steam as possible before passing the final loading
of the shader programs off to a worker thread. Reporting as many possible link
errors before becoming asynchronous means that linking should only fail due to
unexpected system issues at that point.
This also allows other backends to asynchronously load program binaries.
BUG=angleproject:2857
Change-Id: I587917a3e54522114dabd41d1b14fc491c8fd18a
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1473451
Commit-Queue: Jamie Madill <jmadill@google.com>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
|
|
d4c09dd3
|
2019-01-29T11:22:54
|
|
Fix unnecessary copy of for loop variables in ANGLE
Bug: angleproject:3075
Change-Id: I34dd5d4ecded6def5a2b46369277312af0de7c8c
Reviewed-on: https://chromium-review.googlesource.com/c/1443572
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Commit-Queue: Jonah Ryan-Davis <jonahr@google.com>
|
|
c3abb7f1
|
2019-01-17T11:26:48
|
|
Fix MultiDraw shaders when loaded from cache
State updates that need to be done after linking vs. deserializing can
get out of sync, as was the case for mDrawIDLocation (introduced in
1bf18ce9e2caca7067b4439373f4fb04a5cd7d21). This commit introduces a
common function that's called from both paths to hopefully avoid such
issues in the future.
The serialize/deserialize functions are moved from MemoryProgramCache
to the Program itself.
Bug: 890539,angleproject:2516
Change-Id: Idc5b87de53298aacbb1884e79e721b876281fb13
Reviewed-on: https://chromium-review.googlesource.com/c/1417970
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
a100d8f4
|
2018-12-29T16:39:55
|
|
ParallelCompile: add GL backend support
For GL backend, at first each worker thread must have a naitve context
for its own to work in. These worker contexts have to be shared from
the main context, so that all shader and program objects are seen in
any context. This extends backend displays to create and destroy the
worker contexts. RendererGL manages and allocates them to the worker
threads. ShaderImpl has a new compile method added to do the actual
glCompile work in worker thread. The ProgramGL's link method is broken
down by introducing the LinkEventGL class.
Bug: chromium:849576
Change-Id: Idc2c51b4b6c978781ae77810e62c480acc67ebb5
Reviewed-on: https://chromium-review.googlesource.com/c/1373015
Commit-Queue: Jie A Chen <jie.a.chen@intel.com>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
|
|
6e18a238
|
2019-01-16T13:27:14
|
|
Optimize more front-end VertexArray binding.
Improves perf slightly (1-2%) in the Vulkan VBO state change test.
Bug: angleproject:3014
Change-Id: Ia8082b5b3f5e847a6b2775e896893fa8d38c1afd
Reviewed-on: https://chromium-review.googlesource.com/c/1393904
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
|
|
ab2bfa81
|
2019-01-15T19:06:47
|
|
Enable Chromium clang style plugin for libANGLE.
This fixes a few style warnings:
* auto should not deduce to raw pointer type
* inlined virtual methods are not allowed
* non-trivial constructors and destructors should be explicit
* inlined non-trivial constructors should not be in-class
* missing override keywords
Bug: angleproject:3069
Change-Id: I3b3e55683691da3ebf6da06a5d3c729c71b6ee53
Reviewed-on: https://chromium-review.googlesource.com/c/1407640
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Yuly Novikov <ynovikov@chromium.org>
|
|
e4109f27
|
2018-12-13T16:25:53
|
|
WebGL: validate texture format matches sampler type
WebGL requires that drawing produces INVALID_OPERATION if a texture's
format doesn't match the sampler type it is bound to. This is a little
confusing because samplers have two attributes that could be called
"type": addressing mode (2D/3D/Cube), and component format
(float/signed/unsigned/shadow). ANGLE already handled checking the
addressing mode; this change adds checking for the component format.
Fixes WebGL conformance test
conformance2/uniforms/incompatible-texture-type-for-sampler.html
Bug: chromium:809237
Change-Id: I52ebfecd92625e3ee10274cb5f548d7e53de72dd
Reviewed-on: https://chromium-review.googlesource.com/c/1377611
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Yuly Novikov <ynovikov@chromium.org>
Commit-Queue: James Darpinian <jdarpinian@chromium.org>
|
|
c3dc5d48
|
2018-12-30T12:12:04
|
|
Merge gl::Context and gl::ContextState.
This reduces the number of indrections when accessing the Extensions
or Caps structures. It will provide a small speed-up to some methods.
It also cleans up the code.
Bug: angleproject:2966
Change-Id: Idddac70758c42c1c2b75c885d0cacc8a5c458685
Reviewed-on: https://chromium-review.googlesource.com/c/1392391
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Markus Tavenrath <matavenrath@nvidia.com>
|
|
cb9609fe
|
2018-12-26T00:52:44
|
|
Optimize glDrawElements performance
A call to glDrawElements results in a calling depth of up to 4
* glDrawElements
* gl::Context::DrawElements
* rx::ContextGL::DrawElements
* VertexArrayGL::syncDrawState.
Each function call has to save/restore a lot of registers which
results in a stall in the prologue of rx::ContextGL::DrawElements
due to memory bandwidth limitations.
The main change is the function gl::Context::DrawElements being
inlined to reduce the calling depth by one. In addition the call
to ContextGL::syncDrawElementsState is now protected so that it
gets called only if it's required. Finally a few small getter
functions have been inlined where the calling code was bigger
than the actual function.
In total this change improves performance of the
DrawElementsPerfBenchmark.Run/gl benchmark by 16%.
Bug: angleproject:2966
Change-Id: I423d18452f2f5b520ab52850fda2054e1da86991
Reviewed-on: https://chromium-review.googlesource.com/c/1389988
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Markus Tavenrath <matavenrath@nvidia.com>
|
|
7c985f5c
|
2018-11-29T18:16:17
|
|
Make angle::Result an enum.
This moves away from a class type to a value type. This should improve
performance when using angle::Result as a return value. Previously the
generated code would return a pointer instead of a value.
Improves performance in the most targeted microbenchmark by 10%. In
more realistic scanarios it will have a smaller improvement. Also
simplifies the class implementation and usage.
Includes some unrelated code generation changes.
Bug: angleproject:2491
Change-Id: Ifcf86870bf1c00a2f73c39ea6e4f05ca705050aa
Reviewed-on: https://chromium-review.googlesource.com/c/1356139
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
e3e680ca
|
2018-12-03T17:49:08
|
|
Remove State::syncProgramTextures.
Removes the concept of the program textures dirty object. Instead we
use a set of dirty bits to represent dirty texture samples. We mark
certain textures dirty and update state structures whenever there is
a new Texture/Program/Sampler bound, or when Texture/Program/Sampler
state changes.
This is in preparation for making clearing the uncleared active
textures into a dirty bit as well.
Also includes new dirty bit handling for texture image units. These are
a GLES 3.1 feature.
Bug: angleproject:2966
Change-Id: Ibb8619dd2669bb39fdbcd75e3685be9a8aeeee91
Reviewed-on: https://chromium-review.googlesource.com/c/1346649
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
|
|
e90d4ee9
|
2018-11-28T14:04:00
|
|
Pass Context to setLabel.
This is useful for triggering a dirty state notification for Textures.
It will lead to improvements for program and texture dirty bits.
Bug: angleproject:2966
Change-Id: Iaba625da8a970a558f7d158bfa2f09c964f6761a
Reviewed-on: https://chromium-review.googlesource.com/c/1347669
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Reviewed-by: Yuly Novikov <ynovikov@chromium.org>
|
|
b980c563
|
2018-11-27T11:34:27
|
|
Reformat all cpp and h files.
This applies git cl format --full to all ANGLE sources.
Bug: angleproject:2986
Change-Id: Ib504e618c1589332a37e97696cdc3515d739308f
Reviewed-on: https://chromium-review.googlesource.com/c/1351367
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
|
|
1bf18ce9
|
2018-10-19T15:34:02
|
|
Implement GL_ANGLE_multi_draw
This patch adds entrypoints glMultiDrawArraysANGLE,
glMultiDrawElementsANGLE, glMultiDrawArraysInstancedANGLE,
annd glMultiDrawElementsInstancedANGLE
Bug: chromium:890539
Change-Id: Ic9c374c53892460f44ca6e73a253b78473ac2dff
Reviewed-on: https://chromium-review.googlesource.com/c/1282268
Reviewed-by: Kai Ninomiya <kainino@chromium.org>
Commit-Queue: Austin Eng <enga@chromium.org>
|
|
f4a789f9
|
2018-10-18T16:56:20
|
|
Use angle::Result in front-end (Part 6)
Refactors the gl::Program, gl::Compiler and gl::Query classes.
Bug: angleproject:2491
Change-Id: I96acecdc6af301a89201bd7f5222a180433e5eb2
Reviewed-on: https://chromium-review.googlesource.com/c/1289711
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
78bcd2be
|
2018-10-16T15:05:20
|
|
Vulkan: Fix deleting in-use descriptor sets.
Sequences of many frames with uniform updates could lead to a bug where
we attempt to delete descriptor sets that are still in use. To trigger
the bug we need to write enough uniform data to trigger a descriptor
set to be freed. This would correctly trigger refresh sets in the
Program. But if there was a second program idle in the background that
also allocated descriptors from the old pool, the bug would manifest.
Fix this by storing a shared handle to the descriptor pool in the
Program. The dynamic descriptor pool won't recycle descriptor pools
internally unless there are zero outstanding references to the pool.
We could also improve this in a resource sharing situation by keeping
a single shared dynamic descriptor pool per share group.
Includes a contribution from tobine@google.com that adds a test to
cover the bug.
Bug: angleproject:2863
Change-Id: Id585b85f33f8cfa3772ceff3af512d1e4fb0b75a
Reviewed-on: https://chromium-review.googlesource.com/c/1271919
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
956ab4d9
|
2018-10-10T16:13:03
|
|
Optimize several functions for the Program perf test.
This gives the same or slightly better performance in the ProgramDraw
perf test. Also only set the Program object as dirty when there are
dirty bits set in the Program itself.
Bug: angleproject:2877
Change-Id: I07b428b40d3e3c24e0a42c970524756b6dc3a30e
Reviewed-on: https://chromium-review.googlesource.com/c/1271475
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
6f755b21
|
2018-10-09T12:48:54
|
|
Use angle::Result in front-end. (Part 1)
This covers most of the hot paths used in draw calls. Gives in the
order of a 5% reduction in draw call overhead.
Bug: angleproject:2491
Change-Id: I2d53afb1163eaceed61fb9cd9ce6c1267c85c0fa
Reviewed-on: https://chromium-review.googlesource.com/c/1258149
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
785e8a0b
|
2018-10-04T17:42:00
|
|
Remove gl::LinkResult.
Instead of returning a small struct from LinkProgram calls we use
angle::Result. Linking can have 3 cases:
- the link was successful -> angle::Result::Continue
- the link failed -> angle::Result::Incomplete
- there was an internal error -> angle::Result::Stop
Note that any unexpected Incomplete is still an error. Each function
that accepts Incomplete must check explicitly.
This is the last user of ErrorOrResult.
Bug: angleproject:2491
Change-Id: Idba23be27efe4b561720a4bdd8fe486b40779497
Reviewed-on: https://chromium-review.googlesource.com/c/1255645
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Yuly Novikov <ynovikov@google.com>
|
|
0ca09753
|
2018-09-24T11:00:50
|
|
Add GLES3 support for EXT_blend_func_extended
This adds GLES3 API support for EXT_blend_func_extended. The patch
includes the API entrypoints, validation and also implementation on
the desktop GL backend.
Instead of having built-in fragment color variables, ESSL 3.00 has
custom output variables, which can now be bound to either primary or
secondary output color locations. The "index" set to a custom output
variable determines whether it's used a primary or secondary blending
source color.
The shader layout qualifier takes precedence over the bind call. This
is not specified in the EXT spec, but is specified in desktop OpenGL
specs.
BUG=angleproject:1085
TEST=angle_end2end_tests
Change-Id: Ia24e8e5dadcc165e5e8fbd7c653c7fab6217db88
Reviewed-on: https://chromium-review.googlesource.com/c/1249361
Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
|
|
44a6fbfd
|
2018-10-02T13:38:56
|
|
Optimize resolveLink.
This changes the program query to resolve the link if required. If the
validation layer is skipped the link is resolved in the gl::Context.
Resolving the link on program query allows us to avoid resolving the
link on most of the gl::Program query APIs.
This improves inlining and particularly affects uniform update. It
fixes a performance regression introduced by the parallel shader
linking extension. Gives a 17% increased score on a uniform benchmark.
Also fixes two missing cases of checking for the extension in our
validation code.
Note that some bugs might still exist when the validation layer is
disabled.
Bug: angleproject:2851
Change-Id: I5d725eede3fa147cedf2ce0129791b3412a97a61
Reviewed-on: https://chromium-review.googlesource.com/1255509
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Yuly Novikov <ynovikov@google.com>
|
|
9137adea
|
2018-08-27T14:22:37
|
|
Add support for EGL_ANDROID_blob_cache
The functionality of MemoryProgramCache is divided up in two. BlobCache
is now a generic binary cache, which interfaces with the callbacks from
EGL_ANDROID_blob_cache. MemoryProgramCache handles program
[de]serialization and interacts with BlobCache.
Bug: angleproject:2516
Change-Id: Ie4328a2e56a26338e033d84f4e53a1103411937d
Reviewed-on: https://chromium-review.googlesource.com/1194285
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
|
|
47f6dd0d
|
2018-08-10T13:36:32
|
|
Implement robust initialization for image texture
This change fixes a bug that the image texture initialization time is not
correct. It happens when we use compute shader to write data to an
uninitialized texture, then use readPixels to read the result which
results that texture initialization falls behind image store and
covers the real result.
Bug: angleproject:2766
Change-Id: I4e986972096857afc975c40dfa4d559a2f31194c
Reviewed-on: https://chromium-review.googlesource.com/1170569
Commit-Queue: Jiajia Qin <jiajia.qin@intel.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
87498164
|
2018-08-21T21:57:22
|
|
Make some Program methods inlined
These methods are very hot in the DrawCall/gl_null bechmark. With this
CL applied, the score can improve about 10% on Linux.
This also removes a few unnecessary resolveLink calls.
Bug: chromium:873724
Change-Id: I6034f29eeeebe8341dae3988c38196123687a44f
Reviewed-on: https://chromium-review.googlesource.com/1183522
Commit-Queue: Jie A Chen <jie.a.chen@intel.com>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
70aeda49
|
2018-08-20T12:17:40
|
|
Add gl::Program::syncState and dirty bits.
Currently this handles uniform block bindings. Cleans up some logic in D3D.
Bug: angleproject:2747
Change-Id: I8c2989738d50a77d6f6d90a9ff11dceab6d3129c
Reviewed-on: https://chromium-review.googlesource.com/1172085
Reviewed-by: Frank Henigman <fjhenigman@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
5055fba5
|
2018-08-17T09:57:07
|
|
Optimize Program::resolveLink
The method has to be extremely fast as it's very frequently called. It
contributes about 2% cpu time in the DrawCall/gl_null benchmark. With
this optimization it can be decreased to less than 1%.
Bug: chromium:873724
Change-Id: I7fb376db73452dbdf6cb44c92815848e860867c9
Reviewed-on: https://chromium-review.googlesource.com/1179369
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Commit-Queue: Jie A Chen <jie.a.chen@intel.com>
|
|
3fd614d0
|
2018-08-13T12:21:58
|
|
Refactor Context dependency for resolveCompile
The context parameter of Shader::resolveCompile method causes a bad
impact that many methods in Shader, Program etc. have to have a same
context parameter. By removing it, these methods can be decoupled
from Context.
BUG=chromium:849576
Change-Id: Ia5545ee9dce45794550f6086bc0e6c4707e1276e
Reviewed-on: https://chromium-review.googlesource.com/1172202
Commit-Queue: Jie A Chen <jie.a.chen@intel.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
7ae70d8f
|
2018-07-06T13:47:01
|
|
ParallelCompile: Parallelize D3D linking
This adds a new linking state to Program. If a Program is in linking
state, on the one hand the foreground thread may continue issuing more
GL calls, and on the other hand the background linking threads may be
accessing Program internally too. Without a proper constraint there
must be conflicts between them. For this purpose, we block any further
GL calls to Program until it's actually linked. In addition, we
prohibit parallel linking an active program, so that ProgramD3D does
not have to worry about such similar conflicts.
Also changes the WorkerThread to support limiting the number of
concurrently running worker threads.
BUG=chromium:849576
Change-Id: I52618647539323f8bf27201320bdf7301c4982e6
Reviewed-on: https://chromium-review.googlesource.com/1127495
Commit-Queue: Jie A Chen <jie.a.chen@intel.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
7e4eff11
|
2018-08-08T15:49:26
|
|
Program: Add cache samplers and type masks.
This mask cleans up some of the iteration logic in
State::syncProgramTextures. It will make it easier to optimize this
function in the future. This will also make it easier to recompute
the sampler type validation.
Leads to a 5% improvement in State::syncProgramTextures.
Bug: angleproject:2747
Bug: angleproject:2763
Change-Id: Ic9a555df843ad23b4c562e6e4a2d425bee58a856
Reviewed-on: https://chromium-review.googlesource.com/1164306
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
|
|
cc73f241
|
2018-08-01T11:34:48
|
|
Micro-optimize some validation checks.
Prepares for caching hasMappedBuffer. Also inclines several checks for
faster speed.
Bug: angleproject:2746
Change-Id: I74f9408d7b41e245c3f58d367dd2cc8fbace4a7a
Reviewed-on: https://chromium-review.googlesource.com/1150762
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Frank Henigman <fjhenigman@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
|
|
21061026
|
2018-07-12T23:56:30
|
|
Vulkan: Use angle::Result error handling.
Introduces a vk::Context class to contain an error handler and Renderer
pointer. This abtracts the common code path for ContextVk + DisplayVk.
Removes vk::Error in favor of the POD angle::Result class. There are a
few remaining usages of gl::Error that will have to be cleaned up when
we can change the front-end APIs.
Bug: angleproject:2713
Change-Id: I5e68f223d595c6c561b59d6a85759e5738ed43c6
Reviewed-on: https://chromium-review.googlesource.com/1128924
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Frank Henigman <fjhenigman@chromium.org>
|
|
3bb2bbea
|
2018-06-15T09:47:03
|
|
Program: Sampler uniform query in front-end.
We have this information stored in the front-end sampler bindings.
This solves sampler uniform query across the various back-ends.
Turns on a bunch of uniform_api dEQP tests.
Bug: angleproject:2612
Change-Id: If8752a26438595ad103598369df360e2f5e12d53
Reviewed-on: https://chromium-review.googlesource.com/1101572
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Luc Ferron <lucferron@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
|
|
e17b5ba5
|
2018-06-04T14:28:58
|
|
Vulkan: Keep unused uniforms list to fix glslang issues
We we're unable to cleanup the unused uniforms if we did not keep
a list of them while parsing them in ProgramLinkResource. Now
that we keep a history of them, we're able to clean them up and
fix a few dEQP tests.
Bug: angleproject:2582
Bug: angleproject:2585
Bug: angleproject:2587
Bug: angleproject:2589
Bug: angleproject:2590
Bug: angleproject:2593
Change-Id: Ic1f9151e356a3d05e83f1031cc7b187b370284e5
Reviewed-on: https://chromium-review.googlesource.com/1085644
Commit-Queue: Luc Ferron <lucferron@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
|
|
b26ab825
|
2018-05-29T11:19:00
|
|
Return a program binary size of 0 when the program is not linked.
From the GLES3 spec:
"... When a program object's LINK_STATUS is FALSE, its program binary
length is zero ..."
Querying the size was generating errors in the GL backend.
BUG=angleproject:2569
Change-Id: I1be511040331abaec2bba98502d8aa88fb4bd19c
Reviewed-on: https://chromium-review.googlesource.com/1076317
Commit-Queue: Geoff Lang <geofflang@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
493f9571
|
2018-05-24T19:52:15
|
|
Add PrimitiveMode packed GLenum.
Bug: angleproject:2574
Change-Id: I3d7bd7ca0d69a364a611dc04799ea34906fc4a6c
Reviewed-on: https://chromium-review.googlesource.com/1067114
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Yuly Novikov <ynovikov@chromium.org>
|
|
2fc0806f
|
2018-05-10T15:10:55
|
|
Micro-optimize uniform updates.
This CL is adapted from work by matavenrath@nvidia.com. It does the
following small optimizations:
* inlines a bunch of accessors.
* reorders checks to hit the cache more often
Also some small style updates.
Bug: angleproject:1671
Change-Id: I8f21318e6644dcfe1f99c98f7f377742fcad78d3
Reviewed-on: https://chromium-review.googlesource.com/1054367
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
|
|
54aafe58
|
2018-04-27T14:54:57
|
|
Use ShaderMap in Caps - Part I
This patch is the first one of the series that organize
implementation dependent resource limits on every type
of shader into ShaderMap and clean up all the related
code.
In the next patch all such resource limits are put in
the corresponding ShaderMaps.
BUG=angleproject:2169
Change-Id: I40cb58c55b2e82df33221ddb36eff0abcd7e8b22
Reviewed-on: https://chromium-review.googlesource.com/1034108
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
|
|
7a8fe156
|
2018-04-28T12:59:58
|
|
ES31: Add link validation on MAX_COMBINED_SHADER_OUTPUT_RESOURCES
This patch adds the link validation on the maximum combined shader
output resources required in OpenGL ES 3.1 SPEC.
OpenGL ES 3.1 SPEC has restrictions on the sum of the number of all
active images, shader storage blocks and fragment shader outputs. A
link error will be generated if this sum exceeds the implementation-
dependent value of MAX_COMBINED_SHADER_OUTPUT_RESOURCES.
In order not to affect the existing image tests, this patch also
sets a temporary value for maxCombinedShaderOutputResources on D3D11
back-ends. We will set more accurate values for all the UAV related
resource limits in the next patch.
BUG=angleproject:2345
TEST=dEQP-GLES31.functional.state_query.integer.max_combined_shader_output_resources_*
Change-Id: Ib83a19ef0ae0b9af3422b5c970c7c07d96b2359d
Reviewed-on: https://chromium-review.googlesource.com/1039155
Commit-Queue: Jiawei Shao <jiawei.shao@intel.com>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
|
|
bb3255b5
|
2018-04-27T09:45:18
|
|
Remove redundant computations on combined interface block counts
This patch intends to remove redundant computations on combined
interface block counts in ValidateGraphicsInterfaceBlocks.
In this patch, we compute and check the number of combined interface
blocks by the result of ValidateInterfaceBlocksCount directly instead
of re-compute it, and if the check on max combined interface blocks
failed, Program::link() can early return without entering
ValidateGraphicsInterfaceBlocks.
BUG=angleproject:2345
Change-Id: I7573f7c645993b4d75230a8471203a305127f2a3
Reviewed-on: https://chromium-review.googlesource.com/1031852
Reviewed-by: Jiajia Qin <jiajia.qin@intel.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Jiawei Shao <jiawei.shao@intel.com>
|
|
40786bdf
|
2018-04-18T13:58:57
|
|
ES31: Add validation on geometry shader interface blocks matching
This patch adds the validation on checking if there is any mismatch
among geometry shader interface blocks and the ones defined in other
graphics shaders in the same program.
BUG=angleproject:1941
TEST=angle_end2end_tests
Change-Id: I1f65e3c49390135bbe9f9323098daf28c9b838c7
Reviewed-on: https://chromium-review.googlesource.com/1016175
Commit-Queue: Geoff Lang <geofflang@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
|
|
016105bb
|
2018-04-12T16:38:31
|
|
Store shader information in ShaderMap in class Program and Compiler
This patch is the first one in the series of using ShaderMap as
the container of the resources for each type of shader everywhere
in ANGLE.
This patch defines the new data structure ShaderMap and use it in
class Program and Compiler in ANGLE front-end.
The following work includes:
1. Use ShaderMap in D3D back-ends.
2. Use ShaderMap in Vulkan back-ends.
BUG=angleproject:2169
Change-Id: I1c284d95f5a071c45bb468901eabc15694fffe38
Reviewed-on: https://chromium-review.googlesource.com/1011722
Commit-Queue: Geoff Lang <geofflang@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
|
|
ebd6e2df
|
2018-03-23T17:07:55
|
|
Take all attributes into account when checking for aliasing
This makes ANGLE to follow GLSL ES 3.00.6 spec section 12.46. The spec
requires that all attributes are taken into account when checking for
aliasing, regardless of if they are active or not. WebGL 2.0 spec was
also recently changed to reflect GLSL ES 3.00.6 correctly. Aliasing
checks for GLSL ES 1.00 shaders are left as-is.
BUG=chromium:829541
TEST=angle_end2end_tests, WebGL conformance tests
Change-Id: I71c36ac123f18dadf075e81f93af29321c15136b
Reviewed-on: https://chromium-review.googlesource.com/1005077
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
|
|
6bc264ae
|
2018-03-31T15:36:05
|
|
Fix potential bad access in LinkProgram.
This could happen when linking a program with missing attachments
and shaders that have no compiled sources.
Also re-enables the EGL program cache control tests, which were
disabled due to a wrong extension name check.
Bug: chromium:827158
Change-Id: I181f878093c6e3a4acc51552ade8e7c084733a3d
Reviewed-on: https://chromium-review.googlesource.com/989262
Reviewed-by: Luc Ferron <lucferron@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
30b604d8
|
2018-03-12T17:26:57
|
|
Check that transform feedback will not overflow its buffers.
Also fix the check for uniform buffer size to use the actual buffer
size instead of the size of the bound range.
Bug: 820639
Change-Id: Iaa2a617ee7ce5ce7cfabbf64bd1d6f8c82c46b65
Reviewed-on: https://chromium-review.googlesource.com/965627
Commit-Queue: James Darpinian <jdarpinian@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
385b3e03
|
2018-03-21T09:43:28
|
|
Use packed enums on shader types in ANGLE renderer
This patch uses a packed internal enum ShaderType everywhere we
need a shader type instead of the GLenum value of the shader type.
This patch also uses program::getAttachedShader(type) everywhere
we need to get gl::Shader from a program in ANGLE.
BUG=angleproject:2169
Change-Id: I28a7fa1cfe35622c57a486932911110688eaadec
Reviewed-on: https://chromium-review.googlesource.com/972844
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
|
|
107c7247
|
2018-03-20T15:45:35
|
|
ShaderVariable: separate fields for staticUse and active
Thus far the compiler has used the "staticUse" flag to mark variables
that should have rather been marked "active", meaning that the code
may actually execute in a way that accesses the variable. There's a
clear definition for this use of the term "active" in the GLES 3.0.5
spec, section 2.12.6, and in GLES 3.1 section 7.3.1.
Having separate fields for recording static use and "activeness" of a
variable is the first step to fixing this.
According to the spec, usually only active resources should be
considered when checking use against max limits. Also, only active
uniforms get assigned a location. libANGLE code now correctly checks
the active flag rather than the static use flag in these cases.
The static use field still mirrors the active field for now, since
some code in Chromium also needs to be fixed to use the active field
correctly before the two can diverge.
After Chromium is fixed, we can fix ANGLE so that static use
information is recorded earlier during compilation and will accurately
reflect whether variables are statically used. Currently the compiler
only records variables once some static use may already have been
pruned from the AST.
BUG=angleproject:2262
TEST=angle_unittests, angle_end2end_tests
Change-Id: I025bb71361246ae00c911a1f8b66ec045f665f29
Reviewed-on: https://chromium-review.googlesource.com/970962
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
|
|
427071ea
|
2018-03-19T09:21:37
|
|
ES31: Add link validation on geometry shader interface block limits
This patch adds link validation on the maximum number of active
uniform blocks and shader storage blocks defined in the geometry
shader.
BUG=angleproject:1941
TEST=angle_end2end_tests
Change-Id: Ieffc234981a3f32a569392786e8fa1c6623a7a23
Reviewed-on: https://chromium-review.googlesource.com/966491
Commit-Queue: Geoff Lang <geofflang@chromium.org>
Reviewed-by: Jiajia Qin <jiajia.qin@intel.com>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
|
|
1c08cbb3
|
2018-03-15T15:11:56
|
|
Clean up link validations on interface blocks
This patch intends to clean up the link validations on interface
blocks for better implementing program linking with geoemtry shader.
1. Move three interface block validation functions to the anonymous
namespace of Program.cpp instead of the member function of class
Program.
2. Use IsActiveInterfaceBlock everywhere we need to know if an
interface block is active or not.
BUG=angleproject:1941
Change-Id: Ic868d015e45f04d57ba382a2b447be00952fa4fc
Reviewed-on: https://chromium-review.googlesource.com/965395
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Jiajia Qin <jiajia.qin@intel.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
|
|
b7d924a8
|
2018-03-10T11:16:54
|
|
Vulkan: Make free part of DescriptorPool.
This also fixes a missed VkResult error. In order to do this
we also return an error from ProgramImpl::destroy.
Bug: angleproject:2396
Change-Id: I649b19e64732785bb33eebadea7f361245137d0f
Reviewed-on: https://chromium-review.googlesource.com/958406
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
d2cb7cec
|
2018-03-02T09:04:03
|
|
ES31: Fix wrong method of computing combined interface blocks
This patch fixes a bug in the method of validating the number of
combined interface blocks in currenct ANGLE implementation.
When a resource (uniform block, shader storage block, image, atomic
counter buffer, atomic counter) is used by multiple shader stages,
each such use counts separately against the combined resource limit.
This patch also fixes an unexpected link error in a related test by
skipping the test when the number of ssbos exceeds the resouorce
limit.
BUG=angleproject:1951
TEST=angle_end2end_tests
Change-Id: I0de439a412148e0d5ebef3c27d20e0cbd536175a
Reviewed-on: https://chromium-review.googlesource.com/945143
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Jiajia Qin <jiajia.qin@intel.com>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
|
|
f0e89be6
|
2017-11-08T14:00:32
|
|
Use packed enums for the texture types and targets, part 1
In OpenGL there are two enum "sets" used by the API that are very
similar: texture types (or bind point) and texture targets. They only
differ in that texture types have GL_TEXTURE_CUBEMAP and target have
GL_TEXTURE_CUBEMAP_[POSITIVE|NEGATIVE]_[X|Y|Z].
This is a problem because in ANGLE we use GLenum to pass around both
types of data, making it difficult to know which of type and target a
variable is.
In addition these enums are placed somewhat randomly in the space of
OpenGL enums, making it slow to have a mapping from texture types to
some data. Such a mapping is in hot-code with gl::State::mTextures.
This commit stack makes the texture types and target enums be
translated to internal packed enums right at the OpenGL entry point
and used throughout ANGLE to have type safety and performance gains.
This is the first of two commit which does the refactor for all of the
validation and stops inside gl::Context. This was the best place to
split patches without having many conversions from packed enums to GL
enums.
BUG=angleproject:2169
Change-Id: Ib43da7e71c253bd9fe210fb0ec0de61bc286e6d3
Reviewed-on: https://chromium-review.googlesource.com/758835
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
0d88ec9f
|
2018-02-27T16:25:31
|
|
ES31: Add link validations on geometry shader uniforms
This patch adds the link validations on the uniforms defined in a
geometry shader.
1. Validate if there is any link mismatch between a geometry shader
uniform and a uniform defined in another shader in the current
graphics pipeline.
2. Validate if the number of images, samplers or atomic counters in
a geometry shader exceeds the related resource limit.
3. Validate if there is name contradiction between a geometry shader
uniform and a vertex shader attribute.
BUG=angleproject:1941
TEST=dEQP-GLES31.functional.shaders.linkage.es31.geometry.uniform.*
dEQP-GLES31.functional.geometry_shading.basic.*
dEQP-GLES31.functional.geometry_shading.conversion.*
dEQP-GLES31.functional.geometry_shading.emit.*
dEQP-GLES31.functional.geometry_shading.varying.*
dEQP-GLES31.functional.geometry_shading.instanced.geometry_*
dEQP-GLES31.functional.geometry_shading.instanced.invocation_output_*
dEQP-GLES31.functional.geometry_shading.instanced.draw_*
Change-Id: I365aee624a3a79658c3e4c7487a586cf9532b529
Reviewed-on: https://chromium-review.googlesource.com/939264
Commit-Queue: Geoff Lang <geofflang@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
|
|
d063affa
|
2018-02-22T10:19:09
|
|
ES31: Add link validation on geometry shader varyings
This patch adds the link validation on geometry shader varyings.
According to SPEC, geometry shader inputs should not be treated
as arrays for the purpose of interface matching.
This patch also moves the checks on fragment input bindings into
a single function.
BUG=angleproject:1941
TEST=angle_end2end_tests
dEQP-GLES31.functional.shaders.linkage.es31.geometry.varying.*
Change-Id: Ib3ca64e28683e9688edc9432d43ff5a70c86117e
Reviewed-on: https://chromium-review.googlesource.com/929866
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
|
|
4ed05da2
|
2018-02-02T14:26:15
|
|
ES31: Add link validation on geometry shader itself
This patch intends to support program link validation on geometry
shader itself. A link error should occur when linking a program with
a geometry shader that lacks input primitive or output primitive or
the declaration of 'max_vertices'.
This patch also adds the support of linking a program with geometry
shader in angle_end2end_tests.
BUG=angleproject:1941
TEST=angle_end2end_tests
dEQP-GLES31.functional.shaders.linkage.es31.geometry.varying.rules.unspecified_*
Change-Id: I25fb08514753102f5dd3ab86211c05d2ca4fd185
Reviewed-on: https://chromium-review.googlesource.com/898842
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
|
|
8efd1268
|
2017-12-19T09:32:55
|
|
ES31: Add max combined interface blocks validation
BUG=angleproject:1951
Change-Id: I9223964fa84cee3888fb7f5949c3e098fe2aa2b0
Reviewed-on: https://chromium-review.googlesource.com/890818
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
61d5325e
|
2018-01-31T14:49:24
|
|
D3D9: Improve varying packing failure mode.
D3D9 has a special limitation on varying packing, where each
variable takes up a full register width, and cannot share space
with other packed varyings.
A bug was counting registers incorrectly on D3D9. Fix this by
introducing a new limitation exposed to the ANGLE front-end via
the gl::Limitations structure. Now varying packing will fail
correctly in the ANGLE linking front-end with a more descriptive
error message, as such:
"Could not pack varying blah"
"Note: Additional non-conformant packing restrictions are enforced on D3D9."
Also change the packing so that input built-in variables are
counted towards varying limits (e.g. gl_PointSize), except for
gl_Position. On D3D9 we don't pack gl_PointSize, since it is
used in a special extra PSIZE register.
Also update some tests to be more robust.
Bug: chromium:804799
Change-Id: I9027266a8b66a28626f038f259bff42ebf09dcd2
Reviewed-on: https://chromium-review.googlesource.com/889898
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
|
|
9bf55527
|
2018-01-29T13:56:23
|
|
Fix the incorrect calculation for MAX_NAME_LENGTH
The old implementation forgot to consider the instance array situation.
This change will use unified method to calculate the interface block's
MAX_NAME_LENGTH. It also removes some cases which have already passed
from expectation files.
BUG=angleproject:1920
TEST=angle_end2end_tests
*program_interface_query.uniform_block.resource_list.block_array*
*program_interface_query.shader_storage_block.resource_list.block_array*
Change-Id: I6ef53951487e6366d69ecaa43e4df6824baad042
Reviewed-on: https://chromium-review.googlesource.com/890386
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
|
|
881b7bfa
|
2017-12-25T11:18:37
|
|
ES31: Refactor link mismatch error log
This patch intends to refactor the structure of logging link mismatch
errors to meet the new GLES 3.1 program link requirements and support
linking program with geometry shader.
This patch is mainly focusing on the following 4 issues:
1. There are totally 14 places that log the link mismatch errors
in almost same format.
2. A temporary string is created (STRUCT_NAME.FIELD_NAME) before
checking a field of a block, which is of no use if link succeeds.
3. LinkValidateVariablesBase needs to know "shaderTypes" if we support
geometry shader based on current structure. Since uniforms are
checked in the range of the whole program, it is unnecessary to
know in which shader a uniform is defined if link succeeds.
4. GLES 3.1 regards varyings with same location but different names
as matched, so it isn't enough to log errors only by one name.
This patch can solve all these issues by the following 3 changes:
1. Replace "infoLog" and "variableNames" by "mismatchedFieldName" (the
complete field name if the mismatch occurs on a field of a struct
or block).
2. Use enum LinkMismatchError as the return value of all linkValidate*
functions to reflect the detail of the link mismatch error.
3. Log all the link mismatch errors by InfoLog::logLinkMismatch where
we can get shader types instead of passing them into linkValidate*
functions.
BUG=angleproject:1941, angleproject:2144
TEST=angle_end2end_tests
Change-Id: I3ed876d61f812cc7a45a6a3c5fec0b4a88b9cc2c
Reviewed-on: https://chromium-review.googlesource.com/844215
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
|
|
c405ae71
|
2017-12-06T14:15:03
|
|
Optimize Vertex Shader Attribute Type Validition
Improves ValidateVertexShaderAttributeTypeMatch by storing vertex
attributes types into masks for quick comparisons when needed. This shows
2% improvement to glDrawElements for the aquarium workload.
BUG=angleproject:2202
Change-Id: I87fa3d30c3d8cdba6dfd936cd1a41fd27b1c6b77
Reviewed-on: https://chromium-review.googlesource.com/814795
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
|
|
02f15239
|
2017-12-27T10:10:28
|
|
Clear error logs when starting a new link process
This patch intends to fix a bug in logging link errors.
OpenGL ES requires glGetProgramInfoLog return a string
that contains information about last link or validation
attempt on a program object (GLES 2.0 Chapter 6.1.8,
GLES 3.0 Chapter 6.1.12). So all the link error logs
should be cleared when a new link process is begun.
This patch also removes several redundant allocations
of mLazyStream in ProgramD3D::compileProgramExecutables.
Calling "<<" on InfoLog objects will initialize its
member mLazyStream from heap, so we will skip using "<<"
if there is actually nothing to output.
BUG=angleproject:2295
TEST=angle_end2end_tests
Change-Id: Ib81fffd3d05919a8ebccd9145ff780548ca86a70
Reviewed-on: https://chromium-review.googlesource.com/848324
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
910a3daf
|
2017-11-15T09:40:11
|
|
ES31 program query: support TRANSFORM_FEEDBACK_VARYING
TRANSFORM_FEEDBACK_VARYING corresponds to the set of output variables
in the last non-fragment stage of program that would be captured when
transform feedback is active. The resources enumerated by this query
are listed as specified by the most recent call to
TransformFeedbackVaryings before the last call to LinkProgram.
This mainly collects these resources for query.
BUG=angleproject:1920
TEST=angle_end2end_tests:ProgramInterfaceTest*
dEQP-GLES31.functional.program_interface_query.transform_feedback_varying.*
Change-Id: I0655b12c6d82cef1b44d4ca57ea55bb60d1f78fb
Reviewed-on: https://chromium-review.googlesource.com/770450
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
73618601
|
2017-12-20T15:47:15
|
|
ES31: Clean up Program::link
This patch intends to solve some structure and coding style issues
in Program::link to make it easier to support linking program with
geometry shader.
1. Move all the shader specific validations to linkValidateShaders.
Geometry shader related link validations can also be added here.
2. Rename functions with "VertexAndFragment" to "Graphics" because
these functions will also be responsible for the validations on
geometry shader.
3. Refer uniforms by pointer when validating uniforms.
4. Re-declare functions to 'static' if we can and capitialize the
first letter of all static functions in Program.h.
BUG=angleproject:1941
Change-Id: I46608e86bddc12d95cbbbf9a85803d07ccf843d8
Reviewed-on: https://chromium-review.googlesource.com/836149
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
ece12535
|
2017-11-21T15:50:21
|
|
ES31: Fix the issue for relink rendering/compute program.
When link or relink fails, if we try to install the unsuccessfully linked
program (via UseProgram) and start rendering or dispatch compute, We can
not always report INVALID_OPERATION for rendering/compute pipeline.
The result depends on the previous state: Whether a valid program has been
installed in pipeline before. If a valid program has been installed, it
should be OK to use the old executable residing in the GL state to start
rendering or dispatch compute. No error should be reported.
This change also add unit tests for unsuccessfully linked/relinked program
for rendering pipeline to avoid potential error.
If a program successfully relinks when it is in use, the program might
change from a rendering program to a compute program in theory,
or vice versa.
BUG=angleproject:2266
Change-Id: I4726112af2bc74f5beef25e35d2fcaa9f31e0768
Reviewed-on: https://chromium-review.googlesource.com/784273
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
|
|
8225e73b
|
2017-11-14T16:29:03
|
|
Support struct varying for transform feedback
Capturing struct members is vague In ES 3.00. But the ES 3.10
explicitly says that base-level members of struct are feasible for
transform feedback capture. This implementation fills the gap.
TEST=angle_end2end_tests:TrasnformFeedbackTest*
BUG=angleproject:2241
Change-Id: Ibdf3ae6c2b8b28952e2f7fef1363545cbccad389
Reviewed-on: https://chromium-review.googlesource.com/768613
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
3de2703d
|
2017-11-30T12:16:47
|
|
Fix handling matrix qualifiers on block members
Individual block member row_major/column_major layout qualifiers may
override the qualifiers set on the block. During parsing, this was
already being handled correctly, so that the qualifier is resolved for
each block member and recorded for each TField / InterfaceBlockField.
Now we always write the qualifiers on a per-member granularity to the
output GLSL shaders, so that the native driver gets the correct
per-member qualifiers. This replaces earlier behavior where the matrix
qualifiers were only written per-block.
Also only use qualifiers from individual members in block layout.
Since the block-level qualifier information is no longer used after
parsing, it is no longer kept in the AST. A dummy value is still set
to the InterfaceBlock structs exposed through the ShaderVars
interface, since that has existing usage in Chromium that needs to be
removed before the field can be removed.
Some AMD OpenGL drivers don't seem to handle matrix layout qualifiers
correctly, so most of the added tests need to be skipped for AMD GL.
On NVIDIA and Intel the tests pass.
BUG=angleproject:2271
TEST=angle_unittests, angle_end2end_tests,
dEQP-GLES31.functional.program_interface_query.uniform.matrix*
Change-Id: I1baa7a633bc2da548743c2190cb72db491b5227a
Reviewed-on: https://chromium-review.googlesource.com/800174
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
|
|
76746f9b
|
2017-11-22T11:44:41
|
|
Optimize Fragment Shader Type Match Validation
Improves ValidateFragmentShaderColorBufferTypeMatch by storing input and
output types into a bitmask for quick comparison when validation is
needed. This shows a 2% improvement to glDrawElements for the aquarium
workload.
BUG=angleproject:2203
Change-Id: Iade2ecf28383164e370b48442f01fba6c0962fba
Reviewed-on: https://chromium-review.googlesource.com/775019
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
|
|
94f1e89f
|
2017-11-20T12:14:32
|
|
ES31: Add atomic counter buffer data size
BUG=angleproject:1729
TEST=dEQP-GLES31.functional.ssbo.layout.*
dEQP-GLES31.functional.compute.basic.atomic_counter*
Change-Id: Ic78c0f089fd539c0b1064e8405d63505456dbc01
Reviewed-on: https://chromium-review.googlesource.com/777958
Commit-Queue: Geoff Lang <geofflang@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
|
|
3c1da04e
|
2017-11-27T18:33:40
|
|
Isolate GlslangWrapper header from most of ANGLE.
Since we might want to use the ANGLE PoolAlloc in the Vulkan back-end,
we want to make completely sure that it doesn't show up in any header
that might be included with the Glslang headers, since this could
cause a conflict.
This change moves as much as possible to forward-declaring instead of
including headers directly in ProgramLinkedResources.h. This means
making several internal Program helper classes external. I.E. instead
of Program::Bindings, we have ProgramBindings.
It also redeclares a "using" in two places, since it isn't possible to
forward declare these, and it seemed overdesigned to put the using in
a separate header.
Bug: angleproject:2264
Change-Id: Idd08706580c927327dddf46e86acbcd2c4e3286f
Reviewed-on: https://chromium-review.googlesource.com/792270
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
85072e8f
|
2017-11-14T15:43:28
|
|
ES31: Fix detaching/deleting compute shader after LinkProgram.
This change also moves the ShaderType enum from D3D renderer to angletype.h.
And it uses a bit mask to track the linked shader stages.
BUG=angleproject:2247
Change-Id: I5c7ee1445d353a02e24549ffcf6b0ac694dd1069
Reviewed-on: https://chromium-review.googlesource.com/768629
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
465835d6
|
2017-09-26T13:34:10
|
|
Support arrays of arrays in the API
The ShaderVariable class that is used as an interface between the
compiler and the rest of the code gets arrays of arrays support.
Array of array variables are passed from the compiler just like any
other variables. However, when stored in Program state each innermost
array constitutes a separate variable. This is done to make the
implementation match the GLES specification for program interface
query APIs.
This will be tested more fully once support for parsing arrays of
arrays lands in the compiler.
TEST=angle_end2end_tests, angle_unittests
BUG=angleproject:2125
Change-Id: I0f7159000f039be92a87a52b3b68cd9a215a21cb
Reviewed-on: https://chromium-review.googlesource.com/684742
Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
acf2f3ad
|
2017-11-21T19:22:44
|
|
Apply Chromium style fixes.
This addresses several minor code quality issues that are validated
in Chromium, but not yet applied to ANGLE:
* constructors and destructors must be defined out-of-line
* auto is not allowed for simple pointer types
* use override everywhere instead of virtual
* virtual functions must also be defined out-of-line
Slightly reduces binary size for me (~2k on Win, 150k on Linux).
Bug: angleproject:1569
Change-Id: I073ca3365188caf5f29fb28d9eb207903c1843e6
Reviewed-on: https://chromium-review.googlesource.com/779959
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
89be29a5
|
2017-11-06T14:36:45
|
|
ES31: Implement creation and attaching geometry shader on OpenGL
This patch intends to implement the creation of a geometry shader
and attaching a geometry shader to a program on OpenGL back-ends.
This patch also adds all geometry shader related dEQP-GLES31 test
failures to deqp_gles31_test_expectations.txt.
BUG=angleproject:1941
TEST=angle_end2end_tests
Change-Id: Ib0b497030255b15dacd967e48bc59eef0009af46
Reviewed-on: https://chromium-review.googlesource.com/757979
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
85c93c41
|
2017-11-12T15:36:47
|
|
Refactor VaryingPacking
Move all packing related logic from Program to VaryingPacking.
Do linkValidateTransformFeedback check first to simplify packing.
Make getPackedVaryings collect all required VaryingPackings in one
run pass, so that packUserVaryings can focus on packing merely.
BUG=angleproject:2241
Change-Id: I5e84e6e4688c80ba7a77a265b8ffaf79f4ddbb87
Reviewed-on: https://chromium-review.googlesource.com/764821
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Commit-Queue: Geoff Lang <geofflang@chromium.org>
|
|
92019431
|
2017-11-20T13:09:34
|
|
Make conversion from GL types to native bools consistant.
Some places would compare with "== GL_TRUE" and others with "!= GL_FALSE".
This behaviour is not in the OpenGL spec but "!= GL_FALSE" is the most
standard and follows the same rules as C and C++.
Remove un-necessary validation that params are either GL_TRUE or
GL_FALSE.
Update some internal storage from GLboolean to bool.
BUG=angleproject:2258
Change-Id: I12adbe2d24318a206521ca6ad1099ee7e2bf677e
Reviewed-on: https://chromium-review.googlesource.com/779799
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Geoff Lang <geofflang@chromium.org>
|
|
3a9090fa
|
2017-09-27T14:37:04
|
|
ES31: Add BUFFER_VARIABLE and SHADER_STORAGE_BLOCK program interfaces
This patch collects the shader storage block members information.
It implements getShaderStorageBlockMemberInfo and getShaderStorageBlockSize
for OpenGL backend. Meanwhile, it implements BUFFER_VARIABLE and SHADER_STORAGE_BLOCK
interfaces for program query.
BUG=angleproject:1920
TEST=angle_end2end_tests:ProgramInterfaceTest*
dEQP-GLES31.functional.layout_binding.ssbo*
dEQP-GLES31.functional.compute.basic.empty
dEQP-GLES31.functional.compute.basic.ssbo_rw*
dEQP-GLES31.functional.compute.basic.ssbo_local_barrier*
dEQP-GLES31.functional.compute.basic.copy_image_to_ssbo_small
dEQP-GLES31.functional.compute.basic.copy_ssbo_multiple_groups
dEQP-GLES31.functional.compute.basic.copy_ssbo_multiple_invocations
dEQP-GLES31.functional.compute.basic.copy_ssbo_single_invocation
dEQP-GLES31.functional.compute.basic.copy_ssbo_to_image_small
dEQP-GLES31.functional.compute.basic.shared_var*
dEQP-GLES31.functional.compute.basic.ubo_to_ssbo*
dEQP-GLES31.functional.compute.basic.write_multiple_arr*
dEQP-GLES31.functional.compute.shared_var.basic_type.*
dEQP-GLES31.functional.compute.shared_var.work_group_size.*
dEQP-GLES31.functional.atomic_counter.*
Change-Id: Ie8b81fde5a2e919aab77adb3d137c9ff2f193409
Reviewed-on: https://chromium-review.googlesource.com/712235
Reviewed-by: Olli Etuaho <oetuaho@nvidia.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
6db1c2e8
|
2017-11-08T09:17:40
|
|
Link interface blocks in ProgramImpl::link.
This allows the back-end to have access to the interface block info
in the link operation, and also allows the interface block info to
have direct access to the post-link Impl information.
BUG=angleproject:2208
Change-Id: Ib2bfb3c9155eee715bd3d29de1c3fdd67b16eed4
Reviewed-on: https://chromium-review.googlesource.com/753521
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
7af0de52
|
2017-11-06T17:09:33
|
|
Rename UniformLinker.cpp/h to ProgramLinkedResources.
A more general name for a file that will house a collection of pogram
variable related linking code.
BUG=angleproject:2208
Change-Id: I82710f6abadd2df58fb58a3c4179989fe956e7e4
Reviewed-on: https://chromium-review.googlesource.com/755858
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
1734e171
|
2017-10-27T15:30:27
|
|
Only store innermost array offset in VariableLocation
Separate entries will be generated for each innermost array of arrays
of arrays in the variable tables. Because of this VariableLocation
actually only needs to store the innermost array index.
BUG=angleproject:2125
TEST=angle_end2end_tests
Change-Id: Id1ee35b3cecfc011d96b58e43cf0b1cccbfed408
Reviewed-on: https://chromium-review.googlesource.com/741742
Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
c9727f31
|
2017-11-07T12:37:07
|
|
Pass InterfaceBlockLinker to ProgramImpl::link.
This change is in preparation for moving the linking logic to the
Implementation.
Introduces a ProgramLinkedResources class that is passed into the Impl
and holds linking-related info such as the UBOs, Varyings, etc.
BUG=angleproject:2208
Change-Id: I2ef0824b54bfb462c79d003bffe34e9cfad60d8a
Reviewed-on: https://chromium-review.googlesource.com/746204
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
977abce7
|
2017-11-07T08:03:19
|
|
Refactor interface block linking.
This moves the logic for interface block linking. The new design is
intended to be flexible enough to be passed into a back-end call to
ProgramImpl::link. Then, the Impl object can be responsible for both
filtering out unreferenced interface blocks as well as having access
to the linked interface block information.
A future change will pass the InterfaceBlockLinker objects (or objects
when dealing with ES 3.1 and Shader Storage Blocks) to the Impl. This
will help fix a D3D11 back-end bug where we would need acess to the
Shader objects to finish a deferred uniform block link.
This should also potentially make it easier for the back-ends to
determine Shader Storage Block size and properties without defining
new Impl methods.
BUG=angleproject:2208
Change-Id: Ic5244a808dba44ba1a8c08d9ee701952034d2b18
Reviewed-on: https://chromium-review.googlesource.com/746203
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Yuly Novikov <ynovikov@chromium.org>
|
|
d255123c
|
2017-10-26T20:03:33
|
|
Store shader interface variables as per query spec
GLES 3.1 section 7.3.1.1 specifies how active variable entries should
be generated and how active variables are named. The specs for program
interface variable queries are built on top of this section.
ANGLE has already followed this spec for the most part for generating
variable lists in ProgramState, but now we also follow the naming spec
for arrays and include [0] at the end of the stored name.
This will make implementing arrays of arrays more straightforward.
Most logic for variable queries will just keep working as is when
arrays of arrays are added instead of needing more complex logic for
handling array indexing.
BUG=angleproject:2125
TEST=angle_end2end_tests
Change-Id: I3acd14253153e10bc312114b0303065da2efb506
Reviewed-on: https://chromium-review.googlesource.com/739826
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
|
|
58f67be0
|
2017-10-27T08:59:27
|
|
ES31 program query: support AtomicCounterBuffer and UniformBlock
Calculates atomic counter buffer's shader reference according to its
child counters.
Merges GL_UNIFORM_BLOCK_* queries to GL_*.
Refreshes deqp_gles31_test_expectations.
BUG=angleproject:1920
TEST=angle_end2end_tests:ProgramInterfaceTest*
dEQP-GLES31.functional.state_query.program.active_atomic_counter_buffers_get_programiv
dEQP-GLES31.functional.layout_binding.ubo.*
Change-Id: Ia23ddfef5f5dd7e15628f4c259273e1c01c14d80
Reviewed-on: https://chromium-review.googlesource.com/715436
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
|
|
4ef25033
|
2017-11-01T09:36:51
|
|
Refactor StaticallyUsed
Gather vertexStaticUse, fragmentStaticUse, and computeStaticUse
into a new mixin class StaticallyUsed, from which various
program resources can inherit to track their shader references.
BUG=angleproject:1920
Change-Id: Ibb3c0fe035bb8789aad65dbdfefaf7cb17b64c4e
Reviewed-on: https://chromium-review.googlesource.com/748317
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
|
|
3d40488b
|
2017-10-16T13:30:48
|
|
Split varyings into input and output varyings in renderer
This patch intends to split all vector<Varying> into two vectors
to store input and output varyings separately in the renderer.
This patch is a base of supporting program linking with geometry
shader. Unlike the vertex shaders (their outputs are varyings)
and fragment shaders (their inputs are varyings), the inputs and
outputs of geometry shaders are all varyings, so we need two
vector<Varying> to store them correctly.
BUG=angleproject:1941
TEST=angle_end2end_tests
Change-Id: Ic4b8343f2fc3df87b764c45f2ea7810e565f7bee
Reviewed-on: https://chromium-review.googlesource.com/720617
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Olli Etuaho <oetuaho@nvidia.com>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
|
|
bd159f06
|
2017-10-09T19:39:06
|
|
Vulkan: Use minimal dirty bits in VertexArrayVk.
This should slightly reduce draw call overhead.
BUG=angleproject:1898
Change-Id: I0e515bf2868f237f1d6948c12942f8cb6637c0c0
Reviewed-on: https://chromium-review.googlesource.com/707690
Reviewed-by: Frank Henigman <fjhenigman@chromium.org>
Reviewed-by: Yuly Novikov <ynovikov@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
c853804c
|
2017-09-27T11:20:15
|
|
Add support for arrays of arrays to VariableLocation
Array indices are sorted so that the outermost index is in the back.
This is because we want to be consistent with future arrays of arrays
parsing code. In parsing we'll have a utility function to make a
TType object into an array, and there it's most natural to push the
new outermost sizes to the back of the vector.
Further patches will still be needed to parse arrays of arrays and
add support to arrays of arrays into the API.
BUG=angleproject:2125
TEST=angle_unittests, angle_end2end_tests
Change-Id: I6c88edabf68ae9dbd803ec6d20543016c408b702
Reviewed-on: https://chromium-review.googlesource.com/686414
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
|
|
baf5d945
|
2017-08-28T20:45:48
|
|
ES31: Add UNIFORM support for ProgramInterface
Add program resource properties for uniform.
BUG=angleproject:1920
TEST=angle_end2end_tests:ProgramInterfaceTest*
Change-Id: Ia5cf6219db43b8b1f73efbb3565d21c86e9d3ec0
Reviewed-on: https://chromium-review.googlesource.com/638050
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
fb997ec1
|
2017-09-20T15:44:27
|
|
Removed "name" and "used" from variable location.
The used flag was redundant with the index (which used MAXUINT). The
name was redundant with the stored uniform. Removing these gives a
very minor performance speed up when iterating and retrieving
uniform locations.
BUG=angleproject:1390
Change-Id: Ieeccdff7c131e1359e754e246d3648b73aad5baf
Reviewed-on: https://chromium-review.googlesource.com/659224
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
|
|
729b2c6e
|
2017-08-14T09:36:11
|
|
ES31: Enable shader storage buffer support for OpenGL backend
BUG=angleproject:1951
TEST=angle_end2end_tests:ShaderStorageBuffer
Change-Id: I1afc3cd005ad2e595c6ce937fc53e17423f8ec8b
Reviewed-on: https://chromium-review.googlesource.com/618132
Commit-Queue: Geoff Lang <geofflang@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
|
|
d68248be
|
2017-09-11T14:34:14
|
|
Update Texture dirty bits documentation.
BUG=angleproject:1387
Change-Id: Ie2277874acb9e7a3eed4bce327f2c08750213967
Reviewed-on: https://chromium-review.googlesource.com/660419
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
81c2e253
|
2017-09-09T23:32:46
|
|
Add top-level dirty bits for texture and samplers.
These will have to be fleshed out in the back-ends.
Also currently uses a single bit for all the bindings, and we can
extend this to more fine-grained updates in the future.
This patch implements top-level updates for texture completeness.
Sampler completeness caches are removed from the Texture class, and
replaced by a cache in the gl::State class. The State class also
keeps a channel binding to the bound textures so it can be notified
when textures might change from complete <-> incomplete.
In future CLs we skip updating back-ends if texture state doesn't
change.
BUG=angleproject:1387
Change-Id: If580b4851303c86f3240e62891f5f6047eefb6a2
Reviewed-on: https://chromium-review.googlesource.com/648053
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
fe8b5989
|
2017-09-07T17:00:18
|
|
Program: Fixed unreferenced Samplers.
The calculation for unreferenced was incorrect - it checked the 'used'
flag of the uniform location, but if samplers started at index zero,
all the unused uniforms were to be considered valid samplers. Instead,
initialize the uniform index to INVALID_INDEX.
This bug was uncovered after doing work on the Texture dirty bits.
BUG=angleproject:1387
Change-Id: I5e404e367caed38368bcc0e581699ae2c911bcc9
Reviewed-on: https://chromium-review.googlesource.com/655930
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
134f93d1
|
2017-08-31T17:11:00
|
|
D3D: Small optimizations to uniform updates.
Uses more of the type info table for updates.
Also special-case clamping when uniform count == 1.
Improves the speed of the d3d11 uniform stress test by ~20%.
BUG=angleproject:1390
Change-Id: I6707c67db84c94a28b1519b0bbee5d28fe38b189
Reviewed-on: https://chromium-review.googlesource.com/646828
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
be5e2ec3
|
2017-08-31T13:28:28
|
|
Remove uniform memory copy from GL front-end.
This moves the uniform query to the back-end. In D3D, this requires
a bit more redesign, especially for matrix uniforms.
Gives about a 10% speed improvement in the GL/NULL uniforms stress
test on Windows (UniformsBenchmark.Run/gl_null_400_vec4).
BUG=angleproject:1390
Change-Id: Idac22a77118e9e94d2f28c585e31ff0bc785ba94
Reviewed-on: https://chromium-review.googlesource.com/623929
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
|
|
855d964b
|
2017-05-17T14:05:06
|
|
Prefix user-defined names in GLSL output
Now user-defined names are prefixed by _u in GLSL output in case name
hashing is not on. Internal names such as names of temporary variables
created in AST transformations are written out as such.
This makes handling of internal function names and internal variable
names consistent. It also removes the possibility of name conflicts
between user-defined names and internal names in case name hashing is
not on. In the same vein, it makes it safe to use GLSL reserved words
that are not reserved in ESSL as variable names in case name hashing
is not on.
This also makes the GLSL output more consistent with how names are
handled in HLSL output. Name hashing code is shared between
VariableInfo and OutputGLSLBase to ensure names are handled
consistently in both. The name that's used in the shader source for a
given interface variable is written out to ShaderVariable::mappedName.
An exception needs to be made for identifiers close to the length
limit, since adding any prefix would take them over the limit. But
they can be just written out as such, since we don't have any builtins
or ANGLE internal variables that have as long names and could create a
conflict.
BUG=angleproject:2139
BUG=angleproject:2038
TEST=angle_unittests, angle_end2end_tests, WebGL conformance tests
Change-Id: Id6ed052c4fab2d091227dc9a3668083053b67a38
Reviewed-on: https://chromium-review.googlesource.com/507647
Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
39e78122
|
2017-08-29T14:34:22
|
|
Fix assert when linking nonexistent transform feedback varying
linkValidateTransformFeedback needs to be run after packing varyings,
since it relies on nonexistent varyings being already handled.
BUG=angleproject:2141
TEST=angle_end2end_tests on debug
Change-Id: I6178348f05a19070a2d17caf90f732df9eb06b9d
Reviewed-on: https://chromium-review.googlesource.com/641152
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
|
|
54164b0c
|
2017-08-28T15:17:37
|
|
Add getUniform impl methods.
This will let us remove some of the uniform data management code in
the GL front-end, and simplify the GL back-end. It will also enable
us to implement uniform data more efficiently in the D3D11 back-end,
and probably Vulkan back-end later.
This also implements a new impl method for the ProgramGL class to
flag optimized-out uniforms as no longer used, post-link. This is
important because otherwise the optimized uniforms get assigned
valid locations, and then the getUniform calls are expected to
succeed.
We also use a workaround for uniform value queries for the GL
back-end. It seems as though some drivers (seen on NVIDIA and AMD)
may not properly clamp to the maximum representable integer value
when querying out-of-range floating point values. Work around this by
always calling the driver with the proper type and then casting the
value in ANGLE.
BUG=angleproject:1390
Change-Id: I03dc2382e7af52455c356a2bf3971a4d1bd46ec6
Reviewed-on: https://chromium-review.googlesource.com/616785
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
|
|
9b11ea4f
|
2017-07-11T16:50:08
|
|
Gather UniformBlock and ShaderStorageBlock separately
Refactor InterfaceBlocks since it only stands for UniformBlock before
ES31. But for ES31, uniform block and shader storage block both belong
to interface block.
This CL will add GetUniformBlocks and GetShaderStorageBlocks in
ShaderLang.h. Meanwhile, keep GetInterfaceBlocks which can return all
the interface blocks together.
BUG=angleproject:1951
Change-Id: I3036e201aadfbd490575ed03538c81bcc3793ff3
Reviewed-on: https://chromium-review.googlesource.com/582546
Commit-Queue: Geoff Lang <geofflang@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
|
|
880683b1
|
2017-04-12T16:21:55
|
|
ES31: Add glGetProgramResourceiv API
Add API entry and validation checks(GLES 3.1 section 7.3).
Add the first 2 interfaces(PROGRAM_INPUT and PROGRAM_OUTPUT) implementation.
BUG=angleproject:1920
TEST=angle_end2end_tests:ProgramInterfaceTestES31.*
Change-Id: I50057f7b99f4dc7c23ca87fa9b797ca424f66e3d
Reviewed-on: https://chromium-review.googlesource.com/475075
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
6c58b062
|
2017-08-01T13:44:25
|
|
Add histograms for the program cache.
Also includes some tracking of if a cache hit comes from a binary
inserted after a Link call, or sourced from the external disk cache.
Chromium-side CL: https://chromium-review.googlesource.com/c/592151/
BUG=angleproject:2118
Change-Id: I80eefd203d8ce31d1ac03dd1a36459d3581128f5
Reviewed-on: https://chromium-review.googlesource.com/590689
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
|