OLD | NEW |
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 4893 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4904 // deoptimize. | 4904 // deoptimize. |
4905 __ andl(result_reg, Immediate(1)); | 4905 __ andl(result_reg, Immediate(1)); |
4906 DeoptimizeIf(not_zero, instr->environment()); | 4906 DeoptimizeIf(not_zero, instr->environment()); |
4907 __ bind(&done); | 4907 __ bind(&done); |
4908 } | 4908 } |
4909 __ Integer32ToSmi(result_reg, result_reg); | 4909 __ Integer32ToSmi(result_reg, result_reg); |
4910 DeoptimizeIf(overflow, instr->environment()); | 4910 DeoptimizeIf(overflow, instr->environment()); |
4911 } | 4911 } |
4912 | 4912 |
4913 | 4913 |
| 4914 void LCodeGen::DoCheckSmiAndReturn(LCheckSmiAndReturn* instr) { |
| 4915 LOperand* input = instr->value(); |
| 4916 Condition cc = masm()->CheckSmi(ToRegister(input)); |
| 4917 DeoptimizeIf(NegateCondition(cc), instr->environment()); |
| 4918 } |
| 4919 |
| 4920 |
4914 void LCodeGen::DoCheckSmi(LCheckSmi* instr) { | 4921 void LCodeGen::DoCheckSmi(LCheckSmi* instr) { |
4915 LOperand* input = instr->value(); | 4922 LOperand* input = instr->value(); |
4916 Condition cc = masm()->CheckSmi(ToRegister(input)); | 4923 Condition cc = masm()->CheckSmi(ToRegister(input)); |
4917 DeoptimizeIf(NegateCondition(cc), instr->environment()); | 4924 DeoptimizeIf(NegateCondition(cc), instr->environment()); |
4918 } | 4925 } |
4919 | 4926 |
4920 | 4927 |
4921 void LCodeGen::DoCheckNonSmi(LCheckNonSmi* instr) { | 4928 void LCodeGen::DoCheckNonSmi(LCheckNonSmi* instr) { |
4922 LOperand* input = instr->value(); | 4929 LOperand* input = instr->value(); |
4923 Condition cc = masm()->CheckSmi(ToRegister(input)); | 4930 Condition cc = masm()->CheckSmi(ToRegister(input)); |
(...skipping 765 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5689 FixedArray::kHeaderSize - kPointerSize)); | 5696 FixedArray::kHeaderSize - kPointerSize)); |
5690 __ bind(&done); | 5697 __ bind(&done); |
5691 } | 5698 } |
5692 | 5699 |
5693 | 5700 |
5694 #undef __ | 5701 #undef __ |
5695 | 5702 |
5696 } } // namespace v8::internal | 5703 } } // namespace v8::internal |
5697 | 5704 |
5698 #endif // V8_TARGET_ARCH_X64 | 5705 #endif // V8_TARGET_ARCH_X64 |
OLD | NEW |