diff options
author | Paul Berry <stereotype441@gmail.com> | 2012-05-04 12:41:00 -0700 |
---|---|---|
committer | Paul Berry <stereotype441@gmail.com> | 2012-05-10 11:32:39 -0700 |
commit | da02f72bc286fd8d669f3860bdd97a8d1a1c3015 (patch) | |
tree | 879637f843a63c689d172be5f7c06cae2687f47a /intel/intel_bufmgr.h | |
parent | cf7cc62a9817a495264bbb037f0175cef9bd7a53 (diff) |
intel: Add the ability to supply annotations for .aub files.
This patch adds a new function,
drm_intel_bufmgr_gem_set_aub_annotations(), which can be used to
annotate the type and subtype of data stored in various sections of
each buffer. This data is used to populate type and subtype fields
when generating the .aub file, which improves the ability of later
debugging tools to analyze the contents of the .aub file.
If drm_intel_bufmgr_gem_set_aub_annotations() is not called, then we
fall back to the old set of annotations (annotate the portion of the
batchbuffer that is executed as AUB_TRACE_TYPE_BATCH, and everything
else as AUB_TRACE_TYPE_NOTYPE).
Reviewed-by: Eric Anholt <eric@anholt.net>
Diffstat (limited to 'intel/intel_bufmgr.h')
-rw-r--r-- | intel/intel_bufmgr.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/intel/intel_bufmgr.h b/intel/intel_bufmgr.h index 45389e1e..c197abc6 100644 --- a/intel/intel_bufmgr.h +++ b/intel/intel_bufmgr.h @@ -92,6 +92,12 @@ enum aub_dump_bmp_format { AUB_DUMP_BMP_FORMAT_ARGB_8888 = 7, }; +typedef struct _drm_intel_aub_annotation { + uint32_t type; + uint32_t subtype; + uint32_t ending_offset; +} drm_intel_aub_annotation; + #define BO_ALLOC_FOR_RENDER (1<<0) drm_intel_bo *drm_intel_bo_alloc(drm_intel_bufmgr *bufmgr, const char *name, @@ -169,6 +175,10 @@ void drm_intel_gem_bo_aub_dump_bmp(drm_intel_bo *bo, int x1, int y1, int width, int height, enum aub_dump_bmp_format format, int pitch, int offset); +void +drm_intel_bufmgr_gem_set_aub_annotations(drm_intel_bo *bo, + drm_intel_aub_annotation *annotations, + unsigned count); int drm_intel_get_pipe_from_crtc_id(drm_intel_bufmgr *bufmgr, int crtc_id); |