Open DTran0 opened 1 year ago
I think I found the issue:
Due to way get_range()
computes result, uint64_t overflows to zero when max_value=2**64 - 1
and min_value=0
(as uint64_t can't hold 2**64). Some computations in file use division by get_range()
value. This causes division by zero error (or Floating point exception).
I checked this by changing min_value to 1. Then it works and TRex doesn't crash.
You could cap max value to prevent overflow. But then result of get_range()
will be off by one for min/max values provided above. It is probably better solution (when it will be documented in API) than crashing. But I am not familiar with code enough to know if there are any unwanted consequences to this solution.
Hi,
TRex crashes when I try to send packet with Field Engine instructions where I use max uint64_t value (18446744073709551615 or $2^{64}-1$ ). However, TRex works fine when I use $2^{64}-2$ or lower. Documentation of STLVmFlowVar doesn't mention this limitation and uint32_t doesn't have this problem.
TRex version: 3.04 Used NICs: Mellanox ConnectX-5 TRex command:
./t-rex-64 -i --stl
(so trex console can connect) TRex log:To reproduce crash, I am using following code (inspired by scripts in
stl/
directory) and load it via trex console (start -f path_to_script
):