Main Page | Class List | Directories | File List | Class Members | File Members

vm_load.c File Reference

CKPM virtual machine executable loader. More...

#include <stdio.h>
#include <unistd.h>
#include <stdlib.h>
#include <string.h>
#include "vm.h"
#include "vm_disasm.h"
#include "ld_object.h"

Functions

vm_mem_tload_file (int verbose, int argc, char **argv, char *file_name, vm_size_t mem_size)
 load a virtual machine executable


Detailed Description

CKPM virtual machine executable loader.


Function Documentation

vm_mem_t* load_file int  verbose,
int  argc,
char **  argv,
char *  file_name,
vm_size_t  mem_size
 

load a virtual machine executable

Parameters:
verbose if != 0 this function will provide verbose output
argc argument counter, contains the number of entries in argv
argv argument vector
file_name the file name of the VM executable to be loaded
mem_size the requested size in MB of the VM memory
Returns:
the pointer to the VM memory on success, NULL otherwise
This function allocates the requested size of memory for the virtual machine and loads a virtual machine executable into this memory. Additionally, it initialises the virtual machine registers.


Generated on Thu Jul 13 03:56:37 2006 for CKPMcc by  doxygen 1.4.4