| 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 3948 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3959 if (instr->value()->IsConstantOperand()) { | 3959 if (instr->value()->IsConstantOperand()) { |
| 3960 LConstantOperand* operand_value = LConstantOperand::cast(instr->value()); | 3960 LConstantOperand* operand_value = LConstantOperand::cast(instr->value()); |
| 3961 if (!IsInteger32Constant(operand_value) && | 3961 if (!IsInteger32Constant(operand_value) && |
| 3962 !IsSmiConstant(operand_value)) { | 3962 !IsSmiConstant(operand_value)) { |
| 3963 DeoptimizeIf(no_condition, instr->environment()); | 3963 DeoptimizeIf(no_condition, instr->environment()); |
| 3964 } | 3964 } |
| 3965 } | 3965 } |
| 3966 } else if (representation.IsHeapObject()) { | 3966 } else if (representation.IsHeapObject()) { |
| 3967 if (instr->value()->IsConstantOperand()) { | 3967 if (instr->value()->IsConstantOperand()) { |
| 3968 LConstantOperand* operand_value = LConstantOperand::cast(instr->value()); | 3968 LConstantOperand* operand_value = LConstantOperand::cast(instr->value()); |
| 3969 if (IsInteger32Constant(operand_value)) { | 3969 if (chunk_->LookupConstant(operand_value)->HasSmiValue()) { |
| 3970 DeoptimizeIf(no_condition, instr->environment()); | 3970 DeoptimizeIf(no_condition, instr->environment()); |
| 3971 } | 3971 } |
| 3972 } else { | 3972 } else { |
| 3973 if (!hinstr->value()->type().IsHeapObject()) { | 3973 if (!hinstr->value()->type().IsHeapObject()) { |
| 3974 Register value = ToRegister(instr->value()); | 3974 Register value = ToRegister(instr->value()); |
| 3975 Condition cc = masm()->CheckSmi(value); | 3975 Condition cc = masm()->CheckSmi(value); |
| 3976 DeoptimizeIf(cc, instr->environment()); | 3976 DeoptimizeIf(cc, instr->environment()); |
| 3977 | 3977 |
| 3978 // We know that value is a smi now, so we can omit the check below. | 3978 // We know that value is a smi now, so we can omit the check below. |
| 3979 check_needed = OMIT_SMI_CHECK; | 3979 check_needed = OMIT_SMI_CHECK; |
| (...skipping 1679 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5659 FixedArray::kHeaderSize - kPointerSize)); | 5659 FixedArray::kHeaderSize - kPointerSize)); |
| 5660 __ bind(&done); | 5660 __ bind(&done); |
| 5661 } | 5661 } |
| 5662 | 5662 |
| 5663 | 5663 |
| 5664 #undef __ | 5664 #undef __ |
| 5665 | 5665 |
| 5666 } } // namespace v8::internal | 5666 } } // namespace v8::internal |
| 5667 | 5667 |
| 5668 #endif // V8_TARGET_ARCH_X64 | 5668 #endif // V8_TARGET_ARCH_X64 |
| OLD | NEW |