[Clang] Invoke pass plugin preCodeGenCallback
Single-use AddEmitPasses is inlined into RunCodegenPipeline for clarity
in comparing the parameters to the plugin and the parameters passed to
addPassesToEmitFile.
Pull Request: https://github.com/llvm/llvm-project/pull/171872
[lldb-dap] refactor monitor thread in tests (#172879)
This patch fixes a timeout in the monitor thread of the
`test_by_name_waitFor` test.
Currently, if `self.attach` fails, the `spawn_thread` will never finish
and the test will eventually timeout after the 15mins timeout. We now
ensure that we always join the thread at the end of the test.
Additionally, this change also uses of the `spawnSubprocess` method to
create the process. This should ensure the process is always properly
cleaned up after an exception occurs.
[lldb][ObjC][NFC] Use llvm::StringRef::consume_front(char) where possible (#173012)
Now that the `llvm::StringRef::consume_front(char)` exists, lets use it
to replace the `consumeChar` helper.
Drive-by:
* Also use the overload where we previously had to pass a single
character as a string literal.
[libc++] Refactor std::equal to forward to the 3-leg overload if the size of the ranges is known (#171585)
This allows us to merge some optimizations common between the 3-leg
overload and the two ranges overload.
In some cases this could also improve performance, since we avoid
checking one of the iterators if the size if the ranges is known. I
haven't been able to show any improvements though.
This is also a prerequisite for optimizing `std::search`.
[libc++] Update locale.cpp to use some newer C++ features (#173286)
`locale.cpp` has been written a long time ago and has implemented a few
things again that have only been added in newer C++ versions. This
replaces the custom implementations with standard ones.