예제 #1
0
 protected override IEnumerable <TAVerb> RealizeDefault()
 {
     return(_host.TASite.RShift(
                SignalSource.Create(StdLogicVector._0s(_host.DataWidth)),
                SignalSource.Create(StdLogicVector._0s(_host.ShiftWidth)),
                SignalSink.Nil <StdLogicVector>()));
 }
예제 #2
0
 private TAVerb NopVerb()
 {
     return(Verb(ETVMode.Locked,
                 _host.BrP.Dual.Drive(SignalSource.Create <StdLogicVector>("0")),
                 _host.BrN.Dual.Drive(SignalSource.Create <StdLogicVector>("1")),
                 _host.AltAddr.Dual.Drive(SignalSource.Create(StdLogicVector._0s(_host.AddrWidth)))));
 }
예제 #3
0
 public override IEnumerable <TAVerb> DoNothing()
 {
     yield return(Verb(ETVMode.Locked,
                       _brAltFlagP.Drive(SignalSource.Create <StdLogicVector>("0")),
                       _brAltFlagN.Drive(SignalSource.Create <StdLogicVector>("1")),
                       GetNilDriver()));
 }
예제 #4
0
 public IEnumerable <TAVerb> BranchIfNot(ISignalSource <StdLogicVector> cond, BranchLabel target)
 {
     yield return(Verb(ETVMode.Locked,
                       _brAltFlagP.Drive(SignalSource.Create <StdLogicVector>("0")),
                       _brAltFlagN.Drive(cond),
                       GetStateDriver(target)));
 }
예제 #5
0
 protected override IEnumerable <TAVerb> RealizeDefault()
 {
     ISignalSource <StdLogicVector>[] ops = Enumerable.Repeat(
         SignalSource.Create(StdLogicVector._0s(_host.WordWidth)),
         _host.NumWords).ToArray();
     return(_host.TASite.Concat(ops, SignalSink.Nil <StdLogicVector>()));
 }
예제 #6
0
 /// <summary>
 /// Returns a transaction which loads a constant to the specified signal sink.
 /// </summary>
 /// <param name="target">signal sink to receive constant</param>
 public IEnumerable <TAVerb> LoadConstant(ISignalSink <StdLogicVector> target)
 {
     if (_constSignal != null)
     {
         yield return(Verb(ETVMode.Shared, target.Comb.Connect(_constSignal.AsSignalSource <StdLogicVector>())));
     }
     else
     {
         yield return(Verb(ETVMode.Shared, target.Comb.Connect(SignalSource.Create(_constValue))));
     }
 }
예제 #7
0
            public IEnumerable <TAVerb> BranchIfNot(ISignalSource <StdLogicVector> cond, BranchLabel target)
            {
                yield return(Verb(ETVMode.Locked,
                                  _host.BrP.Dual.Drive(SignalSource.Create <StdLogicVector>("0")),
                                  _host.BrN.Dual.Drive(cond),
                                  _host.AltAddr.Dual.Drive(
                                      SignalSource.Create(
                                          StdLogicVector.FromUInt(
                                              (uint)target.CStep, _host.AddrWidth)))));

                for (int i = 1; i < _host.Latency; i++)
                {
                    yield return(NopVerb());
                }
            }
예제 #8
0
파일: LERP.cs 프로젝트: cephdon/systemsharp
 public IEnumerable <TAVerb> DoNothing()
 {
     yield return(new TAVerb(this, ETVMode.Locked, () => { },
                             _host.X.Dual.Drive(SignalSource.Create(StdLogicVector.DCs(_host.XIntWidth + _host.XFracWidth)))));
 }
예제 #9
0
 public override IEnumerable <TAVerb> DoNothing()
 {
     yield return(Verb(ETVMode.Locked,
                       _host.DIn.Dual.Drive(SignalSource.Create(StdLogicVector.DCs(_host.FloatWidth)))));
 }
예제 #10
0
 protected override IEnumerable <TAVerb> RealizeDefault()
 {
     return(_host.TASite.Write(SignalSource.Create(StdLogicVector._0s(_host.DataWidth))));
 }
예제 #11
0
 protected override IEnumerable <TAVerb> RealizeDefault()
 {
     return(_site.Id(SignalSource.Create <StdLogicVector>("0"), SignalSink.Nil <StdLogicVector>()));
 }