Commit 2b0f88cc authored by sanjoy@chromium.org's avatar sanjoy@chromium.org

Install guards for new invariants required for parallel compilation.

BUG=
TEST=

Review URL: https://chromiumcodereview.appspot.com/10700185

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@12068 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
parent 31027880
...@@ -1711,15 +1711,12 @@ class HGlobalValueNumberer BASE_EMBEDDED { ...@@ -1711,15 +1711,12 @@ class HGlobalValueNumberer BASE_EMBEDDED {
block_side_effects_(graph->blocks()->length(), graph->zone()), block_side_effects_(graph->blocks()->length(), graph->zone()),
loop_side_effects_(graph->blocks()->length(), graph->zone()), loop_side_effects_(graph->blocks()->length(), graph->zone()),
visited_on_paths_(graph->zone(), graph->blocks()->length()) { visited_on_paths_(graph->zone(), graph->blocks()->length()) {
ASSERT(info->isolate()->heap()->allow_allocation(false)); ASSERT(!info->isolate()->heap()->IsAllocationAllowed());
block_side_effects_.AddBlock(GVNFlagSet(), graph_->blocks()->length(), block_side_effects_.AddBlock(GVNFlagSet(), graph_->blocks()->length(),
graph_->zone()); graph_->zone());
loop_side_effects_.AddBlock(GVNFlagSet(), graph_->blocks()->length(), loop_side_effects_.AddBlock(GVNFlagSet(), graph_->blocks()->length(),
graph_->zone()); graph_->zone());
} }
~HGlobalValueNumberer() {
ASSERT(!info_->isolate()->heap()->allow_allocation(true));
}
// Returns true if values with side effects are removed. // Returns true if values with side effects are removed.
bool Analyze(); bool Analyze();
...@@ -3085,6 +3082,9 @@ HGraph* HGraphBuilder::CreateGraph() { ...@@ -3085,6 +3082,9 @@ HGraph* HGraphBuilder::CreateGraph() {
} }
bool HGraph::Optimize(SmartArrayPointer<char>* bailout_reason) { bool HGraph::Optimize(SmartArrayPointer<char>* bailout_reason) {
NoHandleAllocation no_handles;
AssertNoAllocation no_gc;
*bailout_reason = SmartArrayPointer<char>(); *bailout_reason = SmartArrayPointer<char>();
OrderBlocks(); OrderBlocks();
AssignDominators(); AssignDominators();
...@@ -3482,7 +3482,6 @@ void HGraph::EliminateRedundantBoundsChecks(HBasicBlock* bb, ...@@ -3482,7 +3482,6 @@ void HGraph::EliminateRedundantBoundsChecks(HBasicBlock* bb,
void HGraph::EliminateRedundantBoundsChecks() { void HGraph::EliminateRedundantBoundsChecks() {
HPhase phase("H_Eliminate bounds checks", this); HPhase phase("H_Eliminate bounds checks", this);
AssertNoAllocation no_gc;
BoundsCheckTable checks_table(zone()); BoundsCheckTable checks_table(zone());
EliminateRedundantBoundsChecks(entry_block(), &checks_table); EliminateRedundantBoundsChecks(entry_block(), &checks_table);
} }
......
...@@ -391,6 +391,9 @@ Representation LChunk::LookupLiteralRepresentation( ...@@ -391,6 +391,9 @@ Representation LChunk::LookupLiteralRepresentation(
LChunk* LChunk::NewChunk(HGraph* graph) { LChunk* LChunk::NewChunk(HGraph* graph) {
NoHandleAllocation no_handles;
AssertNoAllocation no_gc;
int values = graph->GetMaximumValueID(); int values = graph->GetMaximumValueID();
if (values > LUnallocated::kMaxVirtualRegisters) { if (values > LUnallocated::kMaxVirtualRegisters) {
if (FLAG_trace_bailout) { if (FLAG_trace_bailout) {
......
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