I have done my best to follow the directions, but in all of my trials, the results are essentially the same, as the one I showed previously.
My most recent trial appears as follows:
$ python3 /usr/lib/llvm-20/build/utils/lit/lit.py -sv --param package-path=/usr/local/lib/swift --param llvm-bin-dir=./usr/lib/llvm-20/bin/ .
lit.py: /home/user/swift-integration-tests/lit.cfg:120: note: 'pexpect' module unavailable, skipping related tests
lit.py: /home/user/swift-integration-tests/lit.cfg:139: note: testing package: '/usr/local/lib/swift'
lit.py: /home/user/swift-integration-tests/lit.cfg:152: note: testing using 'FileCheck': './usr/lib/llvm-20/bin/FileCheck'
lit.py: /home/user/swift-integration-tests/lit.cfg:153: note: testing using 'readelf': './usr/lib/llvm-20/bin/llvm-readelf'
lit.py: /home/user/swift-integration-tests/lit.cfg:154: note: testing using 'readobj': './usr/lib/llvm-20/bin/llvm-readobj'
lit.py: /home/user/swift-integration-tests/lit.cfg:180: note: Failed to find swift benchmarks, skipping related tests.
lit.py: /home/user/swift-integration-tests/lit.cfg:187: note: testing using 'swift': '/usr/local/lib/swift/usr/bin/swift'
lit.py: /home/user/swift-integration-tests/lit.cfg:192: note: testing using 'swiftc': '/usr/local/lib/swift/usr/bin/swiftc'
lit.py: /home/user/swift-integration-tests/lit.cfg:201: note: testing using 'repl_swift': /usr/local/lib/swift/usr/bin/repl_swift
lit.py: /home/user/swift-integration-tests/lit.cfg:210: note: testing using 'docc': /usr/local/lib/swift/usr/bin/docc
lit.py: /home/user/swift-integration-tests/lit.cfg:215: note: testing using 'wasmkit': /usr/local/lib/swift/usr/bin/wasmkit
lit.py: /home/user/swift-integration-tests/lit.cfg:219: fatal: swift does not exist!
For this case, I installed LLVM tools for my distribution. My distribution is based on Ubuntu 24.04, and the package I selected is llvm-20-tools.
Several matters seem relevant.
First, LLVM tools are packaged with a major semantic version in the package name, in contrast to the more typical case of a package being named for the project in general, with the package manager handling upgrades based on metadata that distinguishes the different versions of the same package.
Second, the files provided by the package are placed in separate paths depending on the version.
Combined, the two observations suggest that backward compatibility is not provided among the various versions, and that therefore, the one selected must be exactly equal to a particular compatible version, for a particular use, or must occur within an acceptable range of particular versions.
I have no guidance, however, for which version is appropriate, and the matter is further complicated by older versions of the tools not being packaged for newer versions of the distribution. For example, based on my best understanding, the recommendation you offered, llvm-12-tools is available for Ubuntu 20.04 (jammy), but not 22.04 (noble), the prior obsolete by being four years old, against the two-year cycle used in Ubuntu for LTS.
Regardless, the output from the trial leaves me with little sense of the cause of the failure. I appreciate assistance understanding the various issues, and finding a path to proceed.