[Lldb-commits] [PATCH] D88840: [dotest] Simplify logic to find the Python path

Jonas Devlieghere via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Tue Oct 6 10:46:00 PDT 2020


JDevlieghere added a comment.

In D88840#2314594 <https://reviews.llvm.org/D88840#2314594>, @labath wrote:

> In D88840#2314587 <https://reviews.llvm.org/D88840#2314587>, @rupprecht wrote:
>
>> In D88840#2313331 <https://reviews.llvm.org/D88840#2313331>, @kastiglione wrote:
>>
>>> About `-P`, the man page for `lldb` and the driver's `Options.td` say it:
>>>
>>>> Prints out the path to the lldb.py file for this version of lldb.
>>>
>>> Should it do just that? If so this can be simplified further.
>>
>> It can print the path, or it can print `<COULD NOT FIND PATH>` if e.g. lldb wasn't built with python support or has some non-standard python setup. So I think this is basically as simple as the parsing can get.
>
> One way this could be simplified further is to ditch `-P` and pass down the appropriate value from cmake/lit.

LLDB in Xcode supports both Python 2 and 3 and we use a default `com.apple.dt.lldb DefaultPythonVersion` to override the version. By using `-P` here we can run the test suite with both versions by just changing the value of the default without having to reconfigure CMake. I'm not saying we should not do this because our donwstream fork, just that it would complicate things for us.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D88840/new/

https://reviews.llvm.org/D88840



More information about the lldb-commits mailing list