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

Side by Side Diff: src/compiler/instruction-selector.h

Issue 2390303002: [turbofan] Check instruction input/output count limits in instruction selector. (Closed)
Patch Set: Fix silly mistakes in the test. Created 4 years, 2 months 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 unified diff | Download patch
« no previous file with comments | « src/compiler/instruction.h ('k') | src/compiler/instruction-selector.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 the V8 project authors. All rights reserved. 1 // Copyright 2014 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef V8_COMPILER_INSTRUCTION_SELECTOR_H_ 5 #ifndef V8_COMPILER_INSTRUCTION_SELECTOR_H_
6 #define V8_COMPILER_INSTRUCTION_SELECTOR_H_ 6 #define V8_COMPILER_INSTRUCTION_SELECTOR_H_
7 7
8 #include <map> 8 #include <map>
9 9
10 #include "src/compiler/common-operator.h" 10 #include "src/compiler/common-operator.h"
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
54 Zone* zone, size_t node_count, Linkage* linkage, 54 Zone* zone, size_t node_count, Linkage* linkage,
55 InstructionSequence* sequence, Schedule* schedule, 55 InstructionSequence* sequence, Schedule* schedule,
56 SourcePositionTable* source_positions, Frame* frame, 56 SourcePositionTable* source_positions, Frame* frame,
57 SourcePositionMode source_position_mode = kCallSourcePositions, 57 SourcePositionMode source_position_mode = kCallSourcePositions,
58 Features features = SupportedFeatures(), 58 Features features = SupportedFeatures(),
59 EnableScheduling enable_scheduling = FLAG_turbo_instruction_scheduling 59 EnableScheduling enable_scheduling = FLAG_turbo_instruction_scheduling
60 ? kEnableScheduling 60 ? kEnableScheduling
61 : kDisableScheduling); 61 : kDisableScheduling);
62 62
63 // Visit code for the entire graph with the included schedule. 63 // Visit code for the entire graph with the included schedule.
64 void SelectInstructions(); 64 bool SelectInstructions();
65 65
66 void StartBlock(RpoNumber rpo); 66 void StartBlock(RpoNumber rpo);
67 void EndBlock(RpoNumber rpo); 67 void EndBlock(RpoNumber rpo);
68 void AddInstruction(Instruction* instr); 68 void AddInstruction(Instruction* instr);
69 69
70 // =========================================================================== 70 // ===========================================================================
71 // ============= Architecture-independent code emission methods. ============= 71 // ============= Architecture-independent code emission methods. =============
72 // =========================================================================== 72 // ===========================================================================
73 73
74 Instruction* Emit(InstructionCode opcode, InstructionOperand output, 74 Instruction* Emit(InstructionCode opcode, InstructionOperand output,
(...skipping 250 matching lines...) Expand 10 before | Expand all | Expand 10 after
325 bool CanProduceSignalingNaN(Node* node); 325 bool CanProduceSignalingNaN(Node* node);
326 326
327 // =========================================================================== 327 // ===========================================================================
328 328
329 Schedule* schedule() const { return schedule_; } 329 Schedule* schedule() const { return schedule_; }
330 Linkage* linkage() const { return linkage_; } 330 Linkage* linkage() const { return linkage_; }
331 InstructionSequence* sequence() const { return sequence_; } 331 InstructionSequence* sequence() const { return sequence_; }
332 Zone* instruction_zone() const { return sequence()->zone(); } 332 Zone* instruction_zone() const { return sequence()->zone(); }
333 Zone* zone() const { return zone_; } 333 Zone* zone() const { return zone_; }
334 334
335 void set_instruction_selection_failed() {
336 instruction_selection_failed_ = true;
337 }
338 bool instruction_selection_failed() { return instruction_selection_failed_; }
339
335 // =========================================================================== 340 // ===========================================================================
336 341
337 Zone* const zone_; 342 Zone* const zone_;
338 Linkage* const linkage_; 343 Linkage* const linkage_;
339 InstructionSequence* const sequence_; 344 InstructionSequence* const sequence_;
340 SourcePositionTable* const source_positions_; 345 SourcePositionTable* const source_positions_;
341 SourcePositionMode const source_position_mode_; 346 SourcePositionMode const source_position_mode_;
342 Features features_; 347 Features features_;
343 Schedule* const schedule_; 348 Schedule* const schedule_;
344 BasicBlock* current_block_; 349 BasicBlock* current_block_;
345 ZoneVector<Instruction*> instructions_; 350 ZoneVector<Instruction*> instructions_;
346 BoolVector defined_; 351 BoolVector defined_;
347 BoolVector used_; 352 BoolVector used_;
348 IntVector effect_level_; 353 IntVector effect_level_;
349 IntVector virtual_registers_; 354 IntVector virtual_registers_;
350 IntVector virtual_register_rename_; 355 IntVector virtual_register_rename_;
351 InstructionScheduler* scheduler_; 356 InstructionScheduler* scheduler_;
352 EnableScheduling enable_scheduling_; 357 EnableScheduling enable_scheduling_;
353 Frame* frame_; 358 Frame* frame_;
359 bool instruction_selection_failed_;
354 }; 360 };
355 361
356 } // namespace compiler 362 } // namespace compiler
357 } // namespace internal 363 } // namespace internal
358 } // namespace v8 364 } // namespace v8
359 365
360 #endif // V8_COMPILER_INSTRUCTION_SELECTOR_H_ 366 #endif // V8_COMPILER_INSTRUCTION_SELECTOR_H_
OLDNEW
« no previous file with comments | « src/compiler/instruction.h ('k') | src/compiler/instruction-selector.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698