Bug 368416 - Add tc06_two_races_xml.exp output for ppc64.
Summary: Add tc06_two_races_xml.exp output for ppc64.
Status: CLOSED FIXED
Alias: None
Product: valgrind
Classification: Developer tools
Component: general (show other bugs)
Version: 3.12 SVN
Platform: Other Linux
: NOR normal
Target Milestone: ---
Assignee: Julian Seward
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-09-07 18:47 UTC by Carl Love
Modified: 2016-09-14 17:06 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments
Add tc06_two_races_xml.exp output for ppc64. (8.21 KB, patch)
2016-09-07 18:51 UTC, Carl Love
Details
updated and refactored patch (3.19 KB, patch)
2016-09-12 21:35 UTC, Will Schmidt
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Carl Love 2016-09-07 18:47:58 UTC
Add a tc06_two_races_xml exp output for ppc64.  This differs from the
existing .exp in that does not contain the pthread_create_WRK entry frame.

The non-xml version of this test passes because there is a filter that
eliminates the pthread_create_WRK entry from that output.  That was
introduced in r13983, which added a filter to scrub out
pthread_create_WRK from all of the outputs, and updated the .exp files
to match.

The additional exp file added here covers that same condition for the
xml version of this test.

I'll note that I did look at the code in and around pthread_create_WRK,
in conjunction with the debug and comments from r13983.  It looks like
the _WRK stack frame is being reused rather than stacked upon.  I suspect
some part of branch-and-relink-to-noredir is not behaving quite as expected.
That said, this rather simple update to the exp is sufficient and is not
hiding anything I think is critical...

Reproducible: Always
Comment 1 Carl Love 2016-09-07 18:51:49 UTC
Created attachment 100975 [details]
Add tc06_two_races_xml.exp output for ppc64.

The attached patch was submitted by Will Schmidt.  I have reviewed and tested the patch.  The patch fixes the helgrind/tests/tc06_two_races_xml test case on PPC64

I will post the patch to the developer's email list for additional review.
Comment 2 Philippe Waroquiers 2016-09-10 09:35:40 UTC
Adding a specific ppc64 file is for sure something that makes the test pass.
However, this means we have (almost) duplicated files to maintain.
Wouldn't it be possible to instead write a filter for the xml (similarly to the filter for
the text output) that removes the ..._WRK ?
If that is reasonably easy, the filter approach is preferrable to a duplicated exp file.
Comment 3 Will Schmidt 2016-09-12 21:35:43 UTC
Created attachment 101061 [details]
updated and refactored patch

Per feedback and commentary, this is a different approach to solving the problem...

Update and modify the filter_xml filter to strip out the troublesome frame. 
And a tweak to the same to suppress the blurb that typically indicates a frame has been skipped.
Appears to work OK across the systems I have access to.  (a mix of ppc64 and a couple x86 boxes).
Comment 4 Philippe Waroquiers 2016-09-13 19:56:23 UTC
(In reply to Will Schmidt from comment #3)
> Created attachment 101061 [details]
> updated and refactored patch
> 
> Per feedback and commentary, this is a different approach to solving the
> problem...
> 
> Update and modify the filter_xml filter to strip out the troublesome frame. 
> And a tweak to the same to suppress the blurb that typically indicates a
> frame has been skipped.
> Appears to work OK across the systems I have access to.  (a mix of ppc64 and
> a couple x86 boxes).

That looks good to me. Feel free to commit.
Thanks
Comment 5 Carl Love 2016-09-14 16:44:04 UTC
Patch from Will committed, commit 15956
Comment 6 Carl Love 2016-09-14 17:06:24 UTC
Verified patch commit is OK using fresh pull of the upstream repository.  It checks out fine.  Closing