rahuljn Posted April 14, 2015 Report Share Posted April 14, 2015 Hi Guys,I am a bit confused on the primitive and hierarchical channelIn primitive channels we have request-update/update but not in hierarchical channel.Is it mandatory to have request-update/update for primitive channels ? Why ?Why it is not needed for hierarchical channel ThanksRahulJn Quote Link to comment Share on other sites More sharing options...
apfitch Posted April 14, 2015 Report Share Posted April 14, 2015 A channel is simply a class that implements a SystemC interface. A primitive channel implements an interface and is derived from from sc_prim_channel, and can thus have access to the scheduler (evaluate update). A hierarchical channel implements an interface and is derived from sc_module, and can thus have all the features of an sc_module (processes, hierarchy etc). There'd be no point in deriving from sc_prim_channel and then not implementing the update/request-update behaviour. If you want a channel that is not a primitive channel, and is not a hierarchical channel, you would typically implement an interface but derive from sc_object. regards Alan P.S. To answer your questions more specifically - request_update and update are not pure virtual, so you could ignore them. Though why would you ignore them? If you don't want them, derive from sc_object instead. A hierarchical channel is derived from sc_module. sc_module does not have request_update/update, so you can't use them. amitk3553 and Mstones 2 Quote Link to comment Share on other sites More sharing options...
David Black Posted April 16, 2015 Report Share Posted April 16, 2015 It is worth noting that a hierarchical channel is really just an sc_module that implements an sc_interface. It's purpose is for creating complex abstract channels (e.g. PCIe or AXI). Primitive channels are for smaller (primitive) transfers such as wires (i.e. sc_signal<>). amitk3553 1 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.