Line 57... |
Line 57... |
#include "profiler.h"
|
#include "profiler.h"
|
#include "mprofiler.h"
|
#include "mprofiler.h"
|
#include "mc.h"
|
#include "mc.h"
|
|
|
/* CVS revision number. */
|
/* CVS revision number. */
|
const char rcsrev[] = "$Revision: 1.82 $";
|
const char rcsrev[] = "$Revision: 1.83 $";
|
|
|
/* Continuos run versus single step tracing switch. */
|
/* Continuos run versus single step tracing switch. */
|
int cont_run;
|
int cont_run;
|
|
|
/* History of execution */
|
/* History of execution */
|
Line 352... |
Line 352... |
{
|
{
|
if (config.sim.profile) {
|
if (config.sim.profile) {
|
extern int cycles;
|
extern int cycles;
|
fprintf(runtime.sim.fprof,"-%08X FFFFFFFF\n", cycles);
|
fprintf(runtime.sim.fprof,"-%08X FFFFFFFF\n", cycles);
|
fclose(runtime.sim.fprof);
|
fclose(runtime.sim.fprof);
|
|
|
main_profile(config.sim.profile_mode, config.sim.prof_fn);
|
|
}
|
|
|
|
if (config.sim.mprofile) {
|
|
fclose(runtime.sim.fmprof);
|
|
|
|
main_mprofiler(config.sim.mprofile_mode,
|
|
config.sim.mprofile_group,
|
|
config.sim.mprof_fn);
|
|
}
|
}
|
|
|
|
if (config.sim.mprofile) fclose(runtime.sim.fmprof);
|
if (config.sim.exe_log) fclose(runtime.sim.fexe_log);
|
if (config.sim.exe_log) fclose(runtime.sim.fexe_log);
|
if (runtime.vapi.enabled) vapi_done ();
|
if (runtime.vapi.enabled) vapi_done ();
|
done_memory_table ();
|
done_memory_table ();
|
exit(0);
|
exit(0);
|
}
|
}
|
Line 407... |
Line 398... |
printf(" -i enable interactive command prompt\n");
|
printf(" -i enable interactive command prompt\n");
|
printf(" --nosrv do not launch JTAG proxy server\n"); /* (CZ) */
|
printf(" --nosrv do not launch JTAG proxy server\n"); /* (CZ) */
|
printf(" --srv <n> launch JTAG proxy server on port <n>; [random]\n"); /* (CZ) */
|
printf(" --srv <n> launch JTAG proxy server on port <n>; [random]\n"); /* (CZ) */
|
#if !FAST_SIM
|
#if !FAST_SIM
|
printf(" -f or --file load script file [sim.cfg]\n");
|
printf(" -f or --file load script file [sim.cfg]\n");
|
printf(" --profile <[c]|[q]> enable profiling. c - cumulative, q - quiet\n");
|
printf(" --enable-profile enable profiling.\n");
|
printf(" --mprofile <[c]|[q]> enable memory profiling. c - cumulative, q - quiet\n");
|
printf(" --enable-mprofile enable memory profiling.\n");
|
#endif
|
#endif
|
printf(" --output-cfg prints C structure of current configuration to standard output\n");
|
printf(" --output-cfg prints C structure of current\n");
|
|
printf(" configuration to standard output\n");
|
|
printf("\nor : %s ", argv[0]);
|
|
mp_help ();
|
|
printf("\nor : %s ", argv[0]);
|
|
prof_help ();
|
exit(-1);
|
exit(-1);
|
}
|
}
|
|
|
#ifdef HAVE_LIBREADLINE
|
#ifdef HAVE_LIBREADLINE
|
initialize_readline (); /* Bind our completer. */
|
initialize_readline (); /* Bind our completer. */
|
Line 673... |
Line 669... |
}
|
}
|
} else
|
} else
|
if (strcmp(item1, "info") == 0) /* configuration info */
|
if (strcmp(item1, "info") == 0) /* configuration info */
|
sim_info ();
|
sim_info ();
|
else
|
else
|
|
if (strcmp (item1, "profiler") == 0) { /
|
|
av = tokenize_line (linestr
|
|
main_profiler (ac, av);
|
|
} else
|
#if !FAST_SIM
|
#if !FAST_SIM
|
if (strcmp(item1, "set") == 0) { /* configuration info */
|
if (strcmp(item1, "set") == 0) { /* configuration info */
|
char *s = linestr;
|
char *s = linestr;
|
int i;
|
int i;
|
extern section;
|
extern section;
|