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 8376 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
8387 } | 8387 } |
8388 } | 8388 } |
8389 | 8389 |
8390 | 8390 |
8391 RUNTIME_FUNCTION(MaybeObject*, Runtime_CheckIsBootstrapping) { | 8391 RUNTIME_FUNCTION(MaybeObject*, Runtime_CheckIsBootstrapping) { |
8392 RUNTIME_ASSERT(isolate->bootstrapper()->IsActive()); | 8392 RUNTIME_ASSERT(isolate->bootstrapper()->IsActive()); |
8393 return isolate->heap()->undefined_value(); | 8393 return isolate->heap()->undefined_value(); |
8394 } | 8394 } |
8395 | 8395 |
8396 | 8396 |
| 8397 RUNTIME_FUNCTION(MaybeObject*, Runtime_GetRootNan) { |
| 8398 RUNTIME_ASSERT(isolate->bootstrapper()->IsActive()); |
| 8399 return isolate->heap()->nan_value(); |
| 8400 } |
| 8401 |
| 8402 |
8397 RUNTIME_FUNCTION(MaybeObject*, Runtime_Call) { | 8403 RUNTIME_FUNCTION(MaybeObject*, Runtime_Call) { |
8398 HandleScope scope(isolate); | 8404 HandleScope scope(isolate); |
8399 ASSERT(args.length() >= 2); | 8405 ASSERT(args.length() >= 2); |
8400 int argc = args.length() - 2; | 8406 int argc = args.length() - 2; |
8401 CONVERT_ARG_CHECKED(JSReceiver, fun, argc + 1); | 8407 CONVERT_ARG_CHECKED(JSReceiver, fun, argc + 1); |
8402 Object* receiver = args[0]; | 8408 Object* receiver = args[0]; |
8403 | 8409 |
8404 // If there are too many arguments, allocate argv via malloc. | 8410 // If there are too many arguments, allocate argv via malloc. |
8405 const int argv_small_size = 10; | 8411 const int argv_small_size = 10; |
8406 Handle<Object> argv_small_buffer[argv_small_size]; | 8412 Handle<Object> argv_small_buffer[argv_small_size]; |
(...skipping 4935 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
13342 // Handle last resort GC and make sure to allow future allocations | 13348 // Handle last resort GC and make sure to allow future allocations |
13343 // to grow the heap without causing GCs (if possible). | 13349 // to grow the heap without causing GCs (if possible). |
13344 isolate->counters()->gc_last_resort_from_js()->Increment(); | 13350 isolate->counters()->gc_last_resort_from_js()->Increment(); |
13345 isolate->heap()->CollectAllGarbage(Heap::kNoGCFlags, | 13351 isolate->heap()->CollectAllGarbage(Heap::kNoGCFlags, |
13346 "Runtime::PerformGC"); | 13352 "Runtime::PerformGC"); |
13347 } | 13353 } |
13348 } | 13354 } |
13349 | 13355 |
13350 | 13356 |
13351 } } // namespace v8::internal | 13357 } } // namespace v8::internal |
OLD | NEW |