Lines Matching refs:ib

96         LdaInstBase(const Brig::BrigInstBase *ib, const BrigObject *obj,
104 unsigned op_offs = obj->getOperandPtr(ib->operands, 0);
106 op_offs = obj->getOperandPtr(ib->operands, 1);
172 LdaInst(const Brig::BrigInstBase *ib, const BrigObject *obj,
175 AddrOperandType>(ib, obj, _opcode)
185 decodeLda(const Brig::BrigInstBase *ib, const BrigObject *obj)
187 unsigned op_offs = obj->getOperandPtr(ib->operands, 1);
191 return new LdaInst<DataType, NoRegAddrOperand>(ib, obj, "ldas");
196 return new LdaInst<DataType, SRegAddrOperand>(ib, obj, "ldas");
198 return new LdaInst<DataType, DRegAddrOperand>(ib, obj, "ldas");
221 LdInstBase(const Brig::BrigInstBase *ib, const BrigObject *obj,
230 if (ib->opcode == BRIG_OPCODE_LD) {
231 const BrigInstMem *ldst = (const BrigInstMem*)ib;
239 unsigned op_offs = obj->getOperandPtr(ib->operands, 0);
244 op_offs = obj->getOperandPtr(ib->operands, 1);
247 const BrigInstAtomic *at = (const BrigInstAtomic*)ib;
255 unsigned op_offs = obj->getOperandPtr(ib->operands, 0);
261 op_offs = obj->getOperandPtr(ib->operands,1);
402 LdInst(const Brig::BrigInstBase *ib, const BrigObject *obj,
406 AddrOperandType>(ib, obj, _opcode),
411 unsigned op_offs = obj->getOperandPtr(ib->operands,0);
703 decodeLd2(const Brig::BrigInstBase *ib, const BrigObject *obj)
705 unsigned op_offs = obj->getOperandPtr(ib->operands,1);
709 return new LdInst<MemDT, DestDT, NoRegAddrOperand>(ib, obj, "ld");
715 SRegAddrOperand>(ib, obj, "ld");
718 DRegAddrOperand>(ib, obj, "ld");
729 decodeLd(const Brig::BrigInstBase *ib, const BrigObject *obj)
731 unsigned op_offs = obj->getOperandPtr(ib->operands,0);
738 switch (ib->type) {
742 return decodeLd2<MemDT, B32>(ib, obj);
746 return decodeLd2<MemDT, U32>(ib, obj);
750 return decodeLd2<MemDT, S32>(ib, obj);
753 return decodeLd2<MemDT, U32>(ib, obj);
756 dest.regKind, ib->type);
759 switch (ib->type) {
761 return decodeLd2<MemDT, B64>(ib, obj);
763 return decodeLd2<MemDT, U64>(ib, obj);
765 return decodeLd2<MemDT, S64>(ib, obj);
767 return decodeLd2<MemDT, U64>(ib, obj);
770 dest.regKind, ib->type);
774 ib->type);
791 StInstBase(const Brig::BrigInstBase *ib, const BrigObject *obj,
800 if (ib->opcode == BRIG_OPCODE_ST) {
801 const BrigInstMem *ldst = (const BrigInstMem*)ib;
808 unsigned op_offs = obj->getOperandPtr(ib->operands, 0);
816 op_offs = obj->getOperandPtr(ib->operands, 1);
819 const BrigInstAtomic *at = (const BrigInstAtomic*)ib;
826 unsigned op_offs = obj->getOperandPtr(ib->operands, 0);
829 op_offs = obj->getOperandPtr(ib->operands, 1);
962 StInst(const Brig::BrigInstBase *ib, const BrigObject *obj,
965 AddrOperandType>(ib, obj, _opcode),
971 unsigned op_offs = obj->getOperandPtr(ib->operands,srcIdx);
1178 decodeSt(const Brig::BrigInstBase *ib, const BrigObject *obj)
1182 if (ib->opcode == Brig::BRIG_OPCODE_ATOMIC ||
1183 ib->opcode == Brig::BRIG_OPCODE_ATOMICNORET) {
1187 unsigned op_offs = obj->getOperandPtr(ib->operands,destIdx);
1193 NoRegAddrOperand>(ib, obj, "st", srcIdx);
1199 SRegAddrOperand>(ib, obj, "st", srcIdx);
1202 DRegAddrOperand>(ib, obj, "st", srcIdx);
1226 AtomicInstBase(const Brig::BrigInstBase *ib, const BrigObject *obj,
1232 const BrigInstAtomic *at = (const BrigInstAtomic*)ib;
1238 opcode = (BrigOpcode)ib->opcode;
1344 unsigned op_offs = obj->getOperandPtr(ib->operands, 0);
1347 op_offs = obj->getOperandPtr(ib->operands, 1);
1351 op_offs = obj->getOperandPtr(ib->operands, i + 2);
1356 unsigned op_offs = obj->getOperandPtr(ib->operands, 0);
1360 op_offs = obj->getOperandPtr(ib->operands, i + 1);
1466 AtomicInst(const Brig::BrigInstBase *ib, const BrigObject *obj,
1470 (ib, obj, _opcode),
1691 constructAtomic(const Brig::BrigInstBase *ib, const BrigObject *obj)
1693 const Brig::BrigInstAtomic *at = (const Brig::BrigInstAtomic*)ib;
1696 return decodeLd<DataType>(ib, obj);
1698 switch (ib->type) {
1700 return decodeSt<S8,S8>(ib, obj);
1702 return decodeSt<S16,S16>(ib, obj);
1704 return decodeSt<S32,S32>(ib, obj);
1706 return decodeSt<S64,S64>(ib, obj);
1707 default: fatal("AtomicSt: Operand type mismatch %d\n", ib->type);
1710 if ((Brig::BrigOpcode)ib->opcode == Brig::BRIG_OPCODE_ATOMICNORET)
1712 NumSrcOperands, false>(ib, obj, "atomicnoret");
1715 NumSrcOperands, true>(ib, obj, "atomic");
1721 decodeAtomicHelper(const Brig::BrigInstBase *ib, const BrigObject *obj)
1723 unsigned addrIndex = (Brig::BrigOpcode)ib->opcode ==
1726 unsigned op_offs = obj->getOperandPtr(ib->operands,addrIndex);
1732 NumSrcOperands>(ib, obj);
1738 NumSrcOperands>(ib, obj);
1741 NumSrcOperands>(ib, obj);
1753 decodeAtomic(const Brig::BrigInstBase *ib, const BrigObject *obj)
1755 const Brig::BrigInstAtomic *at = (const Brig::BrigInstAtomic*)ib;
1758 return decodeAtomicHelper<DataType, 2>(ib, obj);
1760 return decodeAtomicHelper<DataType, 1>(ib, obj);
1766 decodeAtomicNoRet(const Brig::BrigInstBase *ib, const BrigObject *obj)
1768 const Brig::BrigInstAtomic *at = (const Brig::BrigInstAtomic*)ib;
1770 return decodeAtomicHelper<DataType, 2>(ib, obj);
1772 return decodeAtomicHelper<DataType, 1>(ib, obj);