98 void VM_ThreadStop::doit() {
99 assert(SafepointSynchronize::is_at_safepoint(), "must be at a safepoint");
100 ThreadsListHandle tlh;
101 JavaThread* target = java_lang_Thread::thread(target_thread());
102 // Note that this now allows multiple ThreadDeath exceptions to be
103 // thrown at a thread.
104 if (target != NULL && (!EnableThreadSMRExtraValidityChecks || tlh.includes(target))) {
105 // The target thread has run and has not exited yet.
106 target->send_thread_stop(throwable());
107 }
108 }
109
110 void VM_ClearICs::doit() {
111 if (_preserve_static_stubs) {
112 CodeCache::cleanup_inline_caches();
113 } else {
114 CodeCache::clear_inline_caches();
115 }
116 }
117
118 void VM_Deoptimize::doit() {
119 // We do not want any GCs to happen while we are in the middle of this VM operation
120 ResourceMark rm;
121 DeoptimizationMarker dm;
122
123 // Deoptimize all activations depending on marked nmethods
124 Deoptimization::deoptimize_dependents();
125
126 // Make the dependent methods not entrant
127 CodeCache::make_marked_nmethods_not_entrant();
128 }
129
130 void VM_MarkActiveNMethods::doit() {
131 NMethodSweeper::mark_active_nmethods();
132 }
133
134 VM_DeoptimizeFrame::VM_DeoptimizeFrame(JavaThread* thread, intptr_t* id, int reason) {
135 _thread = thread;
136 _id = id;
137 _reason = reason;
138 }
139
140
141 void VM_DeoptimizeFrame::doit() {
142 assert(_reason > Deoptimization::Reason_none && _reason < Deoptimization::Reason_LIMIT, "invalid deopt reason");
143 Deoptimization::deoptimize_frame_internal(_thread, _id, (Deoptimization::DeoptReason)_reason);
144 }
145
146
147 #ifndef PRODUCT
148
149 void VM_DeoptimizeAll::doit() {
|
98 void VM_ThreadStop::doit() {
99 assert(SafepointSynchronize::is_at_safepoint(), "must be at a safepoint");
100 ThreadsListHandle tlh;
101 JavaThread* target = java_lang_Thread::thread(target_thread());
102 // Note that this now allows multiple ThreadDeath exceptions to be
103 // thrown at a thread.
104 if (target != NULL && (!EnableThreadSMRExtraValidityChecks || tlh.includes(target))) {
105 // The target thread has run and has not exited yet.
106 target->send_thread_stop(throwable());
107 }
108 }
109
110 void VM_ClearICs::doit() {
111 if (_preserve_static_stubs) {
112 CodeCache::cleanup_inline_caches();
113 } else {
114 CodeCache::clear_inline_caches();
115 }
116 }
117
118 void VM_MarkActiveNMethods::doit() {
119 NMethodSweeper::mark_active_nmethods();
120 }
121
122 VM_DeoptimizeFrame::VM_DeoptimizeFrame(JavaThread* thread, intptr_t* id, int reason) {
123 _thread = thread;
124 _id = id;
125 _reason = reason;
126 }
127
128
129 void VM_DeoptimizeFrame::doit() {
130 assert(_reason > Deoptimization::Reason_none && _reason < Deoptimization::Reason_LIMIT, "invalid deopt reason");
131 Deoptimization::deoptimize_frame_internal(_thread, _id, (Deoptimization::DeoptReason)_reason);
132 }
133
134
135 #ifndef PRODUCT
136
137 void VM_DeoptimizeAll::doit() {
|