Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(664)

Unified Diff: runtime/vm/thread.h

Issue 1156593002: Cache current thread in a reserved register and use it in LoadIsolate (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Address review comments. Created 5 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« runtime/vm/flow_graph_compiler.cc ('K') | « runtime/vm/stub_code_x64.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/thread.h
diff --git a/runtime/vm/thread.h b/runtime/vm/thread.h
index 056430cc421571032ada75c86f47bc71b4feecfe..457f1a4ed6c32c3996d1b18286ae85f82902dc67 100644
--- a/runtime/vm/thread.h
+++ b/runtime/vm/thread.h
@@ -56,6 +56,9 @@ class Thread {
// The isolate that this thread is operating on, or NULL if none.
Isolate* isolate() const { return isolate_; }
+ static intptr_t isolate_offset() {
+ return OFFSET_OF(Thread, isolate_);
+ }
// The (topmost) CHA for the compilation in the isolate of this thread.
// TODO(23153): Move this out of Isolate/Thread.
« runtime/vm/flow_graph_compiler.cc ('K') | « runtime/vm/stub_code_x64.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698