From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from simark.ca by simark.ca with LMTP id qHafGTwn7GCoaQAAWB0awg (envelope-from ) for ; Mon, 12 Jul 2021 07:27:56 -0400 Received: by simark.ca (Postfix, from userid 112) id 64D101EDEC; Mon, 12 Jul 2021 07:27:56 -0400 (EDT) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on simark.ca X-Spam-Level: X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIM_SIGNED, MAILING_LIST_MULTI,T_DKIM_INVALID,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.2 Received: from sourceware.org (server2.sourceware.org [8.43.85.97]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by simark.ca (Postfix) with ESMTPS id 5F0341E54D for ; Mon, 12 Jul 2021 07:27:55 -0400 (EDT) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id C903C383D82E for ; Mon, 12 Jul 2021 11:27:54 +0000 (GMT) Received: from smtp-out2.suse.de (smtp-out2.suse.de [195.135.220.29]) by sourceware.org (Postfix) with ESMTPS id A39A5383D82E for ; Mon, 12 Jul 2021 11:27:42 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org A39A5383D82E Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=suse.de Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=suse.de Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by smtp-out2.suse.de (Postfix) with ESMTPS id D14D91FF7B; Mon, 12 Jul 2021 11:27:41 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1626089261; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type; bh=+XzuKTnqRbb2KSAnr2t2njywMf8EwbVutI8qntosX0M=; b=In6cC494qYjVlG4Rs3fjWzpP++ftSOHeNRewJ7k71c5L5cn1Om9jpVYyTChxvMCGB4uPDr NMag8crDD4bdyzRVSR2JBIn5JILRr1iXcB243K9rZTY5k5fl7FoIZpkqYPm7+SRos9LFnm 76LFxsy7m9vYH4GwxoKL73cbgi7UZcU= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1626089261; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type; bh=+XzuKTnqRbb2KSAnr2t2njywMf8EwbVutI8qntosX0M=; b=LaYSNDaQ4cFVxluXjLzNbjuT4uKl6u08WcbK0HMf+e4oxUykdvBF3qTO0dBNb0OTyjVkvn 0vs2JTVpKwlmxkDA== Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by imap2.suse-dmz.suse.de (Postfix) with ESMTPS id B01DC13BA8; Mon, 12 Jul 2021 11:27:41 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id XFUxKS0n7GCwRwAAMHmgww (envelope-from ); Mon, 12 Jul 2021 11:27:41 +0000 Date: Mon, 12 Jul 2021 13:27:40 +0200 From: Tom de Vries To: gdb-patches@sourceware.org Subject: [PATCH][gdb/testsuite] Fix gdb.btrace/tsx.exp on system with tsx disabled in microcode Message-ID: <20210712112738.GA2111@delia> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.10.1 (2018-07-13) X-BeenThere: gdb-patches@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: gdb-patches-bounces+public-inbox=simark.ca@sourceware.org Sender: "Gdb-patches" Hi, Recently I started to see this fail with trunk: ... (gdb) record instruction-history^M 1 0x00000000004004ab : call 0x4004b7 ^M 2 0x00000000004004c6 : mov $0x1,%eax^M 3 0x00000000004004cb : ret ^M (gdb) FAIL: gdb.btrace/tsx.exp: speculation indication ... This is due to an intel microcode update (1) that disables Intel TSX by default. Fix this by updating the pattern. Tested on x86_64-linux. [1] https://www.intel.com/content/www/us/en/support/articles/000059422/processors.html Any comments? Thanks, - Tom [gdb/testsuite] Fix gdb.btrace/tsx.exp on system with tsx disabled in microcode gdb/testsuite/ChangeLog: 2021-07-12 Tom de Vries PR testsuite/28057 * gdb.btrace/tsx.exp: Add pattern for system with tsx disabled in microcode. --- gdb/testsuite/gdb.btrace/tsx.exp | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/gdb/testsuite/gdb.btrace/tsx.exp b/gdb/testsuite/gdb.btrace/tsx.exp index ccde1ea807e..7f96313f1b1 100644 --- a/gdb/testsuite/gdb.btrace/tsx.exp +++ b/gdb/testsuite/gdb.btrace/tsx.exp @@ -59,6 +59,11 @@ set abort_2 [multi_line \ "\[0-9\]*\t 0x\[0-9a-f\]+ :\tmov\[^\\\r\\\n\]*" \ "\[0-9\]*\t 0x\[0-9a-f\]+ :\tret\[^\\\r\\\n\]*" \ ] +set abort_3 \ + [multi_line \ + "$decimal\t $hex :\tcall\[^\\\r\\\n\]*" \ + "$decimal\t $hex :\tmov\[^\\\r\\\n\]*" \ + "$decimal\t $hex :\tret\[^\\\r\\\n\]*"] set test "speculation indication" gdb_test_multiple "record instruction-history" $test { @@ -68,6 +73,9 @@ gdb_test_multiple "record instruction-history" $test { -re "$abort_2.*$gdb_prompt $" { pass $test } + -re -wrap "$abort_3" { + pass $gdb_test_name + } -re "$begin_to_end.*$gdb_prompt $" { pass $test }