Home
last modified time | relevance | path

Searched refs:Pos (Results 1 – 25 of 293) sorted by relevance

12345678910>>...12

/openbsd-src/gnu/usr.bin/perl/cpan/Test-Simple/lib/Test/Builder/IO/
H A DScalar.pm97 *$self->{Pos} = 0; ### seek position
171 substr(${*$self->{SR}}, *$self->{Pos}++, 1);
193 my $i = *$self->{Pos}; ### Start matching at this point.
201 *$self->{Pos} = length $$sr;
217 $line = substr ($$sr, *$self->{Pos}, $i - *$self->{Pos} + 1);
218 *$self->{Pos} = $i+1; ### Remember where we finished up.
221 $line = substr ($$sr, *$self->{Pos}, $i - *$self->{Pos});
222 *$self->{Pos} = $len;
232 my $line = substr ($$sr, *$self->{Pos}, $i);
233 *$self->{Pos} += $i;
[all …]
/openbsd-src/gnu/llvm/clang/include/clang/Basic/
H A DJsonSupport.h34 size_t Pos = 0; in JsonFormat() local
38 Pos = Str.find('\\', Pos); in JsonFormat()
39 if (Pos == std::string::npos) in JsonFormat()
43 size_t TempPos = (Pos != 0) ? Pos - 1 : 0; in JsonFormat()
46 if (TempPos != Str.find("\\\\", Pos)) { in JsonFormat()
47 Str.insert(Pos, "\\"); in JsonFormat()
48 ++Pos; // As we insert the backslash move plus one. in JsonFormat()
51 ++Pos; in JsonFormat()
55 Pos = 0; in JsonFormat()
57 Pos = Str.find('\"', Pos); in JsonFormat()
[all …]
/openbsd-src/gnu/llvm/compiler-rt/lib/fuzzer/
H A DFuzzerIOWindows.cpp92 size_t Pos = Path.find_last_of("/\\"); in Basename() local
93 if (Pos == std::string::npos) return Path; in Basename()
94 assert(Pos < Path.size()); in Basename()
95 return Path.substr(Pos + 1); in Basename()
263 size_t Pos = Offset; in ParseFileName() local
265 for(; Pos < End && !IsSeparator(FileName[Pos]); ++Pos) in ParseFileName()
267 return Pos - Offset; in ParseFileName()
273 size_t Pos = Offset; in ParseDir() local
275 if (Pos >= End || IsSeparator(FileName[Pos])) in ParseDir()
277 for(; Pos < End && !IsSeparator(FileName[Pos]); ++Pos) in ParseDir()
[all …]
H A DFuzzerUtil.cpp98 for (size_t Pos = L; Pos <= R; Pos++) { in ParseOneDictionaryEntry() local
99 uint8_t V = (uint8_t)Str[Pos]; in ParseOneDictionaryEntry()
103 if (Pos + 1 <= R && (Str[Pos + 1] == '\\' || Str[Pos + 1] == '"')) { in ParseOneDictionaryEntry()
104 U->push_back(Str[Pos + 1]); in ParseOneDictionaryEntry()
105 Pos++; in ParseOneDictionaryEntry()
109 if (Pos + 3 <= R && Str[Pos + 1] == 'x' in ParseOneDictionaryEntry()
110 && isxdigit(Str[Pos + 2]) && isxdigit(Str[Pos + 3])) { in ParseOneDictionaryEntry()
112 Hex[2] = Str[Pos + 2]; in ParseOneDictionaryEntry()
113 Hex[3] = Str[Pos + 3]; in ParseOneDictionaryEntry()
115 Pos += 3; in ParseOneDictionaryEntry()
[all …]
/openbsd-src/gnu/llvm/llvm/lib/Support/
H A DLineIterator.cpp58 const char *Pos = CurrentLine.end(); in advance() local
59 assert(Pos == Buffer->getBufferStart() || isAtLineEnd(Pos) || *Pos == '\0'); in advance()
61 if (skipIfAtLineEnd(Pos)) in advance()
63 if (!SkipBlanks && isAtLineEnd(Pos)) { in advance()
67 while (skipIfAtLineEnd(Pos)) in advance()
72 if (isAtLineEnd(Pos) && !SkipBlanks) in advance()
74 if (*Pos == CommentMarker) in advance()
76 ++Pos; in advance()
77 } while (*Pos != '\0' && !isAtLineEnd(Pos)); in advance()
78 if (!skipIfAtLineEnd(Pos)) in advance()
[all …]
H A DFoldingSet.cpp55 unsigned Pos = 0; in AddString() local
61 Pos = (Units + 1) * 4; in AddString()
69 for (Pos += 4; Pos <= Size; Pos += 4) { in AddString()
70 unsigned V = ((unsigned char)String[Pos - 4] << 24) | in AddString()
71 ((unsigned char)String[Pos - 3] << 16) | in AddString()
72 ((unsigned char)String[Pos - 2] << 8) | in AddString()
73 (unsigned char)String[Pos - 1]; in AddString()
77 for (Pos += 4; Pos <= Size; Pos += 4) { in AddString()
78 unsigned V = ((unsigned char)String[Pos - 1] << 24) | in AddString()
79 ((unsigned char)String[Pos - 2] << 16) | in AddString()
[all …]
H A DFileUtilities.cpp54 static const char *BackupNumber(const char *Pos, const char *FirstChar) { in BackupNumber() argument
56 if (!isNumberChar(*Pos)) return Pos; in BackupNumber()
60 while (Pos > FirstChar && isNumberChar(Pos[-1])) { in BackupNumber()
62 if (Pos[-1] == '.') { in BackupNumber()
68 --Pos; in BackupNumber()
69 if (Pos > FirstChar && isSignedChar(Pos[0]) && !isExponentChar(Pos[-1])) in BackupNumber()
72 return Pos; in BackupNumber()
78 static const char *EndOfNumber(const char *Pos) { in EndOfNumber() argument
79 while (isNumberChar(*Pos)) in EndOfNumber()
80 ++Pos; in EndOfNumber()
[all …]
/openbsd-src/gnu/llvm/llvm/include/llvm/Transforms/IPO/
H A DWholeProgramDevirt.h46 std::pair<uint8_t *, uint8_t *> getPtrToData(uint64_t Pos, uint8_t Size) { in getPtrToData()
47 if (Bytes.size() < Pos + Size) { in getPtrToData()
48 Bytes.resize(Pos + Size); in getPtrToData()
49 BytesUsed.resize(Pos + Size); in getPtrToData()
51 return std::make_pair(Bytes.data() + Pos, BytesUsed.data() + Pos); in getPtrToData()
56 void setLE(uint64_t Pos, uint64_t Val, uint8_t Size) { in setLE()
57 assert(Pos % 8 == 0); in setLE()
58 auto DataUsed = getPtrToData(Pos / 8, Size); in setLE()
68 void setBE(uint64_t Pos, uint64_t Val, uint8_t Size) { in setBE()
69 assert(Pos % 8 == 0); in setBE()
[all …]
/openbsd-src/gnu/llvm/compiler-rt/lib/scudo/standalone/
H A Dflags_parser.cpp57 while (isSeparator(Buffer[Pos])) in skipWhitespace()
58 ++Pos; in skipWhitespace()
62 const uptr NameStart = Pos; in parseFlag()
63 while (Buffer[Pos] != '=' && !isSeparatorOrNull(Buffer[Pos])) in parseFlag()
64 ++Pos; in parseFlag()
65 if (Buffer[Pos] != '=') in parseFlag()
68 const uptr ValueStart = ++Pos; in parseFlag()
70 if (Buffer[Pos] == '\'' || Buffer[Pos] == '"') { in parseFlag()
71 const char Quote = Buffer[Pos++]; in parseFlag()
72 while (Buffer[Pos] != 0 && Buffer[Pos] != Quote) in parseFlag()
[all …]
H A Dstring_utils.cpp42 int Pos = 0; in appendNumber() local
44 RAW_CHECK_MSG(static_cast<uptr>(Pos) < MaxLen, in appendNumber()
46 NumBuffer[Pos++] = static_cast<uptr>(AbsoluteValue % Base); in appendNumber()
49 if (Pos < MinNumberLength) { in appendNumber()
50 memset(&NumBuffer[Pos], 0, in appendNumber()
51 sizeof(NumBuffer[0]) * static_cast<uptr>(MinNumberLength - Pos)); in appendNumber()
52 Pos = MinNumberLength; in appendNumber()
54 RAW_CHECK(Pos > 0); in appendNumber()
55 Pos--; in appendNumber()
56 for (; Pos >= 0 && NumBuffer[Pos] == 0; Pos--) { in appendNumber()
[all …]
H A Dlinux.cpp188 const char *Pos = Buf; in GetRSSFromBuffer() local
190 while (*Pos >= '0' && *Pos <= '9') in GetRSSFromBuffer()
191 Pos++; in GetRSSFromBuffer()
193 while (!(*Pos >= '0' && *Pos <= '9') && *Pos != 0) in GetRSSFromBuffer()
194 Pos++; in GetRSSFromBuffer()
197 for (; *Pos >= '0' && *Pos <= '9'; Pos++) in GetRSSFromBuffer()
198 Rss = Rss * 10 + static_cast<u64>(*Pos) - '0'; in GetRSSFromBuffer()
/openbsd-src/gnu/llvm/llvm/lib/CodeGen/
H A DAllocationOrder.h46 int Pos = 0; variable
49 Iterator(const AllocationOrder &AO, int Pos) : AO(AO), Pos(Pos) {} in Iterator() argument
52 bool isHint() const { return Pos < 0; } in isHint()
56 if (Pos < 0)
57 return AO.Hints.end()[Pos];
58 assert(Pos < AO.IterationLimit);
59 return AO.Order[Pos];
65 if (Pos < AO.IterationLimit)
66 ++Pos;
67 while (Pos >= 0 && Pos < AO.IterationLimit && AO.isHint(AO.Order[Pos]))
[all …]
H A DRenameIndependentSubregs.cpp189 SlotIndex Pos = LIS->getInstructionIndex(*MO.getParent()); in findComponents() local
190 Pos = MO.isDef() ? Pos.getRegSlot(MO.isEarlyClobber()) in findComponents()
191 : Pos.getBaseIndex(); in findComponents()
192 const VNInfo *VNI = SR.getVNInfoAt(Pos); in findComponents()
223 SlotIndex Pos = LIS->getInstructionIndex(*MI); in rewriteOperands() local
224 Pos = MO.isDef() ? Pos.getRegSlot(MO.isEarlyClobber()) in rewriteOperands()
225 : Pos.getBaseIndex(); in rewriteOperands()
234 const VNInfo *VNI = SR.getVNInfoAt(Pos); in rewriteOperands()
291 static bool subRangeLiveAt(const LiveInterval &LI, SlotIndex Pos) { in subRangeLiveAt() argument
293 if (SR.liveAt(Pos)) in subRangeLiveAt()
[all …]
/openbsd-src/gnu/llvm/llvm/tools/llvm-rc/
H A DResourceScriptToken.cpp88 Tokenizer(StringRef Input) : Data(Input), DataLength(Input.size()), Pos(0) {} in Tokenizer()
145 size_t DataLength, Pos; member in __anona72bc9cb0111::Tokenizer
149 Pos = Data.find_first_of("\r\n", Pos); in skipCurrentLine()
150 Pos = Data.find_first_not_of("\r\n", Pos); in skipCurrentLine()
152 if (Pos == StringRef::npos) in skipCurrentLine()
153 Pos = DataLength; in skipCurrentLine()
157 Pos = 0; in run()
170 return getStringError("Invalid token found at position " + Twine(Pos)); in run()
172 const size_t TokenStart = Pos; in run()
180 RCToken Token(TokenKind, Data.take_front(Pos).drop_front(TokenStart)); in run()
[all …]
H A DResourceScriptCppFilter.cpp38 size_t Pos = 0; member in __anon86252c330111::Filter
45 while (!streamEof() && Pos != StringRef::npos) { in run()
46 size_t LineStart = Pos; in run()
47 Pos = Data.find_first_of("\r\n", Pos); in run()
48 Pos = Data.find_first_not_of("\r\n", Pos); in run()
49 StringRef Line = Data.take_front(Pos).drop_front(LineStart); in run()
103 bool Filter::streamEof() const { return Pos == DataLength; } in streamEof()
/openbsd-src/gnu/llvm/clang/lib/Frontend/
H A DLayoutOverrideSource.cpp60 StringRef::size_type Pos; in LayoutOverrideSource() local
61 if ((Pos = LineStr.find("struct ")) != StringRef::npos) in LayoutOverrideSource()
62 LineStr = LineStr.substr(Pos + strlen("struct ")); in LayoutOverrideSource()
63 else if ((Pos = LineStr.find("class ")) != StringRef::npos) in LayoutOverrideSource()
64 LineStr = LineStr.substr(Pos + strlen("class ")); in LayoutOverrideSource()
65 else if ((Pos = LineStr.find("union ")) != StringRef::npos) in LayoutOverrideSource()
66 LineStr = LineStr.substr(Pos + strlen("union ")); in LayoutOverrideSource()
77 StringRef::size_type Pos = LineStr.find(" Size:"); in LayoutOverrideSource() local
78 if (Pos != StringRef::npos) { in LayoutOverrideSource()
80 LineStr = LineStr.substr(Pos + strlen(" Size:")); in LayoutOverrideSource()
[all …]
/openbsd-src/gnu/llvm/compiler-rt/lib/gwp_asan/optional/
H A Doptions_parser.cpp57 uintptr_t Pos = 0; member in __anon9de786660111::OptionParser
81 while (isSeparator(Buffer[Pos])) in skipWhitespace()
82 ++Pos; in skipWhitespace()
86 const uintptr_t NameStart = Pos; in parseOption()
87 while (Buffer[Pos] != '=' && !isSeparatorOrNull(Buffer[Pos])) in parseOption()
88 ++Pos; in parseOption()
91 if (Buffer[Pos] != '=') { in parseOption()
96 const uintptr_t ValueStart = ++Pos; in parseOption()
98 if (Buffer[Pos] == '\'' || Buffer[Pos] == '"') { in parseOption()
99 const char Quote = Buffer[Pos++]; in parseOption()
[all …]
/openbsd-src/gnu/llvm/llvm/lib/Target/Mips/
H A DMipsBranchExpansion.cpp162 MachineBasicBlock::iterator Pos, DebugLoc DL);
380 MachineBasicBlock::iterator Pos, in buildProperJumpMI() argument
401 BuildMI(*MBB, Pos, DL, TII->get(JumpOp)).addReg(ATReg); in buildProperJumpMI()
414 MachineBasicBlock::iterator Pos; in expandToLongBranch() local
468 Pos = LongBrMBB->begin(); in expandToLongBranch()
470 BuildMI(*LongBrMBB, Pos, DL, TII->get(Mips::ADDiu), Mips::SP) in expandToLongBranch()
473 BuildMI(*LongBrMBB, Pos, DL, TII->get(Mips::SW)) in expandToLongBranch()
494 BuildMI(*LongBrMBB, Pos, DL, TII->get(Mips::LONG_BRANCH_LUi), Mips::AT) in expandToLongBranch()
506 LongBrMBB->insert(Pos, ADDiuInstr); in expandToLongBranch()
507 LongBrMBB->insert(Pos, BalInstr); in expandToLongBranch()
[all …]
/openbsd-src/gnu/llvm/clang/lib/AST/
H A DCommentParser.cpp50 Position Pos; member in clang::comments::TextTokenRetokenizer
53 return Pos.CurToken >= Toks.size(); in isEnd()
59 const Token &Tok = Toks[Pos.CurToken]; in setupBuffer()
61 Pos.BufferStart = Tok.getText().begin(); in setupBuffer()
62 Pos.BufferEnd = Tok.getText().end(); in setupBuffer()
63 Pos.BufferPtr = Pos.BufferStart; in setupBuffer()
64 Pos.BufferStartLoc = Tok.getLocation(); in setupBuffer()
68 const unsigned CharNo = Pos.BufferPtr - Pos.BufferStart; in getSourceLocation()
69 return Pos.BufferStartLoc.getLocWithOffset(CharNo); in getSourceLocation()
74 assert(Pos.BufferPtr != Pos.BufferEnd); in peek()
[all …]
/openbsd-src/gnu/llvm/llvm/lib/MC/
H A DStringTableBuilder.cpp86 static int charTailAt(StringPair *P, size_t Pos) { in charTailAt() argument
88 if (Pos >= S.size()) in charTailAt()
90 return (unsigned char)S[S.size() - Pos - 1]; in charTailAt()
95 static void multikeySort(MutableArrayRef<StringPair *> Vec, int Pos) { in multikeySort() argument
103 int Pivot = charTailAt(Vec[0], Pos); in multikeySort()
107 int C = charTailAt(Vec[K], Pos); in multikeySort()
116 multikeySort(Vec.slice(0, I), Pos); in multikeySort()
117 multikeySort(Vec.slice(J), Pos); in multikeySort()
123 ++Pos; in multikeySort()
153 size_t Pos = Size - S.size() - (K != RAW); in finalizeStringTable() local
[all …]
/openbsd-src/gnu/llvm/llvm/lib/TableGen/
H A DTableGenBackend.cpp24 size_t Pos = (size_t)OS.tell(); in printLine() local
28 for (size_t i = (size_t)OS.tell() - Pos, e = MAX_LINE_LEN - Suffix.size(); in printLine()
41 size_t Pos = 0U; in emitSourceFileHeader() local
43 size_t Length = std::min(Desc.size() - Pos, MAX_LINE_LEN - PSLen); in emitSourceFileHeader()
44 printLine(OS, Prefix + Desc.substr(Pos, Length), ' ', Suffix); in emitSourceFileHeader()
45 Pos += Length; in emitSourceFileHeader()
46 } while (Pos < Desc.size()); in emitSourceFileHeader()
/openbsd-src/gnu/llvm/clang/lib/StaticAnalyzer/Checkers/
H A DContainerModeling.cpp568 const auto *Pos = getIteratorPosition(State, Iter); in handleInsert() local
569 if (!Pos) in handleInsert()
578 State = invalidateIteratorPositions(State, Pos->getOffset(), BO_GE); in handleInsert()
599 const auto *Pos = getIteratorPosition(State, Iter); in handleErase() local
600 if (!Pos) in handleErase()
610 State = invalidateIteratorPositions(State, Pos->getOffset(), BO_GE); in handleErase()
619 State = invalidateIteratorPositions(State, Pos->getOffset(), BO_EQ); in handleErase()
663 const auto *Pos = getIteratorPosition(State, Iter); in handleEraseAfter() local
664 if (!Pos) in handleEraseAfter()
674 nonloc::SymbolVal(Pos->getOffset()), in handleEraseAfter()
[all …]
H A DIteratorRangeChecker.cpp67 bool isPastTheEnd(ProgramStateRef State, const IteratorPosition &Pos);
68 bool isAheadOfRange(ProgramStateRef State, const IteratorPosition &Pos);
69 bool isBehindPastTheEnd(ProgramStateRef State, const IteratorPosition &Pos);
199 const auto *Pos = getIteratorPosition(State, Val); in verifyDereference() local
200 if (Pos && isPastTheEnd(State, *Pos)) { in verifyDereference()
284 const auto *Pos = getIteratorPosition(C.getState(), Val); in reportBug() local
285 assert(Pos && "Iterator without known position cannot be out-of-range."); in reportBug()
288 R->markInteresting(Pos->getContainer()); in reportBug()
305 bool isPastTheEnd(ProgramStateRef State, const IteratorPosition &Pos) { in isPastTheEnd() argument
306 const auto *Cont = Pos.getContainer(); in isPastTheEnd()
[all …]
/openbsd-src/gnu/llvm/llvm/include/llvm/LineEditor/
H A DLineEditor.h103 CompletionAction getCompletionAction(StringRef Buffer, size_t Pos) const;
118 virtual CompletionAction complete(StringRef Buffer, size_t Pos) const = 0;
123 CompletionAction complete(StringRef Buffer, size_t Pos) const override;
126 size_t Pos) const = 0;
132 CompletionAction complete(StringRef Buffer, size_t Pos) const override { in complete()
133 return Value(Buffer, Pos); in complete()
142 size_t Pos) const override { in getCompletions()
143 return Value(Buffer, Pos); in getCompletions()
/openbsd-src/gnu/llvm/llvm/include/llvm/ADT/
H A DMapVector.h114 typename MapType::const_iterator Pos = Map.find(Key); in lookup() local
115 return Pos == Map.end()? ValueT() : Vector[Pos->second].second; in lookup()
144 typename MapType::const_iterator Pos = Map.find(Key); in count() local
145 return Pos == Map.end()? 0 : 1; in count()
149 typename MapType::const_iterator Pos = Map.find(Key); in find() local
150 return Pos == Map.end()? Vector.end() : in find()
151 (Vector.begin() + Pos->second); in find()
155 typename MapType::const_iterator Pos = Map.find(Key); in find() local
156 return Pos == Map.end()? Vector.end() : in find()
157 (Vector.begin() + Pos->second); in find()
[all …]

12345678910>>...12