solo.h

来自「一个用在mips体系结构中的操作系统」· C头文件 代码 · 共 62 行

H
62
字号
/* * Copyright (C) 1996-1998 by the Board of Trustees *    of Leland Stanford Junior University. *  * This file is part of the SimOS distribution.  * See LICENSE file for terms of the license.  * *//***************************************************************** * solo.h * *****************************************************************/#ifndef SOLO_H#define SOLO_H#include "cpu_state.h"#include "simtypes.h"#include "eventcallback.h"#include "machine_params.h"typedef struct soloState {   bool inBarrier;   SimTime syncStallStart;   EventCallbackHdr syncCallback;   void (*syncDoneCallback)(int cpuNum);   /* Called when a sync finishes */  /* For explanations, see solo/syscall.c */#define SYSCALL_BUF_SIZE        16384   int syscallNum;              /* Sanity check for syscalls I can't                                 * handle atomically */   char syscallBuf[2][SYSCALL_BUF_SIZE];                                /* Two buffers for syscall array assembly */   int syscallState[2];         /* Indication of progess for this buffer */} SoloState;extern SoloState machineState[];extern int soloActiveProcs;extern int soloCPUNum;/* The soloHighStack and soloLowStack variables will always keep the *//* bounds of the simulated processor's stack addresses. This provides *//* flashlite's virtual to physical mapping function to know to put *//* stack pages local. */extern VA soloLowStack;extern VA soloHighStack;#define IS_STACK_REF(_addr) ((_addr > soloLowStack) && (_addr < soloHighStack)) extern int SoloEmulateSyscall(int cpuNum, int syscallNum);extern void SoloTurnOnCaches(void);extern void SoloTurnOffCaches(void);extern bool SoloCachesAreOn(void);extern void sys_place_range(unsigned start, unsigned stop, int node);extern unsigned GetTotalMemPerProc(void);extern void FlashLiteResetStats(void);extern void SoloBackdoorSyncFinish(int cpuNum);#endif

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?