Jump to content
Khushi

BUSWIDTH template with TLM2 sockets

Recommended Posts

Hello All

I have a confusion regarding the BUSWIDTH template with TLM2 sockets.

In TLM sockets e.g. tlm_initiator_socket/simple_target_socket, why we have BUSWIDTH template and what is the need for this.
If I want to transfer 256 bit data from an initiator (with tlm_initiator_socket port on it) to a target (with tlm_target_socket port on it), I can do it in one go by setting the data length and data pointer payload fields appropriately irrespective of the BUSWIDTH template.


Whether I use BUSWIDTH 1 or 8 or 16 or 32 and so on, I can still call the b_transport and transfer the data in one go.


So what is the significance of this BUSWIDTH template parameter.
Where it is actually makes a difference.

Thanks
Khushi

 

Share this post


Link to post
Share on other sites

If you are calculating the timing of the transfer, it makes a difference as to how much data is received in a single clock. 8-bytes on a byte-wide interface is eight times slower than a 64-bit interface. It's all about modeling. For Loosely-Timed models, it may not make as much difference since time is less important.

It also has application when considering endianess.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×