OLD | NEW |
1 // Copyright 2010 the V8 project authors. All rights reserved. | 1 // Copyright 2010 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 148 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
159 static Handle<Proxy> NewProxy(Address addr, | 159 static Handle<Proxy> NewProxy(Address addr, |
160 PretenureFlag pretenure = NOT_TENURED); | 160 PretenureFlag pretenure = NOT_TENURED); |
161 | 161 |
162 // Allocate a new proxy. The proxy is pretenured (allocated directly in | 162 // Allocate a new proxy. The proxy is pretenured (allocated directly in |
163 // the old generation). | 163 // the old generation). |
164 static Handle<Proxy> NewProxy(const AccessorDescriptor* proxy); | 164 static Handle<Proxy> NewProxy(const AccessorDescriptor* proxy); |
165 | 165 |
166 static Handle<ByteArray> NewByteArray(int length, | 166 static Handle<ByteArray> NewByteArray(int length, |
167 PretenureFlag pretenure = NOT_TENURED); | 167 PretenureFlag pretenure = NOT_TENURED); |
168 | 168 |
169 static Handle<PixelArray> NewPixelArray( | 169 static Handle<ExternalPixelArray> NewExternalPixelArray( |
170 int length, | 170 int length, |
171 uint8_t* external_pointer, | 171 uint8_t* external_pointer, |
172 PretenureFlag pretenure = NOT_TENURED); | 172 PretenureFlag pretenure = NOT_TENURED); |
173 | 173 |
174 static Handle<ExternalArray> NewExternalArray( | 174 static Handle<ExternalArray> NewExternalArray( |
175 int length, | 175 int length, |
176 ExternalArrayType array_type, | 176 ExternalArrayType array_type, |
177 void* external_pointer, | 177 void* external_pointer, |
178 PretenureFlag pretenure = NOT_TENURED); | 178 PretenureFlag pretenure = NOT_TENURED); |
179 | 179 |
180 static Handle<JSGlobalPropertyCell> NewJSGlobalPropertyCell( | 180 static Handle<JSGlobalPropertyCell> NewJSGlobalPropertyCell( |
181 Handle<Object> value); | 181 Handle<Object> value); |
182 | 182 |
183 static Handle<Map> NewMap(InstanceType type, int instance_size); | 183 static Handle<Map> NewMap(InstanceType type, int instance_size); |
184 | 184 |
185 static Handle<JSObject> NewFunctionPrototype(Handle<JSFunction> function); | 185 static Handle<JSObject> NewFunctionPrototype(Handle<JSFunction> function); |
186 | 186 |
187 static Handle<Map> CopyMapDropDescriptors(Handle<Map> map); | 187 static Handle<Map> CopyMapDropDescriptors(Handle<Map> map); |
188 | 188 |
189 // Copy the map adding more inobject properties if possible without | 189 // Copy the map adding more inobject properties if possible without |
190 // overflowing the instance size. | 190 // overflowing the instance size. |
191 static Handle<Map> CopyMap(Handle<Map> map, int extra_inobject_props); | 191 static Handle<Map> CopyMap(Handle<Map> map, int extra_inobject_props); |
192 | 192 |
193 static Handle<Map> CopyMapDropTransitions(Handle<Map> map); | 193 static Handle<Map> CopyMapDropTransitions(Handle<Map> map); |
194 | 194 |
195 static Handle<Map> GetFastElementsMap(Handle<Map> map); | 195 static Handle<Map> GetFastElementsMap(Handle<Map> map); |
196 | 196 |
197 static Handle<Map> GetSlowElementsMap(Handle<Map> map); | 197 static Handle<Map> GetSlowElementsMap(Handle<Map> map); |
198 | 198 |
199 static Handle<Map> GetPixelArrayElementsMap(Handle<Map> map); | 199 static Handle<Map> NewExternalArrayElementsMap(Handle<Map> map); |
200 | 200 |
201 static Handle<FixedArray> CopyFixedArray(Handle<FixedArray> array); | 201 static Handle<FixedArray> CopyFixedArray(Handle<FixedArray> array); |
202 | 202 |
203 // Numbers (eg, literals) are pretenured by the parser. | 203 // Numbers (eg, literals) are pretenured by the parser. |
204 static Handle<Object> NewNumber(double value, | 204 static Handle<Object> NewNumber(double value, |
205 PretenureFlag pretenure = NOT_TENURED); | 205 PretenureFlag pretenure = NOT_TENURED); |
206 | 206 |
207 static Handle<Object> NewNumberFromInt(int value); | 207 static Handle<Object> NewNumberFromInt(int value); |
208 static Handle<Object> NewNumberFromUint(uint32_t value); | 208 static Handle<Object> NewNumberFromUint(uint32_t value); |
209 | 209 |
(...skipping 213 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
423 // Update the map cache in the global context with (keys, map) | 423 // Update the map cache in the global context with (keys, map) |
424 static Handle<MapCache> AddToMapCache(Handle<Context> context, | 424 static Handle<MapCache> AddToMapCache(Handle<Context> context, |
425 Handle<FixedArray> keys, | 425 Handle<FixedArray> keys, |
426 Handle<Map> map); | 426 Handle<Map> map); |
427 }; | 427 }; |
428 | 428 |
429 | 429 |
430 } } // namespace v8::internal | 430 } } // namespace v8::internal |
431 | 431 |
432 #endif // V8_FACTORY_H_ | 432 #endif // V8_FACTORY_H_ |
OLD | NEW |