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

Side by Side Diff: src/code-stubs-hydrogen.cc

Issue 23890030: Rollback trunk to 3.21.15. (Closed) Base URL: https://v8.googlecode.com/svn/trunk
Patch Set: Created 7 years, 3 months 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/code-stubs.h ('k') | src/handles.h » ('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 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 339 matching lines...) Expand 10 before | Expand all | Expand 10 after
350 GetParameter(1), 350 GetParameter(1),
351 static_cast<HValue*>(NULL), 351 static_cast<HValue*>(NULL),
352 FAST_ELEMENTS); 352 FAST_ELEMENTS);
353 IfBuilder checker(this); 353 IfBuilder checker(this);
354 checker.IfNot<HCompareObjectEqAndBranch, HValue*>(allocation_site, 354 checker.IfNot<HCompareObjectEqAndBranch, HValue*>(allocation_site,
355 undefined); 355 undefined);
356 checker.Then(); 356 checker.Then();
357 357
358 HObjectAccess access = HObjectAccess::ForAllocationSiteTransitionInfo(); 358 HObjectAccess access = HObjectAccess::ForAllocationSiteTransitionInfo();
359 HInstruction* boilerplate = Add<HLoadNamedField>(allocation_site, access); 359 HInstruction* boilerplate = Add<HLoadNamedField>(allocation_site, access);
360 HValue* push_value;
361 if (mode == FastCloneShallowArrayStub::CLONE_ANY_ELEMENTS) { 360 if (mode == FastCloneShallowArrayStub::CLONE_ANY_ELEMENTS) {
362 HValue* elements = AddLoadElements(boilerplate); 361 HValue* elements = AddLoadElements(boilerplate);
363 362
364 IfBuilder if_fixed_cow(this); 363 IfBuilder if_fixed_cow(this);
365 if_fixed_cow.If<HCompareMap>(elements, factory->fixed_cow_array_map()); 364 if_fixed_cow.If<HCompareMap>(elements, factory->fixed_cow_array_map());
366 if_fixed_cow.Then(); 365 if_fixed_cow.Then();
367 push_value = BuildCloneShallowArray(boilerplate, 366 environment()->Push(BuildCloneShallowArray(boilerplate,
368 allocation_site, 367 allocation_site,
369 alloc_site_mode, 368 alloc_site_mode,
370 FAST_ELEMENTS, 369 FAST_ELEMENTS,
371 0/*copy-on-write*/); 370 0/*copy-on-write*/));
372 environment()->Push(push_value);
373 if_fixed_cow.Else(); 371 if_fixed_cow.Else();
374 372
375 IfBuilder if_fixed(this); 373 IfBuilder if_fixed(this);
376 if_fixed.If<HCompareMap>(elements, factory->fixed_array_map()); 374 if_fixed.If<HCompareMap>(elements, factory->fixed_array_map());
377 if_fixed.Then(); 375 if_fixed.Then();
378 push_value = BuildCloneShallowArray(boilerplate, 376 environment()->Push(BuildCloneShallowArray(boilerplate,
379 allocation_site, 377 allocation_site,
380 alloc_site_mode, 378 alloc_site_mode,
381 FAST_ELEMENTS, 379 FAST_ELEMENTS,
382 length); 380 length));
383 environment()->Push(push_value);
384 if_fixed.Else(); 381 if_fixed.Else();
385 push_value = BuildCloneShallowArray(boilerplate, 382 environment()->Push(BuildCloneShallowArray(boilerplate,
386 allocation_site, 383 allocation_site,
387 alloc_site_mode, 384 alloc_site_mode,
388 FAST_DOUBLE_ELEMENTS, 385 FAST_DOUBLE_ELEMENTS,
389 length); 386 length));
390 environment()->Push(push_value);
391 } else { 387 } else {
392 ElementsKind elements_kind = casted_stub()->ComputeElementsKind(); 388 ElementsKind elements_kind = casted_stub()->ComputeElementsKind();
393 push_value = BuildCloneShallowArray(boilerplate, 389 environment()->Push(BuildCloneShallowArray(boilerplate,
394 allocation_site, 390 allocation_site,
395 alloc_site_mode, 391 alloc_site_mode,
396 elements_kind, 392 elements_kind,
397 length); 393 length));
398 environment()->Push(push_value);
399 } 394 }
400 395
401 checker.ElseDeopt("Uninitialized boilerplate literals"); 396 checker.ElseDeopt("Uninitialized boilerplate literals");
402 checker.End(); 397 checker.End();
403 398
404 return environment()->Pop(); 399 return environment()->Pop();
405 } 400 }
406 401
407 402
408 Handle<Code> FastCloneShallowArrayStub::GenerateCode(Isolate* isolate) { 403 Handle<Code> FastCloneShallowArrayStub::GenerateCode(Isolate* isolate) {
(...skipping 693 matching lines...) Expand 10 before | Expand all | Expand 10 after
1102 return js_function; 1097 return js_function;
1103 } 1098 }
1104 1099
1105 1100
1106 Handle<Code> FastNewClosureStub::GenerateCode(Isolate* isolate) { 1101 Handle<Code> FastNewClosureStub::GenerateCode(Isolate* isolate) {
1107 return DoGenerateCode(isolate, this); 1102 return DoGenerateCode(isolate, this);
1108 } 1103 }
1109 1104
1110 1105
1111 } } // namespace v8::internal 1106 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/code-stubs.h ('k') | src/handles.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698