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

Unified Diff: src/safepoint-table.cc

Issue 6347067: Fix potential overwriting of debug jumps of following code. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge/build-x64
Patch Set: Addressed review comments. Created 9 years, 11 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
« no previous file with comments | « src/safepoint-table.h ('k') | src/x64/assembler-x64.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/safepoint-table.cc
diff --git a/src/safepoint-table.cc b/src/safepoint-table.cc
index 4db3d9087595bfa68cb8b08ebbca204012390fdb..d2ec54c38874c9782c35f0ca9663482024787318 100644
--- a/src/safepoint-table.cc
+++ b/src/safepoint-table.cc
@@ -230,4 +230,24 @@ uint32_t SafepointTableBuilder::EncodeExceptPC(const DeoptimizationInfo& info) {
}
+int SafepointTableBuilder::CountShortDeoptimizationIntervals(unsigned limit) {
+ int result = 0;
+ if (!deoptimization_info_.is_empty()) {
+ unsigned previous_gap_end = deoptimization_info_[0].pc_after_gap;
+ for (int i = 1, n = deoptimization_info_.length(); i < n; i++) {
+ DeoptimizationInfo info = deoptimization_info_[i];
+ if (static_cast<int>(info.deoptimization_index) !=
+ Safepoint::kNoDeoptimizationIndex) {
+ if (previous_gap_end + limit > info.pc) {
+ result++;
+ }
+ previous_gap_end = info.pc_after_gap;
+ }
+ }
+ }
+ return result;
+}
+
+
+
} } // namespace v8::internal
« no previous file with comments | « src/safepoint-table.h ('k') | src/x64/assembler-x64.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698