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

Unified Diff: src/compiler.h

Issue 100613004: Use optimized code map to cache OSR code. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: correctly upload stuff Created 7 years 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
« no previous file with comments | « src/code-stubs-hydrogen.cc ('k') | src/compiler.cc » ('j') | src/runtime.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler.h
diff --git a/src/compiler.h b/src/compiler.h
index 080907e390ca3e3b14adebfb02b90a61c1867e91..1d5fb7a7b5e8a90aac4fc6113435886844fdf4b0 100644
--- a/src/compiler.h
+++ b/src/compiler.h
@@ -84,7 +84,6 @@ class CompilationInfo {
ScriptDataImpl* pre_parse_data() const { return pre_parse_data_; }
Handle<Context> context() const { return context_; }
BailoutId osr_ast_id() const { return osr_ast_id_; }
- uint32_t osr_pc_offset() const { return osr_pc_offset_; }
int opt_count() const { return opt_count_; }
int num_parameters() const;
int num_heap_slots() const;
@@ -311,12 +310,8 @@ class CompilationInfo {
return abort_due_to_dependency_;
}
- void set_osr_pc_offset(uint32_t pc_offset) {
- osr_pc_offset_ = pc_offset;
- }
-
- bool HasSameOsrEntry(Handle<JSFunction> function, uint32_t pc_offset) {
- return osr_pc_offset_ == pc_offset && function.is_identical_to(closure_);
+ bool HasSameOsrEntry(Handle<JSFunction> function, BailoutId osr_ast_id) {
+ return osr_ast_id == osr_ast_id_ && function.is_identical_to(closure_);
}
protected:
@@ -413,9 +408,6 @@ class CompilationInfo {
// Compilation mode flag and whether deoptimization is allowed.
Mode mode_;
BailoutId osr_ast_id_;
- // The pc_offset corresponding to osr_ast_id_ in unoptimized code.
- // We can look this up in the back edge table, but cache it for quick access.
- uint32_t osr_pc_offset_;
// Flag whether compilation needs to be aborted due to dependency change.
bool abort_due_to_dependency_;
@@ -626,7 +618,7 @@ class Compiler : public AllStatic {
static bool CompileLazy(CompilationInfo* info);
static bool RecompileConcurrent(Handle<JSFunction> function,
- uint32_t osr_pc_offset = 0);
+ BailoutId osr_ast_id = BailoutId::None());
// Compile a shared function info object (the function is possibly lazily
// compiled).
« no previous file with comments | « src/code-stubs-hydrogen.cc ('k') | src/compiler.cc » ('j') | src/runtime.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698