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

Unified Diff: src/compiler/bytecode-loop-analysis.h

Issue 2519983002: [ignition] Replace branch+loop analysis with a single pass (Closed)
Patch Set: Update comments Created 4 years, 1 month 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/compiler/bytecode-graph-builder.cc ('k') | src/compiler/bytecode-loop-analysis.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler/bytecode-loop-analysis.h
diff --git a/src/compiler/bytecode-loop-analysis.h b/src/compiler/bytecode-loop-analysis.h
deleted file mode 100644
index 1a86d7b81f06f252b67d16d674d64f1c3d88d825..0000000000000000000000000000000000000000
--- a/src/compiler/bytecode-loop-analysis.h
+++ /dev/null
@@ -1,67 +0,0 @@
-// Copyright 2016 the V8 project authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#ifndef V8_COMPILER_BYTECODE_LOOP_ANALYSIS_H_
-#define V8_COMPILER_BYTECODE_LOOP_ANALYSIS_H_
-
-#include "src/handles.h"
-#include "src/zone/zone-containers.h"
-
-namespace v8 {
-namespace internal {
-
-class BytecodeArray;
-
-namespace compiler {
-
-class BytecodeBranchAnalysis;
-
-class BytecodeLoopAnalysis BASE_EMBEDDED {
- public:
- BytecodeLoopAnalysis(Handle<BytecodeArray> bytecode_array,
- const BytecodeBranchAnalysis* branch_analysis,
- Zone* zone);
-
- // Analyze the bytecodes to find the branch sites and their
- // targets. No other methods in this class return valid information
- // until this has been called.
- void Analyze();
-
- // Get the loop header offset of the containing loop for arbitrary
- // {offset}, or -1 if the {offset} is not inside any loop.
- int GetLoopOffsetFor(int offset) const;
- // Gets the loop header offset of the parent loop of the loop header
- // at {header_offset}, or -1 for outer-most loops.
- int GetParentLoopFor(int header_offset) const;
-
- private:
- void AddLoopEntry(int entry_offset);
- void AddBranch(int origin_offset, int target_offset);
-
- Zone* zone() const { return zone_; }
- Handle<BytecodeArray> bytecode_array() const { return bytecode_array_; }
-
- Handle<BytecodeArray> bytecode_array_;
- const BytecodeBranchAnalysis* branch_analysis_;
- Zone* zone_;
-
- int current_loop_offset_;
- bool found_current_backedge_;
-
- // Map from the offset of a backedge jump to the offset of the corresponding
- // loop header. There might be multiple backedges for do-while loops.
- ZoneMap<int, int> backedge_to_header_;
- // Map from the offset of a loop header to the offset of its parent's loop
- // header. This map will have as many entries as there are loops in the
- // function.
- ZoneMap<int, int> loop_header_to_parent_;
-
- DISALLOW_COPY_AND_ASSIGN(BytecodeLoopAnalysis);
-};
-
-} // namespace compiler
-} // namespace internal
-} // namespace v8
-
-#endif // V8_COMPILER_BYTECODE_LOOP_ANALYSIS_H_
« no previous file with comments | « src/compiler/bytecode-graph-builder.cc ('k') | src/compiler/bytecode-loop-analysis.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698