OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 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 235 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
246 | 246 |
247 protected: | 247 protected: |
248 // Generates the assembler code for the stub. | 248 // Generates the assembler code for the stub. |
249 virtual void Generate(MacroAssembler* masm) = 0; | 249 virtual void Generate(MacroAssembler* masm) = 0; |
250 }; | 250 }; |
251 | 251 |
252 | 252 |
253 struct CodeStubInterfaceDescriptor { | 253 struct CodeStubInterfaceDescriptor { |
254 CodeStubInterfaceDescriptor() | 254 CodeStubInterfaceDescriptor() |
255 : register_param_count_(-1), | 255 : register_param_count_(-1), |
| 256 stack_parameter_count_(NULL), |
| 257 extra_expression_stack_count_(0), |
256 register_params_(NULL) { } | 258 register_params_(NULL) { } |
257 int register_param_count_; | 259 int register_param_count_; |
| 260 const Register* stack_parameter_count_; |
| 261 int extra_expression_stack_count_; |
258 Register* register_params_; | 262 Register* register_params_; |
259 Address deoptimization_handler_; | 263 Address deoptimization_handler_; |
260 }; | 264 }; |
261 | 265 |
262 | 266 |
263 class HGraph; | 267 class HGraph; |
264 struct Register; | 268 struct Register; |
265 class HydrogenCodeStub : public CodeStub { | 269 class HydrogenCodeStub : public CodeStub { |
266 public: | 270 public: |
267 // Retrieve the code for the stub. Generate the code if needed. | 271 // Retrieve the code for the stub. Generate the code if needed. |
(...skipping 1150 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1418 void Generate(MacroAssembler* masm); | 1422 void Generate(MacroAssembler* masm); |
1419 | 1423 |
1420 bool fp_registers_; | 1424 bool fp_registers_; |
1421 | 1425 |
1422 DISALLOW_COPY_AND_ASSIGN(StoreArrayLiteralElementStub); | 1426 DISALLOW_COPY_AND_ASSIGN(StoreArrayLiteralElementStub); |
1423 }; | 1427 }; |
1424 | 1428 |
1425 | 1429 |
1426 class StubFailureTrampolineStub : public PlatformCodeStub { | 1430 class StubFailureTrampolineStub : public PlatformCodeStub { |
1427 public: | 1431 public: |
1428 StubFailureTrampolineStub() {} | 1432 static const int kMaxExtraExpressionStackCount = 1; |
| 1433 |
| 1434 explicit StubFailureTrampolineStub(int extra_expression_stack_count) |
| 1435 : extra_expression_stack_count_(extra_expression_stack_count) {} |
1429 | 1436 |
1430 private: | 1437 private: |
1431 Major MajorKey() { return StubFailureTrampoline; } | 1438 Major MajorKey() { return StubFailureTrampoline; } |
1432 int MinorKey() { return 0; } | 1439 int MinorKey() { return extra_expression_stack_count_; } |
1433 | 1440 |
1434 void Generate(MacroAssembler* masm); | 1441 void Generate(MacroAssembler* masm); |
1435 | 1442 |
| 1443 int extra_expression_stack_count_; |
| 1444 |
1436 DISALLOW_COPY_AND_ASSIGN(StubFailureTrampolineStub); | 1445 DISALLOW_COPY_AND_ASSIGN(StubFailureTrampolineStub); |
1437 }; | 1446 }; |
1438 | 1447 |
1439 | 1448 |
1440 class ProfileEntryHookStub : public PlatformCodeStub { | 1449 class ProfileEntryHookStub : public PlatformCodeStub { |
1441 public: | 1450 public: |
1442 explicit ProfileEntryHookStub() {} | 1451 explicit ProfileEntryHookStub() {} |
1443 | 1452 |
1444 // The profile entry hook function is not allowed to cause a GC. | 1453 // The profile entry hook function is not allowed to cause a GC. |
1445 virtual bool SometimesSetsUpAFrame() { return false; } | 1454 virtual bool SometimesSetsUpAFrame() { return false; } |
(...skipping 19 matching lines...) Expand all Loading... |
1465 | 1474 |
1466 // The current function entry hook. | 1475 // The current function entry hook. |
1467 static FunctionEntryHook entry_hook_; | 1476 static FunctionEntryHook entry_hook_; |
1468 | 1477 |
1469 DISALLOW_COPY_AND_ASSIGN(ProfileEntryHookStub); | 1478 DISALLOW_COPY_AND_ASSIGN(ProfileEntryHookStub); |
1470 }; | 1479 }; |
1471 | 1480 |
1472 } } // namespace v8::internal | 1481 } } // namespace v8::internal |
1473 | 1482 |
1474 #endif // V8_CODE_STUBS_H_ | 1483 #endif // V8_CODE_STUBS_H_ |
OLD | NEW |