* src/threads/thread.hpp (thread_set_object, thread_get_object): Removed.
[cacao.git] / src / vm / exceptions.cpp
index fcfe94d30f1472e9f7ddb5e9f44f4227e97f6c9f..707efa4c31ea88a321104f91070972f9ae1c2a21 100644 (file)
@@ -1,6 +1,6 @@
 /* src/vm/exceptions.cpp - exception related functions
 
-   Copyright (C) 1996-2005, 2006, 2007, 2008
+   Copyright (C) 1996-2011
    CACAOVM - Verein zur Foerderung der freien virtuellen Maschine CACAO
 
    This file is part of CACAO.
 #include <string.h>
 #include <stdarg.h>
 #include <stdlib.h>
-#include <sys/mman.h>
 
 #include "vm/types.h"
 
 #include "md-abi.h"
 
-#include "mm/memory.h"
+#include "mm/memory.hpp"
 
 #include "native/llni.h"
-#include "native/native.h"
+#include "native/native.hpp"
 
-#include "threads/lock-common.h"
+#include "threads/lock.hpp"
 #include "threads/thread.hpp"
 
 #include "toolbox/util.h"
 
 #include "vm/jit/builtin.hpp"
-#include "vm/class.h"
+#include "vm/class.hpp"
 #include "vm/exceptions.hpp"
 #include "vm/global.h"
 #include "vm/globals.hpp"
 #include "vm/javaobjects.hpp"
-#include "vm/loader.h"
-#include "vm/method.h"
+#include "vm/loader.hpp"
+#include "vm/method.hpp"
 #include "vm/options.h"
 #include "vm/os.hpp"
 #include "vm/string.hpp"
@@ -61,8 +60,8 @@
 #include "vm/jit/asmpart.h"
 #include "vm/jit/jit.hpp"
 #include "vm/jit/methodheader.h"
-#include "vm/jit/patcher-common.h"
-#include "vm/jit/show.h"
+#include "vm/jit/patcher-common.hpp"
+#include "vm/jit/show.hpp"
 #include "vm/jit/stacktrace.hpp"
 #include "vm/jit/trace.hpp"
 
@@ -241,7 +240,7 @@ static void exceptions_abort(utf *classname, utf *message)
 
        log_finish();
 
-       VM::get_current()->abort("Aborting...");
+       os::abort("Aborting...");
 }
 
 
@@ -2011,7 +2010,7 @@ void exceptions_print_stacktrace(void)
                                                                         false);
 
                if (m == NULL)
-                       VM::get_current()->abort("exceptions_print_stacktrace: printStackTrace()V not found");
+                       os::abort("exceptions_print_stacktrace: printStackTrace()V not found");
 
                /* Print message. */
 
@@ -2022,7 +2021,7 @@ void exceptions_print_stacktrace(void)
                   need it afterwards. */
 
                t  = thread_get_current();
-               to = (java_lang_Thread *) thread_get_object(t);
+               to = (java_lang_Thread *) LLNI_WRAP(t->object);
 
                if (to != NULL) {
                        fprintf(stderr, "in thread \"");