Bug 334836 - PPC64 Little Endian support, patch 3 testcase fixes
Summary: PPC64 Little Endian support, patch 3 testcase fixes
Status: RESOLVED FIXED
Alias: None
Product: valgrind
Classification: Developer tools
Component: general (show other bugs)
Version: unspecified
Platform: unspecified Linux
: NOR normal
Target Milestone: ---
Assignee: Julian Seward
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-05-15 19:53 UTC by Carl Love
Modified: 2014-08-14 16:56 UTC (History)
3 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments
PPC LE testcase fixup patch (1.68 MB, patch)
2014-05-15 19:55 UTC, Carl Love
Details
Updated PPC LE testcase fixup patch (1.68 MB, patch)
2014-06-05 19:34 UTC, Carl Love
Details
Updated PPC64 LE support patch to address feedback from Mark Wielaard (1.68 MB, patch)
2014-07-21 20:36 UTC, Carl Love
Details
Updated PPC64 LE support patch (1.68 MB, patch)
2014-07-29 19:26 UTC, Carl Love
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Carl Love 2014-05-15 19:53:32 UTC
This is the third patch in the series.  It fixes up the testcases for PPC64 LE.  The patch is dependent on the first patch in bugzilla 334,384 followed by the second patch in bugzilla 334,834

Reproducible: Always
Comment 1 Carl Love 2014-05-15 19:55:08 UTC
Created attachment 86657 [details]
PPC LE testcase fixup patch
Comment 2 Carl Love 2014-05-15 19:57:30 UTC
Attached patch
Comment 3 Maynard Johnson 2014-05-15 21:24:48 UTC
acked.  I reviewed and tested this patch.
Comment 4 Carl Love 2014-06-05 19:34:59 UTC
Created attachment 87032 [details]
Updated PPC LE testcase fixup patch

Updated none/tests/ppc32/Makefile.am to inclue the file round.stdout.exp-RM-fix which was missing
Comment 5 Julian Seward 2014-06-09 09:03:43 UTC
See bug 334834 for initial comments about the patch sequence (that is,
bug 334384 (prelims), bug 334834 (implementation) and bug 334836 (test cases).
Comment 6 Julian Seward 2014-07-07 21:14:33 UTC
(In reply to comment #4)
> Created attachment 87032 [details]
> Updated PPC LE testcase fixup patch


memcheck/tests/atomic_incs.c
Why do the -le cases need their own code?  Aren't they the
same as the -be cases?


On the whole it would be nice if there was less duplication of output
files.  Especially for the integer/FP/Altivec non-memory instructions,
for which, presumably, the endianness is irrelevant.  How much effort
would it be to remove some of that duplication?
Comment 7 Julian Seward 2014-07-07 21:15:09 UTC
(forgot to say): but on the whole it looks OK.
Comment 8 Mark Wielaard 2014-07-19 00:25:14 UTC
After applying patch 1 and patch 2, this one doesn't apply completely cleanly.
- The none/tests/ppc32/ldst_multiple.c change was already done independently in current svn.
- The memcheck/tests/atomic_incs.c tests/Makefile.am tests/check_isa-2_06_cap tests/check_isa-2_07_cap tests/is_ppc64_BE.c tests/power_insn_available.c changes already came in the earlier 2 patches.

After applying all 3 patches there are still two places that use VGP_ppc64_linux.

- The ifunc_wrapper in coregrind/vg_preloaded.c which is new in svn. Should that use #if defined(VGP_ppc64be_linux) or is there a better way to determine when function descriptors are used?
- none/tests/ppc32/jm-insns.c got adds a #if defined(VGP_ppc64_linux) #elif defined(VGP_ppc64le_linux) pair. The first should be #if defined(VGP_ppc64be_linux)
Comment 9 Carl Love 2014-07-21 20:36:19 UTC
Created attachment 87866 [details]
Updated PPC64 LE support patch to address feedback from Mark Wielaard

Updated the patch to move the testsuite changes noted in Mark's comments, see bugzilla 33834 to this patch.
Comment 10 Carl Love 2014-07-21 20:47:06 UTC
On Sat, 2014-07-19 at 00:25 +0000, Mark Wielaard wrote:
> https://bugs.kde.org/show_bug.cgi?id=334836
> 
> --- Comment #8 from Mark Wielaard <mjw@redhat.com> ---
> After applying patch 1 and patch 2, this one doesn't apply completely cleanly.
> - The none/tests/ppc32/ldst_multiple.c change was already done independently in
> current svn.
> - The memcheck/tests/atomic_incs.c tests/Makefile.am tests/check_isa-2_06_cap
> tests/check_isa-2_07_cap tests/is_ppc64_BE.c tests/power_insn_available.c
> changes already came in the earlier 2 patches.
> 
> After applying all 3 patches there are still two places that use
> VGP_ppc64_linux.
> 
> - The ifunc_wrapper in coregrind/vg_preloaded.c which is new in svn. Should
> that use #if defined(VGP_ppc64be_linux) or is there a better way to determine
> when function descriptors are used?
> - none/tests/ppc32/jm-insns.c got adds a #if defined(VGP_ppc64_linux) #elif
> defined(VGP_ppc64le_linux) pair. The first should be #if
> defined(VGP_ppc64be_linux)
> 

Mark:

I updated the three patches in 

> https://bugs.kde.org/show_bug.cgi?id=334384     Patch 1
> 
> https://bugs.kde.org/show_bug.cgi?id=334834     Patch 2
> 
> https://bugs.kde.org/show_bug.cgi?id=334836     Patch 3

to address the comments you provided.  The patches were forward ported
to the latest code tree.  Please note, I have been working with Julian
on making the endianess a dynamic parameter rather then a #define.  The
patches will be updated again when this work is completed.  Thanks for
the feedback.

            Carl Love
Comment 11 Carl Love 2014-07-29 19:26:09 UTC
Created attachment 88019 [details]
Updated PPC64 LE support patch

The patch was updated to address the previous comments from Julian.
Comment 12 Carl Love 2014-08-07 23:50:11 UTC
Patch committed.  Valgrind commit 14240, no VEX commit.
Comment 13 Carl Love 2014-08-14 16:56:06 UTC
There are two copies of the round test in none/tests/ppc32/round.c
and none/tests/ppc64/round.c.  The two source files should be
identical. The LE functional test commit updated the round.c test for
ppc64 but was missing the ppc32 round updates.  The round.c test was
updated to fix an issue where we were getting different outputs
depending on the compiler.  The output is now consistent for the
compilers allowing the removal of the additional expect files for
ppc32 and ppc64.

The commit number is valgrind 14278.  No VEX commit was made.