Nguyen Anh Quynh | f721e31 | 2014-05-27 10:45:58 +0800 | [diff] [blame] | 1 | /* Capstone Disassembly Engine */ |
| 2 | /* By Nguyen Anh Quynh <aquynh@gmail.com>, 2013-2014 */ |
Nguyen Anh Quynh | f1d489b | 2014-01-05 00:00:05 +0800 | [diff] [blame] | 3 | |
| 4 | #ifndef CS_PPC_MAP_H |
| 5 | #define CS_PPC_MAP_H |
| 6 | |
| 7 | #include "../../include/capstone.h" |
Nguyen Anh Quynh | f1d489b | 2014-01-05 00:00:05 +0800 | [diff] [blame] | 8 | |
| 9 | // return name of regiser in friendly string |
| 10 | const char *PPC_reg_name(csh handle, unsigned int reg); |
| 11 | |
| 12 | // given internal insn id, return public instruction info |
Nguyen Anh Quynh | 1acfd0b | 2014-01-06 10:56:59 +0800 | [diff] [blame] | 13 | void PPC_get_insn_id(cs_struct *h, cs_insn *insn, unsigned int id); |
Nguyen Anh Quynh | f1d489b | 2014-01-05 00:00:05 +0800 | [diff] [blame] | 14 | |
Nguyen Anh Quynh | f1d489b | 2014-01-05 00:00:05 +0800 | [diff] [blame] | 15 | const char *PPC_insn_name(csh handle, unsigned int id); |
Nguyen Anh Quynh | 650f96c | 2014-07-08 08:59:27 +0800 | [diff] [blame] | 16 | const char *PPC_group_name(csh handle, unsigned int id); |
Nguyen Anh Quynh | f1d489b | 2014-01-05 00:00:05 +0800 | [diff] [blame] | 17 | |
Nguyen Anh Quynh | f1d489b | 2014-01-05 00:00:05 +0800 | [diff] [blame] | 18 | // map internal raw register to 'public' register |
| 19 | ppc_reg PPC_map_register(unsigned int r); |
| 20 | |
Nguyen Anh Quynh | 7e57e79 | 2014-09-21 13:04:50 +0800 | [diff] [blame^] | 21 | struct ppc_alias { |
| 22 | unsigned int id; // instruction id |
| 23 | int cc; // code condition |
| 24 | const char *mnem; |
| 25 | }; |
| 26 | |
| 27 | // given alias mnemonic, return instruction ID & CC |
| 28 | bool PPC_alias_insn(const char *name, struct ppc_alias *alias); |
Nguyen Anh Quynh | 721d07f | 2014-09-04 12:03:31 +0800 | [diff] [blame] | 29 | |
Nguyen Anh Quynh | f1d489b | 2014-01-05 00:00:05 +0800 | [diff] [blame] | 30 | #endif |
| 31 | |