finsh_vm.h 481 B

1234567891011121314151617181920212223242526
  1. #ifndef __FINSH_VM_H__
  2. #define __FINSH_VM_H__
  3. #include <finsh.h>
  4. #include "finsh_var.h"
  5. union finsh_value {
  6. char char_value;
  7. short short_value;
  8. long long_value;
  9. void* ptr;
  10. };
  11. extern union finsh_value* finsh_sp; /* stack pointer */
  12. extern u_char* finsh_pc; /* PC */
  13. /* stack */
  14. extern union finsh_value finsh_vm_stack[FINSH_STACK_MAX];
  15. /* text segment */
  16. extern u_char text_segment[FINSH_TEXT_MAX];
  17. void finsh_vm_run(void);
  18. //void finsh_disassemble(void);
  19. #endif