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

Unified Diff: src/objects.cc

Issue 159783002: Re-optimize faster after making a pretenuring decision. Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 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
« src/objects.h ('K') | « src/objects.h ('k') | src/objects-inl.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/objects.cc
diff --git a/src/objects.cc b/src/objects.cc
index f9a52e59c7455d2986ade2ac70296c2dd5db5034..07452c68a55a9f4685499d63d2a192ae37acd15f 100644
--- a/src/objects.cc
+++ b/src/objects.cc
@@ -11836,6 +11836,23 @@ Handle<FixedArray> JSObject::SetFastElementsCapacityAndLength(
}
+void Code::GetICCounts(int* ic_with_type_info_count,
+ int* ic_total_count,
+ int* percentage) {
+ *ic_total_count = 0;
+ *ic_with_type_info_count = 0;
+ Object* raw_info = type_feedback_info();
+ if (raw_info->IsTypeFeedbackInfo()) {
+ TypeFeedbackInfo* info = TypeFeedbackInfo::cast(raw_info);
+ *ic_with_type_info_count = info->ic_with_type_info_count();
+ *ic_total_count = info->ic_total_count();
+ }
+ *percentage = *ic_total_count > 0
+ ? 100 * *ic_with_type_info_count / *ic_total_count
+ : 100;
+}
+
+
void JSObject::SetFastDoubleElementsCapacityAndLength(Handle<JSObject> object,
int capacity,
int length) {
@@ -12315,7 +12332,8 @@ bool DependentCode::Contains(DependencyGroup group, Code* code) {
bool DependentCode::MarkCodeForDeoptimization(
Isolate* isolate,
- DependentCode::DependencyGroup group) {
+ DependentCode::DependencyGroup group,
+ bool instant_optimization) {
DisallowHeapAllocation no_allocation_scope;
DependentCode::GroupStartIndexes starts(this);
int start = starts.at(group);
@@ -12331,6 +12349,7 @@ bool DependentCode::MarkCodeForDeoptimization(
if (!code->marked_for_deoptimization()) {
code->set_marked_for_deoptimization(true);
marked = true;
+ if (instant_optimization) code->set_marked_for_deoptimization(true);
titzer 2014/05/12 12:05:24 You're setting the wrong thing here, I think. Why
Hannes Payer (out of office) 2014/05/12 16:31:19 Done, that was a renaming mistake.
}
} else {
CompilationInfo* info = compilation_info_at(i);
« src/objects.h ('K') | « src/objects.h ('k') | src/objects-inl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698