[lit] Read command stdout/stderr as text on Windows
authorMartin Storsjö <martin@martin.st>
Sat, 26 Feb 2022 22:16:24 +0000 (00:16 +0200)
committerMartin Storsjö <martin@martin.st>
Tue, 1 Mar 2022 12:24:02 +0000 (14:24 +0200)
commit640e45b9b2205ba18a4a562a9404418d8b90abda
tree9ac913b160ebf907a97e1bba9f96f0e245280d11
parent33830326aadb928e304942015b63d5ed38073211
[lit] Read command stdout/stderr as text on Windows

This takes care of normalizing newlines back to single LF instead
of CRLF.

This on itself breaks on a couple tests that accidentally seem to
be writing binary data to stdout; make sure those cases are piped
to /dev/null instead of actually written to a terminal.

Differential Revision: https://reviews.llvm.org/D120623
libcxx/test/libcxx/selftest/dsl/dsl.sh.py
llvm/test/MC/ELF/diff2.s
llvm/test/MC/Mips/relocation-xfail.s
llvm/test/Other/cfg-printer-branch-weights-percent.ll
llvm/test/Other/cfg-printer-branch-weights.ll
llvm/test/Other/cfg-printer-filter.ll
llvm/test/Other/cfg_deopt_unreach.ll
llvm/utils/lit/lit/TestRunner.py