Merge zizzer.eecs.umich.edu:/z/m5/Bitkeeper/m5
[gem5.git] / sim / debug.cc
index 293edcbe2746557268a827a89b630b158a933344..09e5346a83697859c0bf7b278c477f3e57566e30 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2003-2004 The Regents of The University of Michigan
+ * Copyright (c) 2003-2005 The Regents of The University of Michigan
  * All rights reserved.
  *
  * Redistribution and use in source and binary forms, with or without
 
 using namespace std;
 
-#ifdef DEBUG
 void
 debug_break()
 {
+#ifndef NDEBUG
     kill(getpid(), SIGTRAP);
-}
+#else
+    cprintf("debug_break suppressed, compiled with NDEBUG\n");
 #endif
+}
 
 //
 // Debug event: place a breakpoint on the process function and