From UVMC 2.2 /examples/field_types
Supported Data Types
The following types are supported by UVMC for packing and unpacking via the streaming operators.
SV |---- SC
longint ---- long long
int |---- int
shortint |---- short
byte | --- char
bit |---- bool
longint unsigned |---- unsigned long long
int unsigned |---- unsigned int
shortint unsigned | --- unsigned short
byte unsigned |---- unsigned char
bit unsigned |---- bool
shortreal |---- float
real |---- double
string |---- string
time | --- sc_time
T |---- T
T arr[N] |---- T arr[N];
T q[$] |---- vector<T>
T da[] |---- list<T>
T aa[KEY] | --- map<KEY,T>
sc_bit |---- sc_bit
sc_logic |---- sc_logic
sc_lv [L:R] |---- sc_lv<N>
sc_bv [L:R] |---- sc_bv<N>
bit [N-1:0] |---- sc_int<N>
bit [N-1:0] |---- sc_uint<N>
bit [N-1:0] |---- sc_bigint<N>
bit [N-1:0] |- -- sc_biguint<N>
In UVM side i have used real D[$], to declare queue of real numbers. and on SystemC vector.
For packing i am using uvm_pack_queue an unpacking uvm_unpack_queue.
When i print it in UVM side it prints the correct values, but after packing and unpacking, on SystemC side it prints the integral value of the real number.
Same is true, when i pass queue of real numbers from SystemC to UVM(it prints junk values).
As the above table suggest, pack/unpack of queue of real numbers should be possible, as data types of both the language are satisfied.