| 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_COMPILER_C_SIGNATURE_H_ |    5 #ifndef V8_COMPILER_C_SIGNATURE_H_ | 
|    6 #define V8_COMPILER_C_SIGNATURE_H_ |    6 #define V8_COMPILER_C_SIGNATURE_H_ | 
|    7  |    7  | 
|    8 #include "src/compiler/machine-type.h" |    8 #include "src/compiler/machine-type.h" | 
|    9  |    9  | 
|   10 namespace v8 { |   10 namespace v8 { | 
| (...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
|   62                             MachineTypeForC<P5>()}; |   62                             MachineTypeForC<P5>()}; | 
|   63     for (int p = kMax - 1; p >= 0; p--) { |   63     for (int p = kMax - 1; p >= 0; p--) { | 
|   64       if (p < static_cast<int>(parameter_count())) { |   64       if (p < static_cast<int>(parameter_count())) { | 
|   65         CHECK_EQ(GetParam(p), params[p]); |   65         CHECK_EQ(GetParam(p), params[p]); | 
|   66       } else { |   66       } else { | 
|   67         CHECK_EQ(kMachNone, params[p]); |   67         CHECK_EQ(kMachNone, params[p]); | 
|   68       } |   68       } | 
|   69     } |   69     } | 
|   70   } |   70   } | 
|   71  |   71  | 
|   72   static CSignature* FromMachine(Zone* zone, MachineSignature* msig) { |  | 
|   73     return reinterpret_cast<CSignature*>(msig); |  | 
|   74   } |  | 
|   75  |  | 
|   76   static CSignature* New(Zone* zone, MachineType ret, |   72   static CSignature* New(Zone* zone, MachineType ret, | 
|   77                          MachineType p1 = kMachNone, MachineType p2 = kMachNone, |   73                          MachineType p1 = kMachNone, MachineType p2 = kMachNone, | 
|   78                          MachineType p3 = kMachNone, MachineType p4 = kMachNone, |   74                          MachineType p3 = kMachNone, MachineType p4 = kMachNone, | 
|   79                          MachineType p5 = kMachNone) { |   75                          MachineType p5 = kMachNone) { | 
|   80     MachineType* buffer = zone->NewArray<MachineType>(6); |   76     MachineType* buffer = zone->NewArray<MachineType>(6); | 
|   81     int pos = 0; |   77     int pos = 0; | 
|   82     size_t return_count = 0; |   78     size_t return_count = 0; | 
|   83     if (ret != kMachNone) { |   79     if (ret != kMachNone) { | 
|   84       buffer[pos++] = ret; |   80       buffer[pos++] = ret; | 
|   85       return_count++; |   81       return_count++; | 
| (...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
|  157 typedef CSignature2<int32_t, int32_t, int32_t> CSignature_i_ii; |  153 typedef CSignature2<int32_t, int32_t, int32_t> CSignature_i_ii; | 
|  158 typedef CSignature2<uint32_t, uint32_t, uint32_t> CSignature_u_uu; |  154 typedef CSignature2<uint32_t, uint32_t, uint32_t> CSignature_u_uu; | 
|  159 typedef CSignature2<float, float, float> CSignature_f_ff; |  155 typedef CSignature2<float, float, float> CSignature_f_ff; | 
|  160 typedef CSignature2<double, double, double> CSignature_d_dd; |  156 typedef CSignature2<double, double, double> CSignature_d_dd; | 
|  161 typedef CSignature2<Object*, Object*, Object*> CSignature_o_oo; |  157 typedef CSignature2<Object*, Object*, Object*> CSignature_o_oo; | 
|  162 } |  158 } | 
|  163 } |  159 } | 
|  164 }  // namespace v8::internal::compiler |  160 }  // namespace v8::internal::compiler | 
|  165  |  161  | 
|  166 #endif  // V8_COMPILER_C_SIGNATURE_H_ |  162 #endif  // V8_COMPILER_C_SIGNATURE_H_ | 
| OLD | NEW |