Decouple inferior_ptid/inferior_thread(); dup ptids in thread list (PR 25412)
[deliverable/binutils-gdb.git] / sim / frv / sim-if.c
index f530763ca58dc7aea4e17ea8e1c9661a38fe6e06..33758f075a80880ebd4914f7940a3226c77028c9 100644 (file)
@@ -1,5 +1,5 @@
 /* Main simulator entry points specific to the FRV.
-   Copyright (C) 1998-2015 Free Software Foundation, Inc.
+   Copyright (C) 1998-2020 Free Software Foundation, Inc.
    Contributed by Red Hat.
 
 This file is part of the GNU simulators.
@@ -30,10 +30,6 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 static void free_state (SIM_DESC);
 static void print_frv_misc_cpu (SIM_CPU *cpu, int verbose);
-
-/* Records simulator descriptor so utilities like frv_dump_regs can be
-   called from gdb.  */
-SIM_DESC current_state;
 \f
 /* Cover function of sim_state_free to free the cpu buffers as well.  */
 
@@ -53,7 +49,7 @@ sim_open (kind, callback, abfd, argv)
      SIM_OPEN_KIND kind;
      host_callback *callback;
      bfd *abfd;
-     char **argv;
+     char * const *argv;
 {
   char c;
   int i;
@@ -87,9 +83,7 @@ sim_open (kind, callback, abfd, argv)
      augment the meaning of an option.  */
   sim_add_option_table (sd, NULL, frv_options);
 
-  /* getopt will print the error message so we just have to exit if this fails.
-     FIXME: Hmmm...  in the case of gdb we need getopt to call
-     print_filtered.  */
+  /* The parser will print an error message for us, so we silently return.  */
   if (sim_parse_args (sd, argv) != SIM_RC_OK)
     {
       free_state (sd);
@@ -175,10 +169,6 @@ sim_open (kind, callback, abfd, argv)
       frv_initialize (cpu, sd);
     }
 
-  /* Store in a global so things like sparc32_dump_regs can be invoked
-     from the gdb command line.  */
-  current_state = sd;
-
   return sd;
 }
 
@@ -201,8 +191,8 @@ SIM_RC
 sim_create_inferior (sd, abfd, argv, envp)
      SIM_DESC sd;
      bfd *abfd;
-     char **argv;
-     char **envp;
+     char * const *argv;
+     char * const *envp;
 {
   SIM_CPU *current_cpu = STATE_CPU (sd, 0);
   SIM_ADDR addr;
This page took 0.024181 seconds and 4 git commands to generate.