Blame SOURCES/gdb-6.6-scheduler_locking-step-is-default.patch

190f2a
From FEDORA_PATCHES Mon Sep 17 00:00:00 2001
190f2a
From: Fedora GDB patches <invalid@email.com>
190f2a
Date: Fri, 27 Oct 2017 21:07:50 +0200
190f2a
Subject: gdb-6.6-scheduler_locking-step-is-default.patch
190f2a
190f2a
;; Make upstream `set scheduler-locking step' as default.
190f2a
;;=push+jan: How much is scheduler-locking relevant after non-stop?
190f2a
190f2a
diff --git a/gdb/infrun.c b/gdb/infrun.c
190f2a
--- a/gdb/infrun.c
190f2a
+++ b/gdb/infrun.c
190f2a
@@ -2193,7 +2193,7 @@ static const char *const scheduler_enums[] = {
190f2a
   schedlock_replay,
190f2a
   NULL
190f2a
 };
190f2a
-static const char *scheduler_mode = schedlock_replay;
190f2a
+static const char *scheduler_mode = schedlock_step;
190f2a
 static void
190f2a
 show_scheduler_mode (struct ui_file *file, int from_tty,
190f2a
 		     struct cmd_list_element *c, const char *value)
190f2a
diff --git a/gdb/testsuite/gdb.mi/mi-cli.exp b/gdb/testsuite/gdb.mi/mi-cli.exp
190f2a
--- a/gdb/testsuite/gdb.mi/mi-cli.exp
190f2a
+++ b/gdb/testsuite/gdb.mi/mi-cli.exp
190f2a
@@ -199,7 +199,7 @@ mi_expect_stop "breakpoint-hit" "main" "" ".*basics.c" \
190f2a
 # Test that the token is output even for CLI commands
190f2a
 # Also test that *stopped includes frame information.
190f2a
 mi_gdb_test "34 next" \
190f2a
-    ".*34\\\^running.*\\*running,thread-id=\"all\"" \
190f2a
+    ".*34\\\^running.*\\*running,thread-id=\"1\"" \
190f2a
     "34 next: run"
190f2a
 
190f2a
 # Test that the new current source line is output to the console
190f2a
diff --git a/gdb/testsuite/gdb.mi/mi-console.exp b/gdb/testsuite/gdb.mi/mi-console.exp
190f2a
--- a/gdb/testsuite/gdb.mi/mi-console.exp
190f2a
+++ b/gdb/testsuite/gdb.mi/mi-console.exp
190f2a
@@ -60,6 +60,9 @@ if  { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {deb
190f2a
 
190f2a
 mi_run_to_main
190f2a
 
190f2a
+# thread-id=\"all\" vs. thread-id=\"1\" below:
190f2a
+mi_gdb_test "210-gdb-set scheduler-locking off" "210\\^done" "set scheduler-locking off"
190f2a
+
190f2a
 # The output we get from the target depends on how it is hosted.  If
190f2a
 # we are semihosted (e.g., the sim or a remote target that supports
190f2a
 # the File I/O remote protocol extension), we see the target I/O
190f2a
diff --git a/gdb/testsuite/gdb.mi/mi-logging.exp b/gdb/testsuite/gdb.mi/mi-logging.exp
190f2a
--- a/gdb/testsuite/gdb.mi/mi-logging.exp
190f2a
+++ b/gdb/testsuite/gdb.mi/mi-logging.exp
190f2a
@@ -53,7 +53,7 @@ close $chan
190f2a
 
190f2a
 set mi_log_prompt "\[(\]gdb\[)\] \[\r\n\]+"
190f2a
 
190f2a
-if [regexp "\\^done\[\r\n\]+$mi_log_prompt\\^running\[\r\n\]+\\*running,thread-id=\"all\"\[\r\n\]+$mi_log_prompt\\*stopped,reason=\"end-stepping-range\",.*\[\r\n\]+$mi_log_prompt\\^running\[\r\n\]+\\*running,thread-id=\"all\"\[\r\n\]+$mi_log_prompt\\*stopped,reason=\"end-stepping-range\",.*\[\r\n\]+$mi_log_prompt" $logcontent] {
190f2a
+if [regexp "\\^done\[\r\n\]+$mi_log_prompt\\^running\[\r\n\]+\\*running,thread-id=\"1\"\[\r\n\]+$mi_log_prompt\\*stopped,reason=\"end-stepping-range\",.*\[\r\n\]+$mi_log_prompt\\^running\[\r\n\]+\\*running,thread-id=\"1\"\[\r\n\]+$mi_log_prompt\\*stopped,reason=\"end-stepping-range\",.*\[\r\n\]+$mi_log_prompt" $logcontent] {
190f2a
     pass "log file contents"
190f2a
 } else {
190f2a
     fail "log file contents"
190f2a
@@ -76,7 +76,7 @@ set chan [open $milogfile]
190f2a
 set logcontent [read $chan]
190f2a
 close $chan
190f2a
 
190f2a
-if [regexp "1001\\^done\[\r\n\]+$mi_log_prompt.*1002\\^running\[\r\n\]+\\*running,thread-id=\"all\"\[\r\n\]+$mi_log_prompt\\*stopped,reason=\"end-stepping-range\",.*\[\r\n\]+$mi_log_prompt.*1003\\^running\[\r\n\]+\\*running,thread-id=\"all\"\[\r\n\]+$mi_log_prompt\\*stopped,reason=\"end-stepping-range\",.*\[\r\n\]+$mi_log_prompt" $logcontent] {
190f2a
+if [regexp "1001\\^done\[\r\n\]+$mi_log_prompt.*1002\\^running\[\r\n\]+\\*running,thread-id=\"1\"\[\r\n\]+$mi_log_prompt\\*stopped,reason=\"end-stepping-range\",.*\[\r\n\]+$mi_log_prompt.*1003\\^running\[\r\n\]+\\*running,thread-id=\"1\"\[\r\n\]+$mi_log_prompt\\*stopped,reason=\"end-stepping-range\",.*\[\r\n\]+$mi_log_prompt" $logcontent] {
190f2a
     pass "redirect log file contents"
190f2a
 } else {
190f2a
     fail "redirect log file contents"
190f2a
diff --git a/gdb/testsuite/gdb.opt/inline-cmds.exp b/gdb/testsuite/gdb.opt/inline-cmds.exp
190f2a
--- a/gdb/testsuite/gdb.opt/inline-cmds.exp
190f2a
+++ b/gdb/testsuite/gdb.opt/inline-cmds.exp
190f2a
@@ -331,7 +331,7 @@ proc mi_cli_step {cli_output_re message} {
190f2a
 
190f2a
     send_gdb "interpreter-exec console \"step\"\n"
190f2a
     gdb_expect {
190f2a
-	-re "\\^running\r\n\\*running,thread-id=\"all\"\r\n${mi_gdb_prompt}${cli_output_re}" {
190f2a
+	-re "\\^running\r\n\\*running,thread-id=\"1\"\r\n${mi_gdb_prompt}${cli_output_re}" {
190f2a
 	    pass $message
190f2a
 	}
190f2a
 	timeout {