equal
deleted
inserted
replaced
24 #ifndef SHARE_GC_Z_ZCPU_HPP |
24 #ifndef SHARE_GC_Z_ZCPU_HPP |
25 #define SHARE_GC_Z_ZCPU_HPP |
25 #define SHARE_GC_Z_ZCPU_HPP |
26 |
26 |
27 #include "memory/allocation.hpp" |
27 #include "memory/allocation.hpp" |
28 #include "memory/padded.hpp" |
28 #include "memory/padded.hpp" |
|
29 #include "utilities/globalDefinitions.hpp" |
29 |
30 |
30 class Thread; |
31 class Thread; |
31 |
32 |
32 class ZCPU : public AllStatic { |
33 class ZCPU : public AllStatic { |
33 private: |
34 private: |
34 struct ZCPUAffinity { |
35 struct ZCPUAffinity { |
35 Thread* _thread; |
36 Thread* _thread; |
36 }; |
37 }; |
37 |
38 |
38 static PaddedEnd<ZCPUAffinity>* _affinity; |
39 static PaddedEnd<ZCPUAffinity>* _affinity; |
39 static __thread Thread* _self; |
40 static THREAD_LOCAL Thread* _self; |
40 static __thread uint32_t _cpu; |
41 static THREAD_LOCAL uint32_t _cpu; |
41 |
42 |
42 public: |
43 public: |
43 static void initialize(); |
44 static void initialize(); |
44 |
45 |
45 static uint32_t count(); |
46 static uint32_t count(); |