| OLD | NEW |
| 1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 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_HYDROGEN_H_ | 5 #ifndef V8_HYDROGEN_H_ |
| 6 #define V8_HYDROGEN_H_ | 6 #define V8_HYDROGEN_H_ |
| 7 | 7 |
| 8 #include "src/accessors.h" | 8 #include "src/accessors.h" |
| 9 #include "src/allocation.h" | 9 #include "src/allocation.h" |
| 10 #include "src/ast.h" | 10 #include "src/ast.h" |
| (...skipping 1982 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1993 | 1993 |
| 1994 | 1994 |
| 1995 template<> | 1995 template<> |
| 1996 inline HInstruction* HGraphBuilder::AddUncasted<HReturn>(HConstant* value) { | 1996 inline HInstruction* HGraphBuilder::AddUncasted<HReturn>(HConstant* value) { |
| 1997 return Add<HReturn>(value); | 1997 return Add<HReturn>(value); |
| 1998 } | 1998 } |
| 1999 | 1999 |
| 2000 | 2000 |
| 2001 template<> | 2001 template<> |
| 2002 inline HCallRuntime* HGraphBuilder::Add<HCallRuntime>( | 2002 inline HCallRuntime* HGraphBuilder::Add<HCallRuntime>( |
| 2003 Handle<String> name, | |
| 2004 const Runtime::Function* c_function, | 2003 const Runtime::Function* c_function, |
| 2005 int argument_count) { | 2004 int argument_count) { |
| 2006 HCallRuntime* instr = New<HCallRuntime>(name, c_function, argument_count); | 2005 HCallRuntime* instr = New<HCallRuntime>(c_function, argument_count); |
| 2007 if (graph()->info()->IsStub()) { | 2006 if (graph()->info()->IsStub()) { |
| 2008 // When compiling code stubs, we don't want to save all double registers | 2007 // When compiling code stubs, we don't want to save all double registers |
| 2009 // upon entry to the stub, but instead have the call runtime instruction | 2008 // upon entry to the stub, but instead have the call runtime instruction |
| 2010 // save the double registers only on-demand (in the fallback case). | 2009 // save the double registers only on-demand (in the fallback case). |
| 2011 instr->set_save_doubles(kSaveFPRegs); | 2010 instr->set_save_doubles(kSaveFPRegs); |
| 2012 } | 2011 } |
| 2013 AddInstruction(instr); | 2012 AddInstruction(instr); |
| 2014 return instr; | 2013 return instr; |
| 2015 } | 2014 } |
| 2016 | 2015 |
| 2017 | 2016 |
| 2018 template<> | 2017 template<> |
| 2019 inline HInstruction* HGraphBuilder::AddUncasted<HCallRuntime>( | 2018 inline HInstruction* HGraphBuilder::AddUncasted<HCallRuntime>( |
| 2020 Handle<String> name, | 2019 Handle<String> name, |
| 2021 const Runtime::Function* c_function, | 2020 const Runtime::Function* c_function, |
| 2022 int argument_count) { | 2021 int argument_count) { |
| 2023 return Add<HCallRuntime>(name, c_function, argument_count); | 2022 return Add<HCallRuntime>(c_function, argument_count); |
| 2024 } | 2023 } |
| 2025 | 2024 |
| 2026 | 2025 |
| 2027 template<> | 2026 template<> |
| 2028 inline HContext* HGraphBuilder::New<HContext>() { | 2027 inline HContext* HGraphBuilder::New<HContext>() { |
| 2029 return HContext::New(zone()); | 2028 return HContext::New(zone()); |
| 2030 } | 2029 } |
| 2031 | 2030 |
| 2032 | 2031 |
| 2033 template<> | 2032 template<> |
| (...skipping 1006 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3040 } | 3039 } |
| 3041 | 3040 |
| 3042 private: | 3041 private: |
| 3043 HGraphBuilder* builder_; | 3042 HGraphBuilder* builder_; |
| 3044 }; | 3043 }; |
| 3045 | 3044 |
| 3046 | 3045 |
| 3047 } } // namespace v8::internal | 3046 } } // namespace v8::internal |
| 3048 | 3047 |
| 3049 #endif // V8_HYDROGEN_H_ | 3048 #endif // V8_HYDROGEN_H_ |
| OLD | NEW |