Lines Matching refs:Code
6 // * Redistributions of source code must retain the above copyright
1389 // case of eval code, the context passed is the context of the caller,
1870 Handle<Code> code(isolate->builtins()->builtin(builtin_name));
1875 code,
2042 CONVERT_ARG_CHECKED(Code, code, 0);
2045 RUNTIME_ASSERT(0 <= offset && offset < code->Size());
2047 Address pc = code->address() + offset;
2048 return Smi::FromInt(code->SourcePosition(pc));
2167 Handle<Object> code = args.at<Object>(1);
2171 if (!code->IsNull()) {
2172 RUNTIME_ASSERT(code->IsJSFunction());
2173 Handle<JSFunction> fun = Handle<JSFunction>::cast(code);
2181 shared->code()->set_optimizable(false);
2182 // Set the code, scope info, formal parameter count,
2184 target->shared()->set_code(shared->code());
2185 target->ReplaceCode(shared->code());
2190 // Set the source code of the target function to undefined.
2192 // Array, and Object, and some web code
2193 code for constructors.
2195 target->shared()->code()->set_optimizable(false);
2196 // Clear the optimization hints related to the compiled code as these are no
2197 // longer valid when the code is overwritten.
2218 shared, Handle<Code>(shared->code()));
2240 uint32_t code;
2241 if (char_code->ToArrayIndex(&code)) {
2242 if (code <= 0xffff) {
2243 return isolate->heap()->LookupSingleCharacterStringFromCode(code);
4390 // change, this should be fixed once we cleanup the underlying code.
5748 // attempt. See CALL_AND_RETRY in heap-inl.h and similar code in
5833 // attempt. See CALL_AND_RETRY in heap-inl.h and similar code in
7150 // smallest because the char code of '-' is less than the char code
7740 // into C++ code. Collect these in a newly allocated array of handles (possibly
7796 // TODO(lrn): Create bound function in C++ code from premade shared info.
7916 Handle<Code> code = compiler.CompileConstructStub(function);
7917 function->shared()->set_construct_stub(*code);
7939 // case generated code bailouts here, since function has no initial_map.
8035 // All done. Return the compiled code.
8037 return function->code();
8050 function->ReplaceCode(function->shared()->code());
8051 return function->code();
8055 // code from the full compiler.
8056 if (!function->shared()->code()->optimizable() ||
8061 PrintF(": is code optimizable: %s, is debugger enabled: %s]\n",
8062 function->shared()->code()->optimizable() ? "T" : "F",
8065 function->ReplaceCode(function->shared()->code());
8066 return function->code();
8068 function->shared()->code()->set_profiler_ticks(0);
8072 return function->code();
8079 function->ReplaceCode(function->shared()->code());
8080 return function->code();
8159 // the optimized code around.
8183 PrintF("[removing optimized code for: ");
8187 function->ReplaceCode(function->shared()->code());
8231 Code* unoptimized = function->shared()->code();
8233 unoptimized->kind() == Code::FUNCTION) {
8238 Code::kMaxLoopNestingMarker);
8279 // selected for on-stack replacement. Find the unoptimized code object.
8280 Handle<Code> unoptimized(function->shared()->code(), isolate);
8300 // unoptimized code.
8307 // Use linear search of the unoptimized code's stack check table to find
8330 // Try to compile the optimized code. A true return value from
8336 function->code()->deoptimization_data());
8339 PrintF("[on-stack replacement offset %d in optimized code]\n",
8353 // Revert to the original stack checks in the original unoptimized code.
8359 Handle<Code> check_code;
8372 Handle<Code> replacement_code = isolate->builtins()->OnStackReplacement();
8384 ASSERT(function->code()->kind() == Code::OPTIMIZED_FUNCTION);
8388 function->ReplaceCode(function->shared()->code());
8537 // A smi sentinel indicates a context nested inside global code rather
8563 // A smi sentinel indicates a context nested inside global code rather
8588 // A smi sentinel indicates a context nested inside global code rather
8987 // If we have a string, assume it's a code "marker"
9131 // No callback set and code generation disallowed.
9134 // Callback set. Let it decide if code generation is allowed.
9149 // Check if global context allows code generation from
9177 // Check if global context allows code generation from
9250 // Use as fallback for allocation in generated code when NewSpace
10155 // GC can happen later in this code so put the required fields into
10475 // Find source position in unoptimized code.
10968 // Reparse the code and analyze the scopes.
10973 // Check whether we are in global, eval or function code.
10976 // Global or eval code.
10989 // Function code
10998 int source_position = shared_info->code()->SourcePosition(frame_->pc());
11768 // stack frame. A function which calls eval with the code to evaluate is then
11869 // Currently, the eval code will be executed in non-strict mode,
11870 // even in the strict code context.
11953 // the context of the debugged function and the eval code to be executed.
11962 // Currently, the eval code will be executed in non-strict mode,
11963 // even in the strict code context.
12277 func->code()->PrintLn();
12379 // all generated code keeps references to this particular instance of script.
12433 // Replaces code of SharedFunctionInfo with a new one.
12468 // In a code of a parent function replaces original function as embedded object
12534 Handle<Code> code(function->code(), isolate);
12536 if (code->kind() != Code::FUNCTION &&
12537 code->kind() != Code::OPTIMIZED_FUNCTION) {
12541 RelocIterator it(*code, RelocInfo::ModeMask(RelocInfo::STATEMENT_POSITION));
12550 static_cast<int>(it.rinfo()->pc() - code->instruction_start());
12563 // This is used in unit tests to run code as if debugger is entered or simply
12928 // element segments each containing a receiver, function, code and
12929 // native code offset.
12973 Handle<Code> code = frames[i].code();
12977 elements->set(cursor++, *code);
13152 // Exclude the code in release mode.
13282 // Non-recoverable failure. Calling code must restart heap