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 427 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
438 b(eq, &done); | 438 b(eq, &done); |
439 mov(dst, Operand(0, RelocInfo::NONE), LeaveCC, mi); // 0 if negative. | 439 mov(dst, Operand(0, RelocInfo::NONE), LeaveCC, mi); // 0 if negative. |
440 mov(dst, Operand(satval), LeaveCC, pl); // satval if positive. | 440 mov(dst, Operand(satval), LeaveCC, pl); // satval if positive. |
441 bind(&done); | 441 bind(&done); |
442 } else { | 442 } else { |
443 usat(dst, satpos, src, cond); | 443 usat(dst, satpos, src, cond); |
444 } | 444 } |
445 } | 445 } |
446 | 446 |
447 | 447 |
448 void MacroAssembler::SmiJumpTable(Register index, Vector<Label*> targets) { | |
449 // Empty the const pool. | |
450 CheckConstPool(true, true); | |
451 add(pc, pc, Operand(index, | |
452 LSL, | |
453 Instruction::kInstrSizeLog2 - kSmiTagSize)); | |
454 BlockConstPoolBefore(pc_offset() + (targets.length() + 1) * kInstrSize); | |
455 nop(); // Jump table alignment. | |
456 for (int i = 0; i < targets.length(); i++) { | |
457 b(targets[i]); | |
458 } | |
459 } | |
460 | |
461 | |
462 void MacroAssembler::LoadRoot(Register destination, | 448 void MacroAssembler::LoadRoot(Register destination, |
463 Heap::RootListIndex index, | 449 Heap::RootListIndex index, |
464 Condition cond) { | 450 Condition cond) { |
465 ldr(destination, MemOperand(roots, index << kPointerSizeLog2), cond); | 451 ldr(destination, MemOperand(roots, index << kPointerSizeLog2), cond); |
466 } | 452 } |
467 | 453 |
468 | 454 |
469 void MacroAssembler::StoreRoot(Register source, | 455 void MacroAssembler::StoreRoot(Register source, |
470 Heap::RootListIndex index, | 456 Heap::RootListIndex index, |
471 Condition cond) { | 457 Condition cond) { |
(...skipping 2699 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3171 void CodePatcher::EmitCondition(Condition cond) { | 3157 void CodePatcher::EmitCondition(Condition cond) { |
3172 Instr instr = Assembler::instr_at(masm_.pc_); | 3158 Instr instr = Assembler::instr_at(masm_.pc_); |
3173 instr = (instr & ~kCondMask) | cond; | 3159 instr = (instr & ~kCondMask) | cond; |
3174 masm_.emit(instr); | 3160 masm_.emit(instr); |
3175 } | 3161 } |
3176 | 3162 |
3177 | 3163 |
3178 } } // namespace v8::internal | 3164 } } // namespace v8::internal |
3179 | 3165 |
3180 #endif // V8_TARGET_ARCH_ARM | 3166 #endif // V8_TARGET_ARCH_ARM |
OLD | NEW |