Packing Macros

UVMkit » 1800.2-2020

The packing macros are implemented as described in section B.2.4 of the 1800.2 specification.

The Accellera implementation adds an additional PACKER argument to these macros with a default value of ‘packer’.  This allows the macros to be used in environments with alternative packer names.

For example, <`uvm_pack_intN> is defined in the LRM as

`define uvm_pack_intN(VAR,SIZE)

Whereas the implementation is

`define uvm_pack_intN(VAR,SIZE,PACKER=packer)

This allows for usage such as

function void pack_foo( uvm_packer other_packer );
  `uvm_pack_intN(foo, 32, other_packer)
endfunction : pack_foo

@uvm-contrib This API is being considered for potential contribution to 1800.2

Summary
Packing Macros
The packing macros are implemented as described in section B.2.4 of the 1800.2 specification.