Age | Commit message (Collapse) | Author | Files | Lines |
|
retrace has a cleanup() routine which can be called to free resources
after a retrace. However, it fails to free resources which are
allocated in several static global data structures.
Due to this shortcoming, a trace file cannot be traced twice in a single
process. This directly affects gtests which need to execute a minimal
trace file and check the results.
|
|
This object is only needed for profiling. Global initialization is
unnecessary and it creates temporary file (with mmap_allocator.hpp),
which can be avoided.
|
|
Usually if an app is using MRT, we want to dump (and diff) *all* the
render targets to track down where things are going wrong. Also dumps
depth and stencil buffers.
When the --mrt (or -m) argument is specified, all render targets plus
depth and/or stencil are dumped, with the suffix -mrtN/-z/-s. Otherwise
the behavior is as before, only mrt0 is dumped with no suffix.
Only implemented for GLDumper, since I don't know anything about D3D.
|
|
Minimal testing.
|
|
We were already using cached program on call lists. This changes
generalizes to outside call lists and pipelines.
This avoids glGetInteger calls on traces with lots of glUniform calls.
|
|
Thanks to Steinar Gunderson for catching this.
https://github.com/apitrace/apitrace/issues/446#issuecomment-209673877
|
|
Fixes https://github.com/apitrace/apitrace/issues/443
|
|
This module will have more than just description of OpenGL profiles, but
actual features.
|
|
|
|
To avoid the need of stripping newlines.
|
|
|
|
As the latter is not portable.
|
|
So that apitrace (and maybe the drivers) can distinguish these messages
from others.
|
|
|
|
|
|
KHR_debug spec is not clear, but at leat Mesa doesn't seem to like it.
|
|
Dumper is only for dumping state to JSON.
|
|
If the extension is present, use it to log call numbers for draw
commands, using GL_DEBUG_TYPE_MARKER. If supported by the driver,
this embeds the draw call no's in the commandstream.
Signed-off-by: Rob Clark <robdclark@gmail.com>
|
|
|
|
Just like we do for KHR_debug messages.
|
|
In OpenGL, a context switch is executed by calling MakeCurrent.
Two new functions in the MetricBackend interface:
void pausePass()
void continuePass()
In glretrace these calls are added to MakeCurrent invocation.
The pausePass() function should be called before the context switch while
the continuePass() one should be called after.
pausePass() ends all current queries, prepares for context switch.
continuePass() is called in a new context, makes everything needed for
profiling continuation (checks backends support, setups queries etc.)
With this commit backends gain only basic support for context switches.
Somewhere checks are missing, somewhere it should be made more clear
what to do with interrupted queries.
|
|
The option is "--gen-passes".
For using with new "--pframes", "--pcalls", "--pdrawcalls".
|
|
The option is "--list-metrics".
It outputs metrics and metric groups for each plugged backend.
It also requires the trace file to be specified, as some backends
can query metrics only after context is created. They can also possibly
depend on the context version.
Trace file is only replayed until the context is created.
|
|
Make use of MetricWriter in glretrace to output new metrics in the last
pass.
Last pass is determined via method isLastPass() in glretrace.
3 tabular outputs are returned for each profiling option in the following
order:
1) for frames
2) for calls
3) for draw calls
|
|
New options: "glretrace --pframes=SELECTION_STRING",
"glretrace --pdrawcalls=SELECTION_STRING",
"glretrace --pcalls=SELECTION_STRING".
Each option is for profiling corresponding boundary (frames, draw calls
or all calls).
Profiling is done with the backends in glretrace::metricBackends and metrics
selected in them (via enableMetric() backend interface call). Selection
strings are parsed in enableMetricsFromCLI().
Backends are used in series. For each backend required number of passes
is evaluated.
It does not work with old profiling options.
Format for SELECTION_STRING:
--pdrawcalls="backend1:metric1,metric2,metric3;backend2:metric1,metric2"
Where metric1 is either [groupId, metricId]
or metricName
Example:
--pframes="GL_AMD_performance_monitor: [0,4], [1,5], VS_INVOCATION_COUNT;
GL_INTEL_performance_query: [1,2]"
|
|
Instead of using the requested context version.
This fixes occlusion query detection with all traces recorded on Windows,
as wglCreateContext doesn't provide way to specify context version and
can't be avoided.
Fixes https://github.com/apitrace/apitrace/issues/358#issuecomment-131519038
|
|
|
|
|
|
|
|
|
|
Fixes #359.
|
|
Was part of core in GL_ARB_timer_query.
|
|
GL_ARB_occlusion_query was made part of core OpenGL 1.5. Furthermore we
don't use the *ARB entry-points, so we really rely on the core support.
Futhermore, on Mac OS, core 3.2+ profiles do not list core extensions,
so we were wrongly assuming it was missing.
Fixes #358.
|
|
So that we can later dump state in formats other than JSON.
|
|
Had forgotten GL_ prefix in extension name.
|
|
|
|
As these typically have size specified in the creation call.
See in trace referred in issue #306.
|
|
|
|
is supported.
|
|
|
|
|
|
As these are quite useful to diagnose problems in glstate module itself.
|
|
|
|
When replaying, glretrace must wait for all fences that were recorded
as signalled in the trace, as subsequent calls might depend upon it.
|
|
So that it's obvious which message is being ignored.
|
|
|
|
Message volume is often too much -- need some way to make important
messages stand out.
|
|
|
|
Of any kind, and not just
|
|
|