#include "Record.h"
#include "llvm/ADT/StringExtras.h"
#include "llvm/Support/CommandLine.h"
+#include "llvm/Target/TargetInstrInfo.h"
#include <set>
#include <algorithm>
using namespace llvm;
unsigned TIdx = I->getOperandNamed(Name);
if (TIdx >= FIdx)
throw "Illegal tied-to operand constraint '" + CStr + "'";
- return std::make_pair(FIdx, (TIdx << 16) | 1);
+ return std::make_pair(FIdx, (TIdx << 16) |
+ (1 << (unsigned)TargetInstrInfo::TIED_TO));
}
static std::vector<unsigned> parseConstraints(const std::string &CStr,
#include "InstrInfoEmitter.h"
#include "CodeGenTarget.h"
+#include "llvm/Target/TargetInstrInfo.h"
#include "Record.h"
#include <algorithm>
using namespace llvm;
// For backward compatibility: isTwoAddress means operand 1 is tied to
// operand 0.
if (Inst.isTwoAddress)
- Result[1].second |= 1;
+ Result[1].second |= (0 << 16) | (1 << (unsigned)TargetInstrInfo::TIED_TO);
return Result;
}