[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Separating stdout and stderr
From: |
Maxim Kuvyrkov |
Subject: |
Re: Separating stdout and stderr |
Date: |
Wed, 30 Mar 2016 16:44:29 +0300 |
Hi Ben,
Hi Christophe,
[TL;DR] Will it be a problem for dejagnu to merge test's stderr into stderr
with an equivalent of bash's 2>&1 ?
From my investigations of the sanitizer testsuite, it seems to be hitting
several unrelated issues in DejaGnu. Ben's patch is addressing one of those,
but there is at least one other issue that also related to handling of stdout
and stderr.
The sanitizer testsuite is maintained as part of LLVM project, and it is using
a different testing framework. In the LLVM copy of the sanitizer testsuite
every testcase has an annotation to call itself with stderr merged into stdout
via 2>&1 shell syntax. This is done [at least in part] to avoid races between
output to stdout and stderr streams. [Note that tests tend to print using
printf, while sanitizer libraries print to stderr with fprintf.]
Dejagnu, on the other hand, seems to be giving the test process separate stdout
and stderr streams, and then merges the output from the two internally. This
causes non-determinism in output due to races in how kernel flushes the two
streams.
I understand that this is, primarily, an issue with the test itself, and,
indeed, it can be avoided by the test using exclusively stderr or exclusively
stdout, but I don't think any dejagnu testsuite is relying on separate stdout
and stderr. So maybe we should just merge the two?
--
Maxim Kuvyrkov
www.linaro.org
> On Mar 30, 2016, at 11:47 AM, Ben Elliston <address@hidden> wrote:
>
> On Wed, Mar 30, 2016 at 10:15:46AM +0200, Christophe Lyon wrote:
>
>> Well, I re-ran it, and I still have no evidence of using standard_wait.
>> Are you running native validations?
>
> Yes.
>
>> I remind you that we are using a cross-testing configuration, so we might be
>> using a different code path than the one you are looking at.
>
> Oh, I see. Sorry.
>
>> As I said earlier, I'm looking at local_exec in remote.exp and it
>> does contain a code fragment similar to the one you've just
>> patched. Does it need the same change?
>
> Yes, probably. Can you give it a try?
>
> Cheers, Ben
> _______________________________________________
> DejaGnu mailing list
> address@hidden
> https://lists.gnu.org/mailman/listinfo/dejagnu
signature.asc
Description: Message signed with OpenPGP using GPGMail
- Re: Separating stdout and stderr, (continued)
- Re: Separating stdout and stderr, Christophe Lyon, 2016/03/25
- Re: Separating stdout and stderr, Rob Savoye, 2016/03/25
- Re: Separating stdout and stderr, Christophe Lyon, 2016/03/25
- Re: Separating stdout and stderr, Ben Elliston, 2016/03/25
- Re: Separating stdout and stderr, Christophe Lyon, 2016/03/26
- Re: Separating stdout and stderr, Ben Elliston, 2016/03/26
- Re: Separating stdout and stderr, Christophe Lyon, 2016/03/29
- Re: Separating stdout and stderr, Ben Elliston, 2016/03/29
- Re: Separating stdout and stderr, Christophe Lyon, 2016/03/30
- Re: Separating stdout and stderr, Ben Elliston, 2016/03/30
- Re: Separating stdout and stderr,
Maxim Kuvyrkov <=
- Re: Separating stdout and stderr, Christophe Lyon, 2016/03/30
- Re: Separating stdout and stderr, Maxim Kuvyrkov, 2016/03/31
- Re: Separating stdout and stderr, Christophe Lyon, 2016/03/31
- Re: Separating stdout and stderr, Ben Elliston, 2016/03/31
- Re: Separating stdout and stderr, Christophe Lyon, 2016/03/31
- Re: Separating stdout and stderr, Ben Elliston, 2016/03/31
- Re: Separating stdout and stderr, Christophe Lyon, 2016/03/31
- Re: Separating stdout and stderr, Christophe Lyon, 2016/03/31