| OLD | NEW |
| 1 // Copyright 2006-2008 the V8 project authors. All rights reserved. | 1 // Copyright 2006-2008 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 480 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 491 private: | 491 private: |
| 492 int MinorKey() { return 1; } | 492 int MinorKey() { return 1; } |
| 493 | 493 |
| 494 const char* GetName() { return "JSConstructEntryStub"; } | 494 const char* GetName() { return "JSConstructEntryStub"; } |
| 495 }; | 495 }; |
| 496 | 496 |
| 497 | 497 |
| 498 class ArgumentsAccessStub: public CodeStub { | 498 class ArgumentsAccessStub: public CodeStub { |
| 499 public: | 499 public: |
| 500 enum Type { | 500 enum Type { |
| 501 READ_LENGTH, | |
| 502 READ_ELEMENT, | 501 READ_ELEMENT, |
| 503 NEW_OBJECT | 502 NEW_OBJECT |
| 504 }; | 503 }; |
| 505 | 504 |
| 506 explicit ArgumentsAccessStub(Type type) : type_(type) { } | 505 explicit ArgumentsAccessStub(Type type) : type_(type) { } |
| 507 | 506 |
| 508 private: | 507 private: |
| 509 Type type_; | 508 Type type_; |
| 510 | 509 |
| 511 Major MajorKey() { return ArgumentsAccess; } | 510 Major MajorKey() { return ArgumentsAccess; } |
| 512 int MinorKey() { return type_; } | 511 int MinorKey() { return type_; } |
| 513 | 512 |
| 514 void Generate(MacroAssembler* masm); | 513 void Generate(MacroAssembler* masm); |
| 515 void GenerateReadLength(MacroAssembler* masm); | |
| 516 void GenerateReadElement(MacroAssembler* masm); | 514 void GenerateReadElement(MacroAssembler* masm); |
| 517 void GenerateNewObject(MacroAssembler* masm); | 515 void GenerateNewObject(MacroAssembler* masm); |
| 518 | 516 |
| 519 const char* GetName() { return "ArgumentsAccessStub"; } | 517 const char* GetName() { return "ArgumentsAccessStub"; } |
| 520 | 518 |
| 521 #ifdef DEBUG | 519 #ifdef DEBUG |
| 522 void Print() { | 520 void Print() { |
| 523 PrintF("ArgumentsAccessStub (type %d)\n", type_); | 521 PrintF("ArgumentsAccessStub (type %d)\n", type_); |
| 524 } | 522 } |
| 525 #endif | 523 #endif |
| (...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 601 private: | 599 private: |
| 602 Major MajorKey() { return ToBoolean; } | 600 Major MajorKey() { return ToBoolean; } |
| 603 int MinorKey() { return 0; } | 601 int MinorKey() { return 0; } |
| 604 }; | 602 }; |
| 605 | 603 |
| 606 | 604 |
| 607 } // namespace internal | 605 } // namespace internal |
| 608 } // namespace v8 | 606 } // namespace v8 |
| 609 | 607 |
| 610 #endif // V8_CODEGEN_H_ | 608 #endif // V8_CODEGEN_H_ |
| OLD | NEW |