<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=windows-1250">
<style type="text/css" style="display:none;"> P {margin-top:0;margin-bottom:0;} </style>
</head>
<body dir="ltr">
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
I believe, Pat and Damian are talking about execution tests for Fortran intrinsics. While these are not testing the intermediate representations, these are unit-tests that only apply to Flang. And when we make changes to the compiler, it will be good to test
 (with check-flang) that they pass. I don't know what is the framework that is being chosen for running these tests, but for the trivial cases, we do not need CMake. There are already end-to-end tests running in the fir-dev branch. <a href="https://github.com/flang-compiler/f18-llvm-project/blob/fir-dev/flang/test/Lower/end-to-end-character-assignment.f90" id="LPlnk406809">https://github.com/flang-compiler/f18-llvm-project/blob/fir-dev/flang/test/Lower/end-to-end-character-assignment.f90</a></div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<br>
</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
--Kiran</div>
<div id="appendonsend"></div>
<hr style="display:inline-block;width:98%" tabindex="-1">
<div id="divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" style="font-size:11pt" color="#000000"><b>From:</b> flang-dev <flang-dev-bounces@lists.llvm.org> on behalf of Andrzej Warzynski via flang-dev <flang-dev@lists.llvm.org><br>
<b>Sent:</b> 21 July 2021 09:35<br>
<b>To:</b> McCormick, Pat <pat@lanl.gov>; Damian Rouson <rouson@lbl.gov><br>
<b>Cc:</b> via flang-dev <flang-dev@lists.llvm.org><br>
<b>Subject:</b> Re: [flang-dev] [EXTERNAL] flang test questions</font>
<div> </div>
</div>
<div class="BodyFragment"><font size="2"><span style="font-size:11pt;">
<div class="PlainText">I agree with Pat. For me, anything that tests one of Flang's internal
<br>
representations (parse-tree, FIR, LLVM IR) or the generated diagnostics, <br>
belongs somewhere within flang/test (i.e. with other regression tests). <br>
I always run all of them (ninja check-flang) when developing a patch. I <br>
rarely use the test-suite. Not sure about the others. Btw, LLVM's <br>
test-suite requires CMake support, which we don't have. But perhaps I'm <br>
missing something here!<br>
<br>
As for the actual location for new tests, I've just submitted a patch to <br>
move all of regression tests for lowering the intrinsics into <br>
f18-llvm-project/flang/test/Lower/intrinsic-procedures [1]. These tests <br>
only look at FIR. We may want a different directory for LLVM IR. It <br>
would be very nice to keep all tests for intrinsics in sync :)<br>
<br>
Thanks for working on this!<br>
<br>
-Andrzej<br>
<br>
[1] <a href="https://github.com/flang-compiler/f18-llvm-project/pull/927/">https://github.com/flang-compiler/f18-llvm-project/pull/927/</a><br>
<br>
On 20/07/2021 16:17, McCormick, Pat via flang-dev wrote:<br>
> Hi Damian,<br>
> <br>
> For a bit broader visibility…<br>
> <br>
> We recently added a (temporary?) directory for intrinsic tests under <br>
> "flang/test/Intrinsics” but we still need to decide how to best <br>
> integrate it into the testing infrastructure.  For now, my vote would be <br>
> that it is OK to land your tests there and we can then decide where <br>
> these tests should live in the long run.  Personally, I think the <br>
> intrinsic specific details (both lowering and “correctness") make a bit <br>
> more sense as part flang's testing vs. rolling them all the way up to <br>
> the llvm  level.  But that’s just my take — others should chime in if <br>
> there is a better path…<br>
> <br>
> —Pat<br>
> <br>
> <br>
> <br>
>> On Jul 20, 2021, at 2:02 AM, Damian Rouson via flang-dev <br>
>> <flang-dev@lists.llvm.org <<a href="mailto:flang-dev@lists.llvm.org">mailto:flang-dev@lists.llvm.org</a>>> wrote:<br>
>><br>
>><br>
>><br>
>> On Mon, Jul 19, 2021 at 11:30 PM Kiran Chandramohan <br>
>> <Kiran.Chandramohan@arm.com <<a href="mailto:Kiran.Chandramohan@arm.com">mailto:Kiran.Chandramohan@arm.com</a>>> wrote:<br>
>><br>
>><br>
>>     >>Am Di., 13. Juli 2021 um 14:59 Uhr schrieb Damian Rouson via flang-dev<br>
>>     >><flang-dev@lists.llvm.org <<a href="mailto:flang-dev@lists.llvm.org">mailto:flang-dev@lists.llvm.org</a>>>:<br>
>>     >>> I'm getting started with writing tests for flang and have a few questions. First, would you recommend contributing tests to the llvm-test-suite repository at
<a href="https://github.com/llvm/llvm-test-suite?">https://github.com/llvm/llvm-test-suite?</a><br>
>>     <<a href="https://github.com/llvm/llvm-test-suite?">https://github.com/llvm/llvm-test-suite?</a>><br>
>><br>
>>     > Yes, I think the llvm-test-suite should feature more Fortran tests.<br>
>>     > See the documentation at [1] and [2] as an example for how tests are<br>
>>     > added. For instance, NASA Advanced Supercomputing Parallel Benchmarks<br>
>>     > [3] could be added.<br>
>><br>
>>     If these are tests for Fortran intrinsics then wouldn't the better<br>
>>     place be somewhere in the flang directory? Like in unit-tests or<br>
>>     something?<br>
>><br>
>><br>
>> After some discussion offline, I decided to put the tests in the LLVM <br>
>> repository -- presumably the flang directory -- instead of in <br>
>> llvm-test-suite.<br>
>><br>
>> Damian<br>
>> _______________________________________________<br>
>> flang-dev mailing list<br>
>> flang-dev@lists.llvm.org <<a href="mailto:flang-dev@lists.llvm.org">mailto:flang-dev@lists.llvm.org</a>><br>
>> <a href="https://lists.llvm.org/cgi-bin/mailman/listinfo/flang-dev">https://lists.llvm.org/cgi-bin/mailman/listinfo/flang-dev</a>
<br>
>> <<a href="https://lists.llvm.org/cgi-bin/mailman/listinfo/flang-dev">https://lists.llvm.org/cgi-bin/mailman/listinfo/flang-dev</a>><br>
> <br>
> <br>
> _______________________________________________<br>
> flang-dev mailing list<br>
> flang-dev@lists.llvm.org<br>
> <a href="https://lists.llvm.org/cgi-bin/mailman/listinfo/flang-dev">https://lists.llvm.org/cgi-bin/mailman/listinfo/flang-dev</a><br>
> <br>
_______________________________________________<br>
flang-dev mailing list<br>
flang-dev@lists.llvm.org<br>
<a href="https://lists.llvm.org/cgi-bin/mailman/listinfo/flang-dev">https://lists.llvm.org/cgi-bin/mailman/listinfo/flang-dev</a><br>
</div>
</span></font></div>
</body>
</html>