GcdUnitFL.py 文件源码

python
阅读 21 收藏 0 点赞 0 评论 0

项目:ece5745-sec-pymtl-cl 作者: cornell-ece5745 项目源码 文件源码
def __init__( s ):

    # Interface

    s.req    = InValRdyBundle  ( GcdUnitReqMsg() )
    s.resp   = OutValRdyBundle ( Bits(16)        )

    # Adapters

    s.req_q  = InValRdyQueueAdapter  ( s.req  )
    s.resp_q = OutValRdyQueueAdapter ( s.resp )

    # Concurrent block

    @s.tick_fl
    def block():
      req_msg = s.req_q.popleft()
      result = gcd( req_msg.a, req_msg.b )
      s.resp_q.append( result )

  # Line tracing
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号