Home
last modified time | relevance | path

Searched refs:regs_ (Results 1 – 14 of 14) sorted by relevance

/system/core/libunwindstack/
DRegsMips64.cpp40 return regs_[MIPS64_REG_PC]; in pc()
44 return regs_[MIPS64_REG_SP]; in sp()
48 regs_[MIPS64_REG_PC] = pc; in set_pc()
52 regs_[MIPS64_REG_SP] = sp; in set_sp()
56 uint64_t ra = regs_[MIPS64_REG_RA]; in SetPcFromReturnAddress()
57 if (regs_[MIPS64_REG_PC] == ra) { in SetPcFromReturnAddress()
61 regs_[MIPS64_REG_PC] = ra; in SetPcFromReturnAddress()
66 fn("r0", regs_[MIPS64_REG_R0]); in IterateRegisters()
67 fn("r1", regs_[MIPS64_REG_R1]); in IterateRegisters()
68 fn("r2", regs_[MIPS64_REG_R2]); in IterateRegisters()
[all …]
DRegsMips.cpp40 return regs_[MIPS_REG_PC]; in pc()
44 return regs_[MIPS_REG_SP]; in sp()
48 regs_[MIPS_REG_PC] = static_cast<uint32_t>(pc); in set_pc()
52 regs_[MIPS_REG_SP] = static_cast<uint32_t>(sp); in set_sp()
56 uint32_t ra = regs_[MIPS_REG_RA]; in SetPcFromReturnAddress()
57 if (regs_[MIPS_REG_PC] == ra) { in SetPcFromReturnAddress()
61 regs_[MIPS_REG_PC] = ra; in SetPcFromReturnAddress()
66 fn("r0", regs_[MIPS_REG_R0]); in IterateRegisters()
67 fn("r1", regs_[MIPS_REG_R1]); in IterateRegisters()
68 fn("r2", regs_[MIPS_REG_R2]); in IterateRegisters()
[all …]
DRegsArm64.cpp43 return regs_[ARM64_REG_PC]; in pc()
47 return regs_[ARM64_REG_SP]; in sp()
68 regs_[ARM64_REG_PC] = pc; in set_pc()
72 regs_[ARM64_REG_SP] = sp; in set_sp()
76 uint64_t lr = regs_[ARM64_REG_LR]; in SetPcFromReturnAddress()
77 if (regs_[ARM64_REG_PC] == lr) { in SetPcFromReturnAddress()
81 regs_[ARM64_REG_PC] = lr; in SetPcFromReturnAddress()
86 fn("x0", regs_[ARM64_REG_R0]); in IterateRegisters()
87 fn("x1", regs_[ARM64_REG_R1]); in IterateRegisters()
88 fn("x2", regs_[ARM64_REG_R2]); in IterateRegisters()
[all …]
DRegsX86_64.cpp39 return regs_[X86_64_REG_PC]; in pc()
43 return regs_[X86_64_REG_SP]; in sp()
47 regs_[X86_64_REG_PC] = pc; in set_pc()
51 regs_[X86_64_REG_SP] = sp; in set_sp()
57 if (!process_memory->ReadFully(regs_[X86_64_REG_SP], &new_pc, sizeof(new_pc)) || in SetPcFromReturnAddress()
58 new_pc == regs_[X86_64_REG_PC]) { in SetPcFromReturnAddress()
62 regs_[X86_64_REG_PC] = new_pc; in SetPcFromReturnAddress()
67 fn("rax", regs_[X86_64_REG_RAX]); in IterateRegisters()
68 fn("rbx", regs_[X86_64_REG_RBX]); in IterateRegisters()
69 fn("rcx", regs_[X86_64_REG_RCX]); in IterateRegisters()
[all …]
DRegsX86.cpp38 return regs_[X86_REG_PC]; in pc()
42 return regs_[X86_REG_SP]; in sp()
46 regs_[X86_REG_PC] = static_cast<uint32_t>(pc); in set_pc()
50 regs_[X86_REG_SP] = static_cast<uint32_t>(sp); in set_sp()
56 if (!process_memory->ReadFully(regs_[X86_REG_SP], &new_pc, sizeof(new_pc)) || in SetPcFromReturnAddress()
57 new_pc == regs_[X86_REG_PC]) { in SetPcFromReturnAddress()
61 regs_[X86_REG_PC] = new_pc; in SetPcFromReturnAddress()
66 fn("eax", regs_[X86_REG_EAX]); in IterateRegisters()
67 fn("ebx", regs_[X86_REG_EBX]); in IterateRegisters()
68 fn("ecx", regs_[X86_REG_ECX]); in IterateRegisters()
[all …]
DRegsArm.cpp39 return regs_[ARM_REG_PC]; in pc()
43 return regs_[ARM_REG_SP]; in sp()
47 regs_[ARM_REG_PC] = pc; in set_pc()
51 regs_[ARM_REG_SP] = sp; in set_sp()
55 uint32_t lr = regs_[ARM_REG_LR]; in SetPcFromReturnAddress()
56 if (regs_[ARM_REG_PC] == lr) { in SetPcFromReturnAddress()
60 regs_[ARM_REG_PC] = lr; in SetPcFromReturnAddress()
65 fn("r0", regs_[ARM_REG_R0]); in IterateRegisters()
66 fn("r1", regs_[ARM_REG_R1]); in IterateRegisters()
67 fn("r2", regs_[ARM_REG_R2]); in IterateRegisters()
[all …]
DUnwinder.cpp57 uint64_t dex_pc = regs_->dex_pc(); in FillInDexFrame()
59 frame->sp = regs_->sp(); in FillInDexFrame()
101 frame->sp = regs_->sp(); in FillInFrame()
103 frame->pc = regs_->pc() - pc_adjustment; in FillInFrame()
149 ArchEnum arch = regs_->Arch(); in Unwind()
154 uint64_t cur_pc = regs_->pc(); in Unwind()
155 uint64_t cur_sp = regs_->sp(); in Unwind()
157 MapInfo* map_info = maps_->Find(regs_->pc()); in Unwind()
163 step_pc = regs_->pc(); in Unwind()
177 step_pc = regs_->pc(); in Unwind()
[all …]
DArmExidx.h57 : regs_(regs), elf_memory_(elf_memory), process_memory_(process_memory) {} in ArmExidx()
75 RegsArm* regs() { return regs_; } in regs()
107 RegsArm* regs_ = nullptr; variable
DArmExidx.cpp238 if (!process_memory_->Read32(cfa_, &(*regs_)[reg])) { in DecodePrefix_10_00()
249 cfa_ = (*regs_)[ARM_REG_SP]; in DecodePrefix_10_00()
286 cfa_ = (*regs_)[bits]; in DecodePrefix_10_01()
331 if (!process_memory_->Read32(cfa_, &(*regs_)[i])) { in DecodePrefix_10_10()
339 if (!process_memory_->Read32(cfa_, &(*regs_)[ARM_REG_R14])) { in DecodePrefix_10_10()
422 if (!process_memory_->Read32(cfa_, &(*regs_)[reg])) { in DecodePrefix_10_11_0001()
/system/core/libunwindstack/tests/
DUnwinderTest.cpp144 regs_.FakeSetArch(ARCH_ARM); in SetUp()
145 regs_.FakeSetReturnAddressValid(false); in SetUp()
149 static RegsFake regs_; member in unwindstack::UnwinderTest
154 RegsFake UnwinderTest::regs_(5); member in unwindstack::UnwinderTest
162 regs_.set_pc(0x1000); in TEST_F()
163 regs_.set_sp(0x10000); in TEST_F()
168 Unwinder unwinder(64, maps_.get(), &regs_, process_memory_); in TEST_F()
226 regs_.set_pc(0x1000); in TEST_F()
227 regs_.set_sp(0x10000); in TEST_F()
232 Unwinder unwinder(64, maps_.get(), &regs_, process_memory_); in TEST_F()
[all …]
DDwarfSectionTest.cpp62 static RegsFake regs_; member in unwindstack::DwarfSectionTest
65 RegsFake DwarfSectionTest::regs_(10); member in unwindstack::DwarfSectionTest
82 ASSERT_FALSE(section_->Step(0x1000, &regs_, nullptr, &finished)); in TEST_F()
96 ASSERT_FALSE(section_->Step(0x1000, &regs_, nullptr, &finished)); in TEST_F()
110 EXPECT_CALL(*section_, Eval(&cie, &process, ::testing::_, &regs_, ::testing::_)) in TEST_F()
114 ASSERT_TRUE(section_->Step(0x1000, &regs_, &process, &finished)); in TEST_F()
136 EXPECT_CALL(*section_, Eval(&cie, &process, ::testing::_, &regs_, ::testing::_)) in TEST_F()
140 ASSERT_TRUE(section_->Step(0x1000, &regs_, &process, &finished)); in TEST_F()
141 ASSERT_TRUE(section_->Step(0x1000, &regs_, &process, &finished)); in TEST_F()
142 ASSERT_TRUE(section_->Step(0x1500, &regs_, &process, &finished)); in TEST_F()
[all …]
DUnwindOfflineTest.cpp98 regs_.reset(regs); in Init()
104 regs_.reset(regs); in Init()
110 regs_.reset(regs); in Init()
116 regs_.reset(regs); in Init()
159 std::unique_ptr<Regs> regs_; member in unwindstack::UnwindOfflineTest
212 std::unique_ptr<Regs> regs_copy(regs_->Clone()); in TEST_F()
213 Unwinder unwinder(128, maps_.get(), regs_.get(), process_memory_); in TEST_F()
253 Unwinder unwinder(128, maps_.get(), regs_.get(), process_memory_); in TEST_F()
274 Unwinder unwinder(128, maps_.get(), regs_.get(), process_memory_); in TEST_F()
316 Unwinder unwinder(128, maps_.get(), regs_.get(), process_memory_); in TEST_F()
[all …]
/system/core/libunwindstack/include/unwindstack/
DRegs.h96 : Regs(total_regs, return_loc), regs_(total_regs) {} in RegsImpl()
101 inline AddressType& operator[](size_t reg) { return regs_[reg]; }
103 void* RawData() override { return regs_.data(); } in RawData()
106 for (size_t i = 0; i < regs_.size(); ++i) { in IterateRegisters()
107 fn(std::to_string(i).c_str(), regs_[i]); in IterateRegisters()
112 std::vector<AddressType> regs_;
DUnwinder.h67 : max_frames_(max_frames), maps_(maps), regs_(regs), process_memory_(process_memory) { in Unwinder()
95 void SetRegs(Regs* regs) { regs_ = regs; } in SetRegs()
132 Regs* regs_; variable