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

Unified Diff: src/compiler/bytecode-liveness-map.cc

Issue 2552723004: [ignition/turbofan] Wrap bytecode liveness bitvectors (Closed)
Patch Set: Created 4 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/compiler/bytecode-liveness-map.h ('k') | test/unittests/compiler/bytecode-analysis-unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler/bytecode-liveness-map.cc
diff --git a/src/compiler/bytecode-liveness-map.cc b/src/compiler/bytecode-liveness-map.cc
index 899e155b888d2620962eb5c66ebffcde0520dd92..ba98dec6e51af7fbb0f62acdc745e4c261eacfe9 100644
--- a/src/compiler/bytecode-liveness-map.cc
+++ b/src/compiler/bytecode-liveness-map.cc
@@ -8,9 +8,9 @@ namespace v8 {
namespace internal {
namespace compiler {
-Liveness::Liveness(int size, Zone* zone)
- : in(new (zone) BitVector(size, zone)),
- out(new (zone) BitVector(size, zone)) {}
+BytecodeLiveness::BytecodeLiveness(int register_count, Zone* zone)
+ : in(new (zone) BytecodeLivenessState(register_count, zone)),
+ out(new (zone) BytecodeLivenessState(register_count, zone)) {}
BytecodeLivenessMap::BytecodeLivenessMap(int bytecode_size, Zone* zone)
: liveness_map_(base::bits::RoundUpToPowerOfTwo32(bytecode_size / 4 + 1),
@@ -19,20 +19,21 @@ BytecodeLivenessMap::BytecodeLivenessMap(int bytecode_size, Zone* zone)
uint32_t OffsetHash(int offset) { return offset; }
-Liveness& BytecodeLivenessMap::InitializeLiveness(int offset, int size,
- Zone* zone) {
+BytecodeLiveness& BytecodeLivenessMap::InitializeLiveness(int offset,
+ int register_count,
+ Zone* zone) {
return liveness_map_
.LookupOrInsert(offset, OffsetHash(offset),
- [&]() { return Liveness(size, zone); },
+ [&]() { return BytecodeLiveness(register_count, zone); },
ZoneAllocationPolicy(zone))
->value;
}
-Liveness& BytecodeLivenessMap::GetLiveness(int offset) {
+BytecodeLiveness& BytecodeLivenessMap::GetLiveness(int offset) {
return liveness_map_.Lookup(offset, OffsetHash(offset))->value;
}
-const Liveness& BytecodeLivenessMap::GetLiveness(int offset) const {
+const BytecodeLiveness& BytecodeLivenessMap::GetLiveness(int offset) const {
return liveness_map_.Lookup(offset, OffsetHash(offset))->value;
}
« no previous file with comments | « src/compiler/bytecode-liveness-map.h ('k') | test/unittests/compiler/bytecode-analysis-unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698