|
ab288fea
|
2021-07-09T13:02:08
|
|
Upgrade restricted traces. (Re-land)
Includes removing capture to temporary ResourceMaps,
and including all source files in the JSON.
Bug: angleproject:5133
Change-Id: I0508dd46a9f613a96ca3635f82b6904c0f2523a7
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3345222
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
c1f478fe
|
2021-12-20T12:37:33
|
|
Frame Capture: Allow for no FBO when running MEC.
Multi-context captures use the surfaceless context extension. That
was crashing MEC because we were assuming the context would have a
Framebuffer.
Bug: angleproject:5133
Change-Id: I6be12d332f4754f80c088d88973219327eca251a
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3352084
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
eba2e620
|
2021-12-15T12:29:12
|
|
Capture/Replay: Fix uniform program indexing.
We were using the "native" version of the program ID in the update
call, which could overflow the bounds of our fixed-size program
maps. Instead use the captured (and upper-bounded) version of the
ID and only get the mapped ID when calling GetUniformLocation.
Bug: angleproject:6431
Bug: angleproject:6816
Change-Id: I807bd07c9dcff6ba5a50991e28b0a58d16f7bc63
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3345220
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
d4b8cd5e
|
2021-09-14T16:34:31
|
|
FrameCapture: Implement capture of coherent bufferstorages.
Track buffers with the GL_MAP_COHERENT_BIT_EXT access flag in a
CoherentBufferTracker on a per page basis using the
PageFaultHandler and protection functions from system_utils.
Check for dirty memory and capture it on draw calls.
Bug: angleproject:5857
Change-Id: Ib098f96952db7583d3e6517570c179e7754f54b2
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3168629
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Lubosz Sarnecki <lubosz.sarnecki@collabora.com>
|
|
f60b152c
|
2021-12-06T10:19:53
|
|
Frame Capture: Merge small frames into single sources.
By buffering up the replay functions before writing them out into
sources, we can reduce the number of replay files by a large
margin.
Bug: angleproject:5133
Change-Id: I0a556fd1a3a5f2dcc8a26b761e885c9b7e464cf5
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3316200
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Reviewed-by: Tim Van Patten <timvp@google.com>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
e8b186c9
|
2021-12-09T09:45:20
|
|
Frame Capture: Don't unmap regenned buffers in reset.
These buffers are deleted and recreated, so unmapping them gives
a "resource not mapped" error during replay.
Found when working on the "world_war_doh" trace.
Bug: angleproject:5133
Change-Id: Id1e6318c44a2a09fa643ef0a72f1d03d8396e5fb
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3327862
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
a24919e7
|
2021-12-09T10:04:25
|
|
Frame Capture: Clear array buffer binding in MEC.
This should allow us to properly reset buffer state when capturing
vertex attribute pointer state in the per-context (not shared)
setup function.
Also adds a missing replay state buffer binding update.
Fixes a state serialization difference in "badland".
Bug: angleproject:5133
Change-Id: I8509dbf7211726ff47f4e7e5ff86a0eb8726d75c
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3327861
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
9b23be91
|
2021-12-08T13:55:22
|
|
Frame Capture: Fix client buffers in MEC.
In some cases we would neglect to reset the currently bound array
buffer to "null" before capturing a client array buffer in MEC.
Noticed in the "badland" trace context setup.
Bug: angleproject:5133
Change-Id: I693edce763b449720a7f2123dcaf460854142e91
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3323683
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Reviewed-by: Tim Van Patten <timvp@google.com>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
d02d6a40
|
2021-12-06T09:26:14
|
|
Frame Capture: Track written files in ReplayWriter.
This means we don't need to recreate the list of written files in
the JSON where we list the trace files. It will allow for more
flexibility when we change what trace files we output.
Bug: angleproject:5133
Change-Id: I651b6a281c50040d32361a5a020ba3eaa4241bf0
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3316199
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Reviewed-by: Tim Van Patten <timvp@google.com>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
0f09d378
|
2021-12-07T13:32:39
|
|
Frame Capture: Track return value in max resource IDs.
This adds handling for return value processing when it comes to
maximum resource IDs. Specifically for glCreateShader and
glCreateProgram.
Fixes MEC with re-capture with the blockman_go and probably other
traces that call CreateShader as the final operations during setup.
Bug: angleproject:5133
Change-Id: I799dfec776ca8c80a0b89c7f0c7c23423ef3896a
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3320887
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Reviewed-by: Tim Van Patten <timvp@google.com>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
dcadfa87
|
2021-12-07T10:34:56
|
|
Frame Capture: Fix missing header include in shared setup.
This could produce undefined string errors in some traces.
Bug: angleproject:5133
Bug: angleproject:6772
Change-Id: I336369a035e30fc7d73530084b5e192d60afee1b
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3320865
Reviewed-by: Lubosz Sarnecki <lubosz.sarnecki@collabora.com>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
8313ffe2
|
2021-11-29T15:46:25
|
|
FrameCapture: Add ReplayWriter helper class.
This centralizes all of the replay file I/O into a single point.
Each function is stored separately in this class. Right now there's
some small file format changes:
- the namespaces for the capture label are gone. these had no
functional impact now that each trace was a separate module.
- the header is cleaned up into private and public functions. this
cleans up a few things like defining non-existent functions.
- inline variables are tracked through the replay. they are now
global instead of anonymous, and string sets get reused instead
of duplicated between frames.
There should be no functional changes with the naming of the trace
files or the trace behaviour.
This change sets the stage for the ReplayWriter buffering multiple
frames into a single cpp file on disk, which can potentially reduce
the number of object files in the compilation by a great deal. It
could also be extended to work with buffered I/O so we don't block
and hitch when we're writing large trace files.
Bug: angleproject:5133
Change-Id: Ib96685e1202ac8101a4b828fa79642236af2120a
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3311940
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Reviewed-by: Tim Van Patten <timvp@google.com>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
6f96a189
|
2021-12-01T11:14:33
|
|
FrameCapture: Clean up 'WriteCppReplayFunctionWithParts'.
This function was using two extra temporary streams that it didn't
need. Clean this up and remove the extra streams and repeated code.
Bug: angleproject:5133
Change-Id: I8065a189211ba9030fee523dc7145dc5daf71d92
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3311577
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Reviewed-by: Tim Van Patten <timvp@google.com>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
3b6f80b7
|
2021-11-23T10:07:43
|
|
Capture/Replay: eliminate redundant parameters in GenOnBind
The template parameter already defines the parameter value name and
the parameter value type, so add some traits to simplify the call
interface of the function.
Bug: angleproject:6425
Change-Id: I037bed8e5cc2e7367d8faa3af5d4fba2bfbb52c3
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3295617
Commit-Queue: Gert Wollny <gert.wollny@collabora.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
|
|
ce854632
|
2021-11-29T10:48:48
|
|
FrameCapture: Fix Gen on Bind for MEC
The logic for detecting whether a resource has been generated
was not accounting for starting resources, which would only
be populated if using MEC. We also weren't tracking framebuffer
creation correctly in CaptureMidExecutionSetup.
Test: Asphalt 9 MEC
Bug: angleproject:5883
Bug: angleproject:6425
Change-Id: I8a7dfa4736c4d735dec8cd26ffa329f051927de6
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3307778
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Cody Northrop <cnorthrop@google.com>
|
|
440e5458
|
2021-11-27T19:55:06
|
|
FrameCapture: Integer attribs in MEC
If the component type of a vertex attribute is integer, we need to
use the appropriate VertexAttribI* functions to set it up.
Test: Asphalt 9 MEC
Bug: angleproject:5883
Change-Id: I2ab2248e5a36cc6636b081acf6474b5dbe2484db
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3305057
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Cody Northrop <cnorthrop@google.com>
|
|
1d555687
|
2021-11-09T11:16:24
|
|
Capture/Replay: Set FBO ID when generated on bind
GLES allows FBO ID's to be reserved on bind, so if a FBO is bound with
and ID that was not yet reserved by a glGenFramebuffers call, update the
resource tracking and the resource map to account for this resources
that was created on bind.
Bug: angleproject:6425
Change-Id: I343fc17bfbbfd9c8c47d6fe207a4f3817acb835d
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3190970
Commit-Queue: Gert Wollny <gert.wollny@collabora.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
|
|
71bffb8a
|
2021-11-09T11:16:07
|
|
Capture/Replay: Handle newly generated FBOs in tracker
Bug: angleproject:6425
Change-Id: I39d22a6770290a0c407ac358b1c059c6a2ddeefa
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3269886
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Commit-Queue: Gert Wollny <gert.wollny@collabora.com>
|
|
a514df08
|
2021-10-27T01:25:11
|
|
Add detachShader capture calls in MEC
This change adds a capture call to detach shader
object before deleting the shader object in function
GenerateLinkedProgram(), if that is also what the app does.
GenerateLinkedProgram() is part of the Mid Execution Capture
(MEC), and the purpose of the MEC is to setup a program that
more closely mirrors the original app.
The game World Cricket Championship2 detaches the shader object
before deleting the shader object. With this change, we can follow
the same behavior in GenerateLinkedProgram(). This ensures that
the Shader Object refcount is decremented to 0 before the
CaptureDeleteShader call is applied, and the ShaderProgramID
handle assigned to the Shader Object will be released and
can be reused for subsequent glCreateShader calls. The total number
of ShaderProgramID we need will be consistent between
SetupReplayContextShared() and the game uses.
We are allocating memory slots for gUniformLocations2 array
based on the total number of ShaderProgramID the game uses.
Keeping the ShaderProgramID counts the same between
trace replay and the game ensures we allocate the right amount
of memory for the trace replay.
Bug: angleproject:6621
Bug: b/194508692
Change-Id: Ib2810b486a6e9108db2a32f084d650a25f14bebd
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3246533
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Commit-Queue: Yuxin Hu <yuxinhu@google.com>
|
|
f020c713
|
2021-10-12T20:29:15
|
|
Capture/Replay: Allow capturing Gen/Delete with zero elements
This is allowed, and hence the capture/replay should also work.
Bug: angleproject:6558
Change-Id: Iae40e2870f9ff121c8396ee4c0caf0905d3fd84c
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3220632
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Commit-Queue: Gert Wollny <gert.wollny@collabora.com>
|
|
8b627444
|
2021-10-13T10:58:40
|
|
Capture/Replay: capture program with ActiveShaderProgram too
Here the program parameter is the second parameter, so
UpdateCurrentProgram needs some refactoring too, to support
specifying the parameter position.
Bug: angleproject:6560
Change-Id: Iea08e1c0b7271bcd82aba64898cec76c09edefbb
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3220690
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Commit-Queue: Gert Wollny <gert.wollny@collabora.com>
|
|
5a682795
|
2021-10-19T18:10:43
|
|
Capture/Replay: Fix glAttachShader filtering
Dota Underlords capture was filtering shaders that should be active.
It is using a pattern that creates shaders in advance, then attaches
them in later frames. This requires MEC to setup the shader, but
not the program.
We were failing to set those active because glAttachShader refers to
two ShaderProgramIDs, and we've only been scanning for the first in
any given API call:
glAttachShader(gShaderProgramMap2[1], gShaderProgramMap2[2]);
This CL fixes it by scanning for all ShaderProgramIDs in each call.
Test: Dota Underlords MEC
Bug: angleproject:5857
Change-Id: I1f76ad3345178cdfeb00479a84489dd363858e13
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3233875
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Tim Van Patten <timvp@google.com>
Commit-Queue: Cody Northrop <cnorthrop@google.com>
|
|
d8c18ac6
|
2021-10-08T13:00:19
|
|
Re-land: "Isolate commit_id.h from other code."
Re-land limits the angle_version deps to Windows to fix an iOS
visibility rule violation in GN.
Instead of recompiling multiple source files, we can seal off the
files that include commit_id to prevent recompilations when the
commit changes and source files don't change.
Bug: angleproject:2551
Change-Id: I033f00ec7afe4bfd01e29e0eea8848eea27747a0
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3233899
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
7defdb60
|
2021-10-19T14:07:07
|
|
Revert "Isolate commit_id.h from other code."
This reverts commit 6d7ebf656d06f1152967aa5f4457d3787a24732c.
Reason for revert: Suspected reason for failing ANGLE roll into Chromium
Original change's description:
> Isolate commit_id.h from other code.
>
> Instead of recompiling multiple source files, we can seal off the
> files that include commit_id to prevent recompilations when the
> commit changes and source files don't change.
>
> Bug: angleproject:2551
> Change-Id: I98800c5a8e04ec7d4c3e57ea0eb3b636d3b224bb
> Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3212895
> Commit-Queue: Jamie Madill <jmadill@chromium.org>
> Reviewed-by: Geoff Lang <geofflang@chromium.org>
> Reviewed-by: Jonah Ryan-Davis <jonahr@google.com>
Bug: angleproject:2551
Bug: angleproject:6588
Change-Id: I19f41141f57d0683efb9a4ec043e078a9f7dc925
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3226056
Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
|
|
6d7ebf65
|
2021-10-08T13:00:19
|
|
Isolate commit_id.h from other code.
Instead of recompiling multiple source files, we can seal off the
files that include commit_id to prevent recompilations when the
commit changes and source files don't change.
Bug: angleproject:2551
Change-Id: I98800c5a8e04ec7d4c3e57ea0eb3b636d3b224bb
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3212895
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Reviewed-by: Jonah Ryan-Davis <jonahr@google.com>
|
|
bb5dbd49
|
2021-10-05T11:57:44
|
|
Capture/Replay: Handle TvoidPointer in specialization
Bug: angleproject:6521
Change-Id: I863ad5307498e6394f5fbe3e650ce29c821083b1
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3204960
Commit-Queue: Gert Wollny <gert.wollny@collabora.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
|
|
8770cefc
|
2021-10-04T13:47:23
|
|
Capture/Replay: Store enums to JSON as hex
We're storing some enums in the per-trace JSON as decimal.
This makes them difficult to read, i.e.:
"DisplayDeviceType": 12810,
"DisplayPlatformType": 13392,
"DrawSurfaceColorSpace": 12425,
If we instead convert them to hex, they are much easier to
read and grep the source for.
"DisplayDeviceType": "0x320A",
"DisplayPlatformType": "0x3450",
"DrawSurfaceColorSpace": "0x3089",
Since JSON doesn't actually support hexadecimal values, this CL
stores them as strings.
Ideally we could take this a step farther and store the enum
directly in JSON, but we have no facilities for converting
a string back to an enum.
Bug: angleproject:5133
Bug: angleproject:6515
Change-Id: I7b5d4dc8958d43c611da1fe98887e089f3d855b2
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3204135
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Tim Van Patten <timvp@google.com>
Commit-Queue: Cody Northrop <cnorthrop@google.com>
|
|
043120ee
|
2021-09-29T15:56:46
|
|
Capture/Replay: Allow disabling program trimming.
The ANGLE_CAPTURE_TRIM_ENABLED variable disables program trimming
when set to 0. This is useful for trace validation, which expects
the GL state vectors to be identical.
Bug: angleproject:5133
Change-Id: I3ab41de80af7b223c4cb8a1b7e14f049717305fc
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3193417
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
0004ecc2
|
2021-09-22T13:39:55
|
|
Write GL info to test artifact in end2end_tests.
These will show up as glinfo.json in the "cas outputs" of the shard
that runs these tests.
We currently have information for Pixel 4, NVIDIA and Intel Win/Linux,
and SwiftShader Windows. GLES 1.x extensions are treated separately.
Some WebGL/Mac-only/D3D-only extensions show as unsupported anywhere.
In order to capture artifacts on Android, we use a render test output
parameter.
Bug: angleproject:6379
Change-Id: I560b219b5a586cdbb68d272090f38eedc76aba20
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3176780
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Ian Elliott <ianelliott@google.com>
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Jonah Ryan-Davis <jonahr@google.com>
|
|
b930b9d3
|
2021-09-08T09:08:28
|
|
Capture/Replay: Remove redundant "capture" from label
old: trex_200_capture_context1_frame001.cpp
new: trex_200_context1_frame001.cpp
The 'capture' word wasn't really adding any useful information.
Take it out so the filenames are a bit shorter.
Bug: angleproject:5133
Change-Id: Ibd7d47df2aa1f24a641c5d5b2a6dd14d6ce240e1
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3149370
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
|
|
5db7885f
|
2021-09-28T17:16:40
|
|
FrameCapture: Fix GLES1 VertexArrayState
Broke recently when adding support for ES3.1 semantics.
GLES1 traces are hitting the loop below, generating
BindVertexBuffer.
Test: Zillow MEC (GLES 1)
Bug: b/199919700
Change-Id: Ibe83d1b4009b00f891903cae889449d42e9f510b
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3192990
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
3719c172
|
2021-09-20T17:33:14
|
|
FrameCapture: Filter program setup calls
This CL adds filtering to shared setup calls based on whether
a resource is used during the frame capture. Calls that are
filtered out will not be written to SetupReplayContextShared.
This eliminates setup for unused resources.
This has become critical for apps like Fortnite that compile
tens of thousands of programs before running any frames. This
can take multiple minutes to perform before rendering a frame.
To achieve this, we do the following:
- Add an active status to every call (default to TRUE).
- Mark setup calls for tracked resources to FALSE during MEC.
- During the run, track for any use of the resource, and mark
its setup calls back to TRUE.
- Enable tracking for ShaderPrograms.
Test: Fortnite MEC
Bug: b/180418810
Bug: angleproject:5658
Change-Id: I5070297d339de3b80f870640e8955077a2bc20aa
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3150387
Commit-Queue: Cody Northrop <cnorthrop@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Tim Van Patten <timvp@google.com>
|
|
a09dca68
|
2021-09-20T23:40:28
|
|
Fix app trace heap buffer overflow
During runMidExecutionCapture(), we need to update
mMaxAccessedResourceIDs[idType] for idType==ShaderProgram, so that we
have enought slot in gShaderProgramMap2 to store the
temp shader we create in GenerateLinkedProgram().
Changes in this CL:
1.Renaming Jamie's mMaxAccessResourceIDS array update function
updatePreCallResourceCounts() to updateResourceCounts().
2. Adding updateResourceCounts() to Cody's setup call post processing
function scanSetupCalls(). In GenerateLinkedProgram(),
we add the temp shader create call with its' tempShaderID
into the shareGroupSetupCalls.
After that we will run the function scanSetupCalls(),
where we will be able to loop through the tempShaderID
and update the mMaxAccessResourceIDS[ShaderProgram] with the correct
count.
Bug: angleproject:6398
Change-Id: Iee78b3b7c1908a90ee8456476902f5e52e4615dc
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3172005
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Yuxin Hu <yuxinhu@google.com>
|
|
0babcb08
|
2021-09-14T10:49:06
|
|
FrameCapture: Scan Setup instructions
The ability to add calls from a multitude of locations rather than a
centralized spot has become a useful feature. But some locations
were updating the max read buffer size via updateReadBufferSize,
while others weren't.
Rather than force everything to call a central spot for tracking, add
post process scanning of Setup calls to handle updates. This is
already done for frame calls in maybeCapturePreCallUpdates.
Test: Fortnite MEC
Bug: b/180418810
Bug: angleproject:5658
Change-Id: I51d3a39ea40073d2dca50339ef4b38712b81f4ca
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3160500
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Tim Van Patten <timvp@google.com>
Commit-Queue: Cody Northrop <cnorthrop@google.com>
|
|
1af5c46c
|
2021-09-14T14:40:49
|
|
Move JsonSerializer from libANGLE to common.
This lets us use the serializer from outside of libANGLE. The plan is
to use it to serialize a list of supported extensions from the tests.
Bug: angleproject:6379
Change-Id: Ib7b64cca32e733e342b80f893d3752318089f0c2
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3163361
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
653973e4
|
2021-09-15T14:06:34
|
|
Capture/Replay: Disable when no arguments specified.
Bug: angleproject:6397
Change-Id: I09fb060044fd280f50a3b8ce71d8d455dbd4985f
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3163360
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Reviewed-by: Tim Van Patten <timvp@google.com>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
077b8eef
|
2021-08-26T22:15:54
|
|
FrameCapture: Add ES 3.1 Vertex Attrib MEC support
ES 3.1 adds new, more explicit ways to bind vertex buffers to
different format combinations. This allows changing how data is
interpreted without respecifying all the data as well.
Apps using new ES 3.1 vertex attribute functions can be incompatible
with our MEC setup that uses VertexAttribPointer. This was caught
recently by Jamie's changes to enforce ES2 only conditions. Fortnite
is the first app that uses ES3.1 semantics exclusively.
To support this, add VertexAttribFormat and VertexAttribBinding to
to our attribute setup loop. For binding indexes that *aren't* used
with VertexAttibPointer, set them up with BindVertexBuffer.
Test: Fortnite MEC
Bug: b/180418810
Bug: angleproject:5658
Bug: angleproject:6274
Change-Id: Id0cd10f6270fc96354797c3008ac181a4d008031
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3124339
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Cody Northrop <cnorthrop@google.com>
|
|
5650273a
|
2021-09-07T09:41:59
|
|
Capture/Replay: Capture trace file list to JSON.
Instead of using a text file, we can use a JSON file to store the
list of files in a trace. We can use this list in the GN to pull
the trace files directly instead of using auto-generated code. It
also consolidates the trace metadata in a single location.
Also captures the Windows Surface ID to the JSON file.
Bug: angleproject:5133
Change-Id: I236b614f7d0c844e7c4a5276dd6ac5964e5c393d
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3144214
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Reviewed-by: Tim Van Patten <timvp@google.com>
|
|
eb8ffe2f
|
2021-09-07T09:53:22
|
|
JsonSerializer: Allow adding values to root node.
Previously we would only allow a single group at the root document
node. This change allows us to have multiple members. It also changes
the API slightly. Instead of calling startDocument, you now can add
values and groups on an empty serializer object. It also removes the
implicit endGroup call in endDocument. Groups must now be manually
ended.
Bug: angleproject:5133
Change-Id: Id39016233d73270d1e20d99d59c1729fbcdd8860
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3144213
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
|
|
2f3e4db8
|
2021-09-02T10:31:13
|
|
Capture/Replay: Serialize trace metadata to a JSON file.
This will allow us to remove more code auto-generation for the trace
tests. The trace info now can be loaded directly from JSON instead of
from the autogenerated information.
Bug: angleproject:5133
Change-Id: I04e22b9279b19282df274bc8defcd363d0449111
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3140218
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
|
|
c5a38976
|
2021-09-01T07:35:40
|
|
Capture/Replay: Add expression trigger validation calls.
Setting the environment variable "ANGLE_CAPTURE_VALIDATION_EXPR"
will make ANGLE's capture logic evaluate this expression every
captured call to see if it should insert a validation checkpoint.
The retracing script also accepts --validation-expr as an argument.
For instance, the expression:
((frame == 2) && (call < 1189) && (call > 1100) && ((call % 5) == 0))
Will insert validation checkpoints on frame 2, between calls 1100 and
1189 and will validate every 5th call. The 'call' here is the count of
captured calls, which are mostly GL calls with a few ANGLE replay
calls in the mix.
We add a small single-header library that can evaluate arthithmetic
expressions in order to parse these expressions, as well as an option
to the retracing script.
Bug: angleproject:5133
Change-Id: Ic369e85d8e905a3a7a32fa098f7d8ebe7baf4ab9
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3136094
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
|
|
b0dfd268
|
2021-09-02T10:53:57
|
|
Capture/Replay: Handle Gen/Delete ProgramPipelines
Enable the test that failed compilation before.
Bug: angleproject:6180
Change-Id: Id15a5b82c8ee5dab291090375d15ce93b8908535
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3139900
Commit-Queue: Gert Wollny <gert.wollny@collabora.com>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
349d555d
|
2021-09-02T10:07:26
|
|
Capture/Replay: handle glGetBooleani_v
This also fixes a test.
Bug: angleproject:6180
Change-Id: Icad2d089738f4458c90b87620337e9798adb9141
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3139898
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Gert Wollny <gert.wollny@collabora.com>
|
|
584a10cc
|
2021-07-02T15:24:32
|
|
Capture/Replay: Use flat map for uniform locations.
Similarly to prior changes that change the resource map lookup, this
change switches the uniform lookup from an unordered map to a plain
pointer lookup. It internally uses an unordered_map of vectors, and
caches each vector base pointer whenever a program updates uniform
locations.
Testing with Manhattan 3.0, this CL decreases the binary size in a
Windows/Release build from 6.125MB to 4.413 MB. This is about a 28%
decrease. This allows for longer traces and also reduced replay
overhead.
Bug: angleproject:5133
Change-Id: I0957bc1075ec87ed9dca4a2525f27149c61cbe12
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3002511
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Gert Wollny <gert.wollny@collabora.com>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
|
|
ec8418da
|
2021-07-02T09:55:39
|
|
Capture/Replay: Use plain arrays for resource maps.
Instead of using the templated wrapper class, use C++ arrays that
are dynamically allocated with "new". This saves a fair bit of binary
size spent in calling the operator[] function. To get the right size
this CL adds tracking to the capture for each resource type, then
updates trace initialization to store the maximum allocated resource
ID for each type.
Tested with Manhattan 3.0: on Windows with Release, binary size for
the trace shared object went from 7.053 MB to 6.125 MB. About a 13%
decrease in binary size. That will allow for longer captures and will
also reduce trace overhead.
Bug: angleproject:5133
Change-Id: I2cd7515262a9ec76112d5f790001e3a6e9acd3a9
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3003383
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Reviewed-by: Gert Wollny <gert.wollny@collabora.com>
Reviewed-by: Tim Van Patten <timvp@google.com>
|
|
9c05f55a
|
2021-07-15T10:58:10
|
|
Capture/Replay: Add replay state validation.
We can use this to validate traces that have slight differences
when retracing. The valdation works by embedding the "expected"
JSON into a string at the end of each captured frame. The replay
also embeds a callback which fires right before the swap in the
replay harness. The harness then gets the "actual" JSON and runs
a comparison. On a mismatch it calls "diff" externally.
Currently the diff call is hard-coded to work on Linux only.
Note that when running validation it's important to replay on
SwiftShader since that's what we use to retrace.
Bug: angleproject:5133
Change-Id: Icbf0031d07be8bd916607c537dec235f9a512c43
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3066008
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
|
|
58bb11ca
|
2021-04-16T12:28:50
|
|
Capture/Replay: Multi-Context Support
Add support for capturing and replaying multiple contexts.
1.) Create and initialize the Contexts in the share group during
SetupReplay().
2.) Track the Context the command stream is for, and if the Context ID
changes, inject an eglMakeCurrent() call to switch to the new Context.
3.) Intercept eglCreateContext() and eglMakeCurrent() to route to either
EGLWindow or WGLWindow, depending on the current platform.
Specifically, this enables capturing and replaying Asphalt 9.
Bug: angleproject:5878
Change-Id: I5bc9b7ece5388ce405ba3f9e9dc3967e78662000
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2830145
Commit-Queue: Tim Van Patten <timvp@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
|
|
b3d062da
|
2021-08-26T20:41:42
|
|
Capture/Replay: Handle glCopyTexture3DANGLE
Bug: angleproject:6331
Change-Id: I704a34587600e612dd1d8d16b87225a7c66d4e82
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3122164
Commit-Queue: Gert Wollny <gert.wollny@collabora.com>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
5f092f8b
|
2021-08-17T17:15:59
|
|
FrameCapture: Support glProgramBinary
This CL allows applications to use glProgramBinary. Normally this is
a problem because we need program source in order to recreate shaders
in use during mid-execution capture. Use of program binaries
means an app can start and render frames without having submitted
source for that run.
To support this, we will embed program source into ANGLE's binary
format. This will allow us to extract it when the app submits the
binary. We will only embed this when capture is enabled to prevent
increased binary size in the common case. Since this changes ANGLE's
binary format, apps will recreate binaries when capture is enabled.
Additionally, we can't allow captures to have glProgramBinary calls
in the middle of captured frame ranges, so intercept those calls and
replace with a full linking sequence.
Changes include:
- Add new frontend feauture enableProgramBinaryForCapture that allows
OES_get_program_binary during capture.
- Update ANGLE's binary format to include program source when
capture is enabled.
- Update maybeOverrideEntryPoint to handle multiple new calls
instead of a single call.
- Override calls to glProgramBinary that occur mid-capture
to instead emit a full GenerateLinkedProgram sequence.
- Add checks for created/attached shaders during FrameCapture since
they won't be available for programs populated by the app using
glProgramBinary.
Test: Fortnite MEC
Bug: b/180418810
Bug: angleproject:5658
Change-Id: Ib2a0e9e434d3ee0f384d128c48b2a7d4834f5b0f
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3105390
Commit-Queue: Cody Northrop <cnorthrop@google.com>
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
9f59cac0
|
2021-08-17T16:37:03
|
|
FrameCapture: Move MEC of program binaries to a helper
This creates a new function called GenerateLinkedProgram that will
facilitate capture support of glProgramBinary.
Note this also moves one line out of the GenerateLinkedProgram path
because it modifies state. The new function needs to be run against
const state mid-capture in the next CL.
Test: Fortnite MEC
Bug: b/180418810
Bug: angleproject:5658
Change-Id: I4e3a7f3ff8d31b07bb0ebc220858a66e91e24933
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3105389
Commit-Queue: Cody Northrop <cnorthrop@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Tim Van Patten <timvp@google.com>
|
|
257ef4e2
|
2021-08-17T16:26:46
|
|
FrameCapture: Add more helpful texture errors
Rather than asserting, print an error message that provides
some helpful details to guide capture triage.
Test: Fortnite MEC
Bug: b/180418810
Bug: angleproject:5658
Change-Id: I03ee2a12fa1185698650643f8767cd758bd87a4d
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3105387
Commit-Queue: Cody Northrop <cnorthrop@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Tim Van Patten <timvp@google.com>
|
|
03fdde06
|
2021-08-17T16:21:07
|
|
FrameCapture: Adjust CopyImageSubData target
Our PackedEnums don't line up exactly with the texture targets
used by glCopyImageSubData. Adjust the CUBE selection to use
a face instead.
Test: Fortnite MEC
Bug: b/180418810
Bug: angleproject:5658
Change-Id: I855f9e68f3b78212ccb03d9e2ffe947084db85b5
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3105386
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Cody Northrop <cnorthrop@google.com>
|
|
b2cb9e50
|
2021-08-19T07:37:28
|
|
Capture/Replay: Fix extra frame captured with trigger.
A prior CL erroneously removed the -1 from the trigger frame count.
Restore this to ensure we capture the right number of frames.
Bug: angleproject:5133
Change-Id: Ic24404fbfeb8578badd6204db8316f081eafaa53
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3104693
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Reviewed-by: Tim Van Patten <timvp@google.com>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
b2238a3c
|
2021-08-16T08:23:00
|
|
Capture/Replay: MEC consistency improvements.
Fixes a few very small bugs in MEC. The current program wasn't always
captured correctly. Also texture bindings were not always left in the
right state. Fixes this by tracking the currently bound GL state
between the "shared" and "aux" MEC capture functions. Also updates the
vertex array capture to detect when to use ES 2.0 semantics. ES 3.1
is left unimplemented as it was before.
Bug: angleproject:5133
Change-Id: I5f03b8ffbdccec2664fda4698581b166a36fabdd
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3097809
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
|
|
839d5318
|
2021-08-16T08:29:28
|
|
Capture/Replay: Changes to MEC first frame capture.
Recent changes made it so it was impossible to trigger MEC *after*
the first frame and *before* the second frame. Instead it was only
possible to capture *before* the first frame or *after* the second
frame. Makes it possible for the retracing script to do identical
captures.
Also includes a number of refactorings to make it simpler to follow
the code, including renaming methods, and removing some extra
output files.
Bug: angleproject:5133
Change-Id: Ice6a189eb9f4d53e8ee1ba39beb537af2ef5fd9f
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3097807
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
|
|
ad286e71
|
2021-08-17T10:43:47
|
|
Capture/Replay: Clean up ResourceTracker access.
This reduces the boilerplate needed to tracked genned/deleted
resources.
Refactoring change only.
Bug: angleproject:5133
Change-Id: I81f8877b2c308fe9d4136999f3ca63371a070720
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3100591
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
|
|
4aedb71f
|
2021-08-11T17:00:41
|
|
Capture/Replay: Force count and length in CaptureShaderSource
The problem ist that there is a mix on how the captured shader
source is written out, in some cases one string is written, e.g.
with the test ZeroShaderLength, and in others case an array if
strings is written, a with MixedShaderLengths.
Be constistent about it and capture the shader source always as
one string and handle it like this, and override the count to be 1
to reflect this and set the length to {-1} to use the new
accumulated shader strings automatically.
Bug: angleproject:6268
Change-Id: Ide927db1a6e4facdbab4d35c023b9bce4b6c30d8
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3087448
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Commit-Queue: Gert Wollny <gert.wollny@collabora.com>
|
|
62cac8b5
|
2021-08-06T18:24:52
|
|
Capture/Replay: Add EGL support to generate_entry_points.py
Add EGL support to generate_entry_points.py. This is a pre-requisite to
frame capture being able to generate EGL calls, which is required for
multi-context support.
Bug: angleproject:5878
Bug: angleproject:4035
Change-Id: I3b8e9c91f9e2820b5207fc02d858e8109921f581
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3078993
Commit-Queue: Tim Van Patten <timvp@google.com>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
97c21277
|
2021-08-03T15:06:37
|
|
FrameCapture: Don't capture default drawbuffers state.
When capturing framebuffers during mid-execution-capture the
drawbuffers state is now compared with the default one and skipped
when equal.
This prevents capturing the unavailable glDrawBuffers call when using
OES_framebuffer_object on GLES 1 contexts.
Bug: angleproject:6181
Change-Id: Id2076223067dc5f89df88fe6a3a48b09fa9a3f5d
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3068957
Commit-Queue: Lubosz Sarnecki <lubosz.sarnecki@collabora.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
|
|
595ce2b8
|
2021-08-03T15:06:14
|
|
FrameCapture: Use OES suffixes for framebuffer functions on ES1.
Functions using the GL_OES_framebuffer_object extension on GLES 1.1
require the OES suffix or will otherwise crash on certain native OpenGL
drivers.
The framebuffer capture functions are stored in a struct.
This patch makes replay of Sonic The Hedgehog possible on Pixel 4 XL
native GL.
Bug: angleproject:6181
Change-Id: I689267b024824818bfcf28e652b835e075208415
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3068956
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Commit-Queue: Lubosz Sarnecki <lubosz.sarnecki@collabora.com>
|
|
06b19ed8
|
2021-08-06T17:02:36
|
|
Framecapture: Update file naming
Update the file naming to add "shared" and remove the unnecessary frame
numbering:
angle.angledata.gz
angle_capture_context1.cpp
angle_capture_context1.h
angle_capture_context1_files.txt
angle_capture_context1_frame001.cpp
angle_capture_shared.cpp
angle_capture_shared.h
Bug: angleproject:6256
Change-Id: I6454a3dc412896557f29faee1269dfa55146d43b
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3078908
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Commit-Queue: Tim Van Patten <timvp@google.com>
|
|
3fd572c4
|
2021-08-04T12:45:09
|
|
FrameCapture: Fix setCaptureActive() and MEC timing
Frame capture is currently off by one when calling setCaptureActive()
and collecting the mid-execution capture state. The MEC state is
collected at frame N, but setCaptureActive() isn't called until frame
N+1, meaning all of the maybeCapturePreCallUpdates() and
maybeCapturePostCallUpdates() calls are not tracking resources correctly
for frame N.
This CL fixes when setCaptureActive() is called relative to when
setupSharedAndAuxReplay() is called, so the trace is active for the
first frame and all of the resources are correctly tracked.
Additionally, setCaptureActive() during the FrameCaptureShared() ctor if
frame capture starts with the first frame.
Bug: angleproject:6225
Change-Id: Id07e78b2da9c9d33779e20ab6a42f63cd103a6a6
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3071940
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Tim Van Patten <timvp@google.com>
|
|
f9c287f0
|
2021-08-04T17:24:02
|
|
Capture/Replay: Fix reset for immutable textures
Before this CL, we were including TexStorage in the calls to reset an
immutable texture. This throws an error in GL, as you can only call
TexStorage once on a texture.
Example from ResetReplay():
glBindTexture(GL_TEXTURE_2D, gTextureMap[52]);
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, 9729);
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_SWIZZLE_R, 0);
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_SWIZZLE_G, 0);
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_SWIZZLE_B, 0);
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_SWIZZLE_A, 6403);
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAX_LEVEL, 0);
glTexStorage2D(GL_TEXTURE_2D, 1, GL_R8, 256, 512); // <== ERROR
glTexSubImage2D(GL_TEXTURE_2D, 0, 0, 0, 256, 512,
GL_RED, GL_UNSIGNED_BYTE, ...);
To fix this, move TexStorage into the calls used to regen the
texture rather than restore its contents. This means ResetReplay will
only call TexStorage again if the texture was actually deleted.
Example new regen sequence, if the texture had been deleted:
const GLuint deleteTexturesPacked[] = { gTextureMap[52] };
glDeleteTextures(1, deleteTexturesPacked);
glGenTextures(1, reinterpret_cast<GLuint *>(gReadBuffer));
UpdateTextureID(52, 0);
glBindTexture(GL_TEXTURE_2D, gTextureMap[52]);
glTexStorage2D(GL_TEXTURE_2D, 1, GL_R8, 256, 512);
Also rename texCalls to texSetupCalls to more easily distinguish
from texGenCalls, now that they intermingle.
Test: Final Fantasy MEC
Bug: b/195607411
Bug: angleproject:6246
Change-Id: I37daaeb6ea4337969cb241a20256fec07dce514e
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3073379
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Tim Van Patten <timvp@google.com>
Commit-Queue: Cody Northrop <cnorthrop@google.com>
|
|
35bdaf8d
|
2021-08-03T08:12:26
|
|
Capture/Replay: Minor cleanups.
Removes a duplicate assignment to the enabled variable. In the cpp
it's set to true, and in the header it was false. Also updates a
few variable names to be consistent with the group.
Bug: angleproject:5133
Change-Id: I3fb00ecc474191bea7c3a650ce23805b6f02d667
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3066007
Reviewed-by: Tim Van Patten <timvp@google.com>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
5bbaa2c5
|
2021-08-02T15:50:11
|
|
Capture/Replay: Track arrayed uniform locations
Arrayed uniform values consume multiple locations. Until now we've
only tracked the starting location in our lookup table. This breaks
down when applications update uniforms in the middle of an array.
We don't have a location to provide. We need to start tracking a
location per entry.
To support this, pass in the uniform count to UpdateUniformLocation
and track a location for each array entry. Do it with an overload to
preserve functionality with existing traces.
Test: PUBG Mobile MEC
Bug: b/180418573
Bug: angleproject:6087
Bug: angleproject:6234
Change-Id: I74fbe201cb37273d1a5f361ef0c951e00ca89a88
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3068199
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Tim Van Patten <timvp@google.com>
Commit-Queue: Cody Northrop <cnorthrop@google.com>
|
|
262dc97c
|
2021-07-27T11:13:59
|
|
FrameCapture: Capture the EGL color space.
Add a SurfaceParams struct containing extents and color space so
a single map can be used for all draw surface parameters.
Persist the color space in the trace's header.
Bug: angleproject:5857
Change-Id: I327da8c8870f2d76d057954af57d977a10ebb59f
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3056371
Commit-Queue: Lubosz Sarnecki <lubosz.sarnecki@collabora.com>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
ef406f1b
|
2021-07-16T12:19:23
|
|
FrameCapture: Capture GLES1 matrix stack.
Capture the modelview and projection matrix stack. This is required for
GLES1 applications that do not reset the stack every frame.
Bug: angleproject:6181
Change-Id: I71befc15ca287cf91fcebf9d972c7badaeb23605
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3035050
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Commit-Queue: Lubosz Sarnecki <lubosz.sarnecki@collabora.com>
|
|
3bd2273b
|
2021-07-16T12:33:11
|
|
Capture/Replay: Only perform call updates on valid calls.
Bug: angleproject:5133
Change-Id: Ib1a6ae1ca9ff9717c4e51f8908f5a4ee132d72ab
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3035443
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Reviewed-by: Gert Wollny <gert.wollny@collabora.com>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
d67cab22
|
2021-07-12T13:48:22
|
|
Capture/Replay: Handle missing context serialization
Some ContextLost* tests do weird things with the context
serialization which results in a mis-match of available context
serializations.
In this case check whether both serializations are missing, if so
consider this to be an equal contexts states, otherwise, if only
one serialization is available, report failure.
While touching this code, also remove an unused parameter from
the context serialization compare function.
Disable tests that still fail with this change.
Bug: angleproject:6157
Change-Id: Iee6cc7d65437112e38919cff59804e2b7f9467da
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3021061
Commit-Queue: Gert Wollny <gert.wollny@collabora.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
|
|
b5630d5c
|
2021-07-19T20:39:02
|
|
Capture/Replay: Add textures to resource tracking
This CL:
- Shifts resource reset tracking to be stored in an array of structs
indexed by type. This helps curb the complexity of adding more
resource types.
- Moves buffer and program tracking to the new layout.
- Adds textures to the resource tracker, using new layout.
Note that only aspects common to all ResourceIDTypes have been moved
to the new layout. Unique pieces of data, like buffer mapping state
and GLSync handling, remain in resource tracker alone.
Since texture setup is quite involved, this CL takes the approach of
having each call applied to two call chains at the same time;
SetupReplay calls and ResetReplay calls.
ResetReplay ends up with a sequence similar to buffers:
...
const GLuint deleteTextures[] = {
gTextureMap[1], gTextureMap[2], ... gTextureMap[n]};
glDeleteTextures(<count>, deleteTextures);
...
glGenTextures(1, reinterpret_cast<GLuint *>(gReadBuffer));
UpdateTextureID(1, 0);
glGenTextures(1, reinterpret_cast<GLuint *>(gReadBuffer));
UpdateTextureID(2, 0);
glGenTextures(1, reinterpret_cast<GLuint *>(gReadBuffer));
UpdateTextureID(3, 0);
...
glBindTexture(GL_TEXTURE_2D, gTextureMap[1]);
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, 9729);
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_R, 33071);
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, 33071);
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, 33071);
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_COMPARE_FUNC, 519);
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAX_LEVEL, 0);
glTexImage2D(GL_TEXTURE_2D, 0, 6406, 512, 512, 0, GL_ALPHA, GL_UNSIGNED_BYTE,
reinterpret_cast<const GLubyte *>(&gBinaryData[183263280]));
glBindTexture(GL_TEXTURE_2D, gTextureMap[2]);
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, 9987);
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_COMPARE_FUNC, 519);
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAX_LEVEL, 6);
glTexStorage2D(GL_TEXTURE_2D, 7, GL_COMPRESSED_SRGB8_ETC2, 64, 64);
...
Test: PUBG Mobile MEC
Bug: b/180418573
Bug: angleproject:6087
Change-Id: I9f8e151c12aec5b2b7af376b8e0ff644ff9c61c4
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3016114
Commit-Queue: Cody Northrop <cnorthrop@google.com>
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
8a737c5d
|
2021-07-21T16:38:05
|
|
Capture/Replay: Update unpack state in Shared MEC
The shared context state MEC performed by
CaptureSharedContextMidExecutionSetup() needs to include updating the
pixel unpack state before capturing texture contents. Otherwise,
computeRowPitch() will compute the wrong value, leading to a crash in
memcpy() when capturing Pokemon GO.
Bug: angleproject:6203
Change-Id: Id1b2d0b4f3bc79e615778ba513f50aabaeb4a56e
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3044356
Commit-Queue: Tim Van Patten <timvp@google.com>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
d2b659f9
|
2021-03-25T15:40:58
|
|
EGL: implement EGL_EXT_protected_content Context
Add Validation check to Contexts and Surfaces
Add Vulkan protected memory features and properties
Add protected member to Surfaces and Contexts
Implement hasProtectedContent in Vulkan
Add QueueFamily helper, extent DeviceQueueMap
Protected Swapchains always on for Android
Add EGLProtectedContentTest
Test: angle_end2end_test --gtest_filter=EGLProtectedContentTest
Bug: angleproject:3965
Change-Id: I9352b1e594f71bb4e89cee7137a468940d186b1b
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2800413
Commit-Queue: Mohan Maiya <m.maiya@samsung.com>
Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
1e75181f
|
2021-07-15T13:39:08
|
|
Capture/Replay: redesign capturing of arrays passed by pointer
Instead of doing a lookup of the number of passes array when the
call is written, store the number of array values in the
ParamCapture when the call is captured.
Bug: angleproject:6164
Change-Id: I87b0e2f776a6884b999cc50844e0777cda26b380
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3031543
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Commit-Queue: Gert Wollny <gert.wollny@collabora.com>
|
|
106ed74c
|
2021-07-12T20:55:33
|
|
Capture/Replay: Capture FenceNV parameters
Enable according tests.
Bug: angleproject:6163
Change-Id: I4435a650530006997ed3f14315461060729b836a
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3024206
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Commit-Queue: Gert Wollny <gert.wollny@collabora.com>
|
|
223cd0ac
|
2021-06-15T18:46:07
|
|
Capture/Replay: Refactor shared context handling
This is the initial CL to enable capture/replay of multi-context
applications.
This CL refactors FrameCapture and FrameCaptureShared to move much of
the functionality into FrameCaptureShared, since most everything is
shared by Contexts in the share group. For example, the setup of the
majority of the GL objects is done in the new SetupReplayContextShared()
function in the new $LABEL_capture_context_shared_frame001.cpp file. The
setup is performed by (for example):
void SetupReplay()
{
$LABEL::InitReplay();
$LABEL::SetupReplayContextShared();
SetupReplayContext2();
}
This performs the shared setup first, followed by the context-specific
setup, which may reference shared objects careated by
LABEL::SetupReplayContextShared().
No re-capturing is required with this change, since the external APIs
(i.e., SetupReplay()) are still the same.
Bug: angleproject:5878
Test: Manual MEC and replay of Magic Tiles 3, Candy Crush Soda Saga, Temple Run 2
Change-Id: Iab7bfe651437e9be1dee83514cd97acc20c61d1d
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2965780
Commit-Queue: Tim Van Patten <timvp@google.com>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
5fb5f63b
|
2021-06-29T09:56:43
|
|
Capture: Write captured context for empty frames
When a frame is empty, still write the captured context for that
frame because the index file will contain the frame file, and the
replay will execute the according swapbuffer so that the replay will
query the context serialization when testing trace correctness.
With that enable RobustResourceInitTest.SurfaceInitializedAfterSwap/*
for capture/replay.
Bug: angleproject:5939
Change-Id: Ib280d55f739cc2bb8d2da0919e98c37a2cd576ba
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2987991
Commit-Queue: Gert Wollny <gert.wollny@collabora.com>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
4964513a
|
2021-06-28T20:07:46
|
|
ANGLETest: When on WebGL compatibility then use index buffers
WebGL actually requires the use of index buffers, otherwise the
call is invalid, therefore explicitely request index buffers in
the according VertexAttributeOORTest tests.
In addition, assert on the indices when the glDrawElements call is
captured.
With that we can enable VertexAttributeOORTest.*
Bug: angleproject:6125
Change-Id: Id3855c78d4c5fcab5599f19dd74ce745d059fb1c
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2999523
Commit-Queue: Gert Wollny <gert.wollny@collabora.com>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
b3e920e2
|
2021-06-28T14:32:13
|
|
Capture/Replay: don't capture DrawElements with count zero
Usually Context::noopDraw would reject calls that doen't draw,
but FrameCapture::maybeCaptureDrawElementsClientData seems to be
called before Context::noopDraw, and since in ComputeTypedIndexRange
we would obtain the illegal range [0,0) (which is actually prohibited
by an ssertion "count > 0"), we have to exit early.
With that the test can be enabled.
Bug: angleproject:6111
Change-Id: I4c242712bd90602f84ad6072b02c3a13a26840f7
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2993089
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Gert Wollny <gert.wollny@collabora.com>
|
|
dba2e136
|
2021-05-13T20:33:46
|
|
Capture/Replay: Emit InitializeReplay() late
Only emit InitializeReplay() after all captured frames have been run,
so that the readBufferSize and the maxClientArraySize are really
sufficiently large for all frames.
To achieve this a layer of indirection is added, that is because
InitializeReplay() has to be called from SetupFrame() which is still
emitted with the first frame, a new function InitReplay() is added.
The call to this function is emitted with the first frame, buts its
body is emitted after the last frame has been captured.
Bug: angleproject:5965
Change-Id: Ic38791b4c02989594ec87d1ba3f031fd81471314
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2940841
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Commit-Queue: Cody Northrop <cnorthrop@google.com>
|
|
aec47ff6
|
2021-06-22T15:47:43
|
|
Capture/Replay: Update CopyImageSubData params
The parameters to glCopyImageSubData are flexible and
can take a TextureID or a RenderbufferID as a GLuint.
Our replay needs to remap those values, so we'll convert the GLuint
based on the target. This leads to a change like the following.
Before:
glCopyImageSubData(138, 0x0DE1, 0, 0, 0, 0,
642, 0x0DE1, 1, 0, 0, 0,
256, 256, 1);
After:
glCopyImageSubData(gTextureMap[138], 0x0DE1, 0, 0, 0, 0,
gTextureMap[642], 0x0DE1, 1, 0, 0, 0,
256, 256, 1);
Test: PUBG Mobile MEC
Bug: angleproject:6087
Bug: angleproject:6104
Change-Id: I5cd422e41ffbb4f08c8909e520bdce63e3008c5a
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2981464
Commit-Queue: Cody Northrop <cnorthrop@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Tim Van Patten <timvp@google.com>
|
|
8cf6d8cc
|
2021-06-28T10:00:54
|
|
Capture/Replay: Handle Gen/Delete Semaphores and fix map emit
Add capturing of the handles used in GenSemaphores and
DeleteSemaphore, fix the emission of the gSemaphoreMap. and
enable capture/replay tests.
Change-Id: Iabb88bd1d6c22c08271d0883607efb72de9d3d0c
Bug: angleproject:6107
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2988679
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Commit-Queue: Gert Wollny <gert.wollny@collabora.com>
|
|
c2449441
|
2021-06-24T13:06:08
|
|
Capture/Replay: Make sure EGLImageKHR is a parsable number
For some reason on win-trace-rel the pointer value us written
as a hex number but without the leading "0x", so the number gets
interpreted as octal, and compilation fails.
Fixes: cb4f8a79a4def3dd8fd9f941d6674939e1731860
Capture: Add a specialization for TGLeglImageOES
Bug: angleproject:6036
Change-Id: I949ace542a0ad257b47fbe539893a56c1c32b0b3
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2982551
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Gert Wollny <gert.wollny@collabora.com>
|
|
c8677c73
|
2021-06-12T17:23:42
|
|
Capture: Add a specialization for const GLuint *
Bug: angleproject:6058
Change-Id: I31cad1dd23d313aae625874e140c406747e0f4c4
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2957953
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
22716d31
|
2021-06-11T13:51:41
|
|
Capture: Add specialization for ParamType::TGLubyte
Also enable "CurrentColorTest.Set/*" tests.
Bug: angleproject:6049
Change-Id: I65e62b6c0805687ad6744a12217e0c08bc97ca1a
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2954262
Commit-Queue: Gert Wollny <gert.wollny@collabora.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
|
|
90f9ddd9
|
2021-06-10T14:35:13
|
|
Capture: Add support for capturing (Get)ClipPlanef equation
In addition, correctly handle "const GLfloat *" when replaying,
and enable the according capture/replay tests
Bug: angleproject:6047
Change-Id: I5dd7510d1b621d4c941490c9d0261559a96dd681
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2951133
Commit-Queue: Gert Wollny <gert.wollny@collabora.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
|
|
1b104dd9
|
2021-05-26T14:29:01
|
|
Finish switch to angle_version.h.
Bug: b/168736059
Change-Id: I1232c8284f37aadb374840aca8f40e4569382c7b
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2920490
Reviewed-by: Geoff Lang <geofflang@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
|
|
cb4f8a79
|
2021-06-08T10:39:47
|
|
Capture: Add a specialization for TGLeglImageOES
When writing out the parameter TGLeglImageOES an additional cast is
needed.
Bug: angleproject:6036
Change-Id: I7470a58a6ae17b0185d0c2e3fe1184b698f3efaf
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2944952
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Gert Wollny <gert.wollny@collabora.com>
|
|
16b10a54
|
2021-05-21T15:35:00
|
|
Revert "Capture/Replay: Emit SetupReplay() late"
This reverts commit 54ba6f0135715737a55f2dc4fc1cb86874fb98f9.
Reason for revert: breaks MEC.
Bug: angleproject:5999
Original change's description:
> Capture/Replay: Emit SetupReplay() late
>
> Only emit SetupReplay() after all captured frames have been run,
> so that InitializeReplay() is called with values of
> readBufferSize and the maxClientArraySize that are sufficiently
> large for all frames.
>
> Bug: angleproject:5965
> Bug: angleproject:5895
> Change-Id: Ic59597dc27f733fb210d7cc5a144a86e54cd2040
> Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2894486
> Commit-Queue: Gert Wollny <gert.wollny@collabora.com>
> Reviewed-by: Jamie Madill <jmadill@chromium.org>
> Reviewed-by: Cody Northrop <cnorthrop@google.com>
Bug: angleproject:5965
Bug: angleproject:5895
Change-Id: Ia901183b2052fa2b4552ad2e09818a2894fbdf6b
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2911878
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Cody Northrop <cnorthrop@google.com>
|
|
9ba86e06
|
2021-06-03T13:41:39
|
|
Revert "FrameCapture: Write the frame cpp file even if frame is empty"
This reverts commit 6619c464e5f6237d7465ec945d24164372aa4196.
Reason for revert: breaks MEC.
Bug: angleproject:5999
Original change's description:
> FrameCapture: Write the frame cpp file even if frame is empty
>
> The index file will add a reference to this file, and the replay will
> also expect that the frame execution function and the context function
> exist, so write the file even if the frame is empty
>
> Bug: angleproject:5939
> Change-Id: I265d061fdae51b86131d145116ad1c0f9ca8c93f
> Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2882581
> Commit-Queue: Gert Wollny <gert.wollny@collabora.com>
> Reviewed-by: Cody Northrop <cnorthrop@google.com>
> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Bug: angleproject:5939
Change-Id: I759d44ba847c69faf1caf97a9818836d1be3b058
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2937737
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Tim Van Patten <timvp@google.com>
Commit-Queue: Cody Northrop <cnorthrop@google.com>
|
|
a29a64a6
|
2021-05-26T09:34:52
|
|
Capture/Replay: Skip GLGetActiveUniformsiv
Test: Genshin Impact MEC
Bug: b/181794064
Change-Id: Ib0edfa8d1c063d43c34a65be0144bc5efc4cf19b
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2921067
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Cody Northrop <cnorthrop@google.com>
|
|
6619c464
|
2021-05-10T13:00:48
|
|
FrameCapture: Write the frame cpp file even if frame is empty
The index file will add a reference to this file, and the replay will
also expect that the frame execution function and the context function
exist, so write the file even if the frame is empty
Bug: angleproject:5939
Change-Id: I265d061fdae51b86131d145116ad1c0f9ca8c93f
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2882581
Commit-Queue: Gert Wollny <gert.wollny@collabora.com>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
54ba6f01
|
2021-05-13T20:33:46
|
|
Capture/Replay: Emit SetupReplay() late
Only emit SetupReplay() after all captured frames have been run,
so that InitializeReplay() is called with values of
readBufferSize and the maxClientArraySize that are sufficiently
large for all frames.
Bug: angleproject:5965
Bug: angleproject:5895
Change-Id: Ic59597dc27f733fb210d7cc5a144a86e54cd2040
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2894486
Commit-Queue: Gert Wollny <gert.wollny@collabora.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
|
|
421c665c
|
2021-05-13T21:17:16
|
|
Capture: Make writeCppReplayIndexFiles a method of FrameCapture
This is useful to not pass a large amount of parameters around.
Bug: angleproject:5965
Change-Id: I3890a0ca852729bbf74725fb9e5f4062e20e9158
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2894485
Commit-Queue: Gert Wollny <gert.wollny@collabora.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
|
|
40f11af8
|
2021-05-17T23:05:16
|
|
Capture/Replay: Ignore delete of non-genned buffers
Instead of asserting that the app is calling glDeleteBuffers
on buffers we've seen created, ignore buffer names that we
haven't seen. This is allowed by the spec:
Buffer objects are deleted by calling
void DeleteBuffers(sizei n, const uint *buffers);
Unused names in buffers are silently ignored, as is the value zero.
Test: SAKURA School Simulator MEC
Bug: b/188488065
Bug: angleproject:5987
Change-Id: Id4704e544f644dbe3edf6efdf70b5c3ef9ccaba7
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2902442
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Tim Van Patten <timvp@google.com>
Commit-Queue: Cody Northrop <cnorthrop@google.com>
|
|
4b071880
|
2021-05-13T16:20:05
|
|
Capture/Replay: Add const to string pointer
Traces that have shader compiles in the middle of the run are reusing
the string pointers on each go through. On some (multiple) platforms,
the string pointer is no good on the second run through. This may
only happen for large strings.
Adding a const qualifier on the pointer itself, not just the string,
avoids the issue. This has the effect of changing strings from this:
const char *glShaderSource_string_0[] = {
const char *glShaderSource_string_1[] = {
to this:
const char* const glShaderSource_string_0[] = {
const char* const glShaderSource_string_1[] = {
Test: Pokemon Go MEC
Bug: b/188091629
Bug: angleproject:5968
Change-Id: Id6a05c955adb3e1c43d2723450be6b5278d99fba
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2895328
Commit-Queue: Cody Northrop <cnorthrop@google.com>
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
83d22b66
|
2021-05-13T16:10:54
|
|
Capture/Replay: Skip glGetActiveUniform
Apps are querying GL_ACTIVE_UNIFORMS and then walking through them all
numerically, calling glGetActiveUniform on each one. Before this CL,
our trace would also walk through them all, exactly as the app.
But, the active uniform count can vary on different platforms
depending on how aggressive the underlying compiler is. We have at
least one that does cross stage optimizations eliminating more active
uniforms than others.
Rather than check each call against the actual number of active
uniforms, we can just drop the calls to glGetActiveUniform. We don't
actually use any of the results from the call. For example, this is
what we generate before this CL:
glGetActiveUniform(gShaderProgramMap[144], 31, 1024,
reinterpret_cast<GLsizei *>(gReadBuffer),
reinterpret_cast<GLint *>(gReadBuffer),
reinterpret_cast<GLenum *>(gReadBuffer),
glGetActiveUniform_name_30);
This has the downside of moving away from reflecting what the app
actually sent down. The alternatives are too intrusive though, and
we want to stay as close to speed of light as we can.
Test: Pokemon Go MEC
Bug: b/188091629
Bug: angleproject:5968
Change-Id: I1263f2256c6a964dac54d9997a1c1c2dceac711b
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2895327
Commit-Queue: Cody Northrop <cnorthrop@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Tim Van Patten <timvp@google.com>
|
|
8ea11eb7
|
2021-05-13T15:54:41
|
|
Capture/Replay: Reset programs on loop
Apps that create new programs during the run need to have them
deleted on loop. This CL handles that. It does not handle programs
that have been deleted and need to be recreated, or that have been
modified otherwise. An assert has been included to catch that for
future needs.
With this CL, entries like this will show up in ResetReplay:
...
glDeleteProgram(gShaderProgramMap[120]);
glDeleteProgram(gShaderProgramMap[121]);
...
Test: Pokemon Go MEC
Bug: b/188091629
Bug: angleproject:5968
Change-Id: I78c425e8fe95792fc626484641d067613dfae971
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2895326
Commit-Queue: Cody Northrop <cnorthrop@google.com>
Reviewed-by: Tim Van Patten <timvp@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
|
|
31cd0e98
|
2021-05-10T10:37:54
|
|
Capture/Replay: track robustResourceInit
Bug: angleproject:5938
Change-Id: I7c9ab9bebd1ec2dc572a071844a860f99d0befe6
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2882580
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Cody Northrop <cnorthrop@google.com>
|
|
51d02ca0
|
2021-05-06T15:16:16
|
|
FrameCapture: Use gl*Separate functions only when required.
Use non-separate stencil and blend functions that do not
distinguish between front and back buffers or color and alpha,
if they apply.
This prevents capturing GLES2 functions on GLES1 contexts.
Bug: angleproject:5893
Change-Id: I8303ee5b279268ea9c21e2c6465e1b155d1cc54d
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2877238
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Commit-Queue: Lubosz Sarnecki <lubosz.sarnecki@collabora.com>
|
|
4901ac64
|
2021-05-06T15:15:57
|
|
FrameCapture: Capture GLES1 specific states.
Implement capturing GLES1 specific state by checking the difference to
the default state using getEnableFeature.
When getEnableFeature is called from a context version higher than 1 and
a GLES1 state is requested, an assertion is hit. Therefore the context
version needs to be determined before calling getEnableFeature.
Use the available isTextureTargetEnabled function to determine
GL_TEXTURE_2D and GL_TEXTURE_CUBE_MAP states in getEnableFeature.
Return false in isTextureTargetEnabled when mTextUnitEnables is empty,
so the vector is not accessed when not initialized, which was the case
for a default state.
Bug: angleproject:5893
Change-Id: I66ee41c3bf7a8e1f04a8a4ce0461fddc16f9a013
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2877237
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Lubosz Sarnecki <lubosz.sarnecki@collabora.com>
|