banach-space wrote:

> A downside to this is that it also hides information on the RUN line that can 
> be important to folks reproducing tests on a command line, 

That's a very good point, thanks for raising it! However, even today the `RUN` 
lines are not sufficient to reproduce failures. For example (taken from one of 
the tests in this PR):
```
%clang_cc1 -triple arm64-none-linux-gnu -target-feature +fullfp16 
-disable-O0-optnone           -emit-llvm -o - %s
```

expands to (note `-internal-isystem <path>`):
```
  clang -cc1 -internal-isystem <path> -nostdsysteminc -triple 
arm64-none-linux-gnu -target-feature +neon -disable-O0-optnone  
-flax-vector-conversions=none
```

On my system, `<path>` expands to:
* `/home/andwar02/work/llvm-project/build/cir-release/lib/clang/23/include`.

That is something that I need `lit -v` to generate for me (as in, I don't copy 
`RUN` files from files, instead, I let `lit` generate one for me). 

That said, while the flow for reproducing bugs won't change, you are right that 
the flags will be somewhat obfuscated (though quite easily discoverable in the 
LIT config file). 

> it doesn't scale to other common patterns we use in the project.

True, this is only intended for code-gen for AArch64 (it would quite easy to 
generate one for other targets though). However, with ~700 test files, wouldn't 
it be desirable to have something "standard" and consistent? Just for 
reference, I also discussed that  in 
https://github.com/llvm/llvm-project/issues/179952.  

> How often do we have inconsistency that matters?

It's hard to tell and to me that is precisely down to lack of consistency (i.e. 
it is hard to compare two `RUN` lines, let alone identify meaningful 
differences). As a specific example, I have recently identified duplicate test 
files:
* https://github.com/llvm/llvm-project/pull/186084/

The `RUN` lines were actually quite different, but those differences weren't 
significant/meaningful. That was not that obvious and I probably wouldn't 
realise without the ClangIR effort for which we are using the original tests. 
More standardised `RUN` lines would help.

Thanks!

https://github.com/llvm/llvm-project/pull/188547
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to