[PATCH] D139274: Store OptTable::Info::Name as a StringRef

2022-12-06 Thread Douglas Yung via Phabricator via cfe-commits
dyung added a comment. @serge-sans-paille Your change is causing 24 test failures on the Linux PS4 bot, mostly with an assertion failure it seems. Can you take a look? https://lab.llvm.org/buildbot/#/builders/139/builds/32263 Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION h

[PATCH] D139274: Store OptTable::Info::Name as a StringRef

2022-12-06 Thread serge via Phabricator via cfe-commits
serge-sans-paille added a comment. In D139274#3974176 , @thakis wrote: > Reverted in de4b6a1bc64db33643f001ad45fae7b92b4a4688 > for > now. (Note that there was a follow-up fix in > e

[PATCH] D139274: Store OptTable::Info::Name as a StringRef

2022-12-06 Thread Nico Weber via Phabricator via cfe-commits
thakis added a comment. Reverted in de4b6a1bc64db33643f001ad45fae7b92b4a4688 for now. (Note that there was a follow-up fix in e50a60d7349de151bd2b06d85a79201ebc372d8a

[PATCH] D139274: Store OptTable::Info::Name as a StringRef

2022-12-06 Thread Nico Weber via Phabricator via cfe-commits
thakis added a comment. This breaks building lldb: http://45.33.8.238/linux/93366/step_4.txt Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D139274/new/ https://reviews.llvm.org/D139274 ___ cfe-commits mai

[PATCH] D139274: Store OptTable::Info::Name as a StringRef

2022-12-06 Thread serge via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG8ae18303f97d: Store OptTable::Info::Name as a StringRef (authored by serge-sans-paille). Changed prior to commit: https://reviews.llvm.org/D139274

[PATCH] D139274: Store OptTable::Info::Name as a StringRef

2022-12-06 Thread Nikita Popov via Phabricator via cfe-commits
nikic accepted this revision. nikic added a comment. This revision is now accepted and ready to land. LG Comment at: llvm/lib/Option/OptTable.cpp:41 + size_t MinSize = std::min(A.size(), B.size()); + if (int res = A.substr(0, MinSize).compare_insensitive(B.substr(0, MinSize))

[PATCH] D139274: Store OptTable::Info::Name as a StringRef

2022-12-06 Thread serge via Phabricator via cfe-commits
serge-sans-paille updated this revision to Diff 480421. serge-sans-paille added a comment. Also simplify `StrCmpOptionNameIgnoreCase` implementation thanks to the move to StringRef CHANGES SINCE LAST ACTION https://reviews.llvm.org/D139274/new/ https://reviews.llvm.org/D139274 Files: clan

[PATCH] D139274: Store OptTable::Info::Name as a StringRef

2022-12-06 Thread Nikita Popov via Phabricator via cfe-commits
nikic added inline comments. Comment at: llvm/lib/Option/OptTable.cpp:44 if (a == '\0') return 0; The code in this function (and also StrCmpOptionName) depends on the terminating null byte, while a StringRef is not guaranteed to by directly follow

[PATCH] D139274: Store OptTable::Info::Name as a StringRef

2022-12-06 Thread serge via Phabricator via cfe-commits
serge-sans-paille updated this revision to Diff 480363. serge-sans-paille added a comment. fix test / compile errors CHANGES SINCE LAST ACTION https://reviews.llvm.org/D139274/new/ https://reviews.llvm.org/D139274 Files: clang/lib/Driver/ToolChains/Gnu.cpp llvm/include/llvm/Option/OptTab

[PATCH] D139274: Store OptTable::Info::Name as a StringRef

2022-12-05 Thread Nikita Popov via Phabricator via cfe-commits
nikic added a comment. Build failure in pre-merge checks: FAILED: lib/Option/CMakeFiles/LLVMOption.dir/OptTable.cpp.o CCACHE_CPP2=yes CCACHE_HASHDIR=yes /usr/bin/ccache /usr/bin/clang++ -DBUILD_EXAMPLES -DGTEST_HAS_RTTI=0 -D_DEBUG -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACRO

[PATCH] D139274: Store OptTable::Info::Name as a StringRef

2022-12-04 Thread serge via Phabricator via cfe-commits
serge-sans-paille created this revision. serge-sans-paille added reviewers: thakis, aaron.ballman, nikic. Herald added a subscriber: hiraditya. Herald added a project: All. serge-sans-paille requested review of this revision. Herald added subscribers: llvm-commits, cfe-commits, MaskRay. Herald adde