Commit 705735ce authored by titzer@chromium.org's avatar titzer@chromium.org

Remove previous_ast_id and related code in hydrogen.

BUG=

Review URL: https://codereview.chromium.org/14178011

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@14308 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
parent 17629e02
......@@ -106,8 +106,7 @@ bool CodeStubGraphBuilderBase::BuildGraph() {
Zone* zone = this->zone();
int param_count = descriptor_->register_param_count_;
HEnvironment* start_environment = graph()->start_environment();
HBasicBlock* next_block =
CreateBasicBlock(start_environment, BailoutId::StubEntry());
HBasicBlock* next_block = CreateBasicBlock(start_environment);
current_block()->Goto(next_block);
next_block->SetJoinId(BailoutId::StubEntry());
set_current_block(next_block);
......@@ -204,14 +203,14 @@ HValue* CodeStubGraphBuilder<FastCloneShallowArrayStub>::BuildCodeStub() {
NULL,
FAST_ELEMENTS));
CheckBuilder builder(this);
CheckBuilder builder(this, BailoutId::StubEntry());
builder.CheckNotUndefined(boilerplate);
if (mode == FastCloneShallowArrayStub::CLONE_ANY_ELEMENTS) {
HValue* elements =
AddInstruction(new(zone) HLoadElements(boilerplate, NULL));
IfBuilder if_fixed_cow(this);
IfBuilder if_fixed_cow(this, BailoutId::StubEntry());
if_fixed_cow.BeginIfMapEquals(elements, factory->fixed_cow_array_map());
environment()->Push(BuildCloneShallowArray(context(),
boilerplate,
......@@ -220,7 +219,7 @@ HValue* CodeStubGraphBuilder<FastCloneShallowArrayStub>::BuildCodeStub() {
0/*copy-on-write*/));
if_fixed_cow.BeginElse();
IfBuilder if_fixed(this);
IfBuilder if_fixed(this, BailoutId::StubEntry());
if_fixed.BeginIfMapEquals(elements, factory->fixed_array_map());
environment()->Push(BuildCloneShallowArray(context(),
boilerplate,
......@@ -265,7 +264,7 @@ HValue* CodeStubGraphBuilder<FastCloneShallowObjectStub>::BuildCodeStub() {
NULL,
FAST_ELEMENTS));
CheckBuilder builder(this);
CheckBuilder builder(this, BailoutId::StubEntry());
builder.CheckNotUndefined(boilerplate);
int size = JSObject::kHeaderSize + casted_stub()->length() * kPointerSize;
......@@ -357,7 +356,7 @@ HValue* CodeStubGraphBuilder<TransitionElementsKindStub>::BuildCodeStub() {
ElementsKind to_kind = casted_stub()->to_kind();
BuildNewSpaceArrayCheck(array_length, to_kind);
IfBuilder if_builder(this);
IfBuilder if_builder(this, BailoutId::StubEntry());
if_builder.BeginIf(array_length, graph()->GetConstant0(), Token::EQ);
......@@ -376,7 +375,8 @@ HValue* CodeStubGraphBuilder<TransitionElementsKindStub>::BuildCodeStub() {
BuildCopyElements(context(), elements,
casted_stub()->from_kind(), new_elements,
to_kind, array_length, elements_length);
to_kind, array_length, elements_length,
BailoutId::StubEntry());
Factory* factory = isolate()->factory();
......
This diff is collapsed.
......@@ -108,7 +108,7 @@ class HBasicBlock: public ZoneObject {
bool Dominates(HBasicBlock* other) const;
int LoopNestingDepth() const;
void SetInitialEnvironment(HEnvironment* env, BailoutId previous_id);
void SetInitialEnvironment(HEnvironment* env);
void ClearEnvironment() { last_environment_ = NULL; }
bool HasEnvironment() const { return last_environment_ != NULL; }
void UpdateEnvironment(HEnvironment* env) { last_environment_ = env; }
......@@ -484,8 +484,6 @@ class HEnvironment: public ZoneObject {
BailoutId ast_id() const { return ast_id_; }
void set_ast_id(BailoutId id) { ast_id_ = id; }
BailoutId previous_ast_id() const { return previous_ast_id_; }
void set_previous_ast_id(BailoutId id) { previous_ast_id_ = id; }
HEnterInlined* entry() const { return entry_; }
void set_entry(HEnterInlined* entry) { entry_ = entry; }
......@@ -647,7 +645,6 @@ class HEnvironment: public ZoneObject {
int pop_count_;
int push_count_;
BailoutId ast_id_;
BailoutId previous_ast_id_;
Zone* zone_;
};
......@@ -906,9 +903,8 @@ class HGraphBuilder {
protected:
virtual bool BuildGraph() = 0;
HBasicBlock* CreateBasicBlock(HEnvironment* envy,
BailoutId previous_ast_id);
HBasicBlock* CreateLoopHeaderBlock(BailoutId previous_ast_id);
HBasicBlock* CreateBasicBlock(HEnvironment* envy);
HBasicBlock* CreateLoopHeaderBlock();
// Building common constructs
HInstruction* BuildExternalArrayElementAccess(
......@@ -956,7 +952,7 @@ class HGraphBuilder {
class CheckBuilder {
public:
explicit CheckBuilder(HGraphBuilder* builder);
explicit CheckBuilder(HGraphBuilder* builder, BailoutId id);
~CheckBuilder() {
if (!finished_) End();
}
......@@ -978,7 +974,7 @@ class HGraphBuilder {
class IfBuilder {
public:
explicit IfBuilder(HGraphBuilder* builder);
explicit IfBuilder(HGraphBuilder* builder, BailoutId id);
~IfBuilder() {
if (!finished_) End();
}
......@@ -1017,7 +1013,8 @@ class HGraphBuilder {
LoopBuilder(HGraphBuilder* builder,
HValue* context,
Direction direction);
Direction direction,
BailoutId id);
~LoopBuilder() {
ASSERT(finished_);
}
......@@ -1066,7 +1063,8 @@ class HGraphBuilder {
HValue* BuildAllocateElements(HValue* context,
ElementsKind kind,
HValue* capacity);
HValue* capacity,
BailoutId ast_id);
void BuildInitializeElements(HValue* elements,
ElementsKind kind,
......@@ -1080,13 +1078,15 @@ class HGraphBuilder {
HValue* elements,
ElementsKind kind,
HValue* length,
HValue* new_capacity);
HValue* new_capacity,
BailoutId ast_id);
void BuildFillElementsWithHole(HValue* context,
HValue* elements,
ElementsKind elements_kind,
HValue* from,
HValue* to);
HValue* to,
BailoutId ast_id);
void BuildCopyElements(HValue* context,
HValue* from_elements,
......@@ -1094,7 +1094,8 @@ class HGraphBuilder {
HValue* to_elements,
ElementsKind to_elements_kind,
HValue* length,
HValue* capacity);
HValue* capacity,
BailoutId ast_id);
HValue* BuildCloneShallowArray(HContext* context,
HValue* boilerplate,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment