Use target_sim_options for sim target.
authorJon Beniston <jon@beniston.com>
Sat, 10 Sep 2016 20:18:56 +0000 (21:18 +0100)
committerJon Beniston <jon@beniston.com>
Sat, 10 Sep 2016 20:38:47 +0000 (21:38 +0100)
2016-09-10  Jon Beniston  <jon@beniston.com>

* lib/mi-support.exp (mi_gdb_target_load): Use target_sim_options
for sim target.

gdb/testsuite/ChangeLog
gdb/testsuite/lib/mi-support.exp

index 783e30fedb0968a70e4289df82ce949a8a0fef52..1ed9a21d3a1d82e0b7f73903a4155f7a1ed7f0f7 100644 (file)
@@ -1,3 +1,8 @@
+2016-09-10  Jon Beniston  <jon@beniston.com>
+
+       * lib/mi-support.exp (mi_gdb_target_load): Use target_sim_options
+       for sim target.
+
 2016-09-09  Andreas Arnez  <arnez@linux.vnet.ibm.com>
 
        * gdb.base/gnu-ifunc-lib.c (resolver_hwcap): New external
index 18664c4d56f478f5c4d6d96d07e4b46ddb11718e..7c2bb3e243a3f0cd5d0d2364be4311ea8295f1b6 100644 (file)
@@ -602,8 +602,9 @@ proc mi_gdb_target_load { } {
            }
        }
     } elseif { [target_info protocol] == "sim" } {
+       set target_sim_options "[board_info target gdb,target_sim_options]"
        # For the simulator, just connect to it directly.
-       send_gdb "47-target-select sim\n"
+       send_gdb "47-target-select sim $target_sim_options\n"
        gdb_expect $loadtimeout {
            -re "47\\^connected.*$mi_gdb_prompt$" {
            }