| OLD | NEW |
| 1 // Copyright 2011 the V8 project authors. All rights reserved. | 1 // Copyright 2011 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 367 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 378 // __ vldr(dbl_scratch, ToMemOperand(op)); | 378 // __ vldr(dbl_scratch, ToMemOperand(op)); |
| 379 MemOperand mem_op = ToMemOperand(op); | 379 MemOperand mem_op = ToMemOperand(op); |
| 380 __ vldr(dbl_scratch, mem_op.rn(), mem_op.offset()); | 380 __ vldr(dbl_scratch, mem_op.rn(), mem_op.offset()); |
| 381 return dbl_scratch; | 381 return dbl_scratch; |
| 382 } | 382 } |
| 383 UNREACHABLE(); | 383 UNREACHABLE(); |
| 384 return dbl_scratch; | 384 return dbl_scratch; |
| 385 } | 385 } |
| 386 | 386 |
| 387 | 387 |
| 388 Handle<Object> LCodeGen::ToHandle(LConstantOperand* op) const { |
| 389 Handle<Object> literal = chunk_->LookupLiteral(op); |
| 390 ASSERT(chunk_->LookupLiteralRepresentation(op).IsTagged()); |
| 391 return literal; |
| 392 } |
| 393 |
| 394 |
| 395 bool LCodeGen::IsInteger32(LConstantOperand* op) const { |
| 396 return chunk_->LookupLiteralRepresentation(op).IsInteger32(); |
| 397 } |
| 398 |
| 399 |
| 388 int LCodeGen::ToInteger32(LConstantOperand* op) const { | 400 int LCodeGen::ToInteger32(LConstantOperand* op) const { |
| 389 Handle<Object> value = chunk_->LookupLiteral(op); | 401 Handle<Object> value = chunk_->LookupLiteral(op); |
| 390 ASSERT(chunk_->LookupLiteralRepresentation(op).IsInteger32()); | 402 ASSERT(chunk_->LookupLiteralRepresentation(op).IsInteger32()); |
| 391 ASSERT(static_cast<double>(static_cast<int32_t>(value->Number())) == | 403 ASSERT(static_cast<double>(static_cast<int32_t>(value->Number())) == |
| 392 value->Number()); | 404 value->Number()); |
| 393 return static_cast<int32_t>(value->Number()); | 405 return static_cast<int32_t>(value->Number()); |
| 394 } | 406 } |
| 395 | 407 |
| 396 | 408 |
| 397 double LCodeGen::ToDouble(LConstantOperand* op) const { | 409 double LCodeGen::ToDouble(LConstantOperand* op) const { |
| (...skipping 4329 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4727 ASSERT(osr_pc_offset_ == -1); | 4739 ASSERT(osr_pc_offset_ == -1); |
| 4728 osr_pc_offset_ = masm()->pc_offset(); | 4740 osr_pc_offset_ = masm()->pc_offset(); |
| 4729 } | 4741 } |
| 4730 | 4742 |
| 4731 | 4743 |
| 4732 | 4744 |
| 4733 | 4745 |
| 4734 #undef __ | 4746 #undef __ |
| 4735 | 4747 |
| 4736 } } // namespace v8::internal | 4748 } } // namespace v8::internal |
| OLD | NEW |