// FIXME: This should be a property of the target so that more than one target
// at a time can be active...
//
-namespace {
+namespace llvm {
extern const TargetInstrDescriptor *TargetInstrDescriptors;
}
void
MachineInstr::SetMachineOperandConst(unsigned i,
MachineOperand::MachineOperandType opTy,
- int64_t intValue) {
+ int intValue) {
assert(i < getNumOperands()); // must be explicit op
assert(TargetInstrDescriptors[Opcode].resultPos != (int) i &&
"immed. constant cannot be defined");
static inline void OutputReg(std::ostream &os, unsigned RegNo,
const MRegisterInfo *MRI = 0) {
- if (MRegisterInfo::isPhysicalRegister(RegNo)) {
+ if (!RegNo || MRegisterInfo::isPhysicalRegister(RegNo)) {
if (MRI)
os << "%" << MRI->get(RegNo).Name;
else
OS << "\n";
}
+namespace llvm {
std::ostream &operator<<(std::ostream &os, const MachineInstr &MI) {
// If the instruction is embedded into a basic block, we can find the target
// info for the instruction.
return OS;
}
+}