-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
tools/memory-model: Add checktheselitmus.sh to run specified litmus t…
…ests This commit adds a checktheselitmus.sh script that runs the litmus tests specified on the command line. This is useful for verifying fixes to specific litmus tests. Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
- Loading branch information
Paul E. McKenney
committed
Mar 24, 2023
1 parent
a4deb29
commit df0f675
Showing
2 changed files
with
51 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
#!/bin/sh | ||
# SPDX-License-Identifier: GPL-2.0+ | ||
# | ||
# Invokes checklitmus.sh on its arguments to run the specified litmus | ||
# test and pass judgment on the results. | ||
# | ||
# Usage: | ||
# checktheselitmus.sh -- [ file1.litmus [ file2.litmus ... ] ] | ||
# | ||
# Run this in the directory containing the memory model, specifying the | ||
# pathname of the litmus test to check. The usual parseargs.sh arguments | ||
# can be specified prior to the "--". | ||
# | ||
# This script is intended for use with pathnames that start from the | ||
# tools/memory-model directory. If some of the pathnames instead start at | ||
# the root directory, they all must do so and the "--destdir /" parseargs.sh | ||
# argument must be specified prior to the "--". Alternatively, some other | ||
# "--destdir" argument can be supplied as long as the needed subdirectories | ||
# are populated. | ||
# | ||
# Copyright IBM Corporation, 2018 | ||
# | ||
# Author: Paul E. McKenney <paulmck@linux.ibm.com> | ||
|
||
. scripts/parseargs.sh | ||
|
||
ret=0 | ||
for i in "$@" | ||
do | ||
if scripts/checklitmus.sh $i | ||
then | ||
: | ||
else | ||
ret=1 | ||
fi | ||
done | ||
if test "$ret" -ne 0 | ||
then | ||
echo " ^^^ VERIFICATION MISMATCHES" 1>&2 | ||
else | ||
echo All litmus tests verified as was expected. 1>&2 | ||
fi | ||
exit $ret |