OLD | NEW |
1 // Copyright 2011 the V8 project authors. All rights reserved. | 1 // Copyright 2011 the V8 project authors. All rights reserved. |
2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
4 // met: | 4 // met: |
5 // | 5 // |
6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
(...skipping 588 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
599 LChunkBuilder builder(info, this, &allocator); | 599 LChunkBuilder builder(info, this, &allocator); |
600 LChunk* chunk = builder.Build(); | 600 LChunk* chunk = builder.Build(); |
601 if (chunk == NULL) return Handle<Code>::null(); | 601 if (chunk == NULL) return Handle<Code>::null(); |
602 | 602 |
603 if (!FLAG_alloc_lithium) return Handle<Code>::null(); | 603 if (!FLAG_alloc_lithium) return Handle<Code>::null(); |
604 | 604 |
605 allocator.Allocate(chunk); | 605 allocator.Allocate(chunk); |
606 | 606 |
607 if (!FLAG_use_lithium) return Handle<Code>::null(); | 607 if (!FLAG_use_lithium) return Handle<Code>::null(); |
608 | 608 |
609 MacroAssembler assembler(NULL, 0); | 609 MacroAssembler assembler(info->isolate(), NULL, 0); |
610 LCodeGen generator(chunk, &assembler, info); | 610 LCodeGen generator(chunk, &assembler, info); |
611 | 611 |
612 if (FLAG_eliminate_empty_blocks) { | 612 if (FLAG_eliminate_empty_blocks) { |
613 chunk->MarkEmptyBlocks(); | 613 chunk->MarkEmptyBlocks(); |
614 } | 614 } |
615 | 615 |
616 if (generator.GenerateCode()) { | 616 if (generator.GenerateCode()) { |
617 if (FLAG_trace_codegen) { | 617 if (FLAG_trace_codegen) { |
618 PrintF("Crankshaft Compiler - "); | 618 PrintF("Crankshaft Compiler - "); |
619 } | 619 } |
(...skipping 5331 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5951 } | 5951 } |
5952 } | 5952 } |
5953 | 5953 |
5954 #ifdef DEBUG | 5954 #ifdef DEBUG |
5955 if (graph_ != NULL) graph_->Verify(); | 5955 if (graph_ != NULL) graph_->Verify(); |
5956 if (allocator_ != NULL) allocator_->Verify(); | 5956 if (allocator_ != NULL) allocator_->Verify(); |
5957 #endif | 5957 #endif |
5958 } | 5958 } |
5959 | 5959 |
5960 } } // namespace v8::internal | 5960 } } // namespace v8::internal |
OLD | NEW |