Home
last modified time | relevance | path

Searched refs:pos (Results 1 – 25 of 34) sorted by relevance

12

/art/runtime/base/
Dstringpiece.cc37 StringPiece::size_type StringPiece::copy(char* buf, size_type n, size_type pos) const { in copy()
38 size_type ret = std::min(length_ - pos, n); in copy()
39 memcpy(buf, ptr_ + pos, ret); in copy()
43 StringPiece::size_type StringPiece::find(const StringPiece& s, size_type pos) const { in find()
44 if (length_ == 0 || pos > static_cast<size_type>(length_)) { in find()
47 const char* result = std::search(ptr_ + pos, ptr_ + length_, s.ptr_, s.ptr_ + s.length_); in find()
61 StringPiece::size_type StringPiece::find(char c, size_type pos) const { in find()
62 if (length_ == 0 || pos >= length_) { in find()
65 const char* result = std::find(ptr_ + pos, ptr_ + length_, c); in find()
69 StringPiece::size_type StringPiece::rfind(const StringPiece& s, size_type pos) const { in rfind()
[all …]
Dstringpiece.h142 size_type copy(char* buf, size_type n, size_type pos = 0) const;
144 size_type find(const StringPiece& s, size_type pos = 0) const;
145 size_type find(char c, size_type pos = 0) const;
146 size_type rfind(const StringPiece& s, size_type pos = npos) const;
147 size_type rfind(char c, size_type pos = npos) const;
149 StringPiece substr(size_type pos, size_type n = npos) const;
/art/compiler/dex/quick/
Dlazy_debug_frame_opcode_writer.cc35 size_t pos = 0; in Patch() local
37 DCHECK_GE(advance.pos, pos); in Patch()
40 old_opcodes.begin() + pos, in Patch()
41 old_opcodes.begin() + advance.pos); in Patch()
42 pos = advance.pos; in Patch()
50 old_opcodes.begin() + pos, in Patch()
Dlazy_debug_frame_opcode_writer.h53 size_t pos; member
/art/compiler/
Dcfi_test.h75 size_t pos = str.find(substr); in FindEndOf() local
76 CHECK_NE(std::string::npos, pos); in FindEndOf()
77 return pos + strlen(substr); in FindEndOf()
87 size_t pos; in ReformatAsm() local
88 while ((pos = line.find(" ")) != std::string::npos) { in ReformatAsm()
89 line = line.replace(pos, 2, " "); in ReformatAsm()
112 size_t pos; in ReformatCfi() local
113 if ((pos = new_line.find(bad_reg)) != std::string::npos) { in ReformatCfi()
114 new_line = new_line.replace(pos, strlen(bad_reg), ""); in ReformatCfi()
117 if ((pos = new_line.find(" (")) != std::string::npos) { in ReformatCfi()
[all …]
Dimage_test.cc54 size_t pos = image_filename.rfind('/'); in TEST_F() local
55 CHECK_NE(pos, std::string::npos) << image_filename; in TEST_F()
56 std::string image_dir(image_filename, 0, pos); in TEST_F()
/art/tools/dexfuzz/src/dexfuzz/rawdex/
DOffsettable.java87 public void setOriginalPosition(int pos) { in setOriginalPosition() argument
88 originalPosition = pos; in setOriginalPosition()
105 public void setNewPosition(int pos) { in setNewPosition() argument
107 newPosition = pos; in setNewPosition()
/art/runtime/gc/space/
Dbump_pointer_space.cc157 uint8_t* pos = Begin(); in Walk() local
159 uint8_t* main_end = pos; in Walk()
176 while (pos < main_end) { in Walk()
177 mirror::Object* obj = reinterpret_cast<mirror::Object*>(pos); in Walk()
186 pos = reinterpret_cast<uint8_t*>(GetNextObject(obj)); in Walk()
190 while (pos < end) { in Walk()
191 BlockHeader* header = reinterpret_cast<BlockHeader*>(pos); in Walk()
193 pos += sizeof(BlockHeader); // Skip the header so that we know where the objects in Walk()
194 mirror::Object* obj = reinterpret_cast<mirror::Object*>(pos); in Walk()
195 const mirror::Object* end_obj = reinterpret_cast<const mirror::Object*>(pos + block_size); in Walk()
[all …]
Dmalloc_space.cc102 size_t pos = recent_free_pos_; in FindRecentFreedObject() local
107 pos = pos != 0 ? pos - 1 : kRecentFreeMask; in FindRecentFreedObject()
108 if (recent_freed_objects_[pos].first == obj) { in FindRecentFreedObject()
109 return recent_freed_objects_[pos].second; in FindRecentFreedObject()
Dregion_space-inl.h245 uint8_t* pos = r->Begin(); in WalkInternal() local
247 while (pos < top) { in WalkInternal()
248 mirror::Object* obj = reinterpret_cast<mirror::Object*>(pos); in WalkInternal()
251 pos = reinterpret_cast<uint8_t*>(GetNextObject(obj)); in WalkInternal()
/art/runtime/
Dsafe_map.h97 iterator PutBefore(iterator pos, const K& k, const V& v) { in PutBefore() argument
99 DCHECK(pos == map_.end() || map_.key_comp()(k, pos->first)); in PutBefore()
100 DCHECK(pos == map_.begin() || map_.key_comp()((--iterator(pos))->first, k)); in PutBefore()
101 return map_.emplace_hint(pos, k, v); in PutBefore()
Doat_file_assistant.cc756 size_t pos = location.rfind('/'); in CopyProfileFile() local
757 if (pos == std::string::npos) { in CopyProfileFile()
761 std::string dir = location.substr(0, pos+1); in CopyProfileFile()
766 if (pos == std::string::npos) { in CopyProfileFile()
769 file = location.substr(pos+1); in CopyProfileFile()
773 pos = file.rfind('.'); in CopyProfileFile()
774 if (pos == std::string::npos) { in CopyProfileFile()
778 std::string base = file.substr(0, pos); in CopyProfileFile()
Ddex_file.h420 const char* pos = strrchr(location, kMultiDexSeparator); in GetBaseLocation() local
421 if (pos == nullptr) { in GetBaseLocation()
424 return std::string(location, pos - location); in GetBaseLocation()
436 size_t pos = location.rfind(kMultiDexSeparator); in GetMultiDexSuffix() local
437 if (pos == std::string::npos) { in GetMultiDexSuffix()
440 return location.substr(pos); in GetMultiDexSuffix()
Dutils.cc1361 size_t pos = filename->rfind('/'); in InsertIsaDirectory() local
1362 CHECK_NE(pos, std::string::npos) << *filename << " " << isa; in InsertIsaDirectory()
1363 filename->insert(pos, "/", 1); in InsertIsaDirectory()
1364 filename->insert(pos + 1, GetInstructionSetString(isa)); in InsertIsaDirectory()
/art/compiler/dex/
Dmir_analysis.cc1278 for (size_t pos = 0u; pos != ifield_pos; ++pos) { in DoCacheFieldLoweringInfo() local
1279 const uint32_t field_idx = field_idxs[pos]; in DoCacheFieldLoweringInfo()
1284 MirIFieldLoweringInfo(masked_field_idx, field_types[pos], is_quickened)); in DoCacheFieldLoweringInfo()
1294 for (size_t pos = max_refs; pos != sfield_pos;) { in DoCacheFieldLoweringInfo() local
1295 --pos; in DoCacheFieldLoweringInfo()
1296 sfield_lowering_infos_.push_back(MirSFieldLoweringInfo(field_idxs[pos], field_types[pos])); in DoCacheFieldLoweringInfo()
1410 for (size_t pos = 0u; pos != count; ++pos) { in DoCacheMethodLoweringInfo() local
1411 const MapEntry* entry = sequential_entries[pos]; in DoCacheMethodLoweringInfo()
Dmir_graph_test.cc434 size_t pos = 0; in TEST_F() local
438 ASSERT_NE(arraysize(expected_and_change), pos); in TEST_F()
439 ASSERT_EQ(expected_and_change[pos].first, bb->id) << pos; in TEST_F()
440 change = expected_and_change[pos].second; in TEST_F()
441 ++pos; in TEST_F()
443 ASSERT_EQ(arraysize(expected_and_change), pos); in TEST_F()
Dgvn_dead_code_elimination.h99 MIRData* GetMIRData(size_t pos);
Dgvn_dead_code_elimination.cc92 uint16_t pos = mir_data_.size(); in AddMIRWithDef() local
106 vreg_data_[v_reg].change = pos; in AddMIRWithDef()
117 vreg_data_[v_reg + 1].change = pos; in AddMIRWithDef()
165 inline GvnDeadCodeElimination::MIRData* GvnDeadCodeElimination::VRegChains::GetMIRData(size_t pos) { in GetMIRData() argument
166 DCHECK_LT(pos, mir_data_.size()); in GetMIRData()
167 return &mir_data_[pos]; in GetMIRData()
Dmir_graph.cc2438 auto pos = std::find(predecessors.begin(), predecessors.end(), old_pred); in ErasePredecessor() local
2439 DCHECK(pos != predecessors.end()); in ErasePredecessor()
2441 *pos = predecessors.back(); in ErasePredecessor()
2443 size_t idx = std::distance(predecessors.begin(), pos); in ErasePredecessor()
2458 auto pos = std::find(predecessors.begin(), predecessors.end(), old_pred); in UpdatePredecessor() local
2459 DCHECK(pos != predecessors.end()); in UpdatePredecessor()
2460 *pos = new_pred; in UpdatePredecessor()
2461 size_t idx = std::distance(predecessors.begin(), pos); in UpdatePredecessor()
Dlocal_value_numbering.cc1170 int16_t pos = 0; in HandlePhi() local
1172 DCHECK_LT(pos, mir->ssa_rep->num_uses); in HandlePhi()
1173 while (incoming[pos] != lvn->Id()) { in HandlePhi()
1174 ++pos; in HandlePhi()
1175 DCHECK_LT(pos, mir->ssa_rep->num_uses); in HandlePhi()
1177 int s_reg = uses[pos]; in HandlePhi()
1178 ++pos; in HandlePhi()
/art/compiler/optimizing/
Doptimizing_unit_test.h104 std::string::size_type pos = result.find(p.first); in Patch() local
105 EXPECT_NE(pos, std::string::npos); in Patch()
106 result.replace(pos, p.first.size(), p.second); in Patch()
/art/patchoat/
Dpatchoat.cc422 for (size_t pos = 0; pos < section.Size(); pos += sizeof(ArtField)) { in PatchArtFields() local
423 auto* src = reinterpret_cast<ArtField*>(heap_->Begin() + section.Offset() + pos); in PatchArtFields()
433 for (size_t pos = 0; pos < section.Size(); pos += method_size) { in PatchArtMethods() local
434 auto* src = reinterpret_cast<ArtMethod*>(heap_->Begin() + section.Offset() + pos); in PatchArtMethods()
/art/tools/
Dcpplint.py1061 def CloseExpression(clean_lines, linenum, pos): argument
1080 startchar = line[pos]
1088 end_pos = FindEndOfExpressionInLine(line, pos, 0, startchar, endchar)
1091 tail = line[pos:]
2615 pos = line.find('else if')
2616 pos = line.find('(', pos)
2617 if pos > 0:
2618 (endline, _, endpos) = CloseExpression(clean_lines, linenum, pos)
/art/compiler/linker/arm64/
Drelative_patcher_arm64_test.cc196 void InsertInsn(std::vector<uint8_t>* code, size_t pos, uint32_t insn) { in InsertInsn() argument
197 CHECK_LE(pos, code->size()); in InsertInsn()
203 code->insert(code->begin() + pos, insn_code, insn_code + sizeof(insn_code)); in InsertInsn()
/art/runtime/gc/allocator/
Drosalloc.cc804 std::set<Run*>::iterator pos = non_full_runs->find(run); in FreeFromRun() local
805 if (pos != non_full_runs->end()) { in FreeFromRun()
806 non_full_runs->erase(pos); in FreeFromRun()
828 auto pos = non_full_runs->find(run); in FreeFromRun() local
829 if (pos == non_full_runs->end()) { in FreeFromRun()
1292 std::unordered_set<Run*, hash_run, eq_run>::iterator pos = full_runs->find(run); in BulkFree() local
1293 DCHECK(pos != full_runs->end()); in BulkFree()
1294 full_runs->erase(pos); in BulkFree()

12