Received: by 2002:ac0:bc90:0:0:0:0:0 with SMTP id a16csp4765314img; Tue, 26 Mar 2019 16:45:06 -0700 (PDT) X-Google-Smtp-Source: APXvYqzqC1xt4gcLPpgk82UjVoTirDaYFySsgJm1fhZ6eqlmePJGWON0SBPjOwj/HbaajsRSJ++A X-Received: by 2002:a63:4b0a:: with SMTP id y10mr31288284pga.66.1553643906231; Tue, 26 Mar 2019 16:45:06 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1553643906; cv=none; d=google.com; s=arc-20160816; b=qLZKyqcKWuo/5V4IvzDTLNx1jfa2bUY9cXouqhTBWb89DB3DFvyLApdOuncrtwusmM rVKbc62NBD/B18Hdr5PadiYwhGw1YxbZEvAMtlN3PfbKURhxsZdU8dZmeHCybGA5nqBJ NFtPT7V4+nFp3hQryw7PjZOS5EpaQhaVERJwD4vJFX8k1twKgMb2KqnArHfeqiWsIoFE Jf+Orwzyt6Nzb475teFrsBQIBDssFDGfpzA9bod3bPAvAqA9UieBd5UDADyp/PqZ8hNv CMCMMGY6hUuT1lU5IPNgUYMDv3uM/KVmjiO2Q7PXEzPGKjY1aoiBug00wged3UJ/NynD 0YQg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:references:in-reply-to:date :subject:cc:to:from; bh=t9/4zZt5HElXEFfeizkv/mdOjltZ3uo2kB9s1Tt8xOU=; b=qD3Pz47c3Tg8weEDOi+h0eTu1Siyu94jKNZ2h6BkuzDU9qO2zlTZEER4CGh5B83Ees ViRQS05tjV3+OwTjJYR/WKhf4EI03w0LiKTGftuXFz9sEDTypyidAupDDu4FJLxCmkMb p5fUa5kTMeyj6n7+JZENMfLhNBNGF7Yg9JHGPCunV0Fqeuqg9+cYalXWey2RcRjmRc+N U0GS8hhBFxl033A3MSZfe1BbNZSjGXqvr5mN4HZ3o6nUAoEFLoj+Pu9ndscEJ1HojTta /JdlKTDZ86tEqm9H4i7191n9yr9TQujNEOR9v27NijvqYAMxceBn5y9SXR/SMP1Bua48 dE3A== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=ibm.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 76si14475922pge.555.2019.03.26.16.44.51; Tue, 26 Mar 2019 16:45:06 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=ibm.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1732984AbfCZXmY (ORCPT + 99 others); Tue, 26 Mar 2019 19:42:24 -0400 Received: from mx0a-001b2d01.pphosted.com ([148.163.156.1]:57748 "EHLO mx0a-001b2d01.pphosted.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1732983AbfCZXln (ORCPT ); Tue, 26 Mar 2019 19:41:43 -0400 Received: from pps.filterd (m0098394.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.0.27/8.16.0.27) with SMTP id x2QNXdbL027910 for ; Tue, 26 Mar 2019 19:41:42 -0400 Received: from e14.ny.us.ibm.com (e14.ny.us.ibm.com [129.33.205.204]) by mx0a-001b2d01.pphosted.com with ESMTP id 2rfst61n3n-1 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=NOT) for ; Tue, 26 Mar 2019 19:41:41 -0400 Received: from localhost by e14.ny.us.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Tue, 26 Mar 2019 23:41:40 -0000 Received: from b01cxnp23033.gho.pok.ibm.com (9.57.198.28) by e14.ny.us.ibm.com (146.89.104.201) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; (version=TLSv1/SSLv3 cipher=AES256-GCM-SHA384 bits=256/256) Tue, 26 Mar 2019 23:41:36 -0000 Received: from b01ledav003.gho.pok.ibm.com (b01ledav003.gho.pok.ibm.com [9.57.199.108]) by b01cxnp23033.gho.pok.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id x2QNfZmb16711828 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Tue, 26 Mar 2019 23:41:35 GMT Received: from b01ledav003.gho.pok.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id EEA6AB206A; Tue, 26 Mar 2019 23:41:34 +0000 (GMT) Received: from b01ledav003.gho.pok.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id CDB3BB2074; Tue, 26 Mar 2019 23:41:34 +0000 (GMT) Received: from paulmck-ThinkPad-W541 (unknown [9.70.82.188]) by b01ledav003.gho.pok.ibm.com (Postfix) with ESMTP; Tue, 26 Mar 2019 23:41:34 +0000 (GMT) Received: by paulmck-ThinkPad-W541 (Postfix, from userid 1000) id B70D216C613D; Tue, 26 Mar 2019 16:41:35 -0700 (PDT) From: "Paul E. McKenney" To: linux-kernel@vger.kernel.org, linux-arch@vger.kernel.org, mingo@kernel.org Cc: stern@rowland.harvard.edu, andrea.parri@amarulasolutions.com, will.deacon@arm.com, peterz@infradead.org, boqun.feng@gmail.com, npiggin@gmail.com, dhowells@redhat.com, j.alglave@ucl.ac.uk, luc.maranget@inria.fr, akiyks@gmail.com, "Paul E. McKenney" Subject: [PATCH tip/core/rcu 15/21] tools/memory-model: Make judgelitmus.sh ransack .litmus.out files Date: Tue, 26 Mar 2019 16:41:27 -0700 X-Mailer: git-send-email 2.17.1 In-Reply-To: <20190326234114.GA23843@linux.ibm.com> References: <20190326234114.GA23843@linux.ibm.com> X-TM-AS-GCONF: 00 x-cbid: 19032623-0052-0000-0000-000003A18930 X-IBM-SpamModules-Scores: X-IBM-SpamModules-Versions: BY=3.00010820; HX=3.00000242; KW=3.00000007; PH=3.00000004; SC=3.00000282; SDB=6.01180142; UDB=6.00617578; IPR=6.00960857; MB=3.00026170; MTD=3.00000008; XFM=3.00000015; UTC=2019-03-26 23:41:39 X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 19032623-0053-0000-0000-00006048E403 Message-Id: <20190326234133.24962-15-paulmck@linux.ibm.com> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:,, definitions=2019-03-26_15:,, signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 priorityscore=1501 malwarescore=0 suspectscore=0 phishscore=0 bulkscore=0 spamscore=0 clxscore=1015 lowpriorityscore=0 mlxscore=0 impostorscore=0 mlxlogscore=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1810050000 definitions=main-1903260159 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The judgelitmus.sh script currently relies solely on the "Result:" comment in the .litmus file. This is problematic when using the --hw argument, because it is necessary to check the hardware model against LKMM even in the absence of "Result:" comments. This commit therefore modifies judgelitmus.sh to check the observation in a .litmus.out file, in case one was generated by a previous LKMM run. Signed-off-by: Paul E. McKenney --- tools/memory-model/scripts/judgelitmus.sh | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/tools/memory-model/scripts/judgelitmus.sh b/tools/memory-model/scripts/judgelitmus.sh index a5a865620f14..a1313f9960c3 100755 --- a/tools/memory-model/scripts/judgelitmus.sh +++ b/tools/memory-model/scripts/judgelitmus.sh @@ -8,7 +8,9 @@ # is provided, this is assumed to be a hardware test, and the output is # assumed to be in file.HW.litmus.out, where "HW" is the --hw argument. # In addition, non-Sometimes verification results will be noted, but -# forgiven. +# forgiven. Furthermore, if there is no "Result:" comment but there is +# an LKMM .litmus.out file, the observation in that file will be used +# to judge the assembly-language verification. # # Usage: # judgelitmus.sh file.litmus @@ -32,9 +34,11 @@ fi if test -z "$LKMM_HW_MAP_FILE" then litmusout=$litmus.out + lkmmout= else litmusout="`echo $litmus | sed -e 's/\.litmus$/.'${LKMM_HW_MAP_FILE}'.litmus/'`.out" + lkmmout=$litmus.out fi if test -f "$LKMM_DESTDIR/$litmusout" -a -r "$LKMM_DESTDIR/$litmusout" then @@ -46,6 +50,9 @@ fi if grep -q '^ \* Result: ' $litmus then outcome=`grep -m 1 '^ \* Result: ' $litmus | awk '{ print $3 }'` +elif test -n "$LKMM_HW_MAP_FILE" && grep -q '^Observation' $LKMM_DESTDIR/$lkmmout > /dev/null 2>&1 +then + outcome=`grep -m 1 '^Observation ' $LKMM_DESTDIR/$lkmmout | awk '{ print $3 }'` else outcome=specified fi -- 2.17.1