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

Side by Side Diff: src/a64/lithium-codegen-a64.cc

Issue 180803005: HAllocate should never generate allocation code if the requested size does not fit into page. Regre… (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 9 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 | « no previous file | src/arm/lithium-codegen-arm.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 2013 the V8 project authors. All rights reserved. 1 // Copyright 2013 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 1468 matching lines...) Expand 10 before | Expand all | Expand 10 after
1479 ASSERT(!instr->hydrogen()->IsOldDataSpaceAllocation()); 1479 ASSERT(!instr->hydrogen()->IsOldDataSpaceAllocation());
1480 ASSERT(!instr->hydrogen()->IsNewSpaceAllocation()); 1480 ASSERT(!instr->hydrogen()->IsNewSpaceAllocation());
1481 flags = static_cast<AllocationFlags>(flags | PRETENURE_OLD_POINTER_SPACE); 1481 flags = static_cast<AllocationFlags>(flags | PRETENURE_OLD_POINTER_SPACE);
1482 } else if (instr->hydrogen()->IsOldDataSpaceAllocation()) { 1482 } else if (instr->hydrogen()->IsOldDataSpaceAllocation()) {
1483 ASSERT(!instr->hydrogen()->IsNewSpaceAllocation()); 1483 ASSERT(!instr->hydrogen()->IsNewSpaceAllocation());
1484 flags = static_cast<AllocationFlags>(flags | PRETENURE_OLD_DATA_SPACE); 1484 flags = static_cast<AllocationFlags>(flags | PRETENURE_OLD_DATA_SPACE);
1485 } 1485 }
1486 1486
1487 if (instr->size()->IsConstantOperand()) { 1487 if (instr->size()->IsConstantOperand()) {
1488 int32_t size = ToInteger32(LConstantOperand::cast(instr->size())); 1488 int32_t size = ToInteger32(LConstantOperand::cast(instr->size()));
1489 __ Allocate(size, result, temp1, temp2, deferred->entry(), flags); 1489 if (size <= Page::kMaxRegularHeapObjectSize) {
1490 __ Allocate(size, result, temp1, temp2, deferred->entry(), flags);
1491 } else {
1492 __ B(deferred->entry());
1493 }
1490 } else { 1494 } else {
1491 Register size = ToRegister32(instr->size()); 1495 Register size = ToRegister32(instr->size());
1492 __ Sxtw(size.X(), size); 1496 __ Sxtw(size.X(), size);
1493 __ Allocate(size.X(), result, temp1, temp2, deferred->entry(), flags); 1497 __ Allocate(size.X(), result, temp1, temp2, deferred->entry(), flags);
1494 } 1498 }
1495 1499
1496 __ Bind(deferred->exit()); 1500 __ Bind(deferred->exit());
1497 1501
1498 if (instr->hydrogen()->MustPrefillWithFiller()) { 1502 if (instr->hydrogen()->MustPrefillWithFiller()) {
1499 if (instr->size()->IsConstantOperand()) { 1503 if (instr->size()->IsConstantOperand()) {
(...skipping 4162 matching lines...) Expand 10 before | Expand all | Expand 10 after
5662 __ Bind(&out_of_object); 5666 __ Bind(&out_of_object);
5663 __ Ldr(result, FieldMemOperand(object, JSObject::kPropertiesOffset)); 5667 __ Ldr(result, FieldMemOperand(object, JSObject::kPropertiesOffset));
5664 // Index is equal to negated out of object property index plus 1. 5668 // Index is equal to negated out of object property index plus 1.
5665 __ Sub(result, result, Operand::UntagSmiAndScale(index, kPointerSizeLog2)); 5669 __ Sub(result, result, Operand::UntagSmiAndScale(index, kPointerSizeLog2));
5666 __ Ldr(result, FieldMemOperand(result, 5670 __ Ldr(result, FieldMemOperand(result,
5667 FixedArray::kHeaderSize - kPointerSize)); 5671 FixedArray::kHeaderSize - kPointerSize));
5668 __ Bind(&done); 5672 __ Bind(&done);
5669 } 5673 }
5670 5674
5671 } } // namespace v8::internal 5675 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « no previous file | src/arm/lithium-codegen-arm.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698