| 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 1532 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1543 return ArgcBits::decode(minor_key); | 1543 return ArgcBits::decode(minor_key); |
| 1544 } | 1544 } |
| 1545 | 1545 |
| 1546 private: | 1546 private: |
| 1547 int argc_; | 1547 int argc_; |
| 1548 CallFunctionFlags flags_; | 1548 CallFunctionFlags flags_; |
| 1549 | 1549 |
| 1550 virtual void PrintName(StringStream* stream); | 1550 virtual void PrintName(StringStream* stream); |
| 1551 | 1551 |
| 1552 // Minor key encoding in 32 bits with Bitfield <Type, shift, size>. | 1552 // Minor key encoding in 32 bits with Bitfield <Type, shift, size>. |
| 1553 class FlagBits: public BitField<CallFunctionFlags, 0, 3> {}; | 1553 class FlagBits: public BitField<CallFunctionFlags, 0, 2> {}; |
| 1554 class ArgcBits: public BitField<unsigned, 3, 32 - 3> {}; | 1554 class ArgcBits: public BitField<unsigned, 2, 32 - 2> {}; |
| 1555 | 1555 |
| 1556 Major MajorKey() { return CallFunction; } | 1556 Major MajorKey() { return CallFunction; } |
| 1557 int MinorKey() { | 1557 int MinorKey() { |
| 1558 // Encode the parameters in a unique 32 bit value. | 1558 // Encode the parameters in a unique 32 bit value. |
| 1559 return FlagBits::encode(flags_) | ArgcBits::encode(argc_); | 1559 return FlagBits::encode(flags_) | ArgcBits::encode(argc_); |
| 1560 } | 1560 } |
| 1561 | 1561 |
| 1562 bool ReceiverMightBeImplicit() { | 1562 bool ReceiverMightBeImplicit() { |
| 1563 return (flags_ & RECEIVER_MIGHT_BE_IMPLICIT) != 0; | 1563 return (flags_ & RECEIVER_MIGHT_BE_IMPLICIT) != 0; |
| 1564 } | 1564 } |
| 1565 | 1565 |
| 1566 bool ReceiverIsImplicit() { | |
| 1567 return (flags_ & RECEIVER_IS_IMPLICIT) != 0; | |
| 1568 } | |
| 1569 | |
| 1570 bool RecordCallTarget() { | 1566 bool RecordCallTarget() { |
| 1571 return (flags_ & RECORD_CALL_TARGET) != 0; | 1567 return (flags_ & RECORD_CALL_TARGET) != 0; |
| 1572 } | 1568 } |
| 1573 }; | 1569 }; |
| 1574 | 1570 |
| 1575 | 1571 |
| 1576 class CallConstructStub: public PlatformCodeStub { | 1572 class CallConstructStub: public PlatformCodeStub { |
| 1577 public: | 1573 public: |
| 1578 explicit CallConstructStub(CallFunctionFlags flags) : flags_(flags) {} | 1574 explicit CallConstructStub(CallFunctionFlags flags) : flags_(flags) {} |
| 1579 | 1575 |
| (...skipping 871 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2451 int MinorKey() { return 0; } | 2447 int MinorKey() { return 0; } |
| 2452 | 2448 |
| 2453 void Generate(MacroAssembler* masm); | 2449 void Generate(MacroAssembler* masm); |
| 2454 | 2450 |
| 2455 DISALLOW_COPY_AND_ASSIGN(ProfileEntryHookStub); | 2451 DISALLOW_COPY_AND_ASSIGN(ProfileEntryHookStub); |
| 2456 }; | 2452 }; |
| 2457 | 2453 |
| 2458 } } // namespace v8::internal | 2454 } } // namespace v8::internal |
| 2459 | 2455 |
| 2460 #endif // V8_CODE_STUBS_H_ | 2456 #endif // V8_CODE_STUBS_H_ |
| OLD | NEW |