2001-06-06 20:29:01 +00:00
|
|
|
//===-- llvm/iBinary.h - Binary Operator node definitions --------*- C++ -*--=//
|
|
|
|
//
|
|
|
|
// This file contains the declarations of all of the Binary Operator classes.
|
|
|
|
//
|
|
|
|
//===----------------------------------------------------------------------===//
|
|
|
|
|
|
|
|
#ifndef LLVM_IBINARY_H
|
|
|
|
#define LLVM_IBINARY_H
|
|
|
|
|
|
|
|
#include "llvm/InstrTypes.h"
|
|
|
|
|
2001-07-08 04:57:15 +00:00
|
|
|
//===----------------------------------------------------------------------===//
|
|
|
|
// Class to represent Unary operators
|
|
|
|
//===----------------------------------------------------------------------===//
|
|
|
|
//
|
|
|
|
class GenericUnaryInst : public UnaryOperator {
|
|
|
|
public:
|
2002-01-20 22:54:45 +00:00
|
|
|
GenericUnaryInst(UnaryOps Opcode, Value *S1, const std::string &Name = "")
|
2001-07-08 19:03:27 +00:00
|
|
|
: UnaryOperator(S1, Opcode, Name) {
|
2001-07-08 04:57:15 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
virtual const char *getOpcodeName() const;
|
|
|
|
};
|
|
|
|
|
2001-06-06 20:29:01 +00:00
|
|
|
//===----------------------------------------------------------------------===//
|
|
|
|
// Classes to represent Binary operators
|
|
|
|
//===----------------------------------------------------------------------===//
|
|
|
|
//
|
|
|
|
// All of these classes are subclasses of the BinaryOperator class...
|
|
|
|
//
|
|
|
|
|
2001-06-27 23:28:50 +00:00
|
|
|
class GenericBinaryInst : public BinaryOperator {
|
2001-06-06 20:29:01 +00:00
|
|
|
public:
|
2001-07-07 20:17:23 +00:00
|
|
|
GenericBinaryInst(BinaryOps Opcode, Value *S1, Value *S2,
|
2002-01-20 22:54:45 +00:00
|
|
|
const std::string &Name = "")
|
2001-06-27 23:28:50 +00:00
|
|
|
: BinaryOperator(Opcode, S1, S2, Name) {
|
2001-06-06 20:29:01 +00:00
|
|
|
}
|
|
|
|
|
2001-07-07 19:24:15 +00:00
|
|
|
virtual const char *getOpcodeName() const;
|
2001-06-06 20:29:01 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
class SetCondInst : public BinaryOperator {
|
|
|
|
BinaryOps OpType;
|
|
|
|
public:
|
|
|
|
SetCondInst(BinaryOps opType, Value *S1, Value *S2,
|
2002-01-20 22:54:45 +00:00
|
|
|
const std::string &Name = "");
|
2001-06-06 20:29:01 +00:00
|
|
|
|
2001-07-07 19:24:15 +00:00
|
|
|
virtual const char *getOpcodeName() const;
|
2001-06-06 20:29:01 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
#endif
|