MCPcopy Create free account
hub / github.com/Vector35/binaryninja-api / ppc_xxpermr

Function ppc_xxpermr

arch/powerpc/disassembler.cpp:120–137  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

118}
119
120void ppc_xxpermr(uint32_t insword, decomp_result *res)
121{
122 // 111100AAAAABBBBBCCCCC00011010BCA "xxpermr vsA,vsB,vsC"
123 int a = ((insword & 0x3E00000)>>21)|((insword & 0x1)<<5);
124 int b = ((insword & 0x1F0000)>>16)|((insword & 0x4)<<3);
125 int c = ((insword & 0xF800)>>11)|((insword & 0x2)<<4);
126
127 res->detail.ppc.operands[0].reg = (ppc_reg)(PPC_REG_VS0 + a);
128 res->detail.ppc.operands[0].type = PPC_OP_REG;
129 res->detail.ppc.operands[1].reg = (ppc_reg)(PPC_REG_VS0 + b);
130 res->detail.ppc.operands[1].type = PPC_OP_REG;
131 res->detail.ppc.operands[2].reg = (ppc_reg)(PPC_REG_VS0 + c);
132 res->detail.ppc.operands[2].type = PPC_OP_REG;
133
134 res->insn.id = PPC_INS_BN_XXPERMR;
135 res->detail.ppc.op_count = 3;
136 strncpy(res->insn.mnemonic, "xxpermr", sizeof(res->insn.mnemonic));
137}
138
139bool PerformLocalDisassembly(const uint8_t *data, uint64_t addr, size_t &len, decomp_result* res, bool bigendian)
140{

Callers 1

PerformLocalDisassemblyFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected