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

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

Issue 247533005: ARM64: Slightly improve MacroAssembler::Allocate. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 8 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/arm64/lithium-codegen-arm64.h ('k') | src/arm64/macro-assembler-arm64.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 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 1758 matching lines...) Expand 10 before | Expand all | Expand 10 after
1769 case Token::BIT_OR: __ Orr(result, left, right); break; 1769 case Token::BIT_OR: __ Orr(result, left, right); break;
1770 case Token::BIT_XOR: __ Eor(result, left, right); break; 1770 case Token::BIT_XOR: __ Eor(result, left, right); break;
1771 default: 1771 default:
1772 UNREACHABLE(); 1772 UNREACHABLE();
1773 break; 1773 break;
1774 } 1774 }
1775 } 1775 }
1776 1776
1777 1777
1778 void LCodeGen::DoBoundsCheck(LBoundsCheck *instr) { 1778 void LCodeGen::DoBoundsCheck(LBoundsCheck *instr) {
1779 Condition cc = instr->hydrogen()->allow_equality() ? hi : hs; 1779 Condition cond = instr->hydrogen()->allow_equality() ? hi : hs;
1780 ASSERT(instr->hydrogen()->index()->representation().IsInteger32()); 1780 ASSERT(instr->hydrogen()->index()->representation().IsInteger32());
1781 ASSERT(instr->hydrogen()->length()->representation().IsInteger32()); 1781 ASSERT(instr->hydrogen()->length()->representation().IsInteger32());
1782 if (instr->index()->IsConstantOperand()) { 1782 if (instr->index()->IsConstantOperand()) {
1783 Operand index = ToOperand32I(instr->index()); 1783 Operand index = ToOperand32I(instr->index());
1784 Register length = ToRegister32(instr->length()); 1784 Register length = ToRegister32(instr->length());
1785 __ Cmp(length, index); 1785 __ Cmp(length, index);
1786 cc = ReverseConditionForCmp(cc); 1786 cond = ReverseConditionForCmp(cond);
1787 } else { 1787 } else {
1788 Register index = ToRegister32(instr->index()); 1788 Register index = ToRegister32(instr->index());
1789 Operand length = ToOperand32I(instr->length()); 1789 Operand length = ToOperand32I(instr->length());
1790 __ Cmp(index, length); 1790 __ Cmp(index, length);
1791 } 1791 }
1792 if (FLAG_debug_code && instr->hydrogen()->skip_check()) { 1792 if (FLAG_debug_code && instr->hydrogen()->skip_check()) {
1793 __ Assert(InvertCondition(cc), kEliminatedBoundsCheckFailed); 1793 __ Assert(InvertCondition(cond), kEliminatedBoundsCheckFailed);
1794 } else { 1794 } else {
1795 DeoptimizeIf(cc, instr->environment()); 1795 DeoptimizeIf(cond, instr->environment());
1796 } 1796 }
1797 } 1797 }
1798 1798
1799 1799
1800 void LCodeGen::DoBranch(LBranch* instr) { 1800 void LCodeGen::DoBranch(LBranch* instr) {
1801 Representation r = instr->hydrogen()->value()->representation(); 1801 Representation r = instr->hydrogen()->value()->representation();
1802 Label* true_label = instr->TrueLabel(chunk_); 1802 Label* true_label = instr->TrueLabel(chunk_);
1803 Label* false_label = instr->FalseLabel(chunk_); 1803 Label* false_label = instr->FalseLabel(chunk_);
1804 1804
1805 if (r.IsInteger32()) { 1805 if (r.IsInteger32()) {
(...skipping 4089 matching lines...) Expand 10 before | Expand all | Expand 10 after
5895 __ Ldr(result, FieldMemOperand(object, JSObject::kPropertiesOffset)); 5895 __ Ldr(result, FieldMemOperand(object, JSObject::kPropertiesOffset));
5896 // Index is equal to negated out of object property index plus 1. 5896 // Index is equal to negated out of object property index plus 1.
5897 __ Sub(result, result, Operand::UntagSmiAndScale(index, kPointerSizeLog2)); 5897 __ Sub(result, result, Operand::UntagSmiAndScale(index, kPointerSizeLog2));
5898 __ Ldr(result, FieldMemOperand(result, 5898 __ Ldr(result, FieldMemOperand(result,
5899 FixedArray::kHeaderSize - kPointerSize)); 5899 FixedArray::kHeaderSize - kPointerSize));
5900 __ Bind(deferred->exit()); 5900 __ Bind(deferred->exit());
5901 __ Bind(&done); 5901 __ Bind(&done);
5902 } 5902 }
5903 5903
5904 } } // namespace v8::internal 5904 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/arm64/lithium-codegen-arm64.h ('k') | src/arm64/macro-assembler-arm64.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698