Example #1
0
 public MetricComparisonSpec(MetricKind Baseline, MetricKind Bench, PrimalKind Primitive, OpKind Operator)
 {
     this.BaseKind  = Baseline;
     this.BenchKind = Bench;
     this.Primitive = Primitive;
     this.Operator  = Operator;
 }
Example #2
0
 public static OpId OpId(this OpKind op,
                         NumericSystem system,
                         PrimalKind prim,
                         NumericKind numKind = NumericKind.Native,
                         Genericity generic  = Genericity.Direct,
                         OpFusion fusion     = OpFusion.Atomic,
                         string title        = null)
 => new OpId(system, op, prim, numKind, generic, fusion, title);
Example #3
0
 public OpId(NumericSystem NumSystem, OpKind OpKind, PrimalKind OperandKind, NumericKind NumKind, Genericity Generic, OpFusion Fusion, string OpTitle)
 {
     this.NumSystem   = NumSystem;
     this.OpKind      = OpKind;
     this.OperandType = OperandKind;
     this.NumKind     = NumKind;
     this.Generic     = Generic;
     this.Fusion      = Fusion;
     this.OpTitle     = ifEmpty(OpTitle, OpId.DefineOpTitle(this));
     this.OpUri       = BuildOpUri(this);
 }
Example #4
0
 public MetricSpec(OpKind OpKind, NumericSystem NumSystem, NumericKind NumKind, PrimalKind OperandType,
                   OpVariance Variance, ByteSize OperandSize)
 {
     this.OpKind      = OpKind;
     this.NumSystem   = NumSystem;
     this.NumKind     = NumKind;
     this.OperandType = OperandType;
     this.Variance    = Variance;
     this.OperandSize = OperandSize;
 }
Example #5
0
 public static MetricSpec Define(OpKind OpKind, NumericSystem NumSystem, NumericKind NumKind,
                                 PrimalKind OperandType, OpVariance Variance, ByteSize OperandSize)
 => new MetricSpec(OpKind, NumSystem, NumKind, OperandType, Variance, OperandSize);
Example #6
0
 public static MetricComparisonSpec DefineComparison(this MetricKind Baseline, MetricKind Bench, PrimalKind Primitive, OpKind Operator)
 => MetricComparisonSpec.Define(Baseline, Bench, Primitive, Operator);
Example #7
0
 public static void Deconstruct(this MetricId metric, out MetricKind Classifier, out PrimalKind Primitive, out OpKind Operator)
 {
     Classifier = metric.Classifier;
     Primitive  = metric.Primitive;
     Operator   = metric.Operator;
 }
Example #8
0
 public static MetricId Identify(this MetricKind metric, PrimalKind primitive, OpKind op)
 => MetricId.Define(metric, primitive, op);
Example #9
0
File: OpSig.cs Project: 0xCM/arrows
 public ParamSig(int Position, PrimalKind DataType, ParamVariance Variance)
 {
     this.Position  = Position;
     this.Primitive = DataType;
     this.Variance  = Variance;
 }
Example #10
0
File: OpSig.cs Project: 0xCM/arrows
 public static ParamSig Create(int pos, PrimalKind dataType, ParamVariance?variance = null)
 => new ParamSig(pos, dataType, variance ?? ParamVariance.Value);
Example #11
0
 public static MetricId Define(MetricKind Classifier, PrimalKind Primitive, OpKind Operator)
 => new MetricId(Classifier, Primitive, Operator);
Example #12
0
 public static MetricComparisonSpec Define(MetricKind Baseline, MetricKind Bench, PrimalKind Primitive, OpKind Operator)
 => new MetricComparisonSpec(Baseline, Bench, Primitive, Operator);
Example #13
0
 public static MetricComparisonSpec Define <T>(MetricKind Baseline, MetricKind Bench, PrimalKind Primitive, OpKind Operator)
     where T : struct
 => new MetricComparisonSpec(Baseline, Bench, PrimalKinds.kind <T>(), Operator);
Example #14
0
 public static OpType WithType(this OpKind src, PrimalKind prim)
 => OpType.Define(src, prim);