summaryrefslogtreecommitdiffstats
path: root/src/gtest
diff options
context:
space:
mode:
authorHanoh Haim <hhaim@cisco.com>2015-12-13 17:39:29 +0200
committerHanoh Haim <hhaim@cisco.com>2015-12-13 17:39:29 +0200
commitcfa180dc11bc06eb22f24f859abb06173061e174 (patch)
tree05ff90876dd33c646eb726420cdd0e501f7bd62f /src/gtest
parentbc6ecb17ed3cce705f08d9b7f676de9e6fbf8c77 (diff)
add commands
Diffstat (limited to 'src/gtest')
-rw-r--r--src/gtest/trex_stateless_gtest.cpp9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/gtest/trex_stateless_gtest.cpp b/src/gtest/trex_stateless_gtest.cpp
index 02e84c0f..57e42092 100644
--- a/src/gtest/trex_stateless_gtest.cpp
+++ b/src/gtest/trex_stateless_gtest.cpp
@@ -61,17 +61,24 @@ TEST_F(basic_vm, vm1) {
StreamVm vm;
- vm.add_instruction( new StreamVmInstructionFixChecksumIpv4(14) );
vm.add_instruction( new StreamVmInstructionFlowMan( "var1",1,
StreamVmInstructionFlowMan::FLOW_VAR_OP_INC,0,1,7 )
);
vm.add_instruction( new StreamVmInstructionWriteToPkt( "var1",26, 0,true)
);
+ vm.add_instruction( new StreamVmInstructionFixChecksumIpv4(14) );
vm.set_packet_size(128);
vm.compile_next();
+
+ uint32_t program_size=vm.get_dp_instruction_buffer()->get_program_size();
+ printf (" program size : %lu \n",(ulong)program_size);
+
+
+ vm.Dump(stdout);
+
}