projects
/
dosdemo
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
fixed warnings
[dosdemo]
/
src
/
util.h
diff --git
a/src/util.h
b/src/util.h
index
6d200b7
..
76dd044
100644
(file)
--- a/
src/util.h
+++ b/
src/util.h
@@
-43,6
+43,9
@@
void perf_end(void);
"sub eax, [perf_start_count]" \
"mov [perf_interval_count], eax" \
modify [eax ebx ecx edx];
"sub eax, [perf_start_count]" \
"mov [perf_interval_count], eax" \
modify [eax ebx ecx edx];
+
+void debug_break(void);
+#pragma aux debug_break = "int 3";
#endif
#ifdef __GNUC__
#endif
#ifdef __GNUC__
@@
-63,6
+66,9
@@
void perf_end(void);
: "=m"(perf_interval_count) \
: "m"(perf_start_count) \
: "%eax", "%ebx", "%ecx", "%edx")
: "=m"(perf_interval_count) \
: "m"(perf_start_count) \
: "%eax", "%ebx", "%ecx", "%edx")
+
+#define debug_break() \
+ asm volatile ("int $3")
#endif
#ifdef _MSC_VER
#endif
#ifdef _MSC_VER
@@
-86,6
+92,11
@@
void perf_end(void);
mov [perf_interval_count], eax \
} \
} while(0)
mov [perf_interval_count], eax \
} \
} while(0)
+
+#define debug_break() \
+ do { \
+ __asm { int 3 } \
+ } while(0)
#endif
#endif /* UTIL_H_ */
#endif
#endif /* UTIL_H_ */