[patch] Use "set -o pipefail"

Stephen Lin swlin at post.harvard.edu
Thu Jul 4 12:47:06 PDT 2013


> It is for the clang crash recovery tests. We force clang to crash and
> check that the driver collects the crash recovery info. Right now that
> works because we don't use pipefail. With pipefail we have to be able
> to write something like
>
> not clang %s | FileCheck
>
> and have "not clang %s" pass when clang crashes as intended.

It seems somewhat dangerous, though, since a test that is meant to
exit with a non-zero status could start crashing instead without
causing any test failures (depending on what other checks were in the
pipeline).

Maybe this should be another utility instead? It could even be the
same binary but symlinked and have the behavior depend on the name...

Stephen



More information about the llvm-commits mailing list