/freebsd/lib/libefivar/ |
H A D | efivar-dp-format.c | 90 IN OUT POOL_PRINT *Str, in UefiDevicePathLibCatPrint() argument 102 if ((Str->Count + (Count + 1)) > Str->Capacity) { in UefiDevicePathLibCatPrint() 103 Str->Capacity = (Str->Count + (Count + 1) * 2); in UefiDevicePathLibCatPrint() 104 Str->Str = reallocf ( in UefiDevicePathLibCatPrint() 105 Str->Str, in UefiDevicePathLibCatPrint() 106 Str->Capacity in UefiDevicePathLibCatPrint() 108 ASSERT (Str->Str != NULL); in UefiDevicePathLibCatPrint() 112 vsnprintf (Str->Str + Str->Count, Str->Capacity - Str->Count, Fmt, Args); in UefiDevicePathLibCatPrint() 113 Str->Count += Count; in UefiDevicePathLibCatPrint() 116 return Str->Str; in UefiDevicePathLibCatPrint() [all …]
|
/freebsd/contrib/llvm-project/llvm/tools/llvm-mc/ |
H A D | Disassembler.cpp | 77 static bool SkipToToken(StringRef &Str) { in PrintInsts() 79 if (Str.empty()) in SkipToToken() argument 83 if (size_t Pos = Str.find_first_not_of(" \t\r\n,")) { in SkipToToken() 84 Str = Str.substr(Pos); in SkipToToken() 89 if (Str[0] == '#') { in SkipToToken() 90 Str = Str.substr(Str.find_first_of('\n')); in SkipToToken() 99 StringRef &Str, 101 ByteArrayFromString(ByteArrayTy & ByteArray,StringRef & Str,SourceMgr & SM) ByteArrayFromString() argument 165 StringRef Str = Buffer.getBuffer(); disassemble() local [all...] |
/freebsd/contrib/llvm-project/llvm/lib/Support/ |
H A D | StringRef.cpp | 130 size_t StringRef::find(StringRef Str, size_t From) const { in find() argument 137 const char *Needle = Str.data(); in find() 138 size_t N = Str.size(); in find() 176 BadCharSkip[(uint8_t)Str[i]] = N-1-i; in find() 191 size_t StringRef::find_insensitive(StringRef Str, size_t From) const { in find_insensitive() argument 193 while (This.size() >= Str.size()) { in find_insensitive() 194 if (This.starts_with_insensitive(Str)) in find_insensitive() 217 size_t StringRef::rfind(StringRef Str) const { in rfind() 218 return std::string_view(*this).rfind(Str); in rfind() 221 size_t StringRef::rfind_insensitive(StringRef Str) const { in rfind_insensitive() [all …]
|
H A D | ScaledNumber.cpp | 137 static void appendDigit(std::string &Str, unsigned D) { in appendDigit() argument 139 Str += '0' + D % 10; in appendDigit() 142 static void appendNumber(std::string &Str, uint64_t N) { in appendNumber() argument 144 appendDigit(Str, N % 10); in appendNumber() 238 std::string Str; in toString() local 241 appendNumber(Str, Above0); in toString() 242 DigitsOut = Str.size(); in toString() 244 appendDigit(Str, 0); in toString() 245 std::reverse(Str.begin(), Str.end()); in toString() 249 return Str + ".0"; in toString() [all …]
|
H A D | GraphWriter.cpp | 57 std::string Str(Label); in EscapeString() local 58 for (unsigned i = 0; i != Str.length(); ++i) in EscapeString() 59 switch (Str[i]) { in EscapeString() 61 Str.insert(Str.begin()+i, '\\'); // Escape character... in EscapeString() 63 Str[i] = 'n'; in EscapeString() 66 Str.insert(Str.begin()+i, ' '); // Convert to two spaces in EscapeString() 68 Str[i] = ' '; in EscapeString() 71 if (i+1 != Str.length()) in EscapeString() 72 switch (Str[i+1]) { in EscapeString() 75 Str.erase(Str.begin()+i); continue; in EscapeString() [all …]
|
/freebsd/contrib/llvm-project/lldb/source/Plugins/ObjectFile/Breakpad/ |
H A D | BreakpadRecords.cpp | 39 static T stringTo(llvm::StringRef Str); 41 template <> Token stringTo<Token>(llvm::StringRef Str) { in stringTo() 42 return llvm::StringSwitch<Token>(Str) in stringTo() 59 llvm::Triple::OSType stringTo<llvm::Triple::OSType>(llvm::StringRef Str) { in stringTo() 61 return llvm::StringSwitch<Triple::OSType>(Str) in stringTo() 69 llvm::Triple::ArchType stringTo<llvm::Triple::ArchType>(llvm::StringRef Str) { in stringTo() 71 return llvm::StringSwitch<Triple::ArchType>(Str) in stringTo() 87 static T consume(llvm::StringRef &Str) { in consume() 89 std::tie(Token, Str) = getToken(Str); in consume() 40 stringTo(llvm::StringRef Str) stringTo() argument 58 stringTo(llvm::StringRef Str) stringTo() argument 68 stringTo(llvm::StringRef Str) stringTo() argument 86 consume(llvm::StringRef & Str) consume() argument 187 llvm::StringRef Str; parse() local 211 llvm::StringRef Str; parse() local 234 llvm::StringRef Str; parseNumberName() local 280 llvm::StringRef Str; parsePublicOrFunc() local 382 llvm::StringRef Str; parse() local 448 llvm::StringRef Str; parse() local 496 llvm::StringRef Str; parse() local [all...] |
/freebsd/contrib/llvm-project/llvm/lib/Frontend/OpenMP/ |
H A D | OMPContext.cpp | 62 #define OMP_TRAIT_PROPERTY(Enum, TraitSetEnum, TraitSelectorEnum, Str) \ in OMPContext() argument 64 if (TargetTriple.getArch() == TargetTriple.getArchTypeForLLVMName(Str)) \ in OMPContext() 66 if (StringRef(Str) == "x86_64" && \ in OMPContext() 379 #define OMP_TRAIT_SET(Enum, Str) .Case(Str, TraitSet::Enum) in getOpenMPContextTraitSetKind() argument 387 #define OMP_TRAIT_SELECTOR(Enum, TraitSetEnum, Str, ReqProp) \ in getOpenMPContextTraitSetForSelector() argument 397 #define OMP_TRAIT_PROPERTY(Enum, TraitSetEnum, TraitSelectorEnum, Str) \ in getOpenMPContextTraitSetForProperty() argument 406 #define OMP_TRAIT_SET(Enum, Str) \ in getOpenMPContextTraitSetName() argument 408 return Str; in getOpenMPContextTraitSetName() 416 #define OMP_TRAIT_SELECTOR(Enum, TraitSetEnum, Str, ReqProp) \ in getOpenMPContextTraitSelectorKind() argument 417 .Case(Str, TraitSelector::Enum) in getOpenMPContextTraitSelectorKind() [all …]
|
/freebsd/contrib/llvm-project/compiler-rt/lib/scudo/standalone/ |
H A D | timing.h | 152 ScopedString Str; in report() local 153 getAllImpl(Str); in report() 154 Str.output(); in report() 159 ScopedString Str; in printAll() local 160 getAll(Str); in printAll() 161 Str.output(); in printAll() 164 void getAll(ScopedString &Str) EXCLUDES(Mutex) { in getAll() argument 166 getAllImpl(Str); in getAll() 170 void getAllImpl(ScopedString &Str) REQUIRES(Mutex) { in getAllImpl() argument 174 Str.append("%-15s %-15s %-15s\n", AvgHeader, MaxHeader, NameHeader); in getAllImpl() [all …]
|
/freebsd/contrib/llvm-project/compiler-rt/lib/fuzzer/ |
H A D | FuzzerUtil.cpp | 81 bool ParseOneDictionaryEntry(const std::string &Str, Unit *U) { in ParseOneDictionaryEntry() argument 83 if (Str.empty()) return false; in ParseOneDictionaryEntry() 84 size_t L = 0, R = Str.size() - 1; // We are parsing the range [L,R]. in ParseOneDictionaryEntry() 86 while (L < R && isspace(Str[L])) L++; in ParseOneDictionaryEntry() 87 while (R > L && isspace(Str[R])) R--; in ParseOneDictionaryEntry() 90 if (Str[R] != '"') return false; in ParseOneDictionaryEntry() 93 while (L < R && Str[L] != '"') L++; in ParseOneDictionaryEntry() 95 assert(Str[L] == '\"'); in ParseOneDictionaryEntry() 99 uint8_t V = (uint8_t)Str[Pos]; in ParseOneDictionaryEntry() 103 if (Pos + 1 <= R && (Str[Pos + 1] == '\\' || Str[Pos + 1] == '"')) { in ParseOneDictionaryEntry() [all …]
|
/freebsd/contrib/diff/lib/ |
H A D | xstrtol.h | 58 # define _STRTOL_ERROR(Exit_code, Str, Argument_type_string, Err) \ argument 68 (Argument_type_string), (Str)); \ 74 (Argument_type_string), (Str)); \ 79 (Argument_type_string), (Str)); \ 85 # define STRTOL_FATAL_ERROR(Str, Argument_type_string, Err) \ argument 86 _STRTOL_ERROR (exit_failure, Str, Argument_type_string, Err) 88 # define STRTOL_FAIL_WARN(Str, Argument_type_string, Err) \ argument 89 _STRTOL_ERROR (0, Str, Argument_type_string, Err)
|
/freebsd/contrib/llvm-project/llvm/utils/TableGen/Common/ |
H A D | AsmWriterInst.h | 44 std::string Str; member 56 : OperandType(op), Str(LitStr) {} in OperandType() 61 : OperandType(op), MIOpNo(_MIOpNo), Str(Printer), MiModifier(Modifier), in OperandType() 65 if (OperandType != Other.OperandType || Str != Other.Str) 95 void AddLiteralString(const std::string &Str) { in AddLiteralString() argument 100 Operands.back().Str.append(Str); in AddLiteralString() 102 Operands.push_back(AsmWriterOperand(Str)); in AddLiteralString()
|
/freebsd/contrib/llvm-project/llvm/lib/TextAPI/ |
H A D | PackedVersion.cpp | 22 bool PackedVersion::parse32(StringRef Str) { in parse32() argument 25 if (Str.empty()) in parse32() 29 SplitString(Str, Parts, "."); in parse32() 56 std::pair<bool, bool> PackedVersion::parse64(StringRef Str) { in parse64() argument 60 if (Str.empty()) in parse64() 64 SplitString(Str, Parts, "."); in parse64() 104 SmallString<32> Str; in operator std::string() local 105 raw_svector_ostream OS(Str); in operator std::string() 107 return std::string(Str); in operator std::string()
|
/freebsd/contrib/llvm-project/llvm/lib/IR/ |
H A D | DiagnosticPrinter.cpp | 37 DiagnosticPrinter &DiagnosticPrinterRawOStream::operator<<(StringRef Str) { in operator <<() argument 38 Stream << Str; in operator <<() 42 DiagnosticPrinter &DiagnosticPrinterRawOStream::operator<<(const char *Str) { in operator <<() argument 43 Stream << Str; in operator <<() 48 const std::string &Str) { in operator <<() argument 49 Stream << Str; in operator <<() 93 DiagnosticPrinter &DiagnosticPrinterRawOStream::operator<<(const Twine &Str) { in operator <<() argument 94 Str.print(Stream); in operator <<()
|
/freebsd/contrib/llvm-project/llvm/include/llvm/ADT/ |
H A D | StringRef.h | 34 bool getAsUnsignedInteger(StringRef Str, unsigned Radix, 37 bool getAsSignedInteger(StringRef Str, unsigned Radix, long long &Result); 39 bool consumeUnsignedInteger(StringRef &Str, unsigned Radix, 41 bool consumeSignedInteger(StringRef &Str, unsigned Radix, long long &Result); 84 /*implicit*/ constexpr StringRef(const char *Str) in StringRef() argument 85 : Data(Str), Length(Str ? in StringRef() 88 __builtin_strlen(Str) in StringRef() 90 std::char_traits<char>::length(Str) in StringRef() 100 /*implicit*/ StringRef(const std::string &Str) in StringRef() argument 101 : Data(Str.data()), Length(Str.length()) {} in StringRef() [all …]
|
H A D | Twine.h | 273 /*implicit*/ Twine(const char *Str) { in Twine() 274 if (Str[0] != '\0') { in Twine() 275 LHS.cString = Str; in Twine() 287 /*implicit*/ Twine(const std::string &Str) : LHSKind(StdStringKind) { 288 LHS.stdString = &Str; 296 /*implicit*/ Twine(const std::string_view &Str) in Twine() 298 LHS.ptrAndLength.ptr = Str.data(); 299 LHS.ptrAndLength.length = Str.length(); 304 /*implicit*/ Twine(const StringRef &Str) : LHSKind(PtrAndLengthKind) { in Twine() 305 LHS.ptrAndLength.ptr = Str in Twine() 269 Twine(const char * Str) Twine() argument 283 Twine(const std::string & Str) Twine() argument 292 Twine(const std::string_view & Str) Twine() argument 300 Twine(const StringRef & Str) Twine() argument 307 Twine(const SmallVectorImpl<char> & Str) Twine() argument [all...] |
/freebsd/contrib/llvm-project/llvm/lib/DebugInfo/Symbolize/ |
H A D | MarkupFilter.cpp | 548 std::optional<uint64_t> MarkupFilter::parseAddr(StringRef Str) const { in parseAddr() 549 if (Str.empty()) { in parseAddr() 550 reportTypeError(Str, "address"); in parseAddr() 553 if (all_of(Str, [](char C) { return C == '0'; })) in parseAddr() 555 if (!Str.starts_with("0x")) { in parseAddr() 556 reportTypeError(Str, "address"); in parseAddr() 560 if (Str.drop_front(2).getAsInteger(16, Addr)) { in parseAddr() 561 reportTypeError(Str, "address"); in parseAddr() 568 std::optional<uint64_t> MarkupFilter::parseModuleID(StringRef Str) const { in parseModuleID() 570 if (Str in parseModuleID() 687 reportTypeError(StringRef Str,StringRef TypeName) const reportTypeError() argument [all...] |
/freebsd/contrib/llvm-project/llvm/include/llvm/MC/ |
H A D | MCAsmMacro.h | 70 StringRef Str; variable 76 AsmToken(TokenKind Kind, StringRef Str, APInt IntVal) in AsmToken() argument 77 : Kind(Kind), Str(Str), IntVal(std::move(IntVal)) {} in AsmToken() 78 AsmToken(TokenKind Kind, StringRef Str, int64_t IntVal = 0) 79 : Kind(Kind), Str(Str), IntVal(64, IntVal, true) {} in Kind() 92 return Str.slice(1, Str.size() - 1); in getStringContents() 110 StringRef getString() const { return Str; } in getString()
|
/freebsd/contrib/llvm-project/clang/include/clang/Basic/ |
H A D | TargetCXXABI.h | 32 #define CXXABI(Name, Str) Name, argument 44 #define CXXABI(Name, Str) {Str, Name}, in getABIMap() argument 52 #define CXXABI(Name, Str) {Name, Str}, in getSpellingMap() argument 124 #define CXXABI(Name, Str) in isItaniumFamily() argument 125 #define ITANIUM_CXXABI(Name, Str) case Name: in isItaniumFamily() argument 138 #define CXXABI(Name, Str) in isMicrosoft() argument 139 #define MICROSOFT_CXXABI(Name, Str) case Name: in isMicrosoft() argument
|
/freebsd/contrib/llvm-project/llvm/include/llvm/TableGen/ |
H A D | StringToOffsetTable.h | 31 unsigned GetOrAddStringOffset(StringRef Str, bool appendZero = true) { 33 StringOffset.insert(std::make_pair(Str, AggregateString.size())); 36 AggregateString.append(Str.begin(), Str.end()); 46 SmallString<256> Str; in EmitString() local 47 raw_svector_ostream(Str).write_escaped(AggregateString); in EmitString() 48 AggregateString = std::string(Str); in EmitString()
|
/freebsd/contrib/llvm-project/llvm/lib/Option/ |
H A D | OptTable.cpp | 161 static unsigned matchOption(const OptTable::Info *I, StringRef Str, in matchOption() argument 164 if (Str.starts_with(Prefix)) { in matchOption() 165 StringRef Rest = Str.substr(Prefix.size()); in matchOption() 350 StringRef Str(CStr); in parseOneArgGrouped() local 351 if (isInput(getPrefixesUnion(), Str)) in parseOneArgGrouped() 352 return std::make_unique<Arg>(getOption(InputOptionID), Str, Index++, CStr); in parseOneArgGrouped() 355 StringRef Name = Str.ltrim(PrefixChars); in parseOneArgGrouped() 363 unsigned ArgSize = matchOption(Start, Str, IgnoreCase); in parseOneArgGrouped() 386 if (Str[2] == '=') in parseOneArgGrouped() 387 return std::make_unique<Arg>(getOption(UnknownOptionID), Str, Index++, in parseOneArgGrouped() [all …]
|
/freebsd/contrib/llvm-project/clang/lib/Lex/ |
H A D | TokenConcatenation.cpp | 22 static bool IsStringPrefix(StringRef Str, bool CPlusPlus11) { in IsStringPrefix() argument 24 if (Str[0] == 'L' || in IsStringPrefix() 25 (CPlusPlus11 && (Str[0] == 'u' || Str[0] == 'U' || Str[0] == 'R'))) { in IsStringPrefix() 27 if (Str.size() == 1) in IsStringPrefix() 32 if (Str[1] == 'R' && Str[0] != 'R' && Str.size() == 2 && CPlusPlus11) in IsStringPrefix() 36 if (Str[0] == 'u' && Str[1] == '8') { in IsStringPrefix() 37 if (Str.size() == 2) return true; // "u8" in IsStringPrefix() 38 if (Str.size() == 3 && Str[2] == 'R') return true; // "u8R" in IsStringPrefix()
|
/freebsd/contrib/llvm-project/llvm/include/llvm/IR/ |
H A D | DiagnosticPrinter.h | 39 virtual DiagnosticPrinter &operator<<(StringRef Str) = 0; 40 virtual DiagnosticPrinter &operator<<(const char *Str) = 0; 41 virtual DiagnosticPrinter &operator<<(const std::string &Str) = 0; 50 virtual DiagnosticPrinter &operator<<(const Twine &Str) = 0; 72 DiagnosticPrinter &operator<<(StringRef Str) override; 73 DiagnosticPrinter &operator<<(const char *Str) override; 74 DiagnosticPrinter &operator<<(const std::string &Str) override; 83 DiagnosticPrinter &operator<<(const Twine &Str) override;
|
/freebsd/contrib/llvm-project/llvm/lib/Transforms/Utils/ |
H A D | AMDGPUEmitPrintf.cpp | 87 static Value *getStrlenWithNull(IRBuilder<> &Builder, Value *Str) { in getStrlenWithNull() argument 121 Builder.CreateICmpEQ(Str, Constant::getNullValue(Str->getType())); in getStrlenWithNull() 127 auto PtrPhi = Builder.CreatePHI(Str->getType(), 2); in getStrlenWithNull() 128 PtrPhi->addIncoming(Str, Prev); in getStrlenWithNull() 139 auto Begin = Builder.CreatePtrToInt(Str, Int64Ty); in getStrlenWithNull() 154 static Value *callAppendStringN(IRBuilder<> &Builder, Value *Desc, Value *Str, in callAppendStringN() argument 160 Desc->getType(), Str->getType(), in callAppendStringN() 162 return Builder.CreateCall(Fn, {Desc, Str, Length, IsLastInt32}); in callAppendStringN() 184 static void locateCStrings(SparseBitVector<8> &BV, StringRef Str) { in locateCStrings() argument 190 while ((SpecPos = Str.find_first_of('%', SpecPos)) != StringRef::npos) { in locateCStrings() [all …]
|
/freebsd/contrib/llvm-project/clang/lib/Basic/ |
H A D | OpenMPKinds.cpp | 23 unsigned clang::getOpenMPSimpleClauseType(OpenMPClauseKind Kind, StringRef Str, in getOpenMPSimpleClauseType() argument 27 return llvm::StringSwitch<unsigned>(Str) in getOpenMPSimpleClauseType() 32 return llvm::StringSwitch<unsigned>(Str) in getOpenMPSimpleClauseType() 37 return llvm::StringSwitch<unsigned>(Str) in getOpenMPSimpleClauseType() 45 unsigned Type = llvm::StringSwitch<unsigned>(Str) in getOpenMPSimpleClauseType() 54 return llvm::StringSwitch<OpenMPDoacrossClauseModifier>(Str) in getOpenMPSimpleClauseType() 59 return llvm::StringSwitch<OpenMPLinearClauseKind>(Str) in getOpenMPSimpleClauseType() 64 unsigned Type = llvm::StringSwitch<unsigned>(Str) in getOpenMPSimpleClauseType() 79 unsigned Type = llvm::StringSwitch<unsigned>(Str) in getOpenMPSimpleClauseType() 89 return llvm::StringSwitch<OpenMPDistScheduleClauseKind>(Str) in getOpenMPSimpleClauseType() [all …]
|
/freebsd/contrib/llvm-project/llvm/lib/Target/DirectX/ |
H A D | DXILShaderFlags.h | 31 #define SHADER_FEATURE_FLAG(FeatureBit, DxilModuleBit, FlagName, Str) \ argument 33 #define DXIL_MODULE_FLAG(DxilModuleBit, FlagName, Str) bool FlagName : 1; argument 36 #define SHADER_FEATURE_FLAG(FeatureBit, DxilModuleBit, FlagName, Str) \ argument 38 #define DXIL_MODULE_FLAG(DxilModuleBit, FlagName, Str) FlagName = false; argument 48 #define SHADER_FEATURE_FLAG(FeatureBit, DxilModuleBit, FlagName, Str) \ in uint64_t() argument 50 #define DXIL_MODULE_FLAG(DxilModuleBit, FlagName, Str) \ in uint64_t() argument 57 #define SHADER_FEATURE_FLAG(FeatureBit, DxilModuleBit, FlagName, Str) \ in getFeatureFlags() argument
|