comparison src/share/vm/runtime/threadLocalStorage.hpp @ 1972:f95d63e2154a

6989984: Use standard include model for Hospot Summary: Replaced MakeDeps and the includeDB files with more standardized solutions. Reviewed-by: coleenp, kvn, kamg
author stefank
date Tue, 23 Nov 2010 13:22:55 -0800
parents c18cbe5936b8
children b92c45f2bc75
comparison
equal deleted inserted replaced
1971:e33f46fc48ed 1972:f95d63e2154a
1 /* 1 /*
2 * Copyright (c) 1997, 2008, Oracle and/or its affiliates. All rights reserved. 2 * Copyright (c) 1997, 2010, Oracle and/or its affiliates. All rights reserved.
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 * 4 *
5 * This code is free software; you can redistribute it and/or modify it 5 * This code is free software; you can redistribute it and/or modify it
6 * under the terms of the GNU General Public License version 2 only, as 6 * under the terms of the GNU General Public License version 2 only, as
7 * published by the Free Software Foundation. 7 * published by the Free Software Foundation.
20 * or visit www.oracle.com if you need additional information or have any 20 * or visit www.oracle.com if you need additional information or have any
21 * questions. 21 * questions.
22 * 22 *
23 */ 23 */
24 24
25 #ifndef SHARE_VM_RUNTIME_THREADLOCALSTORAGE_HPP
26 #define SHARE_VM_RUNTIME_THREADLOCALSTORAGE_HPP
27
28 #include "gc_implementation/shared/gcUtil.hpp"
29 #include "runtime/os.hpp"
30 #include "utilities/top.hpp"
31
25 // Interface for thread local storage 32 // Interface for thread local storage
26 33
27 // Fast variant of ThreadLocalStorage::get_thread_slow 34 // Fast variant of ThreadLocalStorage::get_thread_slow
28 extern "C" Thread* get_thread(); 35 extern "C" Thread* get_thread();
29 36
35 static void set_thread(Thread* thread); 42 static void set_thread(Thread* thread);
36 static Thread* get_thread_slow(); 43 static Thread* get_thread_slow();
37 static void invalidate_all() { pd_invalidate_all(); } 44 static void invalidate_all() { pd_invalidate_all(); }
38 45
39 // Machine dependent stuff 46 // Machine dependent stuff
40 #include "incls/_threadLS_pd.hpp.incl" 47 #ifdef TARGET_OS_ARCH_linux_x86
48 # include "threadLS_linux_x86.hpp"
49 #endif
50 #ifdef TARGET_OS_ARCH_linux_sparc
51 # include "threadLS_linux_sparc.hpp"
52 #endif
53 #ifdef TARGET_OS_ARCH_linux_zero
54 # include "threadLS_linux_zero.hpp"
55 #endif
56 #ifdef TARGET_OS_ARCH_solaris_x86
57 # include "threadLS_solaris_x86.hpp"
58 #endif
59 #ifdef TARGET_OS_ARCH_solaris_sparc
60 # include "threadLS_solaris_sparc.hpp"
61 #endif
62 #ifdef TARGET_OS_ARCH_windows_x86
63 # include "threadLS_windows_x86.hpp"
64 #endif
65
41 66
42 public: 67 public:
43 // Accessor 68 // Accessor
44 static inline int thread_index() { return _thread_index; } 69 static inline int thread_index() { return _thread_index; }
45 static inline void set_thread_index(int index) { _thread_index = index; } 70 static inline void set_thread_index(int index) { _thread_index = index; }
59 static void pd_init(); 84 static void pd_init();
60 // Invalidate any thread cacheing or optimization schemes. 85 // Invalidate any thread cacheing or optimization schemes.
61 static void pd_invalidate_all(); 86 static void pd_invalidate_all();
62 87
63 }; 88 };
89
90 #endif // SHARE_VM_RUNTIME_THREADLOCALSTORAGE_HPP