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