OLD | NEW |
1 // Copyright 2010 the V8 project authors. All rights reserved. | 1 // Copyright 2010 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 689 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
700 // Print a message to stdout and abort execution. | 700 // Print a message to stdout and abort execution. |
701 void Abort(const char* msg); | 701 void Abort(const char* msg); |
702 | 702 |
703 // Verify restrictions about code generated in stubs. | 703 // Verify restrictions about code generated in stubs. |
704 void set_generating_stub(bool value) { generating_stub_ = value; } | 704 void set_generating_stub(bool value) { generating_stub_ = value; } |
705 bool generating_stub() { return generating_stub_; } | 705 bool generating_stub() { return generating_stub_; } |
706 void set_allow_stub_calls(bool value) { allow_stub_calls_ = value; } | 706 void set_allow_stub_calls(bool value) { allow_stub_calls_ = value; } |
707 bool allow_stub_calls() { return allow_stub_calls_; } | 707 bool allow_stub_calls() { return allow_stub_calls_; } |
708 | 708 |
709 // --------------------------------------------------------------------------- | 709 // --------------------------------------------------------------------------- |
| 710 // Number utilities |
| 711 |
| 712 // Check whether the value of reg is a power of two and not zero. If not |
| 713 // control continues at the label not_power_of_two. If reg is a power of two |
| 714 // the register scratch contains the value of (reg - 1) when control falls |
| 715 // through. |
| 716 void JumpIfNotPowerOfTwoOrZero(Register reg, |
| 717 Register scratch, |
| 718 Label* not_power_of_two_or_zero); |
| 719 |
| 720 // --------------------------------------------------------------------------- |
710 // Smi utilities | 721 // Smi utilities |
711 | 722 |
712 void SmiTag(Register reg, SBit s = LeaveCC) { | 723 void SmiTag(Register reg, SBit s = LeaveCC) { |
713 add(reg, reg, Operand(reg), s); | 724 add(reg, reg, Operand(reg), s); |
714 } | 725 } |
715 void SmiTag(Register dst, Register src, SBit s = LeaveCC) { | 726 void SmiTag(Register dst, Register src, SBit s = LeaveCC) { |
716 add(dst, src, Operand(src), s); | 727 add(dst, src, Operand(src), s); |
717 } | 728 } |
718 | 729 |
719 // Try to convert int32 to smi. If the value is to large, preserve | 730 // Try to convert int32 to smi. If the value is to large, preserve |
(...skipping 173 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
893 #define __FILE_LINE__ __FILE__ ":" CODE_COVERAGE_TOSTRING(__LINE__) | 904 #define __FILE_LINE__ __FILE__ ":" CODE_COVERAGE_TOSTRING(__LINE__) |
894 #define ACCESS_MASM(masm) masm->stop(__FILE_LINE__); masm-> | 905 #define ACCESS_MASM(masm) masm->stop(__FILE_LINE__); masm-> |
895 #else | 906 #else |
896 #define ACCESS_MASM(masm) masm-> | 907 #define ACCESS_MASM(masm) masm-> |
897 #endif | 908 #endif |
898 | 909 |
899 | 910 |
900 } } // namespace v8::internal | 911 } } // namespace v8::internal |
901 | 912 |
902 #endif // V8_ARM_MACRO_ASSEMBLER_ARM_H_ | 913 #endif // V8_ARM_MACRO_ASSEMBLER_ARM_H_ |
OLD | NEW |