|
6c1c3bd9
|
2020-10-09T11:46:04
|
|
Vulkan: Clear depth by shader if depthClamp not supported
This will avoid breaking the render pass when clearing depth through
clearWithDraw if the depthClamp Vulkan feature is not present.
Bug: angleproject:4836
Change-Id: I845fd5074dd95f6896da89f9e119ebc5000a5688
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2462719
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Charlie Lao <cclao@google.com>
|
|
6f521921
|
2020-08-24T11:29:33
|
|
Vulkan: Use one triangle for full-screen utils
In tiling GPUs, using two triangles means the tiles intersecting the
seam would be processed twice.
Bug: angleproject:4936
Change-Id: Ib10b77e6ab15bba932f0e4e970e10ed5a8399cdd
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2372623
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Courtney Goeltzenleuchter <courtneygo@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
f0b02054
|
2020-08-06T20:55:05
|
|
Add a Vulkan feature to compress float32 vertex formats.
Use the vertex conversion pipeline in VertexArrayVk to detect
static vertex data and convert float32 vertices to float16. This
feature is useful for determining if an allication is vertex
bandwidth bound and seeing what gains could be had by using smaller
attributes.
This feature could be implemented in ANGLE's frontend but new
infrastructure for converting and storing the converted attributes
would need to be added to gl::VertexArray. Our backends already
have the functionality needed to handle unsupported attribute formats
and this can be repurposed for compressing vertex formats.
Bug: b/167404532
Bug: b/161716126
Change-Id: I9a09656a72e8499faa4124adf876d7261c8341c9
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2342285
Commit-Queue: Geoff Lang <geofflang@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
|
|
0c25fbe3
|
2020-09-02T17:17:57
|
|
Vulkan: Remove accidental padding in push constants
Bug: chromium:1124379
Change-Id: I45f4511c836858c70d4dae23c7b3954e0bc65ab4
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2391616
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
|
|
8adc5469
|
2020-07-02T10:15:17
|
|
Vulkan: Generate mipmap in compute
An initial implementation based on AMD's FFX SPD (Single Pass
Downsampler).
Apart from requiring STORAGE_IMAGE support for the image format, the
following limitations are in place due to FFX SPD:
- Image must be 2D or 2D array (including cube maps)
- Image must be single-sampled
The following _can_ be supported, but not yet implemented:
- sRGB formats
- Integer formats
- depth/stencil formats
Bug: angleproject:4551
Change-Id: Ibc4d5cea701cca31e55e3d651540872bbd3b473f
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2278713
Reviewed-by: Mohan Maiya <m.maiya@samsung.com>
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
|
|
95bfb3e5
|
2020-07-08T23:07:48
|
|
Vulkan: Fix resolve draw path
If the draw path is taken for resolve, the internal shader previously
calculated (1+sum(sample.a))/sampleCount instead of
sum(sample.a)/sampleCount. Additionally, due to a typo, the result was
rounded.
This change also fixes a number of off-by-one errors when calculating
src/dst offsets in blit/resolve path.
Tests are added to resolve from default to FBO and vice versa to
exercise the draw path which was otherwise never invoked for color
buffers.
Bug: angleproject:4746
BUg: angleproject:4092
Change-Id: I4b9c181339b89af44b27d61d27a6b3d88cde2eea
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2288224
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Ian Elliott <ianelliott@google.com>
|
|
36a97db1
|
2020-07-02T23:29:45
|
|
Vulkan: Compress internal shaders
Shaves ~200KB in binary size. The compressed SPIR-V blobs are in most
cases a little smaller than 1/3 of the original size.
The internal shader blobs at this point take ~100KB.
Bug: angleproject:2022
Change-Id: I1a2cec073cb1f330632c8dce7a550a0cca1e373d
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2280945
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
d38c75c5
|
2020-07-02T22:12:19
|
|
Vulkan: Remove BufferUtils shader
This was the first internal shader written for prototyping UtilsVk. It
ended up never having a user.
Bug: angleproject:2022
Change-Id: I846dcc216c4c018f5bda16ad67463f698b8e1c56
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2280944
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
|
|
da3e6451
|
2020-06-25T23:49:22
|
|
Vulkan: Fix fbo_invalidate tests for pre-rotation
The BlitFramebuffer path wasn't properly supporting stencil and MSAA
paths for pre-rotation:
1) The stencil path on Android isn't going through
UtilsVk::blitResolveImpl, but requires changing
UtilsVk::stencilBlitResolveNoShaderExport for rotation.
2) MSAA resolves requires rotating clippedSourceArea.
Test: angle_deqp_gles3_tests --gtest_filter=dEQP.GLES3/functional_fbo_invalidate_\*
Bug: b/158337857
Change-Id: I092cab302c247ff9b2e262b12de3d1a56a257f8e
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2269499
Commit-Queue: Ian Elliott <ianelliott@google.com>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Courtney Goeltzenleuchter <courtneygo@google.com>
|
|
b067db75
|
2020-06-25T23:47:09
|
|
Vulkan: Fix copySubImageImplWithDraw() for pre-rotation
This involves cases of copying from a rotated default framebuffer.
Various adjustments are needed for where the source is and its
relationship to gl_FragCoord in the custom ImageCopy fragment
shaders. Various tests are affected, including the following:
Test: angle_deqp_gles2_tests --gtest_filter=dEQP.GLES2/functional_texture_specification_basic_copy*teximage2d_*
Test: angle_deqp_gles3_tests --gtest_filter=dEQP.GLES3/functional_texture_specification_basic_copy*teximage2d_*
Bug: b/158245571
Bug: b/157933235
Change-Id: Id9ec56d849cd2268954dd82623a7632a10fb8e8f
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2248204
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Courtney Goeltzenleuchter <courtneygo@google.com>
Commit-Queue: Ian Elliott <ianelliott@google.com>
|
|
6ee18c2d
|
2020-06-17T12:54:52
|
|
Vulkan: Remove debug symbols from internal shaders
Shaves ~47KB on binary size.
Bug: angleproject:2022
Change-Id: Ifc861c4308a806d17f499bf2126009a59125b9f2
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2249566
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
70e706f4
|
2020-06-22T18:14:44
|
|
Vulkan: Fix glBlitFramebuffer() for pre-rotation
This involves cases of blitting to/from a rotated default framebuffer,
potentially with scaling in one or both dimensions. Various
adjustments are needed at different times in the stack, including in
the custom BlitResolve fragment shaders. Various tests are affected,
including the following:
Test: angle_end2end_tests --gtest_filter=*EGLPreRotationLargeSurfaceTest.OrientedWindowWithBlitFramebuffer
Test: angle_deqp_gles3_tests --gtest_filter=dEQP.GLES3/functional_fbo_invalidate_\*
Bug: b/158337857
Change-Id: Ibb176e4215784e85c0f34e6e1c22ba662517fed2
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2242359
Reviewed-by: Ian Elliott <ianelliott@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Ian Elliott <ianelliott@google.com>
|
|
ce3d3413
|
2020-06-23T09:29:05
|
|
Update glslang_validator binary for Linux.
This binary was updated using update_glslang_binary.py.
Please see instructions in tools/glslang/README.md.
Bug: None
Change-Id: Ib1c3ae292a90ec6aabc79b9396ca2e35007edc16
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2260573
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
|
|
e7ae237e
|
2020-06-12T23:52:09
|
|
Vulkan: ANGLE_copy_texture_3d support
Bug: angleproject:4748
Test: CopyTexImage*Vulkan:Texture3DCopy*Vulkan:Texture2DArrayCopy*Vulkan
Test: dEQP.KHR_GLES3/copy_tex_image_conversions_required_cubemap*cubemap*
Change-Id: Ifdc3d455ca8c9e732d0adf4afa9e2809d780ae18
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2246320
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
b900f4e2
|
2020-06-12T16:01:58
|
|
Vulkan: Use GPU path for copy to sRGB textures
To avoid creating aliasing views for sRGB textures, the ImageCopy
texture will do/undo sRGB transformation such that the final result is
as-if both source and destination views were linear.
Possible future optimizations:
- If either of source or destination has already been created with the
MUTABLE flag, i.e. has a linear view already available, that can be
used.
- If destination is sRGB but not renderable while its corresponding
linear format is, and if the image is already created with the MUTABLE
flag, using the linear view would allow the copy to go through the GPU
instead of the CPU.
Bug: b/157934810
Bug: angleproject:4092
Change-Id: I43aaf882c90e1c60d0d9eb04636c203fc04090a4
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2241622
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Antonio Maiorano <amaiorano@google.com>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
|
|
ac44f8c5
|
2020-06-05T23:30:53
|
|
Vulkan: Apply SPIR-V optimization to internal shaders
Shaves about 40KB from binary size.
Bug: angleproject:2022
Bug: angleproject:3432
Change-Id: I008c18e0040b1bafe022087113681e2ace6eb7b8
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1616963
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
da980b40
|
2020-06-10T23:19:40
|
|
Vulkan: Reduce ConvertVertex.comp variations
Handling RGB10A2 and A2BGR10 formats are made through dynamic flags.
One or two `if` checks (based on format) is not worth doubling the
number of shaders.
Shaves about 50KB from binary size.
Bug: angleproject:2022
Bug: chromium:1084580
Change-Id: Ia603a935b66d002dbacdee9342950ceed4042f86
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2240672
Reviewed-by: Mohan Maiya <m.maiya@samsung.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
|
|
8a7b3d61
|
2020-06-08T23:23:56
|
|
Update glslang_validator binary for Linux.
This binary was updated using update_glslang_binary.py.
Please see instructions in tools/glslang/README.md.
Bug: None
Change-Id: I1aed97de25baa3cb47ae81b63a70339a962d957d
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2235361
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
|
|
98496cab
|
2020-05-28T15:02:43
|
|
Fix float to int copy in VK backend
This fixes WebGL tests on Vulkan (e.g. SwiftShaderVK) that copy from the
canvas (GL_RGBA8) to an integer format target texture, such as:
conformance2/textures/canvas_sub_rectangle/tex-2d-rg8ui-rg_integer-unsigned_byte.html
The sampled normalized value needs to be scaled up by 255.
Also fixes angle_end2end test CopyTextureTestES3.ES3UintFormats on
Vulkan.
Bug: b/156399229
Bug: angleproject:4092
Change-Id: I18d46bc4453fdc500caca96ca3a12fe93290b10c
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2219142
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Commit-Queue: Antonio Maiorano <amaiorano@google.com>
|
|
f8b28678
|
2020-02-26T19:12:39
|
|
Vulkan: Add support for VK_EXT_index_type_uint8
Enable VK_EXT_index_type_uint8 Vulkan extension if supported by
VkDevice.
Bug: angleproject:4405
Change-Id: I84d030497898c5944a36d9a88a31e7377ccd5e9e
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2082391
Commit-Queue: Xiaoxuan Liu <xiaoxuan.liu@arm.com>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
82219d28
|
2019-11-26T10:17:11
|
|
Vulkan: fix alpha values in convert vertex shader
When reading vertex attributes, GLES requires the y and z components to
be filled with 0 if missing, and the alpha channel to be filled with 1.0
for float types and 1 for integer types.
At the same time, this change reduces the number of variations in this
shader.
Bug: angleproject:3192
Change-Id: I1bdf491952c296962fa9160f2d29d415eb3d570d
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1936708
Reviewed-by: Jaedon Lee <jaedon1.lee@samsung.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
|
|
b066177a
|
2019-11-19T15:13:20
|
|
Vulkan: Remove duplicate shader variation
ConvertVertex's UintToUint and HalfFloatToHalfFloat were generating
identical shaders.
Bug: angleproject:3802
Change-Id: I8eb2d55debbc5501f191830a2723b02d0d1f0827
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1925248
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Hyunchang Kim <hckim.kim@samsung.com>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
|
|
7f418fc2
|
2019-10-01T07:56:53
|
|
Vulkan: lineloop support for DrawArrayIndirect
Add support for lineloops.
Includes a compute shader for generating an index
buffer to draw lineloop.
Instancing turns out to be a special case for indirect draws if we
have vertex attributes that need to be emulated (e.g. divisor too
large or native vertex format not available).
Test: dEQP.GLES31/functional_draw_indirect_*
angle_end2end_tests --gtest_filter=LineLoopIndirectTest.*/*
dEQP.GLES3/functional_draw_*
Bug: angleproject:3564
Change-Id: I1fdabe2c8a690c8b6df9e252e1e839e08796bcca
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1834682
Commit-Queue: Courtney Goeltzenleuchter <courtneygo@google.com>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
|
|
1850492e
|
2019-10-02T08:23:03
|
|
Vulkan: Disable OES_vertex_type_10_10_10_2 on GLES 2.0
- Because of the difference in the SNORM to FLOAT conversion formula
between GLES 2.0 and 3.0, OES_vertex_type_10_10_10_2 is disabled
when the context version is lower than 3.0.
- Modify test conversion formula to be compliant with GLES 3.0 equation
Bug: angleproject:3868
Test: angle_end2end_tests --gtest_filter=VertexAttributeTest*Packed*Vulkan
Change-Id: I8b85d8146ee05353bc40fa0022f05d6634c33110
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1792197
Commit-Queue: Mohan Maiya <m.maiya@samsung.com>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
f03259ad
|
2019-09-19T11:31:40
|
|
Vulkan: lineloop support for DrawElementsIndirect
Add support for lineloops.
Includes a compute shader for converting lineloop index
buffer with optional restart into linestrip.
Test:
dEQP.GLES31/functional_draw_indirect_*
angle_end2end_tests --gtest_filter=LineLoopIndirectTest.*/*
Bug: angleproject:3564
Change-Id: I12d08db1c8d99867f0611e53be50193647695260
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1797106
Commit-Queue: Courtney Goeltzenleuchter <courtneygo@google.com>
Reviewed-by: Tobin Ehlis <tobine@google.com>
|
|
3c2a5230
|
2019-09-23T11:07:18
|
|
Vulkan: 8bit index support for DrawElementsIndirect
Add partial support for DrawElementsIndirect.
This supports all primitives types except lineloop.
Includes a compute shader for converting 8bit index
buffers to 16bit index buffers where the index buffer range
is defined in a GPU buffer.
Test:
dEQP.GLES31/functional_draw_indirect_*
Bug: angleproject:3564
Change-Id: Ibe9c55323e46a398f0b703cd8597a72ba6790570
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1792948
Commit-Queue: Courtney Goeltzenleuchter <courtneygo@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
d4c75347
|
2019-09-18T10:49:34
|
|
Vulkan: Enable GPU conversion from RGB16F to RGBA16F
- Add proper GPU conversion routine when the source and destination
format of vertex attribute is half float data type.
- Add an end2end test which utilizes half float GPU conversion path.
Bug: angleproject:3802
Test: angle_end2end_tests --gtest_filter=*VertexAttributeTest.HalfFloatBuffer*
Change-Id: Ia88a4984156f8967796bea3852c3cde714f2acab
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1824799
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Commit-Queue: Mohan Maiya <m.maiya@samsung.com>
|
|
fea65766
|
2019-09-19T09:30:38
|
|
Vulkan: Add support for OES_vertex_type_10_10_10_2
- Add support to CPU/GPU convert vertex formats
- Add test cases for type conversion in angle_end2end_tests
- Fix a bug in shader script by adding a ceil when calculating bytes
Bug: angleproject:3192
Test: angle_end2end_tests --gtest_filter=VertexAttributeTest*Packed1010102*
Change-Id: I57bab9fc1c1041cd734746d0e52a33717b635ec0
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1788495
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Commit-Queue: Mohan Maiya <m.maiya@samsung.com>
|
|
050b124d
|
2019-06-30T03:26:18
|
|
Reland "Vulkan: Debug overlay"
This is a reland of e54d0f90d1a165404236fd7abd1b05ddd041a686
This was reverted due to a build failure as a result of a missing
virtual destructor in the widget base class.
Original change's description:
> Vulkan: Debug overlay
>
> A debug overlay system for the Vulkan backend designed with efficiency
> and runtime configurability in mind. Overlay widgets are of two
> fundamental types:
>
> - Text widgets: A single line of text with small, medium or large font.
> - Graph widgets: A bar graph of data.
>
> Built on these, various overlay widget types are defined that gather
> statistics. Five such types are defined with one widget per type as
> example:
>
> - Count: A widget that counts something. VulkanValidationMessageCount
> is an overlay widget of this type that shows the number of validation
> messages received from the validation layers.
> - Text: A generic text. VulkanLastValidationMessage is an overlay
> widget of this type that shows the last validation message.
> - PerSecond: A value that gets reset every second automatically. FPS is
> an overlay widget of this type that simply gets incremented on every
> swap().
> - RunningGraph: A graph of last N values. VulkanCommandGraphSize is an
> overlay of this type. On every vkQueueSubmit, the number of nodes in
> the command graph is accumulated. On every present(), the value is
> taken as the number of nodes for the whole duration of the frame.
> - RunningHistogram: A histogram of last N values. Input values are in
> the [0, 1] range and they are ranked to N buckets for histogram
> calculation. VulkanSecondaryCommandBufferPoolWaste is an overlay
> widget of this type. On vkQueueSubmit, the memory waste from command
> buffer pool allocations is recorded in the histogram.
>
> Overlay font is placed in libANGLE/overlay/ which gen_overlay_fonts.py
> processes to create an array of bits, which is processed at runtime to
> create the actual font image (an image with 3 layers).
>
> The overlay widget layout is defined in overlay_widgets.json which
> gen_overlay_widgets.py processes to generate an array of widgetss, each
> of its respective type, and sets their properties, such as color and
> bounding box. The json file allows widgets to align against other
> widgets as well as against the framebuffer edges.
>
> Two compute shaders are implemented to efficiently render the UI:
>
> - OverlayCull: This shader creates a bitset of Text and Graph widgets
> whose bounding boxes intersect a corresponding subgroup processed by
> OverlayDraw. This is done only when the enabled overlay widgets are
> changed (a feature that is not yet implemented) or the surface is
> resized.
> - OverlayDraw: Using the bitsets generated by OverlayCull, values that
> are uniform for each workgroup (set to be equal to hardware subgroup
> size), this shader loops over enabled widgets that can possibly
> intersect the pixel being processed and renders and blends in texts
> and graphs. This is done once per frame on present().
>
> Currently, to enable overlay widgets an environment variable is used.
> For example:
>
> $ export ANGLE_OVERLAY=FPS:VulkanSecondaryCommandBufferPoolWaste
> $ ./hello_triangle --use-angle=vulkan
>
> Possible future work:
>
> - On Android, add settings in developer options and enable widgets based
> on those.
> - Spawn a small server in ANGLE and write an application that sends
> enable/disable commands remotely.
> - Implement overlay for other backends.
>
> Bug: angleproject:3757
> Change-Id: If9c6974d1935c18f460ec569e79b41188bd7afcc
> Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1729440
> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Bug: angleproject:3757
Change-Id: I47915d88b37b6f882c686c2de13fca309a10b572
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1780897
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
|
|
fc58af47
|
2019-09-02T07:46:44
|
|
Revert "Vulkan: Debug overlay"
This reverts commit e54d0f90d1a165404236fd7abd1b05ddd041a686.
Reason for revert: causes compile failure on Linux CFI bot.
Sample build: https://ci.chromium.org/p/chromium/builders/ci/Linux%20CFI/14810
Sample log: https://logs.chromium.org/logs/chromium/buildbucket/cr-buildbucket.appspot.com/8903575125463586160/+/steps/compile/0/stdout?format=raw
Original change's description:
> Vulkan: Debug overlay
>
> A debug overlay system for the Vulkan backend designed with efficiency
> and runtime configurability in mind. Overlay widgets are of two
> fundamental types:
>
> - Text widgets: A single line of text with small, medium or large font.
> - Graph widgets: A bar graph of data.
>
> Built on these, various overlay widget types are defined that gather
> statistics. Five such types are defined with one widget per type as
> example:
>
> - Count: A widget that counts something. VulkanValidationMessageCount
> is an overlay widget of this type that shows the number of validation
> messages received from the validation layers.
> - Text: A generic text. VulkanLastValidationMessage is an overlay
> widget of this type that shows the last validation message.
> - PerSecond: A value that gets reset every second automatically. FPS is
> an overlay widget of this type that simply gets incremented on every
> swap().
> - RunningGraph: A graph of last N values. VulkanCommandGraphSize is an
> overlay of this type. On every vkQueueSubmit, the number of nodes in
> the command graph is accumulated. On every present(), the value is
> taken as the number of nodes for the whole duration of the frame.
> - RunningHistogram: A histogram of last N values. Input values are in
> the [0, 1] range and they are ranked to N buckets for histogram
> calculation. VulkanSecondaryCommandBufferPoolWaste is an overlay
> widget of this type. On vkQueueSubmit, the memory waste from command
> buffer pool allocations is recorded in the histogram.
>
> Overlay font is placed in libANGLE/overlay/ which gen_overlay_fonts.py
> processes to create an array of bits, which is processed at runtime to
> create the actual font image (an image with 3 layers).
>
> The overlay widget layout is defined in overlay_widgets.json which
> gen_overlay_widgets.py processes to generate an array of widgetss, each
> of its respective type, and sets their properties, such as color and
> bounding box. The json file allows widgets to align against other
> widgets as well as against the framebuffer edges.
>
> Two compute shaders are implemented to efficiently render the UI:
>
> - OverlayCull: This shader creates a bitset of Text and Graph widgets
> whose bounding boxes intersect a corresponding subgroup processed by
> OverlayDraw. This is done only when the enabled overlay widgets are
> changed (a feature that is not yet implemented) or the surface is
> resized.
> - OverlayDraw: Using the bitsets generated by OverlayCull, values that
> are uniform for each workgroup (set to be equal to hardware subgroup
> size), this shader loops over enabled widgets that can possibly
> intersect the pixel being processed and renders and blends in texts
> and graphs. This is done once per frame on present().
>
> Currently, to enable overlay widgets an environment variable is used.
> For example:
>
> $ export ANGLE_OVERLAY=FPS:VulkanSecondaryCommandBufferPoolWaste
> $ ./hello_triangle --use-angle=vulkan
>
> Possible future work:
>
> - On Android, add settings in developer options and enable widgets based
> on those.
> - Spawn a small server in ANGLE and write an application that sends
> enable/disable commands remotely.
> - Implement overlay for other backends.
>
> Bug: angleproject:3757
> Change-Id: If9c6974d1935c18f460ec569e79b41188bd7afcc
> Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1729440
> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
> Reviewed-by: Jamie Madill <jmadill@chromium.org>
TBR=geofflang@chromium.org,syoussefi@chromium.org,jmadill@chromium.org
Bug: angleproject:3757
Change-Id: Ib08e2e7b1a9449ca097673acb11655df5d2bbf31
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1778862
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
|
|
e54d0f90
|
2019-06-30T03:26:18
|
|
Vulkan: Debug overlay
A debug overlay system for the Vulkan backend designed with efficiency
and runtime configurability in mind. Overlay widgets are of two
fundamental types:
- Text widgets: A single line of text with small, medium or large font.
- Graph widgets: A bar graph of data.
Built on these, various overlay widget types are defined that gather
statistics. Five such types are defined with one widget per type as
example:
- Count: A widget that counts something. VulkanValidationMessageCount
is an overlay widget of this type that shows the number of validation
messages received from the validation layers.
- Text: A generic text. VulkanLastValidationMessage is an overlay
widget of this type that shows the last validation message.
- PerSecond: A value that gets reset every second automatically. FPS is
an overlay widget of this type that simply gets incremented on every
swap().
- RunningGraph: A graph of last N values. VulkanCommandGraphSize is an
overlay of this type. On every vkQueueSubmit, the number of nodes in
the command graph is accumulated. On every present(), the value is
taken as the number of nodes for the whole duration of the frame.
- RunningHistogram: A histogram of last N values. Input values are in
the [0, 1] range and they are ranked to N buckets for histogram
calculation. VulkanSecondaryCommandBufferPoolWaste is an overlay
widget of this type. On vkQueueSubmit, the memory waste from command
buffer pool allocations is recorded in the histogram.
Overlay font is placed in libANGLE/overlay/ which gen_overlay_fonts.py
processes to create an array of bits, which is processed at runtime to
create the actual font image (an image with 3 layers).
The overlay widget layout is defined in overlay_widgets.json which
gen_overlay_widgets.py processes to generate an array of widgetss, each
of its respective type, and sets their properties, such as color and
bounding box. The json file allows widgets to align against other
widgets as well as against the framebuffer edges.
Two compute shaders are implemented to efficiently render the UI:
- OverlayCull: This shader creates a bitset of Text and Graph widgets
whose bounding boxes intersect a corresponding subgroup processed by
OverlayDraw. This is done only when the enabled overlay widgets are
changed (a feature that is not yet implemented) or the surface is
resized.
- OverlayDraw: Using the bitsets generated by OverlayCull, values that
are uniform for each workgroup (set to be equal to hardware subgroup
size), this shader loops over enabled widgets that can possibly
intersect the pixel being processed and renders and blends in texts
and graphs. This is done once per frame on present().
Currently, to enable overlay widgets an environment variable is used.
For example:
$ export ANGLE_OVERLAY=FPS:VulkanSecondaryCommandBufferPoolWaste
$ ./hello_triangle --use-angle=vulkan
Possible future work:
- On Android, add settings in developer options and enable widgets based
on those.
- Spawn a small server in ANGLE and write an application that sends
enable/disable commands remotely.
- Implement overlay for other backends.
Bug: angleproject:3757
Change-Id: If9c6974d1935c18f460ec569e79b41188bd7afcc
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1729440
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
324b3915
|
2019-08-29T08:19:11
|
|
Vulkan: Fix compute shader bug affecting 10_10_10_2 formats
When the source format is 10_10_10_2, valueBits needs to be
"2" if the component is "3" i.e, the alpha channel. It was
incorrectly set to "10" for all components
Bug: angleproject:3866
Change-Id: If206c63d704a7a485681e483e12ae9ab611b0d99
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1775105
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Commit-Queue: Mohan Maiya <m.maiya@samsung.com>
|
|
0a3c8246
|
2019-08-15T13:24:20
|
|
Vulkan: Write preprocessed shaders with // instead of #if 0
Bug: 993965
Change-Id: I4fd357bdebc73b7256ae4b34bd1c6aa2f4418e27
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1756503
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
|
|
8400d05c
|
2019-08-07T14:52:54
|
|
Vulkan: Support the vertex_type_2_10_10_10_rev format
- Modify the python script and json file to generate the code which
adds the function for vertex_type_2_10_10_10_rev. These functions
handle the loading and conversion for vertex_type_2_10_10_10_rev.
- Modify ConvertVertex.comp and ConvertVertex.comp.json to perform
a GPU based conversion for vertex format of type 2_10_10_10_rev
- Modify BindingIsAligned function to check that both stride and
binding offset is aligned to the format size when the component
size is not aligned to 8 bits.
- Modify deqp3 expectations file to enable type_2_10_10_10_rev format
vertex array tests.
Bug: angleproject:3193
Test: dEQP-GLES3.functional.vertex_arrays.single_attribute.*2_10_10_10*
Change-Id: I2358d0d8888f7dfd7eac999dc150f643167de817
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1709035
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
765ee7b7
|
2019-06-19T14:19:52
|
|
Vulkan: support for new vertex attribs in GLES 3.0
Fixes handling of packed vertex formats, adds new overrides for 32-bit
[SU](NORM|SCALED) vertex types, and handles half-precision floats
correctly.
Pixel 2 does not natively support certain 10-10-10-2 vertex formats;
this change does not add support for them.
Test: ./angle_deqp_gles3_no_gtest --deqp-egl-display-type=angle-vulkan -n 'dEQP-GLES3.functional.vertex_arrays.*'
Test: ./angle_end2end_tests --gtest_filter='AttributeLayout*/ES3_Vulkan'
Test: ./angle_end2end_tests --gtest_filter='VertexAttribute*/ES3_Vulkan'
Bug: angleproject:3193
Change-Id: I5ae4edd743e86e3e89e2697034c04dc4d9ecd1f9
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1668230
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Tim Van Patten <timvp@google.com>
Commit-Queue: James Dong <dongja@google.com>
|
|
ee21a187
|
2019-07-04T08:51:34
|
|
Store angle::Format in gl::VertexAttribute.
Instead of storing type/size/normalized/pureInteger we instead store a
pointer to the angle::Format. This makes some code logic simpler and
will let us more easily check if a vertex attribute format changes in
calls to VertexAttribPointer or VertexAttribFormat.
This CL adds extra information to angle::Format to represent the vertex
format info needed. It also caches the channel count so that it can be
queried faster.
Also renames "Int" -> "Sint" in UtilsVk for consistency.
Bug: angleproject:3256
Change-Id: I5ef9b983dad8a58c341113c802500b89ce081566
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1684293
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Jonah Ryan-Davis <jonahr@google.com>
|
|
2806a898
|
2019-06-07T12:10:46
|
|
Vulkan: implement primitive restart
Implements ES 3.0 feature GL_PRIMITIVE_RESTART_FIXED_INDEX,
which allows the application to use a fixed "restart" index
to restart the primitive during a single draw call.
This change does't handle GL_LINE_LOOP primitives,
which requires a bit of special handling.
Bug: angleproject:3215
Change-Id: I2388852683fd17328a6a76c48d70a24d67ce8b67
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1650301
Reviewed-by: Courtney Goeltzenleuchter <courtneygo@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Courtney Goeltzenleuchter <courtneygo@google.com>
|
|
b407e1a0
|
2019-06-03T17:15:51
|
|
Vulkan: implement ES3 blit
Augment the resolve shaders to be able to stretch and blit too. The
UtilsVk resolve function is accordingly expanded to include blit.
Bug: angleproject:3200
Change-Id: I30b172a5e388089735ab494f55cbfdc2781a8bf9
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1635753
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
|
|
de70a713
|
2019-06-03T17:05:16
|
|
Vulkan: Rename Resolve* shaders to BlitResolve
In preparation for adding blit functionality.
Bug: angleproject:3200
Change-Id: I77b6b6cbe90b26ee23c25edebaa2b130f3c2987a
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1641626
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
5993d899
|
2019-06-03T13:05:38
|
|
Vulkan: Use storage buffers for index conversion shader.
This allows us to use the shader regardless of driver support for
texel buffer views. It also allows us to convert indices on the GPU
unconditionally.
We add a new internal compute shader that converts pairs of indices
into a packed single uint value that stores two 16-bit values. In the
future we could add support for converting primitive restart indices.
Should speed up benchmarks on systems which didn't have R8_UINT support
for compute shader buffers.
Bug: angleproject:3490
Change-Id: I56ca0cabb094e97f36ab4edc779e6c8ad2d2601e
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1639058
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Tim Van Patten <timvp@google.com>
|
|
6d9b8908
|
2019-05-29T13:18:31
|
|
Vulkan: Merge Color and Depth/Stencil resolve shaders
There is a good deal of overlap in the way these shaders calculate
offsets, flip etc. This change merges the two shaders together, as well
as the UtilsVk functions that invoke them.
This is in preparation for adding blit functionality to the same
shader.
Bug: angleproject:3200
Change-Id: Id7c2cf12e05db1802ae497766fb361fe4bef6479
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1635750
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Yuly Novikov <ynovikov@chromium.org>
|
|
172e5d37
|
2019-05-29T10:00:50
|
|
Vulkan: Implement universal stencil resolve
This is done by resolving stencil into a temporary buffer and copying
that into the stencil aspect of the resolved image.
Bug: angleproject:3200
Change-Id: I29111b44db2cb093acc4544034fbe61178f055a1
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1635709
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Tim Van Patten <timvp@google.com>
|
|
f2a1c384
|
2019-05-21T16:32:49
|
|
Vulkan: Implement multisampled framebuffers
Simultaneously implements ANGLE_framebuffer_multisample and ES3
multisampled framebuffers.
Additionally, implements ES3 framebuffer blitting where multisampled
framebuffers are involved.
Bug: angleproject:3203
Bug: angleproject:3204
Bug: angleproject:3200
Change-Id: I5694a30f71168e807688a9568e3742b81d907918
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1622667
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Yuly Novikov <ynovikov@chromium.org>
|
|
b86e73da
|
2019-05-21T10:23:23
|
|
Vulkan: Update glslang_validator binary for Linux
The new binary has the ability to optimize SPIR-V code.
Bug: angleproject:3432
Change-Id: I5953be6f207f153baaf2efe17380448aff374d60
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1620913
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
|
|
2249d4a7
|
2019-04-05T16:48:55
|
|
Vulkan: remove clear depth ability from clearWithDraw
This partially reverts the following change:
60ec8f576 Vulkan: break dependency to the depthClamp feature
The feature is no longer necessary, and simplifies the usage of
utility shaders.
Bug: angleproject:2361
Change-Id: I1e87ac8d2517c5a3b50e3d0cddd55c852e0e3e7d
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1555313
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Tobin Ehlis <tobine@google.com>
|
|
5d50678e
|
2019-04-06T15:04:03
|
|
Roll glslang forward 1240db678cae..e06c7e9a515b
Manual roll to unblock the autoroller stuck on presubmit failure.
Bug: None
Change-Id: I97094add66a42154309addea43fe6aa5e1411c43
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1556694
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
|
|
c7565353
|
2019-04-03T14:03:56
|
|
Vulkan: break dependency to the depthClamp feature
Image clear's masked clear path using a draw call was using this feature
to clear the depth buffer, but this feature is not available on ARM and
some Qualcomm devices.
This change adds a push constant to the vertex shader used in this call
to export the depth clear value, removing the need to rely on depth
clamping.
Bug: angleproject:3241
Change-Id: I565cd5f731c441820e0702e51dfdf02d0bc7de06
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1551522
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Tobin Ehlis <tobine@google.com>
|
|
43997017
|
2019-03-30T23:24:01
|
|
Vulkan: fix non-float clear with draw
Instead of using one draw call that clears all attachments, multiple
draw calls are issued that clear a single attachment each. This allows
us to have a manageable number of variations for the ImageClear.frag
shader, now that non-float format support is introduced.
Bug: angleproject:3187
Change-Id: Ic0c1067a396250bd80f31d00cad5a272acff8be8
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1545523
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
db4ed317
|
2019-03-29T00:32:45
|
|
Vulkan: glClearBuffer* implementation
Refactors FramebufferVk::clear such that specific render targets could
be cleared, with clear values not necessarily set through glClearColor
etc.
FramebufferVk::clearWithRenderPassOp is modified so that loadOp and
clear values are set after the render pass has been registered in the
graph. This allows multiple glClearBuffer calls to coalesce into the
same render pass.
glClearBuffer calls are then implemented simply as calls to the
refactored clear function with the appropriate parameters.
Bug: angleproject:3187
Change-Id: I2fdfcbea5bf244f63ec981b91caca47f5ee3cd3a
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1545204
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Tim Van Patten <timvp@google.com>
|
|
a532570a
|
2019-03-20T10:18:36
|
|
Vulkan: Cleanups to shader generation script.
Fixes the suprious newlines messages. Also prefer a Release directory
when writing shaders for performance. Also adds glslang's git HEAD to
the list of generated hashes. This should ensure we regenerate all
shaders when there's a roll of glslang.
Glslang was rolled prior to this CL. Also update the SPRI-V libs.
Bug: angleproject:3227
Change-Id: I1fd212a08000c08ef41b60c4201edd3ac771f91d
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1516512
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
4f3b207d
|
2019-01-01T14:48:25
|
|
Vulkan: Shader path for texture-to-texture copy
This change implements glCopy[Sub]TextureCHROMIUM in GPU. As with the
previous change implementing glCopyTex[Sub]Image2D, it currently only
selects the shader path if the texture is already defined.
Bug: angleproject:2958
Change-Id: Ia1b5625f92e6c9f91807c9b601e5c34d2d5e5c30
Reviewed-on: https://chromium-review.googlesource.com/c/1392394
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Yuly Novikov <ynovikov@chromium.org>
|
|
f83a28a6
|
2018-12-09T03:48:34
|
|
Vulkan: Shader path for framebuffer-to-texture copy
Part 1 in a series of changes to perform image copies on the GPU.
Bug: angleproject:2958
Change-Id: I6264a880865c4738c0866f2dc71af63425fc4118
Reviewed-on: https://chromium-review.googlesource.com/c/1370724
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
e321940c
|
2018-12-08T16:54:14
|
|
Vulkan: Move image clear functionality to UtilsVk
DispatchUtilsVk is renamed to UtilsVk and the functionality in
framebuffer's clearWithDraw() is moved to that class. Eventually, more
fragment-shader-based internal algorithms will be added to this class as
well.
Bug: angleproject:2958
Change-Id: I4753c9cb3288b59cd1ed60fe7a57b9f189704322
Reviewed-on: https://chromium-review.googlesource.com/c/1369284
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
611bbaab
|
2018-12-06T01:59:53
|
|
Vulkan: Convert vertex attributes in compute
In this commit, VertexArrayVk::convertVertexBuffer() is renamed to
VertexArrayVk::convertVertexBufferCpu() to explicitly show it does a CPU
readback. A new VertexArrayVk::convertVertexBuffer() function is added
that has the same functionality in gpu (with some assumptions, where the
CPU fallback is used should those assumptions fail). Currently, the
only requirement is that buffer offset/stride are divided by the
component size.
ConvertVertex.comp is the shader responsible for this conversion, and it
implements the functionality in renderer/copyvertex.inc, minus a few
functions that are not used in the Vulkan backend.
Bug: angleproject:2958, angleproject:3009
Change-Id: I8ec9a5f4672509bcf7b9e352cd27663970ad4653
Reviewed-on: https://chromium-review.googlesource.com/c/1364451
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Yuly Novikov <ynovikov@chromium.org>
|
|
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>
|
|
8f1b7a66
|
2018-11-14T16:02:54
|
|
Vulkan: Add DispatchUtilsVK
This class provides a set of compute-based internal utilities.
Currently, buffer clear and copy are implemented. Other possibilities
include more efficient mip map generation, or specialized texture
operations.
VertexArrayVk::updateIndexTranslation() is updated to convert the
GL_UNSIGNED_BYTE index buffer to a GL_UNSIGNED_SHORT one using this
class to avoid a CPU readback.
The vk::Format class is augmented with a few flags (IsInt, IsUnsigned)
to be able to select the appropriate shader based on the format (float,
int or uint).
Bug: angleproject:2958,angleproject:3003
Change-Id: Ie35519deb3c32a3da5ccf74080c70092c9287f0a
Reviewed-on: https://chromium-review.googlesource.com/c/1336307
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
df8c1053
|
2018-11-29T11:49:45
|
|
Vulkan: Uber-shader generated code optimization
Refactors code out of generated functions into a common function and
simplifies assertions.
Bug: angleproject:2958
Change-Id: I896c2304c3ac1e043c16f9ecf81fa8b72a6b87c0
Reviewed-on: https://chromium-review.googlesource.com/c/1355501
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
8dc27f99
|
2018-11-29T11:45:44
|
|
Use packed enum for DrawElementsType.
The packing and unpacking take a few extra instructions. But it
completely obviates the need for any switches in the validation code.
Speed is slightly faster or the similar depending on the back-end.
Also add gl_angle_ext.xml to GL entry point generator inputs. This was
missing and would cause the code generation to miss certain changes.
Bug: angleproject:2985
Change-Id: I1ea41a71db71135000166ead8305ec42d22ff7b3
Reviewed-on: https://chromium-review.googlesource.com/c/1351729
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
|
|
a1442ecd
|
2018-11-26T12:48:10
|
|
Vulkan: Uber-shader support
For each internal shader, there is now possibly a companion .json file
that defines shader variations. The variations consist of a set of
flags and a set of enums. Each enum defines a variation that takes one
of a few values. Flags are shorthands for 2-value enums.
In the shader code, #if can be used to change the shader based on
variations derived from flags and enums. On the C++ side, those
variations are combined into an index and the appropriate shader is
retrieved from a table.
Bug: angleproject:2958
Change-Id: Ic4fc7061adb20c047c26624305285e3005092aab
Reviewed-on: https://chromium-review.googlesource.com/c/1351117
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
|
|
be7e455c
|
2018-07-05T14:47:39
|
|
Vulkan: Regenerate builtin shaders.
BUG=angleproject:2691
Change-Id: Iafb1b4828fa0d54974bfb9d11a436ccaa910b942
Reviewed-on: https://chromium-review.googlesource.com/1127356
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
be7f44fb
|
2018-05-21T14:35:32
|
|
Vulkan: Use push constant for masked clear color
Storing the color in an uniform buffer, and updating it by
vkCmdUpdateBuffer can hit a driver bug. Using vkCmdPushConstants
instead can workaround this bug. Besides, push constant is expected
to outperform memory-backed resource update according to the vkspec
(section 13.2.6).
Bug: angleproject:2547
Change-Id: I319cd8e07e0a1d0cb56005b78a46466d9fca436e
Reviewed-on: https://chromium-review.googlesource.com/1067247
Commit-Queue: Jie A Chen <jie.a.chen@intel.com>
Reviewed-by: Luc Ferron <lucferron@chromium.org>
|
|
d47044ad
|
2018-04-27T11:45:03
|
|
Vulkan: Add framework for internal shaders.
Vulkan intenal shaders are stored in a ShaderLibrary, and this is
owned by the RendererVk. This way the shaders are reused between all
the different Contexts. They are initialized lazily to keep init time
low. They also have an associated Serial (called a ProgramSerial) so
they can be identified in a PipelineDesc (used by the Pipeline cache).
We use a python script to build and invoke the glslang validator, that
also produces SPIR-V binary code snippets. These snippets are gathered
into an auto-generated file that is exposed via an auto-generated
header file. The InternalShaderID enum class gives access to the
internal shaders that are shared through the Vulkan back-end.
This also adds simple clear shaders to be used in masked color clears.
The patch doesn't add any functionality but it is split off from the
color clear functionality to keep the code size down.
Bug: angleproject:2339
Bug: angleproject:2455
Change-Id: Ie83043eda217c9f013817b198c92a3b7ba0878b4
Reviewed-on: https://chromium-review.googlesource.com/1031372
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
|