summaryrefslogtreecommitdiff
path: root/wrappers/trace.py
AgeCommit message (Collapse)AuthorFilesLines
2016-06-30dxgitrace: Never attempt to delete a wrapper.Jose Fonseca1-13/+7
It's not safe, as we're not sure exactly which wrapper class we have. This fixes the "unexpected virtual method" errors introduced with earlier changes.
2016-06-30trace: Add more COM debugging.Jose Fonseca1-18/+25
To try to diagnose regression introduced by ealier commits, whereby map_buffer randomly fail, but only on special circunstances.
2016-06-28trace: Don't presume that COM interface pointers are freed when refcount ↵Jose Fonseca1-3/+7
reaches zero. They often aren't. And worst of all, some apps rely on them sticking around. With this change, the destruction of wrapper objects is effectively deferred until a different interface is created on the same pointer address, or more likely leaked. But this is unavoidable, given there's no generic mechanism to know for sure when the wrapped object is freed. Fixes https://github.com/apitrace/apitrace/issues/462
2016-03-05specs: Handle overloaded methods/functions.Jose Fonseca1-4/+12
2016-03-05trace: Improve handling of structures with no members.Jose Fonseca1-9/+18
2016-01-28wgltrace: Emit fake glBitmap on wglUseFontBitmapsA.Jose Fonseca1-0/+2
Basic implementation.
2016-01-26specs: Add missing GL_EXT_* extensions.Jose Fonseca1-1/+5
2015-08-13wrappers: Allow empty structures without hitting MSVC C2466 error.Jose Fonseca1-1/+2
2015-08-13wrappers: Provide symbolic names for IIDs.Jose Fonseca1-4/+6
As looking up IIDs can be quite time consuming.
2015-08-12trace: Avoid deep if-then-else control flow.Jose Fonseca1-14/+7
Otherwise it will hit MSVC limits.
2015-08-03trace: Flush the trace when we spot unexpected pointers.Jose Fonseca1-0/+1
2015-08-03trace: Ensure we always wrap `void **pvObj` pointers.Jose Fonseca1-2/+3
If nothing else, treat then as IUnknown pointers.
2015-07-13trace,inject: Don't increment refcount on GetModuleHandleExA.Jose Fonseca1-1/+2
2015-06-19d3dtrace: Mention the unexpected pointer value in the warning.Jose Fonseca1-1/+1
2015-02-07dxgitrace: Log the vtable address of unknown IIDs.José Fonseca1-2/+17
2015-02-07dxgitrace: More compact UUID in warnings.José Fonseca1-1/+1
2015-01-25wrappers: Use C casts for polymorphic types.Jose Fonseca1-1/+1
It looks like C++ casts end up being too restrictive, with different casts causing different compilation errors.
2015-01-24glxtrace: Support GLX_MESA_query_renderer.Jose Fonseca1-1/+1
2014-10-07trace: Move parameter unwraping out of ↵José Fonseca1-9/+17
traceFunctionImplBody/implementWrapperInterfaceMethodBody. Should make no difference by itself, but it is more useful like that, and is needed by follow-on changes.
2014-09-15dxgitrace: Improve unexpected virtual method error message.José Fonseca1-1/+1
2014-09-15dxgitrace: Fix D3D11Device1::CreateDeviceContextState wrapping.José Fonseca1-0/+2
The RIID specified in the EmulatedInterface parameter has nothing to do with the IID returned in the ppContextState parameter.
2014-08-22d3dtrace,dxgitrace: Try creating proxy objects for the child interfaces ↵José Fonseca1-48/+124
whenever possible. Fixes case when a pointer to a base interface is statically cast to a child interface, like for example: ID3D10Texture2D::Release(this = 0x14bb8b8) = 0 ... ID3D10RenderTargetView::GetResource(this = 0x14bdf64, ppResource = &0x14bb8b8) ID3D10Texture2D::GetDesc(this = 0x14bb8b8, pDesc = ...)
2014-08-22d3dtrace,dxgitrace: Enhance the dummy method implementation.José Fonseca1-6/+17
- Compact code. - Flush trace before abort.
2014-07-23trace: Make it easier to debug COM object wrapper.José Fonseca1-4/+8
2014-06-25trace: Make fakeMemcpy a function.José Fonseca1-1/+1
2014-06-25trace: Centralize fake memcpy emission.José Fonseca1-16/+2
2014-06-24gltrace: Emit flag calls consistently.José Fonseca1-1/+3
2014-02-28egltrace: Drop debug.apitrace.procname support.José Fonseca1-10/+0
As suggested by Alexander Monakov, given it is no longer necessary with Android 4.0 onwards. Also remove all isTracingEnabled logic with it, simplifying code substantially, and addressing issue #171.
2013-07-20cgltrace: Fix CGLChoosePixelFormat prototype.José Fonseca1-3/+3
And implify AttribList in the process.
2013-07-20wgltrace: Simplify pixel format attrib description.José Fonseca1-1/+1
No point is keeping two separate tables.
2013-07-20wgltrace: Prevent duplicate variable declaration.José Fonseca1-0/+2
2013-07-13Allow float-based attrib_lists as found in WGL.Andreas Hartmetz1-3/+3
It also turns out that no "type" member is needed in AttribArray, so remove it.
2013-07-12Warn on unknown attrib_list keys.Andreas Hartmetz1-1/+3
2013-07-09Improvements in AttribArray / attrib/list code generation.Andreas Hartmetz1-20/+28
- Treat unknown keys the same way while counting elements and while processing them (they are assumed to be followed by an int value). - Support custom terminators. - Serialize the terminator. - Reduce the line count of generated code a bit. - Add forgotten begin/endElement() around writing the keys. - Improve comment wording.
2013-07-08Introduce AttribArray, a code generator for pseudo-type attrib_list.Andreas Hartmetz1-0/+54
Also use it for glXCreateConfigAttribsARB, which gives the expected correct dumps in qapitrace and glretrace dump. Nothing needs to change in dump code because it just reads whatever types were written during tracing. Writing different types into different array elements is allowed by the format, and it turns out that even older versions of apitrace will correctly display dumps created with this patch.
2013-06-10gltrace: Expose marker functions when tracing is disabled.José Fonseca1-2/+6
Matches the output of change proposed by Peter Lohrmann in issue #138, but with slightly less new code. This is achieved by adding a new hook point, doInvokeFunction (could not think of a better name), used to generate the call to the real function, both when trace is enabled or disabled.
2013-05-30dxgi(re)trace: Organize mapping info into a structure.José Fonseca1-1/+2
2013-05-04Remove FunctionSig::backtrace member.José Fonseca1-3/+3
Backtraces are really disjoint from signature. This puts back const keyword in most FunctionSig usages.
2013-05-04Backtrace via call detailEugene Velesevich1-2/+2
Hello, Changes from v3: Instead of writing the backtrace as Array, the backtrace is now recorded as a list of stack frame nodes with optional stack frame details (the scheme is below). This patch implements backtrace recording during tracing, and adds support in 'apitrace dump' and QApitrace. Backtrace is obtained via platform-specific functions (and, internally, in platform-specific format). Then it is parsed to produce an std::vector of stack frame structs: { char *module, *function, *filename, *linenumber, *offset } (some fields may be NULL) and is written into the trace file in the Enter call section as a call detail: BACKTRACE FRAME MODULE "module" FUNCTION "Foo" FILENAME "foo.cpp" LINENUMBER "1234" OFFSET "0xSDF" FRAME FUNCTION "Boo" // no filename line info available for this frame END_BACKTRACE A platform-dependent mechanism is provided to specify a set of traced calls for which backtraces will be recorded. It is possible to specify either function names, or prefixes of names by appending a '*' (e.g. "glUniform*"). On Android the backtrace is retrieved from Dalvik via libdvm functions imported at runtime. Function set is specified in /data/apitrace.fnames, one per line. On Linux the backtrace is retrieved via glibc backtrace(), and will not always yield filename:linenumber information. Function set is specified via APITRACE_BT_FUNCTIONS environment variable. On other platforms, obtaining a backtrace is not implemented by this patch.
2013-04-14gltrace: Better handling of GetPerfMonitorCounterInfoAMDJosé Fonseca1-1/+1
2013-02-22trace: Unwrap all args before serializing them.José Fonseca1-0/+4
2013-02-22trace: Remove unused Trace::unwrapRet method.José Fonseca1-3/+0
2012-11-26d3dtrace: Prevent clashes in method signature IDs.José Fonseca1-6/+14
Methods from base classes had the same ID in all derived classes.
2012-11-23trace: Silence object wrap debug messages.José Fonseca1-3/+3
2012-11-23d3dtrace: Smarter tracking of interface wrappers.José Fonseca1-7/+44
2012-11-23trace: Catch attempts to call unimplemented methods.José Fonseca1-0/+5
2012-11-20d3d10/d3d11: Complete union support.José Fonseca1-55/+13
2012-11-20specs: Initial attempt to support unions.José Fonseca1-15/+30
2012-11-17gltrace: Respect length argument in glShaderSource(ARB)José Fonseca1-1/+1
2012-11-14Merge branch 'modules'José Fonseca1-4/+7