YACASL2
Loading...
Searching...
No Matches
struct.c File Reference
#include "struct.h"
#include "exec.h"
Include dependency graph for struct.c:

Go to the source code of this file.

Enumerations

enum  { CMDTABSIZE = 41 }

Functions

unsigned hash_cmdtype (const char *cmd, CMDTYPE type)
unsigned hash_code (WORD code)
bool create_cmdtable (CMDTAB_HASH hash)
 命令ハッシュ表を作成する
void free_cmdtable (CMDTAB_HASH hash)
WORD getcmdcode (const char *cmd, CMDTYPE type)
const void * getcmdptr (WORD code)
CMDTYPE getcmdtype (WORD code)
char * getcmdname (WORD code)
char * grstr (WORD word)
 汎用レジスタの番号からレジスタを表す文字列を返す
void cpu_reset ()
void memory_reset ()
void comet2_init (int memsize, int clocks)
void comet2_reset ()
void comet2_resetall ()
void comet2_shutdown ()

Variables

SYSTEMsys = NULL
 COMET IIの仮想実行マシンシステム
EXECPTRexecptr = NULL
static const COMET2CMD comet2cmd []
static int comet2cmdsize = ARRAYSIZE(comet2cmd)
static CMDTABcmdtab [HASH_MAX][CMDTABSIZE] = {{NULL}}

Enumeration Type Documentation

◆ anonymous enum

anonymous enum

ハッシュ表のサイズ

Enumerator
CMDTABSIZE 

Definition at line 66 of file struct.c.

Function Documentation

◆ comet2_init()

void comet2_init ( int memsize,
int clocks )

COMET II仮想マシンの初期化

Definition at line 267 of file struct.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ comet2_reset()

void comet2_reset ( )

COMET II仮想マシンのCPUリセット

Definition at line 286 of file struct.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ comet2_resetall()

void comet2_resetall ( )

COMET II仮想マシンのCPUとメモリをリセット

Definition at line 295 of file struct.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ comet2_shutdown()

void comet2_shutdown ( )

COMET II仮想マシンのシャットダウン

Definition at line 306 of file struct.c.

Here is the caller graph for this function:

◆ cpu_reset()

void cpu_reset ( )

Definition at line 250 of file struct.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ create_cmdtable()

bool create_cmdtable ( CMDTAB_HASH hash)

命令ハッシュ表を作成する

命令ハッシュ表を作成する

Definition at line 113 of file struct.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ free_cmdtable()

void free_cmdtable ( CMDTAB_HASH hash)

命令ハッシュ表を解放する

Definition at line 135 of file struct.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ getcmdcode()

WORD getcmdcode ( const char * cmd,
CMDTYPE type )

命令の名前とタイプから、命令コードを返す
無効な場合は0xFFFFを返す

Definition at line 153 of file struct.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ getcmdname()

char * getcmdname ( WORD code)

命令コードから命令の名前を返す

Definition at line 222 of file struct.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ getcmdptr()

const void * getcmdptr ( WORD code)

命令コードから命令の関数ポインタを返す

Definition at line 188 of file struct.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ getcmdtype()

CMDTYPE getcmdtype ( WORD code)

命令コードから命令のタイプを返す

Definition at line 205 of file struct.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ grstr()

char * grstr ( WORD word)

汎用レジスタの番号からレジスタを表す文字列を返す

汎用レジスタの番号からレジスタを表す文字列を返す

Definition at line 240 of file struct.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ hash_cmdtype()

unsigned hash_cmdtype ( const char * cmd,
CMDTYPE type )

命令の名前とタイプからハッシュ値を生成する

Definition at line 88 of file struct.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ hash_code()

unsigned hash_code ( WORD code)

命令コードからハッシュ値を生成する

Definition at line 171 of file struct.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ memory_reset()

void memory_reset ( )

Definition at line 260 of file struct.c.

Variable Documentation

◆ cmdtab

CMDTAB* cmdtab[HASH_MAX][CMDTABSIZE] = {{NULL}}
static

ハッシュ表

Definition at line 73 of file struct.c.

◆ comet2cmd

const COMET2CMD comet2cmd[]
static

システムCOMET IIの命令表

Definition at line 17 of file struct.c.

◆ comet2cmdsize

int comet2cmdsize = ARRAYSIZE(comet2cmd)
static

命令表のサイズ

Definition at line 61 of file struct.c.

◆ execptr

EXECPTR* execptr = NULL

プログラム実行時の開始と終了のアドレス

Definition at line 12 of file struct.c.

◆ sys

SYSTEM* sys = NULL

COMET IIの仮想実行マシンシステム

COMET IIの仮想実行マシンシステム

Definition at line 7 of file struct.c.