opcode: One or two bytes number which is an identifier of an instruction.Generate Rust code from the yaml file by using a template engine.īy scraping this website, I retrieved the information needed to generate the emulation code.Convert the instruction specification to a single yaml file.Scrape a web page of the instruction specification.Code generationĪs the CPU has about 500 instructions, writing all of the emulation code by hand sounds troublesome. This is the table of all the instructions. Misc (stop CPU, interrupt disable/enable).There’re about 500 instructions supported by the CPU, which can be roughly divided into these 5 types: It has only 4 flags, which are stored in the upper four bits of the flag register.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |