Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(277)

Side by Side Diff: src/ic.cc

Issue 14892: Merge changes from bleeding_edge into experimental toiger branch.... (Closed) Base URL: http://v8.googlecode.com/svn/branches/experimental/toiger/
Patch Set: Created 12 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « src/heap.cc ('k') | src/interpreter-irregexp.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 334 matching lines...) Expand 10 before | Expand all | Expand 10 after
345 // Ignored this will degrade performance for Array.prototype.{push,pop}. 345 // Ignored this will degrade performance for Array.prototype.{push,pop}.
346 // Please note we only return the optimized function iff 346 // Please note we only return the optimized function iff
347 // the JSObject has FastElements. 347 // the JSObject has FastElements.
348 if (object->IsJSObject() && JSObject::cast(*object)->HasFastElements()) { 348 if (object->IsJSObject() && JSObject::cast(*object)->HasFastElements()) {
349 Object* opt = Top::LookupSpecialFunction(JSObject::cast(*object), 349 Object* opt = Top::LookupSpecialFunction(JSObject::cast(*object),
350 lookup.holder(), 350 lookup.holder(),
351 JSFunction::cast(result)); 351 JSFunction::cast(result));
352 if (opt->IsJSFunction()) return opt; 352 if (opt->IsJSFunction()) return opt;
353 } 353 }
354 354
355 // If performing debug step into then flood this function with one-shot 355 // Handle stepping into a function if step into is active.
356 // break points if it is called from where step into was requested. 356 if (Debug::StepInActive()) {
357 if (Debug::StepInActive() && fp() == Debug::step_in_fp()) { 357 // Protect the result in a handle as the debugger can allocate and might
358 // Don't allow step into functions in the native context. 358 // cause GC.
359 if (JSFunction::cast(result)->context()->global() != 359 HandleScope scope;
360 Top::context()->builtins()) { 360 Handle<JSFunction> function(JSFunction::cast(result));
361 HandleScope scope; 361 Debug::HandleStepIn(function, fp(), false);
362 Handle<SharedFunctionInfo> shared(JSFunction::cast(result)->shared()); 362 return *function;
363 Debug::FloodWithOneShot(shared);
364 }
365 } 363 }
364
366 return result; 365 return result;
367 } 366 }
368 367
369 // Try to find a suitable function delegate for the object at hand. 368 // Try to find a suitable function delegate for the object at hand.
370 result = TryCallAsFunction(result); 369 result = TryCallAsFunction(result);
371 return result->IsJSFunction() ? 370 return result->IsJSFunction() ?
372 result : TypeError("property_not_function", object, name); 371 result : TypeError("property_not_function", object, name);
373 } 372 }
374 373
375 374
(...skipping 819 matching lines...) Expand 10 before | Expand all | Expand 10 after
1195 #undef ADDR 1194 #undef ADDR
1196 }; 1195 };
1197 1196
1198 1197
1199 Address IC::AddressFromUtilityId(IC::UtilityId id) { 1198 Address IC::AddressFromUtilityId(IC::UtilityId id) {
1200 return IC_utilities[id]; 1199 return IC_utilities[id];
1201 } 1200 }
1202 1201
1203 1202
1204 } } // namespace v8::internal 1203 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/heap.cc ('k') | src/interpreter-irregexp.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698