Blame SOURCES/gdb-rhbz1971095-libthread_db-update-5of5.patch

4a80f0
From FEDORA_PATCHES Mon Sep 17 00:00:00 2001
4a80f0
From: Kevin Buettner <kevinb@redhat.com>
4a80f0
Date: Wed, 9 Jun 2021 19:52:08 -0700
4a80f0
Subject: gdb-rhbz1971095-libthread_db-update-5of5.patch
4a80f0
4a80f0
;; Backport "mi-sym-info.exp: Increase timeout for 114-symbol-info-functions"
4a80f0
;; (Kevin Buettner, RH BZ 1971095)
4a80f0
4a80f0
Loading libc.so's symbols increased the amount of time needed for
4a80f0
114-symbol-info-function to fetch symbols, causing a timeout during my
4a80f0
testing.  I enclosed the entire block with a "with_timeout_factor 4",
4a80f0
which fixes the problem for me.  (Using 2 also fixed it for me, but it
4a80f0
might not be enough when running this test on slower machines.)
4a80f0
4a80f0
gdb/testsuite/ChangeLog:
4a80f0
4a80f0
	* gdb.mi/mi-sym-info.exp (114-symbol-info-function test): Increase
4a80f0
	timeout.
4a80f0
4a80f0
diff --git a/gdb/testsuite/gdb.mi/mi-sym-info.exp b/gdb/testsuite/gdb.mi/mi-sym-info.exp
4a80f0
--- a/gdb/testsuite/gdb.mi/mi-sym-info.exp
4a80f0
+++ b/gdb/testsuite/gdb.mi/mi-sym-info.exp
4a80f0
@@ -122,33 +122,35 @@ gdb_test_multiple $cmd $testname -prompt "${mi_gdb_prompt}$" {
4a80f0
 # (from the symbol table).  There's often so much output output from
4a80f0
 # this command that we overflow expect's buffers, avoid this by
4a80f0
 # fetching the output piece by piece.
4a80f0
-set testname "List all functions"
4a80f0
-set cmd "114-symbol-info-functions --include-nondebug"
4a80f0
-set state 0
4a80f0
-gdb_test_multiple $cmd ${testname} -prompt "${mi_gdb_prompt}$" {
4a80f0
-    -re "114\\^done,symbols=\{" {
4a80f0
-	if { $state == 0 } { set state 1 }
4a80f0
-	exp_continue
4a80f0
-    }
4a80f0
-    -re "debug=\\\[${symtab_re}" {
4a80f0
-	if { $state == 1 } { set state 2 }
4a80f0
-	exp_continue
4a80f0
-    }
4a80f0
-    -re ",${symtab_re}" {
4a80f0
-	exp_continue
4a80f0
-    }
4a80f0
-    -re "\\\],nondebug=\\\[" {
4a80f0
-	if { $state == 2 } { set state 3 }
4a80f0
-	exp_continue
4a80f0
-    }
4a80f0
-    -re "\{address=${qstr},name=${qstr}\}," {
4a80f0
-	exp_continue
4a80f0
-    }
4a80f0
-    -re "\{address=${qstr},name=${qstr}\}\\\]\}\r\n${mi_gdb_prompt}$" {
4a80f0
-	if { $state == 3 } {
4a80f0
-	    pass $gdb_test_name
4a80f0
-	} else {
4a80f0
-	    fail $gdb_test_name
4a80f0
+with_timeout_factor 4 {
4a80f0
+    set testname "List all functions"
4a80f0
+    set cmd "114-symbol-info-functions --include-nondebug"
4a80f0
+    set state 0
4a80f0
+    gdb_test_multiple $cmd ${testname} -prompt "${mi_gdb_prompt}$" {
4a80f0
+	-re "114\\^done,symbols=\{" {
4a80f0
+	    if { $state == 0 } { set state 1 }
4a80f0
+	    exp_continue
4a80f0
+	}
4a80f0
+	-re "debug=\\\[${symtab_re}" {
4a80f0
+	    if { $state == 1 } { set state 2 }
4a80f0
+	    exp_continue
4a80f0
+	}
4a80f0
+	-re ",${symtab_re}" {
4a80f0
+	    exp_continue
4a80f0
+	}
4a80f0
+	-re "\\\],nondebug=\\\[" {
4a80f0
+	    if { $state == 2 } { set state 3 }
4a80f0
+	    exp_continue
4a80f0
+	}
4a80f0
+	-re "\{address=${qstr},name=${qstr}\}," {
4a80f0
+	    exp_continue
4a80f0
+	}
4a80f0
+	-re "\{address=${qstr},name=${qstr}\}\\\]\}\r\n${mi_gdb_prompt}$" {
4a80f0
+	    if { $state == 3 } {
4a80f0
+		pass $gdb_test_name
4a80f0
+	    } else {
4a80f0
+		fail $gdb_test_name
4a80f0
+	    }
4a80f0
 	}
4a80f0
     }
4a80f0
 }