| OLD | NEW |
| 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_CCTEST_COMPILER_GRAPH_BUILDER_TESTER_H_ | 5 #ifndef V8_CCTEST_COMPILER_GRAPH_BUILDER_TESTER_H_ |
| 6 #define V8_CCTEST_COMPILER_GRAPH_BUILDER_TESTER_H_ | 6 #define V8_CCTEST_COMPILER_GRAPH_BUILDER_TESTER_H_ |
| 7 | 7 |
| 8 #include "src/compiler/common-operator.h" | 8 #include "src/compiler/common-operator.h" |
| 9 #include "src/compiler/instruction-selector.h" | 9 #include "src/compiler/instruction-selector.h" |
| 10 #include "src/compiler/linkage.h" | 10 #include "src/compiler/linkage.h" |
| (...skipping 259 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 270 } | 270 } |
| 271 | 271 |
| 272 return result; | 272 return result; |
| 273 } | 273 } |
| 274 | 274 |
| 275 virtual byte* Generate() { | 275 virtual byte* Generate() { |
| 276 if (code_.is_null()) { | 276 if (code_.is_null()) { |
| 277 Zone* zone = graph()->zone(); | 277 Zone* zone = graph()->zone(); |
| 278 CallDescriptor* desc = | 278 CallDescriptor* desc = |
| 279 Linkage::GetSimplifiedCDescriptor(zone, this->csig_); | 279 Linkage::GetSimplifiedCDescriptor(zone, this->csig_); |
| 280 CompilationInfo info("testing", main_isolate(), main_zone()); | 280 CompilationInfo info(ArrayVector("testing"), main_isolate(), main_zone()); |
| 281 code_ = Pipeline::GenerateCodeForTesting(&info, desc, graph()); | 281 code_ = Pipeline::GenerateCodeForTesting(&info, desc, graph()); |
| 282 #ifdef ENABLE_DISASSEMBLER | 282 #ifdef ENABLE_DISASSEMBLER |
| 283 if (!code_.is_null() && FLAG_print_opt_code) { | 283 if (!code_.is_null() && FLAG_print_opt_code) { |
| 284 OFStream os(stdout); | 284 OFStream os(stdout); |
| 285 code_.ToHandleChecked()->Disassemble("test code", os); | 285 code_.ToHandleChecked()->Disassemble("test code", os); |
| 286 } | 286 } |
| 287 #endif | 287 #endif |
| 288 } | 288 } |
| 289 return code_.ToHandleChecked()->entry(); | 289 return code_.ToHandleChecked()->entry(); |
| 290 } | 290 } |
| (...skipping 12 matching lines...) Expand all Loading... |
| 303 Node* return_; | 303 Node* return_; |
| 304 Node** parameters_; | 304 Node** parameters_; |
| 305 MaybeHandle<Code> code_; | 305 MaybeHandle<Code> code_; |
| 306 }; | 306 }; |
| 307 | 307 |
| 308 } // namespace compiler | 308 } // namespace compiler |
| 309 } // namespace internal | 309 } // namespace internal |
| 310 } // namespace v8 | 310 } // namespace v8 |
| 311 | 311 |
| 312 #endif // V8_CCTEST_COMPILER_GRAPH_BUILDER_TESTER_H_ | 312 #endif // V8_CCTEST_COMPILER_GRAPH_BUILDER_TESTER_H_ |
| OLD | NEW |