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

Side by Side Diff: src/arm/assembler-arm.h

Issue 1223213007: Version 4.5.103.7 (cherry-pick) (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@4.5
Patch Set: Created 5 years, 5 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
« no previous file with comments | « include/v8-version.h ('k') | src/arm/assembler-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 (c) 1994-2006 Sun Microsystems Inc. 1 // Copyright (c) 1994-2006 Sun Microsystems Inc.
2 // All Rights Reserved. 2 // All Rights Reserved.
3 // 3 //
4 // Redistribution and use in source and binary forms, with or without 4 // Redistribution and use in source and binary forms, with or without
5 // modification, are permitted provided that the following conditions 5 // modification, are permitted provided that the following conditions
6 // are met: 6 // are met:
7 // 7 //
8 // - Redistributions of source code must retain the above copyright notice, 8 // - Redistributions of source code must retain the above copyright notice,
9 // this list of conditions and the following disclaimer. 9 // this list of conditions and the following disclaimer.
10 // 10 //
(...skipping 682 matching lines...) Expand 10 before | Expand all | Expand 10 after
693 // bind(&L); // illegal: a label may be bound only once 693 // bind(&L); // illegal: a label may be bound only once
694 // 694 //
695 // Note: The same Label can be used for forward and backward branches 695 // Note: The same Label can be used for forward and backward branches
696 // but it may be bound only once. 696 // but it may be bound only once.
697 697
698 void bind(Label* L); // binds an unbound label L to the current code position 698 void bind(Label* L); // binds an unbound label L to the current code position
699 699
700 // Returns the branch offset to the given label from the current code position 700 // Returns the branch offset to the given label from the current code position
701 // Links the label to the current position if it is still unbound 701 // Links the label to the current position if it is still unbound
702 // Manages the jump elimination optimization if the second parameter is true. 702 // Manages the jump elimination optimization if the second parameter is true.
703 int branch_offset(Label* L, bool jump_elimination_allowed); 703 int branch_offset(Label* L);
704 704
705 // Returns true if the given pc address is the start of a constant pool load 705 // Returns true if the given pc address is the start of a constant pool load
706 // instruction sequence. 706 // instruction sequence.
707 INLINE(static bool is_constant_pool_load(Address pc)); 707 INLINE(static bool is_constant_pool_load(Address pc));
708 708
709 // Return the address in the constant pool of the code target address used by 709 // Return the address in the constant pool of the code target address used by
710 // the branch/call instruction at pc, or the object in a mov. 710 // the branch/call instruction at pc, or the object in a mov.
711 INLINE(static Address constant_pool_entry_address(Address pc, 711 INLINE(static Address constant_pool_entry_address(Address pc,
712 Address constant_pool)); 712 Address constant_pool));
713 713
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after
799 void CodeTargetAlign(); 799 void CodeTargetAlign();
800 800
801 // Branch instructions 801 // Branch instructions
802 void b(int branch_offset, Condition cond = al); 802 void b(int branch_offset, Condition cond = al);
803 void bl(int branch_offset, Condition cond = al); 803 void bl(int branch_offset, Condition cond = al);
804 void blx(int branch_offset); // v5 and above 804 void blx(int branch_offset); // v5 and above
805 void blx(Register target, Condition cond = al); // v5 and above 805 void blx(Register target, Condition cond = al); // v5 and above
806 void bx(Register target, Condition cond = al); // v5 and above, plus v4t 806 void bx(Register target, Condition cond = al); // v5 and above, plus v4t
807 807
808 // Convenience branch instructions using labels 808 // Convenience branch instructions using labels
809 void b(Label* L, Condition cond = al) { 809 void b(Label* L, Condition cond = al);
810 b(branch_offset(L, cond == al), cond); 810 void b(Condition cond, Label* L) { b(L, cond); }
811 } 811 void bl(Label* L, Condition cond = al);
812 void b(Condition cond, Label* L) { b(branch_offset(L, cond == al), cond); } 812 void bl(Condition cond, Label* L) { bl(L, cond); }
813 void bl(Label* L, Condition cond = al) { bl(branch_offset(L, false), cond); } 813 void blx(Label* L); // v5 and above
814 void bl(Condition cond, Label* L) { bl(branch_offset(L, false), cond); }
815 void blx(Label* L) { blx(branch_offset(L, false)); } // v5 and above
816 814
817 // Data-processing instructions 815 // Data-processing instructions
818 816
819 void and_(Register dst, Register src1, const Operand& src2, 817 void and_(Register dst, Register src1, const Operand& src2,
820 SBit s = LeaveCC, Condition cond = al); 818 SBit s = LeaveCC, Condition cond = al);
821 819
822 void eor(Register dst, Register src1, const Operand& src2, 820 void eor(Register dst, Register src1, const Operand& src2,
823 SBit s = LeaveCC, Condition cond = al); 821 SBit s = LeaveCC, Condition cond = al);
824 822
825 void sub(Register dst, Register src1, const Operand& src2, 823 void sub(Register dst, Register src1, const Operand& src2,
(...skipping 659 matching lines...) Expand 10 before | Expand all | Expand 10 after
1485 static const int kMaxNumPending32Constants = kMaxDistToIntPool / kInstrSize; 1483 static const int kMaxNumPending32Constants = kMaxDistToIntPool / kInstrSize;
1486 static const int kMaxNumPending64Constants = kMaxDistToFPPool / kInstrSize; 1484 static const int kMaxNumPending64Constants = kMaxDistToFPPool / kInstrSize;
1487 1485
1488 // Postpone the generation of the constant pool for the specified number of 1486 // Postpone the generation of the constant pool for the specified number of
1489 // instructions. 1487 // instructions.
1490 void BlockConstPoolFor(int instructions); 1488 void BlockConstPoolFor(int instructions);
1491 1489
1492 // Check if is time to emit a constant pool. 1490 // Check if is time to emit a constant pool.
1493 void CheckConstPool(bool force_emit, bool require_jump); 1491 void CheckConstPool(bool force_emit, bool require_jump);
1494 1492
1493 void MaybeCheckConstPool() {
1494 if (pc_offset() >= next_buffer_check_) {
1495 CheckConstPool(false, true);
1496 }
1497 }
1498
1495 int EmitEmbeddedConstantPool() { 1499 int EmitEmbeddedConstantPool() {
1496 DCHECK(FLAG_enable_embedded_constant_pool); 1500 DCHECK(FLAG_enable_embedded_constant_pool);
1497 return constant_pool_builder_.Emit(this); 1501 return constant_pool_builder_.Emit(this);
1498 } 1502 }
1499 1503
1500 bool ConstantPoolAccessIsInOverflow() const { 1504 bool ConstantPoolAccessIsInOverflow() const {
1501 return constant_pool_builder_.NextAccess(ConstantPoolEntry::INTPTR) == 1505 return constant_pool_builder_.NextAccess(ConstantPoolEntry::INTPTR) ==
1502 ConstantPoolEntry::OVERFLOWED; 1506 ConstantPoolEntry::OVERFLOWED;
1503 } 1507 }
1504 1508
(...skipping 158 matching lines...) Expand 10 before | Expand all | Expand 10 after
1663 public: 1667 public:
1664 explicit EnsureSpace(Assembler* assembler) { 1668 explicit EnsureSpace(Assembler* assembler) {
1665 assembler->CheckBuffer(); 1669 assembler->CheckBuffer();
1666 } 1670 }
1667 }; 1671 };
1668 1672
1669 1673
1670 } } // namespace v8::internal 1674 } } // namespace v8::internal
1671 1675
1672 #endif // V8_ARM_ASSEMBLER_ARM_H_ 1676 #endif // V8_ARM_ASSEMBLER_ARM_H_
OLDNEW
« no previous file with comments | « include/v8-version.h ('k') | src/arm/assembler-arm.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698