OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 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 4333 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4344 if (representation.IsSmi()) { | 4344 if (representation.IsSmi()) { |
4345 if (instr->value()->IsConstantOperand()) { | 4345 if (instr->value()->IsConstantOperand()) { |
4346 LConstantOperand* operand_value = LConstantOperand::cast(instr->value()); | 4346 LConstantOperand* operand_value = LConstantOperand::cast(instr->value()); |
4347 if (!IsSmi(operand_value)) { | 4347 if (!IsSmi(operand_value)) { |
4348 DeoptimizeIf(no_condition, instr->environment()); | 4348 DeoptimizeIf(no_condition, instr->environment()); |
4349 } | 4349 } |
4350 } | 4350 } |
4351 } else if (representation.IsHeapObject()) { | 4351 } else if (representation.IsHeapObject()) { |
4352 if (instr->value()->IsConstantOperand()) { | 4352 if (instr->value()->IsConstantOperand()) { |
4353 LConstantOperand* operand_value = LConstantOperand::cast(instr->value()); | 4353 LConstantOperand* operand_value = LConstantOperand::cast(instr->value()); |
4354 if (IsInteger32(operand_value)) { | 4354 if (chunk_->LookupConstant(operand_value)->HasSmiValue()) { |
4355 DeoptimizeIf(no_condition, instr->environment()); | 4355 DeoptimizeIf(no_condition, instr->environment()); |
4356 } | 4356 } |
4357 } else { | 4357 } else { |
4358 if (!instr->hydrogen()->value()->type().IsHeapObject()) { | 4358 if (!instr->hydrogen()->value()->type().IsHeapObject()) { |
4359 Register value = ToRegister(instr->value()); | 4359 Register value = ToRegister(instr->value()); |
4360 __ test(value, Immediate(kSmiTagMask)); | 4360 __ test(value, Immediate(kSmiTagMask)); |
4361 DeoptimizeIf(zero, instr->environment()); | 4361 DeoptimizeIf(zero, instr->environment()); |
4362 | 4362 |
4363 // We know that value is a smi now, so we can omit the check below. | 4363 // We know that value is a smi now, so we can omit the check below. |
4364 check_needed = OMIT_SMI_CHECK; | 4364 check_needed = OMIT_SMI_CHECK; |
(...skipping 1987 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
6352 FixedArray::kHeaderSize - kPointerSize)); | 6352 FixedArray::kHeaderSize - kPointerSize)); |
6353 __ bind(&done); | 6353 __ bind(&done); |
6354 } | 6354 } |
6355 | 6355 |
6356 | 6356 |
6357 #undef __ | 6357 #undef __ |
6358 | 6358 |
6359 } } // namespace v8::internal | 6359 } } // namespace v8::internal |
6360 | 6360 |
6361 #endif // V8_TARGET_ARCH_IA32 | 6361 #endif // V8_TARGET_ARCH_IA32 |
OLD | NEW |