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 3482 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3493 Register index = a1; | 3493 Register index = a1; |
3494 Register value = a2; | 3494 Register value = a2; |
3495 | 3495 |
3496 VisitForStackValue(args->at(1)); // index | 3496 VisitForStackValue(args->at(1)); // index |
3497 VisitForStackValue(args->at(2)); // value | 3497 VisitForStackValue(args->at(2)); // value |
3498 VisitForAccumulatorValue(args->at(0)); // string | 3498 VisitForAccumulatorValue(args->at(0)); // string |
3499 __ Pop(index, value); | 3499 __ Pop(index, value); |
3500 | 3500 |
3501 if (FLAG_debug_code) { | 3501 if (FLAG_debug_code) { |
3502 __ SmiTst(value, at); | 3502 __ SmiTst(value, at); |
3503 __ ThrowIf(ne, kNonSmiValue, at, Operand(zero_reg)); | 3503 __ Check(eq, kNonSmiValue, at, Operand(zero_reg)); |
3504 __ SmiTst(index, at); | 3504 __ SmiTst(index, at); |
3505 __ ThrowIf(ne, kNonSmiIndex, at, Operand(zero_reg)); | 3505 __ Check(eq, kNonSmiIndex, at, Operand(zero_reg)); |
3506 __ SmiUntag(index, index); | 3506 __ SmiUntag(index, index); |
3507 static const uint32_t one_byte_seq_type = kSeqStringTag | kOneByteStringTag; | 3507 static const uint32_t one_byte_seq_type = kSeqStringTag | kOneByteStringTag; |
3508 Register scratch = t5; | 3508 Register scratch = t5; |
3509 __ EmitSeqStringSetCharCheck( | 3509 __ EmitSeqStringSetCharCheck( |
3510 string, index, value, scratch, one_byte_seq_type); | 3510 string, index, value, scratch, one_byte_seq_type); |
3511 __ SmiTag(index, index); | 3511 __ SmiTag(index, index); |
3512 } | 3512 } |
3513 | 3513 |
3514 __ SmiUntag(value, value); | 3514 __ SmiUntag(value, value); |
3515 __ Addu(at, | 3515 __ Addu(at, |
(...skipping 14 matching lines...) Expand all Loading... |
3530 Register index = a1; | 3530 Register index = a1; |
3531 Register value = a2; | 3531 Register value = a2; |
3532 | 3532 |
3533 VisitForStackValue(args->at(1)); // index | 3533 VisitForStackValue(args->at(1)); // index |
3534 VisitForStackValue(args->at(2)); // value | 3534 VisitForStackValue(args->at(2)); // value |
3535 VisitForAccumulatorValue(args->at(0)); // string | 3535 VisitForAccumulatorValue(args->at(0)); // string |
3536 __ Pop(index, value); | 3536 __ Pop(index, value); |
3537 | 3537 |
3538 if (FLAG_debug_code) { | 3538 if (FLAG_debug_code) { |
3539 __ SmiTst(value, at); | 3539 __ SmiTst(value, at); |
3540 __ ThrowIf(ne, kNonSmiValue, at, Operand(zero_reg)); | 3540 __ Check(eq, kNonSmiValue, at, Operand(zero_reg)); |
3541 __ SmiTst(index, at); | 3541 __ SmiTst(index, at); |
3542 __ ThrowIf(ne, kNonSmiIndex, at, Operand(zero_reg)); | 3542 __ Check(eq, kNonSmiIndex, at, Operand(zero_reg)); |
3543 __ SmiUntag(index, index); | 3543 __ SmiUntag(index, index); |
3544 static const uint32_t two_byte_seq_type = kSeqStringTag | kTwoByteStringTag; | 3544 static const uint32_t two_byte_seq_type = kSeqStringTag | kTwoByteStringTag; |
3545 Register scratch = t5; | 3545 Register scratch = t5; |
3546 __ EmitSeqStringSetCharCheck( | 3546 __ EmitSeqStringSetCharCheck( |
3547 string, index, value, scratch, two_byte_seq_type); | 3547 string, index, value, scratch, two_byte_seq_type); |
3548 __ SmiTag(index, index); | 3548 __ SmiTag(index, index); |
3549 } | 3549 } |
3550 | 3550 |
3551 __ SmiUntag(value, value); | 3551 __ SmiUntag(value, value); |
3552 __ Addu(at, | 3552 __ Addu(at, |
(...skipping 1408 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4961 Assembler::target_address_at(pc_immediate_load_address)) == | 4961 Assembler::target_address_at(pc_immediate_load_address)) == |
4962 reinterpret_cast<uint32_t>( | 4962 reinterpret_cast<uint32_t>( |
4963 isolate->builtins()->OsrAfterStackCheck()->entry())); | 4963 isolate->builtins()->OsrAfterStackCheck()->entry())); |
4964 return OSR_AFTER_STACK_CHECK; | 4964 return OSR_AFTER_STACK_CHECK; |
4965 } | 4965 } |
4966 | 4966 |
4967 | 4967 |
4968 } } // namespace v8::internal | 4968 } } // namespace v8::internal |
4969 | 4969 |
4970 #endif // V8_TARGET_ARCH_MIPS | 4970 #endif // V8_TARGET_ARCH_MIPS |
OLD | NEW |