|
21f16cb1
|
2023-06-09T17:30:38
|
|
Disable clang-format on ANGLE features autogen outputs
Updates the script to produce reasonably formatted code without
clang-format.
Autogen files moved to autogen/ sub-directories because clang-format
does not support per-file settings ;(
This allows to run this codegen very quickly
(~50ms on my machine)
Bug: angleproject:8193
Change-Id: Ie84282090d574ebb4debe3edcfd82f983f27a5ff
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4604578
Commit-Queue: Roman Lavrov <romanl@google.com>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
|
|
e96e919f
|
2023-04-24T00:00:00
|
|
D3D11: Implement multisampling shader extensions
* OES_sample_variables
* OES_shader_multisample_interpolation
Bug: angleproject:8097
Bug: angleproject:8131
Change-Id: I8ea81725d30ab3a5db6254b897fe72dbe88739d9
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4484164
Reviewed-by: Kenneth Russell <kbr@chromium.org>
Commit-Queue: Alexey Knyazev <lexa.knyazev@gmail.com>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
|
|
997c4c7b
|
2023-03-21T00:00:00
|
|
D3D11: Implement EXT_conservative_depth
Drive-by:
* Hid the extension from ES 2.0 client contexts.
Bug: angleproject:8046
Change-Id: I8bca4161dde4bda7ee75541b9164777884900d89
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4366784
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Commit-Queue: Alexey Knyazev <lexa.knyazev@gmail.com>
|
|
91a5635a
|
2022-12-16T00:00:00
|
|
Support arbitrary clip and cull distance array sizes
Removed limitSimultaneousClipAndCullDistanceUsage cap.
Enhanced HLSL translator to support all valid combinations
of clip and cull distances.
Validate that these arrays are sized explicitly or by using
only constant indices; adjusted link program error message.
Enhanced tests to cover all possible combinations of
implicit and explicit array sizes for both built-ins.
Bug: angleproject:4452
Change-Id: I704db6dc3c8951e5ba482a3e4dad09e5b0182f9c
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4111645
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Commit-Queue: Alexey Knyazev <lexa.knyazev@gmail.com>
|
|
b19d17b8
|
2022-12-09T14:38:08
|
|
Vulkan: Split Serial class into UniqueSerial and Serial
This CL splits Serial class into two classes: UniqueSerial and Serial.
UniqueSerial supports the object unique serial usage where there is ==
and != operator but no > or < comparison. UniqueSerial can have invalid
value, but Serial will not have invalid value (in next CL). The main
reason is for next CL we can further optimize out the invalid value
check in the QueueSerial comparison.
Bug: b/262047600
Change-Id: Ieaed2a0d5546b012a6d63aa18b6006595e4aee1b
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4093557
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Commit-Queue: Charlie Lao <cclao@google.com>
Reviewed-by: Amirali Abdolrashidi <abdolrashidi@google.com>
|
|
805e00b8
|
2022-10-27T00:00:00
|
|
D3D11: Add clip and cull distance support
Added gl_ClipDistance and gl_CullDistance
support to HLSL translator.
Added enabled clip distance GL state emulation.
Added limitSimultaneousClipAndCullDistanceUsage
limitation.
Expanded and optimized related end2end tests.
Bug: angleproject:4452
Change-Id: Id66312505254ceff43d5258d486ddcdb0462db47
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3990944
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Commit-Queue: Alexey Knyazev <lexa.knyazev@gmail.com>
|
|
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>
|
|
400d9fe4
|
2022-04-23T01:08:19
|
|
Rename feature files to *_autogen.h
To clarify further that they are not to be edited by hand.
Bug: angleproject:6435
Change-Id: Iaf79706d2b688a43b3ebb65700cfbdd71a49a742
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3603842
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
|
|
6e130d2b
|
2022-04-19T11:35:46
|
|
D3D: fix SSBOs used in vertex shaders.
Use the total number of pixel shader outputs as the base
UAV register for vertex and pixel shaders. This is less fragile than
making the vertex shader depend on the number of draw-time pixel shader
outputs.
Add a test that exercises SSBOs in vertex shaders, varying the number of
draw-time pixel shader outputs (which should have no effect on register
assignment).
Bug: angleproject:7156
Change-Id: I5801d59299275ea6d2569456d53c230e7e8ee5a9
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3579501
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Stephen White <senorblanco@chromium.org>
|
|
eeb39653
|
2022-04-08T16:09:48
|
|
Autogenerate features
Features are now specified in a json file and autogenerated. This is in
preparation for more autogeneration to support feature override in
tests.
This change doesn't yet fix the issues in anglebug.com/6435 and should
be a no-op.
Bug: angleproject:6435
Change-Id: Icdb63a94dc37b5fef0a356e0fc0b49937e083c8a
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3579941
Reviewed-by: Yuly Novikov <ynovikov@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
|
|
6803a2d0
|
2022-04-01T16:52:49
|
|
D3D11: implement SSBOs in pixel and vertex shaders.
Since the 'u' register space for UAVs in pixel shaders is shared
with render targets, and the number of render targets may vary
depending on GL state, this required deferring register allocation
until draw-time output in DynamicHLSL.
Since non-compute shaders aren't able to immediately output the
SSBO declaration, initial register allocation was broken out from
ResourcesHLSL::shaderStorageBlocksHeader()
into ResourcesHLSL::allocateShaderStorageBlockRegisters() with
the former only called for compute shaders. These initial allocations
are offset by the number of RTs at draw time.
Since Raw UAVs may now be created at draw time for non-compute
shaders, call markRawBufferUsage() from the Renderer11::draw*()
entry points as it is from dispatchCompute*().
Bug: angleproject:7156
Change-Id: I6ab65af1ff36df0313e3c1f8f79661b1547ab9a2
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3565562
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Stephen White <senorblanco@chromium.org>
|
|
361874bb
|
2022-03-24T15:38:56
|
|
D3D: generalize more stuff (mImages, mReadonlyImages).
Bug: angleproject:7121
Change-Id: I39e7df1e9aed84c225c8877a3d16ca3c44f70990
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3550543
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Stephen White <senorblanco@chromium.org>
|
|
cfee4070
|
2022-03-24T15:21:22
|
|
D3D: generalize Image2D, ReadonlyImage2D and AtomicCounter.
Mapify them so they can handle all shader types.
Bug: angleproject:7121
Change-Id: Ia80d46200bf30509e1484f1e198e1edfe6344207
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3550542
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Stephen White <senorblanco@chromium.org>
|
|
c399c693
|
2022-03-24T14:10:57
|
|
D3D: more generalization: cached Image2DBindLayouts.
Bug: angleproject:7121
Change-Id: I5cead9f7e70cfb9ebea807b886ba849948a2ec47
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3550541
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Stephen White <senorblanco@chromium.org>
|
|
f2e7a235
|
2022-03-25T10:00:11
|
|
D3D: generalize the Image2DBindLayoutCache to be per-shader.
Bug: angleproject:7121
Change-Id: I3b5243583ac11a0fc96c4b9271118a8fd7ee4f66
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3550540
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Stephen White <senorblanco@chromium.org>
|
|
4e939ac6
|
2022-03-25T09:58:52
|
|
D3D: generalize mImage2DUniforms.
Mapify this variable so it can accommodate other shader types.
Bug: angleproject:7121
Change-Id: If6893a5fceaf50db87c42176c58319ce17d23d54
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3550539
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Stephen White <senorblanco@chromium.org>
|
|
716b2cba
|
2021-03-12T14:46:53
|
|
Use bitset masks for active shader buffers.
This switches the tracking for the uniform, shader storage, and atomic
counter buffers to use bitset masks to determine where there are
active buffers. This will make iterating these buffer sets faster.
Also renames the limit for atomic counter buffers to be consistent
with the other buffer types.
Also applies the implementation limit to atomic counter buffer
bindings. This fixes out-of-bounds access on some Linux platforms that
expose a large number of bindings.
Bug: angleproject:5736
Change-Id: Ice801645697592d1dda6aebf0cb69767594cc0c5
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2757509
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Tim Van Patten <timvp@google.com>
|
|
580961fb
|
2021-02-02T10:27:48
|
|
Micro-optimizations for setUniform*
This CL improves the setUniform* call for the case where the
niform component size is 4. In that case, we can issue a single
memcpy. This reduces the average wall time of setUniform4fv in
our test app by ~20%.
Test: Run the dEQP shader tests.
Bug: b/179160884
Change-Id: I9352f6188bc87449719aac522d1a2323adf7fca5
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2667592
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Commit-Queue: Doug Horn <doughorn@google.com>
|
|
c5b5cf6c
|
2020-09-10T16:58:18
|
|
Refactor to pass ProgramMergedVaryings to link impl
Follow-on CL needs the ProgramMergedVaryings in the Vulkan backend to
generate valid SPIRV.
Bug: angleproject:3078
Change-Id: Ic442a3e0bd713fec36bd6b9420f67f3b1118e5ad
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2404336
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Courtney Goeltzenleuchter <courtneygo@google.com>
|
|
d10ba166
|
2020-05-19T18:00:38
|
|
Rename ProgramState::getProgramExecutable() to getExecutable()
The "Program" part of ProgramState::getProgramExecutable() is already
implied by being part of a ProgramState, so it can be removed.
Bug: angleproject:3570
Change-Id: I35ffb2af81196fa7f189f7d3a37158f5f1951141
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2209317
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Tim Van Patten <timvp@google.com>
|
|
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>
|
|
07467b4a
|
2020-03-20T10:40:56
|
|
Remove GL_CHROMIUM_path_rendering
Bug: chromium:1063193
Bug: angleproject:4270
Change-Id: I35b24b7d8d892181955e49dd2495655bc57cb0df
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2112275
Reviewed-by: Zhenyao Mo <zmo@chromium.org>
Reviewed-by: Jonah Ryan-Davis <jonahr@google.com>
Commit-Queue: Geoff Lang <geofflang@chromium.org>
|
|
0af8b596
|
2019-09-03T16:24:45
|
|
D3D11: Translate uniform blocks to StructuredBuffer when necessary
fxc exhibits slow compile performance with dynamic cbuffer indexing.
So when a uniform block contains only one large array member, which is
an array of structures, translate this uniform block to
a StructuredBuffer instead.
Bug: angleproject:3682
TEST=angle_end2end_tests.UniformBufferTest.*
Change-Id: Ife80dba8aae65b761737e095895e00a570230f88
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1782046
Commit-Queue: Xinghua Cao <xinghua.cao@intel.com>
Reviewed-by: Kenneth Russell <kbr@chromium.org>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
|
|
90a58622
|
2019-09-04T15:39:58
|
|
Refactor ShaderVariable to Remove Specializations
The following structs are being refactored and moved into the parent
struct ShaderVariable:
VariableWithLocation
Uniform
Attribute
OutputVariable
InterfaceBlockField
Varying
Bug: angleproject:3899
Test: CQ
Change-Id: I389eb3ab4ed44a360e09fca75ecc78d64a277f83
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1785877
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Courtney Goeltzenleuchter <courtneygo@google.com>
Commit-Queue: Tim Van Patten <timvp@google.com>
|
|
9d737966
|
2019-08-14T12:25:12
|
|
Standardize copyright notices to project style
For all "ANGLE Project" copyrights, standardize to the format specified
by the style guide. Changes:
- "Copyright (c)" and "Copyright(c)" changed to just "Copyright".
- Removed the second half of date ranges ("Y1Y1-Y2Y2"->"Y1Y1").
- Fixed a small number of files that had no copyright date using the
initial commit year from the version control history.
- Fixed one instance of copyright being "The ANGLE Project" rather than
"The ANGLE Project Authors"
These changes are applied both to the copyright of source file, and
where applicable to copyright statements that are generated by
templates.
BUG=angleproject:3811
Change-Id: I973dd65e4ef9deeba232d5be74c768256a0eb2e5
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1754397
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
f2412bca
|
2019-07-16T15:47:34
|
|
Get rendering to texture working
Other small fixes for desktop compatibility
Bug: angleproject:3620
Change-Id: I8e75bce1f850fb891c8bb6e16f79302a6d59276c
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1707932
Commit-Queue: Clemen Deng <clemendeng@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
1245f078
|
2019-06-25T13:51:29
|
|
Use D3D11 GetDimensions driver workaround for dynamic images
Some NVIDIA D3D11 drivers are buggy and interprets the level passed to
GetDimensions as being relative to 0, rather than the SRV's MostDetailedMip.
This affects the implementation of the imageSize function in the D3D11 backend.
Bug: angleproject:3100
Change-Id: I1e48f5df5e40caf49a4d07662aec587e98cf8388
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1677206
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
beb0eb2d
|
2019-06-14T15:10:33
|
|
Clean up workarounds/features to single location.
Rename all workarounds structs to features, and move the lists to a
shared location in include/platform (to help with documentation,
see:
https://cs.chromium.org/chromium/src/ui/gl/gl_switches.cc?sq=package:chromium&g=0&l=69)
Bug: angleproject:1621
Change-Id: I4069f08131db5e886047a007efb5d7764dfee5f2
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1660952
Commit-Queue: Jonah Ryan-Davis <jonahr@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
44462cd6
|
2019-05-27T17:12:21
|
|
D3D: Use the ProgramD3D::GetExecutableTask context for loading program binaries
ProgramD3D::GetExecutableTask is a d3d::Context type itself so that errors can
be recorded in a thread-safe maner. Use the task context when loading program
binaries in ProgramD3D.
Fix up incorrect casts in RendererD3D::loadExecutable in both D3D9 and D3D11
backends to stop incorrectly assuming the context type.
BUG=962439
Change-Id: I5b29372a7254f709e1bbb67ee322ef4109f73e48
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1630294
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Jonah Ryan-Davis <jonahr@google.com>
Commit-Queue: Geoff Lang <geofflang@chromium.org>
|
|
216f73d0
|
2019-04-12T13:32:30
|
|
Vulkan: add uniform buffer object support
Support for layout qualifiers in interface blocks are added. All
interface blocks are adjusted to either be in std140 or std430.
In the Vulkan backend, a new descriptor set is added for UBOs. A dirty
bit is added for UBO updating and pipeline layouts and descriptor
bindings are updated.
Bug: angleproject:3199, angleproject:3220
Change-Id: I271fc34ac2e1e8b76dee75e54a7cff0fe15fe4ee
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1565061
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
8ba78da0
|
2019-04-30T23:42:31
|
|
add support for EXT_blend_func_extended to D3D11
Change-Id: Id66868851a490d0a68a7e76280720825c4844a45
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1591192
Commit-Queue: Geoff Lang <geofflang@chromium.org>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
|
|
89899748
|
2019-01-16T08:32:25
|
|
ParallelCompile: D3D compute
This parallelizes the compiling and linking for compute shaders on
the D3D backend.
Bug: chromium:849576
Change-Id: Idd6b418cb9c2448209c15eab2756599f8ff7af4c
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1415725
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Commit-Queue: Jie A Chen <jie.a.chen@intel.com>
|
|
eaf56133
|
2019-03-13T12:56:49
|
|
gl_VertexID is incorrect if offset argument to glDrawArrays is non-zero
On D3D the vertex ID is always indexed from 0, unlike GL. The D3D
backend had assumed the wrong behavior. This forwards the true offset to
D3D by using the ConstantsBuffer.
Bug: angleproject:3090
Change-Id: Ia19e3490503c97541af14979b75af0c94c67ab6b
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1520988
Commit-Queue: Jonah Ryan-Davis <jonahr@google.com>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
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>
|
|
c1c9fb1b
|
2018-10-18T11:41:50
|
|
ES31: Add atomic counter buffer support to D3D11 renderer
Adds support for atomic counters to the D3D11 renderer using UAV.
Bug: angleproject:1729
Test: angle_end2end_tests
Change-Id: I2904ba62644685b7d91f7475bd80a81ae414993b
Reviewed-on: https://chromium-review.googlesource.com/c/1451259
Commit-Queue: Geoff Lang <geofflang@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
|
|
465d6090
|
2019-01-02T16:21:18
|
|
Add GL_ANGLE_provoking_vertex on D3D11 and GL.
This extension is a subset of GL_ARB_provoking_vertex without the
QUADS_FOLLOW_PROVOKING_VERTEX_CONVENTION query.
Bug: angleproject:2829
Change-Id: I907a4d16b7b13d3bbfb948842091eedd7b6a8b77
Reviewed-on: https://chromium-review.googlesource.com/c/1410289
Commit-Queue: Geoff Lang <geofflang@chromium.org>
Reviewed-by: Jamie Madill <jmadill@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>
|
|
f3179a6a
|
2018-07-12T16:22:06
|
|
ES31: Implement bindImageTexture binds a single layer on D3D backend
Dynamically generate image2D variables' declaration and function
definition in libANGLE.
Bug: angleproject:1987
TEST=angle_end2end_tests.ComputeShaderTest.*
Change-Id: Idacc756f7bd15f22eccb1d689e18e997f3e74159
Reviewed-on: https://chromium-review.googlesource.com/c/1142885
Commit-Queue: Xinghua Cao <xinghua.cao@intel.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
a3b2e71f
|
2018-12-08T16:46:48
|
|
ES31: Support for GL_BUFFER_DATA_SIZE on GL_ATOMIC_COUNTER_BUFFER in D3D
This commit adds support for querying the GL_BUFFER_DATA_SIZE of
GL_ATOMIC_COUNTER_BUFFER in the D3D renderer.
Bug: angleproject:1729
Test: angle_end2end_tests
Change-Id: Id6aae0d92c5e0960b2b245ba7d83970b04ba4eed
Reviewed-on: https://chromium-review.googlesource.com/c/1399143
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Geoff Lang <geofflang@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>
|
|
8c78ce4b
|
2018-12-16T19:14:58
|
|
Use visitor pattern for Shader Variable APIs.
In many places in ANGLE we need to traverse a ShaderVariable tree. We
do this to store uniform offset and other information, to flatten the
tree of uniforms for the front-end, or to produce active variable lists
for uniform and shader storage blocks. In each case, we would write
separate tree traversal code.
This patch introduces a shared visitor pattern for all of the shader
variable tree traversal instances. With that get more common code. Also
it is easier to write new variable traversals. ProgramD3D and
ProgramLinkedResources in particular get nice simplificiations.
The visitor object recieves callbacks from the traversal when entering
structs, array elements, and new variables. The visitor can treat these
differently depending on the use case. A common visitor that constructs
full variable names is used as a base class in several places.
Also moves the 'isRowMajorLayout' from sh::InterfaceBlockField to
sh::ShaderVariable. This allows us to forgo using templates in several
call sites.
Bug: angleproject:3024
Change-Id: I472d81ec775e2eee92fb3d2eb0ca83860221ba2e
Reviewed-on: https://chromium-review.googlesource.com/c/1358722
Commit-Queue: Jamie Madill <jmadill@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>
|
|
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>
|
|
a602f906
|
2018-09-11T14:40:24
|
|
ES31: Support shader storage buffer in D3D-API side.
Bug: angleproject:1951
Test: angle_end2end_tests
Change-Id: I0d8a4f8cf00fc7fd2d85315138e2b7457fd0b90c
Reviewed-on: https://chromium-review.googlesource.com/1242846
Commit-Queue: Jiajia Qin <jiajia.qin@intel.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
6dfdca83
|
2018-08-03T17:10:55
|
|
ES31: support compute shader sampling on D3D backend
BUG=angleproject:2756
TEST=angle_end2end_tests.ComputeShaderTest.SamplingAndImageReadWrite/ES3_1_D3D11
Change-Id: I8f112227c5703fcaafffbd2262e6a039f869c483
Reviewed-on: https://chromium-review.googlesource.com/1161754
Commit-Queue: Xinghua Cao <xinghua.cao@intel.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Geoff Lang <geofflang@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>
|
|
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>
|
|
ec1fe5b7
|
2018-08-10T10:05:52
|
|
D3D: Use angle::Result error pattern.
This completes the refactor for the D3D9/D3D11 back-ends.
Bug: angleproject:2752
Change-Id: Ie35a925f75c902d8f9fdab6bc33b3bb9c937f85b
Reviewed-on: https://chromium-review.googlesource.com/1167209
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
|
|
b1565903
|
2018-07-27T08:12:48
|
|
D3D: Pass gl::Context to many more functions.
This makes the Context more available for logging errors.
Also includes more refactoring to VertexDataManager to ensure we can
access the gl::Context.
Bug: angleproject:2738
Change-Id: Iae3d22a1403078d236bfe63a3e2d203c13678dc4
Reviewed-on: https://chromium-review.googlesource.com/1151449
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Reviewed-by: Yuly Novikov <ynovikov@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
a914f7ff
|
2018-06-08T10:07:41
|
|
Use ShaderMap in Statemanager11 - Part II
This patch is the last patch of storing shader resources into
ShaderMap in Statemanager11.
This patch also splits several large functions into smaller
one to make the code structure clearer.
BUG=angleproject:2169
Change-Id: Id6d89976de0376b2479bd11d7551fc6f5b521c13
Reviewed-on: https://chromium-review.googlesource.com/1092511
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Commit-Queue: Jiawei Shao <jiawei.shao@intel.com>
|
|
6b600645
|
2018-05-31T14:53:31
|
|
D3D11: Micro-optimize StateManager11::updateState.
This inlines several accessors.
Bug: angleproject:2574
Change-Id: I61d223dd2a8f08e5331ccefde02e6ce55f5a607d
Reviewed-on: https://chromium-review.googlesource.com/1067118
Reviewed-by: Yuly Novikov <ynovikov@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
4166f014
|
2018-05-31T14:53:30
|
|
D3D11: Optimize Renderer11::drawArrays.
Uses inlining and more efficient computation re-use to streamline this
function.
Bug: angleproject:2575
Change-Id: Ib13e32811f56ec9a010ed66f298d4235e5c6807d
Reviewed-on: https://chromium-review.googlesource.com/1067120
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
46bcea50
|
2018-05-31T09:48:36
|
|
D3D,Vulkan: Prep work to share useful functions from D3D
- Refactor and move some functions used by D3D that are not really
renderer specific to be used by the Vulkan implementation to support
setting matx uniforms.
Bug: angleproject:2581
Change-Id: Ib37ddf4fc62bb8ecb3629893a24969e1f515795b
Reviewed-on: https://chromium-review.googlesource.com/1079845
Commit-Queue: Luc Ferron <lucferron@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
|
|
04796cda
|
2018-05-24T19:52:16
|
|
Remove gl::PrimitiveType.
This replaces the usages with gl::PrimitiveMode. Also replaces
the ProgramD3D Geometry Shader executable storage with a
PackedEnumMap.
Bug: angleproject:2574
Change-Id: I476dd2ba92d6267b9ea2bb9a37ee15fb6a91e627
Reviewed-on: https://chromium-review.googlesource.com/1067115
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Yuly Novikov <ynovikov@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>
|
|
467c15f9
|
2018-04-24T15:04:26
|
|
Use ShaderMap in ProgramD3D - Part II
This patch refactors ProgramD3D by storing all shader information
into ShaderMap to simplify the code structure.
This patch also fixes a bug on getting the number of maximum uniform
blocks.
BUG=angleproject:2169
Change-Id: I5b9fbfd70a18f8731ce19efed0df88037d495389
Reviewed-on: https://chromium-review.googlesource.com/1024749
Commit-Queue: Jiawei Shao <jiawei.shao@intel.com>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
|
|
af2b33be
|
2018-04-19T10:01:52
|
|
Use ShaderMap in ProgramD3D - Part I
This patch is the first part of using ShaderMap to contain shader
information in ProgramD3D, including the refactoring on struct
D3DUniform, D3DUniformBlock and ProgramD3DMetadata.
In the next patch all shader information in class ProgramD3D will
be organized in the form of ShaderMap.
BUG=angleproject:2169
Change-Id: I27008169dbf6cd8017a67f36f474667feddbd1f6
Reviewed-on: https://chromium-review.googlesource.com/1018728
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
|
|
3dd8d291
|
2018-03-30T09:39:09
|
|
Use ShaderBitSet for active use bits on uniforms
BUG=angleproject:2169
Change-Id: I192c2e3c453540c8a6d7b0d066218ea3c9fbaab2
Reviewed-on: https://chromium-review.googlesource.com/989411
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Geoff Lang <geofflang@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>
|
|
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>
|
|
26143fdd
|
2017-11-01T18:19:05
|
|
ES31: Support bindImageTexture on Texture2D for compute shaders on D3D
BUG=angleproject:1987
TEST=angle_end2end_tests
Change-Id: I3b0afb441a41dbd7f204b1d1bba7884c8d203ce1
Reviewed-on: https://chromium-review.googlesource.com/749004
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
37584b36
|
2017-12-01T11:04:03
|
|
Refactor: replace SamplerType with ShaderType
BUG=angleproject:1987
Change-Id: I189e1606bd966eb369e8192a6866c8e90810e937
Reviewed-on: https://chromium-review.googlesource.com/802956
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Yunchao He <yunchao.he@intel.com>
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>
|
|
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>
|
|
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>
|
|
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>
|
|
211bff3f
|
2017-10-10T23:53:20
|
|
Enable inconsistent-missing-override for Clang
Fix the resulting compile errors.
No-Try: true
Change-Id: I88e74f240b29ecf7b3883b0c5880dcb871e4c3cd
Reviewed-on: https://chromium-review.googlesource.com/710415
Commit-Queue: Ben Wagner <benjaminwagner@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
|
|
80823cc8
|
2017-09-14T15:46:21
|
|
D3D: Add memcmp filtering for matrix uniforms.
This was already implemented, it simply hooks it up to the
rest of the code. Could improve performance on some badly
behaved benchmarks.
BUG=angleproject:1390
Change-Id: I539df611d51ca085712fa8022bf8a7c1990afc65
Reviewed-on: https://chromium-review.googlesource.com/663896
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Reviewed-by: Yuly Novikov <ynovikov@chromium.org>
|
|
4148fd74
|
2017-09-14T15:46:20
|
|
Add separate dirty bits for Pixel and Fragment uniforms.
Also use a single UpdateSubresource call to update the buffer.
Should improve performance on some benchmarks.
BUG=angleproject:1390
Change-Id: I70d54d86d3d3beb0e2caee86338ee03081070ac8
Reviewed-on: https://chromium-review.googlesource.com/663895
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
c9fed8dd
|
2017-09-12T15:23:00
|
|
D3D11: Move TF state management to StateManager11.
This also changes the dirty TF object to use a Serial, which is more
secure for very edge-care reallocation issues. It also moves the
StateManager11::updateState call to be the very first thing that
happens in a draw call. This prepares the back-end for making the
state sync actually happen in Context11::syncState, instead of
inside the draw call.
Also moves a bit more TF management code out of RendererD3D and
Renderer9.
BUG=angleproject:2052
Change-Id: I93d033a07be2049023111975a31637c53893e8c8
Reviewed-on: https://chromium-review.googlesource.com/659229
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
d63961d0
|
2017-09-12T15:22:57
|
|
D3D11: Move Constant Buffer state to StateManager11.
Also moves the logic of the constant buffer sync to
StateManager11. Removes a few of the remaining virtual methods in
RendererD3D.
BUG=angleproject:1390
BUG=angleproject:2052
Change-Id: Ia6c1c3949fff84323331510d80bbfb6e1665d294
Reviewed-on: https://chromium-review.googlesource.com/659226
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
|
|
9d815378
|
2017-09-09T23:32:54
|
|
D3D: Refactor driver uniform application.
This is a preparation for more dirty bits. It moves the driver
constant buffer application into the state manager, redesigns
how the dirtiness is tracked (no more memcmp) and also removes
a couple of virtual calls.
BUG=angleproject:1390
BUG=angleproject:2052
Change-Id: I41a75c280600ad8ba1f23c721d436214a116422a
Reviewed-on: https://chromium-review.googlesource.com/659223
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
|
|
33bb7c42
|
2017-09-09T23:32:51
|
|
ProgramD3D: Use more UniformTypeInfo.
Instead of storing a type GLenum, store a pointer into the type info
table. This makes looking up some values a bit easier.
Also includes some micro-optimizations.
Improves the score of the uniforms micro-benchmark by about 12.4% on
a local Windows 10 machine.
BUG=angleproject:1390
Change-Id: I35f7f1c7bb3cf2c62d737b494dc56ff61ea2d1fb
Reviewed-on: https://chromium-review.googlesource.com/659221
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
|
|
0e7f1736
|
2017-09-09T23:32:50
|
|
D3D: Only scan cached shader executable lists once.
Any time we would query ProgramD3D for a particular vertex or pixel
shader, we would iterate over all the cached shaders of the program
looking for the matching input or output layout signature. This change
makes it so we only compute the index of the matching shader once,
and subsequent calls will re-use the shader index. This should speed
up the draw call benchmarks.
Also include a fix to the Serial class that initializes a Serial value
to an invalid sentinel value. This ensures that comparing any other
Serial (including another invalid serial) to the invalid serial will
return not-equals.
BUG=angleproject:1155
Change-Id: I7d913bf08d0bedf6155eae0661b2a5fa94565cc9
Reviewed-on: https://chromium-review.googlesource.com/648730
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
|
|
af4ffe0a
|
2017-09-09T23:32:48
|
|
D3D11: Implement dirty bits for texture updates.
BUG=angleproject:1387
Change-Id: I5f759c3dc60b53a5d4f8a1dd1f4a1d3d5330bfda
Reviewed-on: https://chromium-review.googlesource.com/648487
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
|
|
c1d4e550
|
2017-08-21T12:01:10
|
|
D3D11: Select view in vertex shader
View selection can happen in the vertex shader through the optional
feature VPAndRTArrayIndexFromAnyShaderFeedingRasterizer.
BUG=angleproject:2062
TEST=angle_end2end_tests
Change-Id: Iaf65685e04f828b0936295fea867f6f6cbe69bee
Reviewed-on: https://chromium-review.googlesource.com/628419
Commit-Queue: Martin Radev <mradev@nvidia.com>
Reviewed-by: 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>
|
|
561ed3ae
|
2017-08-31T16:48:09
|
|
D3D: Keep a single dirty bit for uniforms.
This simplifies uniform management in D3D11. It will also facilitate
further optimizations.
Improves performance in a uniforms stress test by ~13% on a test
machine. (UniformsBenchmark.Run/d3d11_null_400_vec4)
BUG=angleproject:1390
Change-Id: Iba2c15d420396aa8fb4e8c451cba2b4dde7b4b77
Reviewed-on: https://chromium-review.googlesource.com/623930
Reviewed-by: Geoff Lang <geofflang@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>
|
|
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>
|
|
41ac68e7
|
2017-06-06T12:16:58
|
|
Select viewport index in GS for multi-view instanced rendering
The patch extends the OutputHLSL and DynamicHLSL translators to
select the viewport index in the geometry shader and propagate
the ViewID variable to the fragment shader.
BUG=angleproject:2062
TEST=angle_end2end_tests
Change-Id: I9e344a7521e2e1137e6eb38d0bfecea8bece778f
Reviewed-on: https://chromium-review.googlesource.com/608967
Commit-Queue: Martin Radev <mradev@nvidia.com>
Reviewed-by: Olli Etuaho <oetuaho@nvidia.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
|
|
4c19a8a8
|
2017-07-24T11:46:06
|
|
D3D11: Update cached dynamically recompiled programs.
This change makes it so that when we need to recompile a program on a
draw call, we also update the cache. It also streamlines the internal
queries of the dynamic vertex and fragment shaders such that we only
update the input and output signatures a single time per draw. This
should also facilitate dirty bit implementations for the D3D11 back-
end.
BUG=angleproject:2116
Change-Id: Iccb0501b700bc894f40a8c68d7f297ff0c8f46bd
Reviewed-on: https://chromium-review.googlesource.com/531798
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
a779b610
|
2017-07-24T11:46:05
|
|
Smart caching of VAO input layout.
Don't recompute the cached attribute layout for a program if the
vertex array info hasn't changed. We can use the Serial class to
know when a vertex array has identical state.
BUG=angleproject:1156
Change-Id: Ia11f6ac268f63c3299f6d6d80c2866009cb8429c
Reviewed-on: https://chromium-review.googlesource.com/529768
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
27a60631
|
2017-06-30T15:12:01
|
|
Re-apply UBO binding workaround on program save.
The workaround which was previously defined to only apply on load
also seems to affect save on some AMD drivers.
BUG=angleproject:1637
BUG=angleproject:1897
Change-Id: Ia01a1420a484f3c2682ce97eaab18baccfb66a50
Reviewed-on: https://chromium-review.googlesource.com/558008
Reviewed-by: Yuly Novikov <ynovikov@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
|
|
db9e5d31
|
2017-06-12T12:05:45
|
|
D3D11: Only apply attachments that are written by the program
This works around a bug in the AMD driver that writes 0's to the
first attachment if it isn't written by the pixel shader.
BUG=angleproject:2048
Change-Id: I384fd60c0e0a37fbc0fd7b69fe1ec74fe4ffac8f
Reviewed-on: https://chromium-review.googlesource.com/531630
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
|
|
9cf9e871
|
2017-06-05T12:59:25
|
|
Move LinkResult to the gl:: namespace.
This is a derived type from gl::Error so makes sense to be there.
Also makes it more accessible than in ProgramImpl.h
BUG=angleproject:1897
Change-Id: Id41b13e5a072745d8c361057f5bef8f152e0452b
Reviewed-on: https://chromium-review.googlesource.com/522872
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
83418fb1
|
2017-06-05T12:59:24
|
|
Don't allow for error in ProgramImpl::save.
Refactoring cleanup patch only.
BUG=angleproject:1897
Change-Id: I6d12de5dab16ead9684886a1cf15b570e3c98156
Reviewed-on: https://chromium-review.googlesource.com/522871
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
bd044ed8
|
2017-06-05T12:59:21
|
|
Defer shader compiles when possible.
When using the program binary memory cache inside ANGLE, this will
give a potential fast path. If the user doesn't query the shader
compile status or info log before calling LinkProgram, then we can
check the program cache before translating the program, and if it
finds a hit, we don't even need to call the translator.
To preserve the shader settings at compile time, a reference to the
current shader translator is kept in a binding pointer on the call
to compile. This mirrors a similar implementation in Chromium's
command buffer. Also the compile options and source are cached at
compile to preserve the correct shader state.
BUG=angleproject:1897
Change-Id: I3c046d7ac8c3b5c8cc169c4802ffe47f95537212
Reviewed-on: https://chromium-review.googlesource.com/517379
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
c564c070
|
2017-06-01T12:45:42
|
|
Pass gl::Context to impl methods instead of ContextImpl.
In some cases we might have to call back into the GL layer, passing
the Context, and if we just have a ContextImpl pointer this isn't
possible. It also removes the need for SafeGetImpl.
BUG=angleproject:2044
Change-Id: I6363e84b25648c992c25779d4c43f795aa2866d6
Reviewed-on: https://chromium-review.googlesource.com/516835
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
bdc1e2a2
|
2017-05-24T14:40:27
|
|
D3D11: Consolidate Buffer allocation.
We now allocate and release all buffer resources from a single place,
allowing us to allocate junk memory, clear on init, and track the
currently allocated buffer memory.
BUG=angleproject:2034
Change-Id: Id60b63a7f77bc369dfc494a7587ab06c8d34a8e2
Reviewed-on: https://chromium-review.googlesource.com/503253
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
73badc07
|
2017-03-29T19:14:53
|
|
ES31: Implement glDispatchCompute for D3D backend
BUG=angleproject:1955
TESTCASE=angle_end2end_tests
Change-Id: I69b4df83d67017d39df67753d6d17fc15ececebf
Reviewed-on: https://chromium-review.googlesource.com/462067
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
aa7203ef
|
2017-05-03T23:32:29
|
|
Inherit privately from angle::NonCopyable.
Make all inheritance from angle::NonCopyable private so the compiler
complains about this (admittedly unlikely) code:
class Foo: angle::NonCopyable {
virtual ~Foo() { ... }
};
angle::NonCopyable *p = new Foo;
delete p;
In the above code ~Foo() is not called, only ~NonCopyable(), because the
latter is not virtual. Making it virtual would add overhead to all derived
classes which don't already have a virtual method.
Also tighten access in NonCopyable, because we can.
BUG=angleproject:2026
Change-Id: Id0dc4d959cfb7bb82cf49382118129abb1d3a4f0
Reviewed-on: https://chromium-review.googlesource.com/495352
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Frank Henigman <fjhenigman@chromium.org>
|
|
61afff14
|
2017-03-14T15:34:03
|
|
ES31: Add PROGRAM_SEPARABLE to ProgramParameter and GetProgram
BUG=angleproject:1939
TEST=angle_end2end_tests
Change-Id: I97ad11360f7c015947a2c0cc7d4a47f994726834
Reviewed-on: https://chromium-review.googlesource.com/454264
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
|
|
8ecf7f9b
|
2017-01-13T17:29:52
|
|
Vulkan: Implement shader compilation.
This hooks up the Vulkan GLSL, decorated with locations, to glslang,
and then pipes the SPIRV back to the Program implementation for later
use when making pipelines to run draw calls.
The program compilation tests work now, but don't really test
anything other than not generating Vulkan validation layer errors
during compilation and shader object generation.
BUG=angleproject:1576
Change-Id: I625e42219f4b4d1433dd3109b94e1a2f666ba4bd
Reviewed-on: https://chromium-review.googlesource.com/408519
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
|
|
b123938d
|
2016-12-13T15:07:05
|
|
D3D11: Add support to compile and link compute shaders
This is a reland of 2cd9d7e032fb412b539a907c58342060340387a1.
BUG=angleproject:1442
TEST=angle_end2end_tests
Change-Id: I5be0032b97617c31cdd4c66a823e8eb3b518867a
Reviewed-on: https://chromium-review.googlesource.com/430199
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
417df92f
|
2017-01-12T09:23:07
|
|
Revert "D3D11: Add support to compile and link compute shaders."
Fails https://build.chromium.org/p/chromium.gpu.fyi/builders/Linux%20Debug%20%28New%20Intel%29/builds/5769
BUG=angleproject:1442
This reverts commit 2cd9d7e032fb412b539a907c58342060340387a1.
Change-Id: Ic1610d20ba0449b423528fa9840aa951c012cf84
Reviewed-on: https://chromium-review.googlesource.com/427229
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|