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 88 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
99 NoCache, // marker for stubs that do custom caching | 99 NoCache, // marker for stubs that do custom caching |
100 NUMBER_OF_IDS | 100 NUMBER_OF_IDS |
101 }; | 101 }; |
102 | 102 |
103 // Retrieve the code for the stub. Generate the code if needed. | 103 // Retrieve the code for the stub. Generate the code if needed. |
104 Handle<Code> GetCode(); | 104 Handle<Code> GetCode(); |
105 | 105 |
106 // Retrieve the code for the stub if already generated. Do not | 106 // Retrieve the code for the stub if already generated. Do not |
107 // generate the code if not already generated and instead return a | 107 // generate the code if not already generated and instead return a |
108 // retry after GC Failure object. | 108 // retry after GC Failure object. |
109 Object* TryGetCode(); | 109 MUST_USE_RESULT MaybeObject* TryGetCode(); |
110 | 110 |
111 static Major MajorKeyFromKey(uint32_t key) { | 111 static Major MajorKeyFromKey(uint32_t key) { |
112 return static_cast<Major>(MajorKeyBits::decode(key)); | 112 return static_cast<Major>(MajorKeyBits::decode(key)); |
113 } | 113 } |
114 static int MinorKeyFromKey(uint32_t key) { | 114 static int MinorKeyFromKey(uint32_t key) { |
115 return MinorKeyBits::decode(key); | 115 return MinorKeyBits::decode(key); |
116 } | 116 } |
117 | 117 |
118 // Gets the major key from a code object that is a code stub or binary op IC. | 118 // Gets the major key from a code object that is a code stub or binary op IC. |
119 static Major GetMajorKey(Code* code_stub) { | 119 static Major GetMajorKey(Code* code_stub) { |
(...skipping 707 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
827 private: | 827 private: |
828 StringCharCodeAtGenerator char_code_at_generator_; | 828 StringCharCodeAtGenerator char_code_at_generator_; |
829 StringCharFromCodeGenerator char_from_code_generator_; | 829 StringCharFromCodeGenerator char_from_code_generator_; |
830 | 830 |
831 DISALLOW_COPY_AND_ASSIGN(StringCharAtGenerator); | 831 DISALLOW_COPY_AND_ASSIGN(StringCharAtGenerator); |
832 }; | 832 }; |
833 | 833 |
834 } } // namespace v8::internal | 834 } } // namespace v8::internal |
835 | 835 |
836 #endif // V8_CODE_STUBS_H_ | 836 #endif // V8_CODE_STUBS_H_ |
OLD | NEW |