[PATCH 0/2] litmus test updates

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



>From 955eefe8ad5a64fddd2e33b343ac3a1e171dd089 Mon Sep 17 00:00:00 2001
From: Akira Yokosawa <akiyks@xxxxxxxxx>
Date: Sun, 9 Jul 2017 09:53:28 +0900
Subject: [PATCH 0/2] litmus test updates

Hi Paul,

I thought that embedding kernel API definitions in each litmus test is
redundant. We can use #include instead. In this case, we need to
specify a -I option for gcc as the compilation is done in a temporally
directory. We can do so by using -ccopts option of litmus7.

Patch 1 does this change.

However, in native run on x86_64, I'm seeing a significant difference
in the resulting statistics.
Before the change, a typical result is:

    Test C-SB+o-o+o-o Allowed
    Histogram (4 states)
    54    *>0:r2=0; 1:r2=0;
    49999628:>0:r2=2; 1:r2=0;
    49999697:>0:r2=0; 1:r2=2;
    621   :>0:r2=2; 1:r2=2;
    Ok

After the change, the result is something like:

    Test C-SB+o-o+o-o Allowed
    Histogram (4 states)
    26    *>0:r2=0; 1:r2=0;
    49999782:>0:r2=2; 1:r2=0;
    49999818:>0:r2=0; 1:r2=2;
    374   :>0:r2=2; 1:r2=2;
    Ok

In cross compilation mode, the result is similar and consistent
with the native run after the change.
So I suspect litmus7's behavior of native run is affected by the
"-ccopts" option. Again, this might depend on the platform variation.

Patch 2 adds targets for cross compilation mode of litmus7.
Because we need to copy the custom header file "api.h" into the target
directory, I made the recipe to do so.

I stopped short of adding recipes to make an archive and scp it to
remote host and to do remote compilation and execution via ssh.
They can be added later.

On PPC, the result of C-SB+o-o+o-o.litmus looks interesting.
(Of course, you are familiar with PPC, but...)

    Test C-SB+o-o+o-o Allowed
    Histogram (4 states)
    988335*>0:r2=0; 1:r2=0;
    49516879:>0:r2=2; 1:r2=0;
    49494779:>0:r2=0; 1:r2=2;
    7     :>0:r2=2; 1:r2=2;
    Ok
    
    Witnesses
    Positive: 988335, Negative: 99011665
    Condition exists (1:r2=0 /\ 0:r2=0) is validated
    Hash=9bb70a6ed845b4be5f335c7eeb134f3f

Note that I've not tested the result of "cross-arm" target actually
builds and runs on ARM hosts.

How does this approach look like?

        Thanks, Akira
-- 
Akira Yokosawa (2):
  advsync: Use '#include "api.h"' in litmus tests
  advsync: Add cross compilation targets

 CodeSamples/advsync/herd/.gitignore                |  5 ++++
 CodeSamples/advsync/herd/C-SB+o-mb-o+o-mb-o.litmus |  4 +--
 CodeSamples/advsync/herd/C-SB+o-o+o-o.litmus       |  3 +-
 CodeSamples/advsync/herd/Makefile                  | 34 ++++++++++++++++++++--
 CodeSamples/advsync/herd/api.h                     |  8 +++++
 5 files changed, 47 insertions(+), 7 deletions(-)
 create mode 100644 CodeSamples/advsync/herd/api.h

-- 
2.7.4

--
To unsubscribe from this list: send the line "unsubscribe perfbook" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux