X-Git-Url: http://demsky.eecs.uci.edu/git/?a=blobdiff_plain;f=utils%2FTableGen%2FCodeGenIntrinsics.h;h=1170da0f35994fc0a25efd1ea3989baf7091e405;hb=65ee1e6ff4d82f58fbea5c2e5cadf9a0be797955;hp=a66c30b6cb89cc7d3758a18322b5bf3a3e76c790;hpb=83ec4b6711980242ef3c55a4fa36b2d7a39c1bfb;p=oota-llvm.git diff --git a/utils/TableGen/CodeGenIntrinsics.h b/utils/TableGen/CodeGenIntrinsics.h index a66c30b6cb8..1170da0f359 100644 --- a/utils/TableGen/CodeGenIntrinsics.h +++ b/utils/TableGen/CodeGenIntrinsics.h @@ -30,16 +30,34 @@ namespace llvm { std::string GCCBuiltinName;// Name of the corresponding GCC builtin, or "". std::string TargetPrefix; // Target prefix, e.g. "ppc" for t-s intrinsics. - /// ArgVTs - The MVT::SimpleValueType for each argument type. Note that - /// this list is only populated when in the context of a target .td file. - /// When building Intrinsics.td, this isn't available, because we don't know - /// the target pointer size. - std::vector ArgVTs; - - /// ArgTypeDefs - The records for each argument type. - /// - std::vector ArgTypeDefs; - + /// IntrinsicSignature - This structure holds the return values and + /// parameter values of an intrinsic. If the number of return values is > 1, + /// then the intrinsic implicitly returns a first-class aggregate. The + /// numbering of the types starts at 0 with the first return value and + /// continues from there throug the parameter list. This is useful for + /// "matching" types. + struct IntrinsicSignature { + /// RetVTs - The MVT::SimpleValueType for each return type. Note that this + /// list is only populated when in the context of a target .td file. When + /// building Intrinsics.td, this isn't available, because we don't know + /// the target pointer size. + std::vector RetVTs; + + /// RetTypeDefs - The records for each return type. + std::vector RetTypeDefs; + + /// ParamVTs - The MVT::SimpleValueType for each parameter type. Note that + /// this list is only populated when in the context of a target .td file. + /// When building Intrinsics.td, this isn't available, because we don't + /// know the target pointer size. + std::vector ParamVTs; + + /// ParamTypeDefs - The records for each parameter type. + std::vector ParamTypeDefs; + }; + + IntrinsicSignature IS; + // Memory mod/ref behavior of this intrinsic. enum { NoMem, ReadArgMem, ReadMem, WriteArgMem, WriteMem @@ -49,6 +67,10 @@ namespace llvm { // types. bool isOverloaded; + // isCommutative - True if the intrinsic is commutative. + // + bool isCommutative; + CodeGenIntrinsic(Record *R); };