diff options
Diffstat (limited to 'firmware')
-rw-r--r-- | firmware/profile.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/firmware/profile.c b/firmware/profile.c index 8ad46515f8..f6cffa7c53 100644 --- a/firmware/profile.c +++ b/firmware/profile.c | |||
@@ -76,10 +76,14 @@ static void profile_timer_unregister(void); | |||
76 | static void write_function_recursive(int fd, struct pfd_struct *pfd, int depth); | 76 | static void write_function_recursive(int fd, struct pfd_struct *pfd, int depth); |
77 | 77 | ||
78 | /* Be careful to use the right one for the size of your variable */ | 78 | /* Be careful to use the right one for the size of your variable */ |
79 | #ifdef CPU_COLDFIRE | ||
79 | #define ADDQI_L(_var,_value) \ | 80 | #define ADDQI_L(_var,_value) \ |
80 | asm ("addq.l %[value],%[var];" \ | 81 | asm ("addq.l %[value],%[var];" \ |
81 | : [var] "+g" (_var) \ | 82 | : [var] "+g" (_var) \ |
82 | : [value] "I" (_value) ) | 83 | : [value] "I" (_value) ) |
84 | #else | ||
85 | #define ADDQI_L(var, value) var += value | ||
86 | #endif | ||
83 | 87 | ||
84 | void profile_thread_stopped(int current_thread) { | 88 | void profile_thread_stopped(int current_thread) { |
85 | if (current_thread == profiling_thread) { | 89 | if (current_thread == profiling_thread) { |
@@ -227,7 +231,6 @@ void profile_func_enter(void *self_pc, void *from_pc) { | |||
227 | if (profiling) { | 231 | if (profiling) { |
228 | return; | 232 | return; |
229 | } | 233 | } |
230 | /* this is equivalent to 'profiling = PROF_BUSY;' but it's faster */ | ||
231 | profiling = PROF_BUSY; | 234 | profiling = PROF_BUSY; |
232 | /* A check that the PC is in the code range here wouldn't hurt, but this is | 235 | /* A check that the PC is in the code range here wouldn't hurt, but this is |
233 | * logically guaranteed to be a valid address unless the constants are | 236 | * logically guaranteed to be a valid address unless the constants are |