[profile]: [11/23] alpha profiling cleanups

From: William Lee Irwin III
Date: Tue Jun 22 2004 - 10:35:12 EST


Convert alpha to use profiling_on() and profile_tick().

Index: prof-2.6.7/arch/alpha/kernel/irq_impl.h
===================================================================
--- prof-2.6.7.orig/arch/alpha/kernel/irq_impl.h 2004-06-15 22:20:26.000000000 -0700
+++ prof-2.6.7/arch/alpha/kernel/irq_impl.h 2004-06-22 07:25:52.346205336 -0700
@@ -46,26 +46,13 @@
static inline void
alpha_do_profile(unsigned long pc)
{
- extern char _stext;
-
- if (!prof_buffer)
+ if (!profiling_on())
return;

/*
* Only measure the CPUs specified by /proc/irq/prof_cpu_mask.
* (default is all CPUs.)
*/
- if (!((1<<smp_processor_id()) & prof_cpu_mask))
- return;
-
- pc -= (unsigned long) &_stext;
- pc >>= prof_shift;
- /*
- * Don't ignore out-of-bounds PC values silently,
- * put them into the last histogram slot, so if
- * present, they will show up as a sharp peak.
- */
- if (pc > prof_len - 1)
- pc = prof_len - 1;
- atomic_inc((atomic_t *)&prof_buffer[pc]);
+ if ((1<<smp_processor_id()) & prof_cpu_mask)
+ profile_tick(pc);
}
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/