OpenCores
URL https://opencores.org/ocsvn/or1k/or1k/trunk

Subversion Repositories or1k

[/] [or1k/] [tags/] [nog_patch_47/] [or1ksim/] [cpu/] [common/] [stats.c] - Diff between revs 1344 and 1350

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

Rev 1344 Rev 1350
Line 19... Line 19...
 
 
#include <stdio.h>
#include <stdio.h>
#include <ctype.h>
#include <ctype.h>
#include <string.h>
#include <string.h>
 
 
 
#include "config.h"
 
 
 
#ifdef HAVE_INTTYPES_H
 
#include <inttypes.h>
 
#endif
 
 
 
#include "port.h"
 
#include "arch.h"
#include "abstract.h"
#include "abstract.h"
#include "sim-config.h"
#include "sim-config.h"
#include "sprs.h"
#include "sprs.h"
#include "spr_defs.h"
#include "spr_defs.h"
#include "execute.h"
#include "execute.h"
Line 272... Line 280...
  case 6:
  case 6:
    if (config.cpu.sbuf_len) {
    if (config.cpu.sbuf_len) {
      extern int sbuf_total_cyc, sbuf_wait_cyc;
      extern int sbuf_total_cyc, sbuf_wait_cyc;
      PRINTF ("stats 6: Store buffer analysis\n");
      PRINTF ("stats 6: Store buffer analysis\n");
      PRINTF ("Using store buffer of length %i.\n", config.cpu.sbuf_len);
      PRINTF ("Using store buffer of length %i.\n", config.cpu.sbuf_len);
      PRINTF ("Number of total memory store cycles: %i/%i\n", sbuf_total_cyc, runtime.sim.cycles + sbuf_total_cyc - sbuf_wait_cyc);
      PRINTF ("Number of total memory store cycles: %i/%lli\n", sbuf_total_cyc,
 
              runtime.sim.cycles + sbuf_total_cyc - sbuf_wait_cyc);
      PRINTF ("Number of cycles waiting for memory stores: %i\n", sbuf_wait_cyc);
      PRINTF ("Number of cycles waiting for memory stores: %i\n", sbuf_wait_cyc);
      PRINTF ("Number of memory cycles spared: %i\n", sbuf_total_cyc - sbuf_wait_cyc);
      PRINTF ("Number of memory cycles spared: %i\n", sbuf_total_cyc - sbuf_wait_cyc);
      PRINTF ("Store speedup %3.2f%%, total speedup %3.2f%%\n", 100.*(sbuf_total_cyc - sbuf_wait_cyc)/sbuf_total_cyc,
      PRINTF ("Store speedup %3.2f%%, total speedup %3.2f%%\n", 100.*(sbuf_total_cyc - sbuf_wait_cyc)/sbuf_total_cyc,
                                                                100.*(sbuf_total_cyc - sbuf_wait_cyc) / (runtime.sim.cycles + sbuf_total_cyc - sbuf_wait_cyc));
                                                                100.*(sbuf_total_cyc - sbuf_wait_cyc) / (runtime.sim.cycles + sbuf_total_cyc - sbuf_wait_cyc));
    } else
    } else

powered by: WebSVN 2.1.0

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