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

Subversion Repositories eco32

[/] [eco32/] [trunk/] [sim/] [command.c] - Diff between revs 83 and 168

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

Rev 83 Rev 168
Line 781... Line 781...
  }
  }
}
}
 
 
 
 
static void doTLB(char *tokens[], int n) {
static void doTLB(char *tokens[], int n) {
 
  static char *mmuAccsWidth[4] = { "byte", "half", "word", "????" };
  int index;
  int index;
  TLB_Entry tlbEntry;
  TLB_Entry tlbEntry;
 
  Word mmuAccs;
  Word data;
  Word data;
 
 
  if (n == 1) {
  if (n == 1) {
    for (index = 0; index < TLB_SIZE; index++) {
    for (index = 0; index < TLB_SIZE; index++) {
      tlbEntry = mmuGetTLB(index);
      tlbEntry = mmuGetTLB(index);
Line 797... Line 799...
    }
    }
    cPrintf("Index(1)   %08X\n", mmuGetIndex());
    cPrintf("Index(1)   %08X\n", mmuGetIndex());
    cPrintf("EntryHi(2) %08X\n", mmuGetEntryHi());
    cPrintf("EntryHi(2) %08X\n", mmuGetEntryHi());
    cPrintf("EntryLo(3) %08X\n", mmuGetEntryLo());
    cPrintf("EntryLo(3) %08X\n", mmuGetEntryLo());
    cPrintf("BadAddr(4) %08X\n", mmuGetBadAddr());
    cPrintf("BadAddr(4) %08X\n", mmuGetBadAddr());
 
    mmuAccs = mmuGetBadAccs();
 
    cPrintf("BadAccs (5)  %08X (%s %s)\n",
 
            mmuAccs,
 
            (mmuAccs & MMU_ACCS_WRITE) ? "write" : "read",
 
            mmuAccsWidth[mmuAccs & 0x03]);
  } else if (n == 2) {
  } else if (n == 2) {
    if (!getDecNumber(tokens[1], &index) || index < 0 || index >= TLB_SIZE) {
    if (!getDecNumber(tokens[1], &index) || index < 0 || index >= TLB_SIZE) {
      cPrintf("illegal TLB index\n");
      cPrintf("illegal TLB index\n");
      return;
      return;
    }
    }

powered by: WebSVN 2.1.0

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