Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[P4_Symbolic] Adding p4_symbolic/ir/expected/hex_string_transition.txt [Extend IR proto and translation to support parsers] #751

Open
wants to merge 6 commits into
base: main
Choose a base branch
from

Conversation

VSuryaprasad-HCL
Copy link
Contributor

Keyword Check:
~/sonic-buildimage/src/sonic-p4rt/sonic-pins$ ~/tools/keyword_checks.sh .
Keyword check Passed.

Build Result:
/sonic/src/sonic-p4rt/sonic-pins$ bazel build $BAZEL_BUILD_OPTS ...
INFO: Analyzed 590 targets (2 packages loaded, 32 targets configured).
INFO: Found 590 targets...
INFO: From Compiling p4_symbolic/sai/parser.cc:
p4_symbolic/sai/parser.cc: In function 'absl::lts_20230802::StatusOr<std::vectorz3::expr > p4_symbolic::EvaluateSaiParser(const SymbolicPerPacketState&)':
p4_symbolic/sai/parser.cc:70:51: warning: suggest parentheses around '&&' within '||' [-Wparentheses]
70 | constraints.push_back(icmp.valid == (ipv4.valid && ipv4.protocol == 0x01 ||
| ~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~
p4_symbolic/sai/parser.cc:72:50: warning: suggest parentheses around '&&' within '||' [-Wparentheses]
72 | constraints.push_back(tcp.valid == (ipv4.valid && ipv4.protocol == 0x06 ||
| ~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~
p4_symbolic/sai/parser.cc:74:50: warning: suggest parentheses around '&&' within '||' [-Wparentheses]
74 | constraints.push_back(udp.valid == (ipv4.valid && ipv4.protocol == 0x11 ||
| ~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~
INFO: From Compiling p4_symbolic/tests/sai_p4_component_test.cc:
In file included from p4_symbolic/tests/sai_p4_component_test.cc:22:
p4_symbolic/tests/sai_p4_component_test.cc: In member function 'virtual void p4_symbolic::{anonymous}::P4SymbolicComponentTest_CanGenerateTestPacketsForSimpleSaiP4Entries_Test::TestBody()':
p4_symbolic/tests/sai_p4_component_test.cc:128:32: warning: 'absl::lts_20230802::StatusOrp4::v1::TableEntry pdpi::PartialPdTableEntryToPiTableEntry(const pdpi::IrP4Info&, const google::protobuf::Message&, const pdpi::TranslationOptions&)' is deprecated: Use PdTableEntryToPiEntity instead [-Wdeprecated-declarations]
128 | pdpi::PartialPdTableEntryToPiTableEntry(ir_p4info, pd_entry));
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
./gutil/status_matchers.h:64:43: note: in definition of macro 'ASSERT_OK_AND_ASSIGN'
INFO: From Executing genrule //p4_symbolic/symbolic:port_table_test_test_runner:
Finding packet for table MyIngress.ports_exact and row -1
Cannot find solution!

Finding packet for table MyIngress.ports_exact and row 0
Dropped = 0
standard_metadata.ingress_port = #b000000000
standard_metadata.egress_spec = #b000000001

Finding packet for table MyIngress.ports_exact and row 1
Dropped = 0
standard_metadata.ingress_port = #b000000001
standard_metadata.egress_spec = #b000000000

INFO: Elapsed time: 64.294s, Critical Path: 53.07s
INFO: 14 processes: 1 internal, 13 linux-sandbox.
INFO: Build completed successfully, 14 total actions

Test Result:
/sonic/src/sonic-p4rt/sonic-pins$ bazel test $BAZEL_BUILD_OPTS --cache_test_results=no ...
INFO: Analyzed 590 targets (0 packages loaded, 350 targets configured).
INFO: Found 396 targets and 194 test targets...
INFO: Elapsed time: 230.871s, Critical Path: 115.29s
INFO: 248 processes: 292 linux-sandbox, 18 local.
INFO: Build completed successfully, 248 total actions
//dvaas:port_id_map_test PASSED in 0.6s
//dvaas:test_vector_stats_diff_test PASSED in 0.1s
//dvaas:test_vector_stats_test PASSED in 1.3s
//dvaas:test_vector_test PASSED in 0.6s
//gutil:collections_test PASSED in 0.7s
//gutil:io_test PASSED in 0.5s
//gutil:proto_matchers_test PASSED in 0.7s
//gutil:proto_ordering_test PASSED in 0.7s
//gutil:proto_test PASSED in 0.8s
//sai_p4/instantiations/google/test_tools:table_entry_generator_helper_test PASSED in 13.6s
//sai_p4/instantiations/google/test_tools:test_entries_test PASSED in 1.0s
//sai_p4/instantiations/google/tests:p4_fuzzer_integration_test PASSED in 5.9s
//sai_p4/tools:p4info_tools_test PASSED in 2.3s
//sai_p4/tools:packetio_tools_test PASSED in 2.9s
//tests:thinkit_gnmi_interface_util_tests PASSED in 3.9s
//tests/qos:gnmi_parsers_test PASSED in 4.8s
//tests/qos:gnmi_parsers_test_runner PASSED in 0.7s
//thinkit:bazel_test_environment_test PASSED in 0.7s
//thinkit:generic_testbed_test PASSED in 4.3s
//thinkit:mock_control_device_test PASSED in 0.9s
//thinkit:mock_generic_testbed_test PASSED in 0.9s
//thinkit:mock_mirror_testbed_test PASSED in 1.0s
//thinkit:mock_ssh_client_test PASSED in 2.6s
//thinkit:mock_switch_test PASSED in 0.8s
//thinkit:mock_test_environment_test PASSED in 0.2s
//thinkit:switch_test PASSED in 1.5s
//sai_p4/instantiations/google/tests:p4_constraints_integration_test PASSED in 1.4s
Stats over 5 runs: max = 1.4s, min = 0.7s, avg = 0.9s, dev = 0.3s
//sai_p4/instantiations/google/test_tools:table_entry_generator_test PASSED in 44.7s
Stats over 50 runs: max = 44.7s, min = 0.8s, avg = 4.2s, dev = 10.2s

Executed 194 out of 194 tests: 194 tests pass.
INFO: Build completed successfully, 248 total actions

@VSuryaprasad-HCL
Copy link
Contributor Author

Co-authored-by: Srikishen Pondicherry Shanmugam [email protected]

Copy link
Contributor

@bibhuprasad-hcl bibhuprasad-hcl left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@kishanps, Could you please review.
Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants