Refresh OProfile code running on the target side to 0.9.5 for ARMV7.
diff --git a/daemon/opd_trans.c b/daemon/opd_trans.c
index 871e6e6..76296a0 100644
--- a/daemon/opd_trans.c
+++ b/daemon/opd_trans.c
@@ -194,7 +194,7 @@
if (vmisc) {
char const * name = verbose_cookie(trans->cookie);
verbprintf(vmisc, "COOKIE_SWITCH to cookie %s(%llx)\n",
- name, trans->cookie);
+ name, trans->cookie);
}
}
@@ -246,11 +246,11 @@
verbprintf(vmisc, "XEN_ENTER_SWITCH to xen\n");
trans->in_kernel = 1;
trans->current = NULL;
- /* subtlety: we must keep trans->cookie cached, even though it's
- * meaningless for Xen - we won't necessarily get a cookie switch
- * on Xen exit. See comments in opd_sfile.c. It seems that we can
- * get away with in_kernel = 1 as long as we supply the correct
- * Xen image, and its address range in startup find_kernel_image
+ /* subtlety: we must keep trans->cookie cached, even though it's
+ * meaningless for Xen - we won't necessarily get a cookie switch
+ * on Xen exit. See comments in opd_sfile.c. It seems that we can
+ * get away with in_kernel = 1 as long as we supply the correct
+ * Xen image, and its address range in startup find_kernel_image
* is modified to look in the Xen image also
*/
}
@@ -258,24 +258,31 @@
extern void code_spu_profiling(struct transient * trans);
extern void code_spu_ctx_switch(struct transient * trans);
+extern void code_ibs_fetch_sample(struct transient * trans);
+extern void code_ibs_op_sample(struct transient * trans);
+
handler_t handlers[LAST_CODE + 1] = {
&code_unknown,
&code_ctx_switch,
&code_cpu_switch,
&code_cookie_switch,
&code_kernel_enter,
- &code_user_enter,
+ &code_user_enter,
&code_module_loaded,
/* tgid handled differently */
&code_unknown,
&code_trace_begin,
&code_unknown,
- &code_xen_enter,
+ &code_xen_enter,
#if defined(__powerpc__)
&code_spu_profiling,
&code_spu_ctx_switch,
-#endif
+#else
&code_unknown,
+ &code_unknown,
+#endif
+ &code_ibs_fetch_sample,
+ &code_ibs_op_sample,
};
extern void (*special_processor)(struct transient *);
@@ -299,7 +306,8 @@
.cpu = -1,
.tid = -1,
.embedded_offset = UNUSED_EMBEDDED_OFFSET,
- .tgid = -1
+ .tgid = -1,
+ .ext = NULL
};
/* FIXME: was uint64_t but it can't compile on alpha where uint64_t
@@ -313,17 +321,9 @@
return;
}
- int i;
-
- for (i = 0; i < count && i < 200; i++) {
- verbprintf(vmisc, "buffer[%d] is %x\n", i, buffer[i]);
- }
-
while (trans.remaining) {
code = pop_buffer_value(&trans);
- verbprintf(vmisc, "In opd_process_samples (code is %lld)\n", code);
-
if (!is_escape_code(code)) {
opd_put_sample(&trans, code);
continue;
@@ -338,7 +338,6 @@
// started with ESCAPE_CODE, next is type
code = pop_buffer_value(&trans);
- verbprintf(vmisc, "next code is %lld\n", code);
if (code >= LAST_CODE) {
fprintf(stderr, "Unknown code %llu\n", code);
abort();