OpenCores
URL https://opencores.org/ocsvn/openrisc_2011-10-31/openrisc_2011-10-31/trunk

Subversion Repositories openrisc_2011-10-31

[/] [openrisc/] [trunk/] [or1ksim/] [sim-cmd.c] - Diff between revs 60 and 235

Go to most recent revision | Show entire file | Details | Blame | View Log

Rev 60 Rev 235
Line 41... Line 41...
/* Package includes */
/* Package includes */
#include "sim-cmd.h"
#include "sim-cmd.h"
#include "sim-config.h"
#include "sim-config.h"
#include "execute.h"
#include "execute.h"
#include "labels.h"
#include "labels.h"
#include "gdbcomm.h"
 
#include "sched.h"
#include "sched.h"
#include "toplevel-support.h"
#include "toplevel-support.h"
#include "dumpverilog.h"
#include "dumpverilog.h"
#include "profiler.h"
#include "profiler.h"
#include "mprofiler.h"
#include "mprofiler.h"
Line 693... Line 692...
#ifdef HAVE_LIBREADLINE
#ifdef HAVE_LIBREADLINE
      cur_arg = readline ("(sim) ");
      cur_arg = readline ("(sim) ");
#else
#else
      PRINTF ("(sim) ");
      PRINTF ("(sim) ");
 
 
      /* RSP does not get involved during CLI, so only check legacy interface
 
         here. */
 
      if (config.debug.gdb_enabled)
 
        {
 
          fflush (stdout);
 
          handle_server_socket (TRUE);  /* block & check_stdin = true */
 
        }
 
 
 
      cur_arg = fgets (b2, sizeof (b2), stdin);
      cur_arg = fgets (b2, sizeof (b2), stdin);
 
 
      if (!cur_arg)
      if (!cur_arg)
        sim_done ();
        sim_done ();
 
 
Line 807... Line 798...
    }
    }
}
}
 
 
#ifdef HAVE_LIBREADLINE
#ifdef HAVE_LIBREADLINE
 
 
int
 
check_gdb_comm (void)
 
{
 
  /* Only do anything for legacy debug interface. RSP does not get involved
 
     when the CLI is active */
 
  if (config.debug.gdb_enabled)
 
    {
 
      handle_server_socket (TRUE);      /* block & check_stdin = true */
 
    }
 
 
 
  return 0;
 
}
 
 
 
char *command_generator ();
char *command_generator ();
char **sim_completion ();
char **sim_completion ();
 
 
/* Tell the GNU readline library how to complete.  We want to try to complete
/* Tell the GNU readline library how to complete.  We want to try to complete
   on command names if this is the first word in the line, or on filenames
   on command names if this is the first word in the line, or on filenames
Line 835... Line 813...
  rl_readline_name = "or1ksim";
  rl_readline_name = "or1ksim";
 
 
  /* Tell the completer that we want a crack first. */
  /* Tell the completer that we want a crack first. */
  rl_attempted_completion_function = sim_completion;
  rl_attempted_completion_function = sim_completion;
 
 
#if HAVE_DECL_RL_EVENT_HOOK
 
  /* Handle the gdb socket while waiting for input */
 
  rl_event_hook = check_gdb_comm;
 
#endif
 
}
}
 
 
/* Attempt to complete on the contents of TEXT.  START and END bound the
/* Attempt to complete on the contents of TEXT.  START and END bound the
   region of rl_line_buffer that contains the word to complete.  TEXT is
   region of rl_line_buffer that contains the word to complete.  TEXT is
   the word to complete.  We can use the entire contents of rl_line_buffer
   the word to complete.  We can use the entire contents of rl_line_buffer

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.