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

Added support for 128 bit constants usage in dpdk backend #5074

Merged
merged 2 commits into from
Dec 23, 2024

Conversation

maheswari-s
Copy link
Contributor

Updated testcases and outputs

This PR overwrites the PRs #5009 and #5034

Updated testcases and outputs

This PR overwrites the PR p4lang#5009

Signed-off-by: Maheswari Subramanian <[email protected]>
@maheswari-s
Copy link
Contributor Author

maheswari-s commented Dec 19, 2024

@jafingerhut, @fruffy, @psivanup, I created this PR for DPDK 128Bit constant support as I could not get rid of DCO check fail in another PR #5034. Now, in this PR everything is clean.

Also we did execution test with this change and it works fine. Please review.

@fruffy fruffy added the dpdk Topics related to the DPDK back end label Dec 19, 2024
@@ -26,7 +26,7 @@ p4c_add_xfail_reason("dpdk"
testdata/p4_16_samples/pna-dpdk-invalid-hdr-warnings5.p4
testdata/p4_16_samples/pna-dpdk-invalid-hdr-warnings6.p4
testdata/p4_16_samples/pna-dpdk-header-union-stack2.p4
testdata/p4_16_samples/dash/dash-pipeline-pna-dpdk.p4
testdata/p4_16_dpdk_errors/psa-dpdk-128bitCast_error.p4
Copy link
Contributor

Choose a reason for hiding this comment

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

I thought that for tests in the p4_16_dpdk_errors (and other testdata/*_errors directories), a passing test is when the compiler produces the expected error messages in the output, which you have as part of this PR for psa-dpdk-128bitCast_error.p4, so that is good. But why is it in the list of tests marked as expected to fail? Do DPDK tests use Xfail differently than other p4c test programs?

@jafingerhut
Copy link
Contributor

These expected output files should be removed, as the test program they are for was moved from the errors directory to the samples directory:

  • testdata/p4_16_dpdk_errors_outputs/dash-pipeline-pna-dpdk.p4.bfrt.json
  • testdata/p4_16_dpdk_errors_outputs/dash-pipeline-pna-dpdk.p4-error

@maheswari-s
Copy link
Contributor Author

@jafingerhut, I addressed your comments. Please check now.

Copy link
Contributor

@jafingerhut jafingerhut left a comment

Choose a reason for hiding this comment

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

I have reviewed the new test programs and their expected output files, and they look good to me. It would be nice if P4 DPDK supported arbitrary constant sizes from 1 up to 128 bits and all sizes in between, but supporting 128, and all sizes in the range 1 through 64 bits, is better than not supporting 128-bit values, certainly. I have not attempted to review the C++ parts of the changes, as that is outside of my expertise.

@maheswari-s
Copy link
Contributor Author

@jafingerhut , Thanks for approving. I don't have write access. Could you try to merge this PR?

@jafingerhut
Copy link
Contributor

Given the list of approvers on #5009, where the C++ code changes are (I believe) the same, merging this.

@jafingerhut jafingerhut added this pull request to the merge queue Dec 23, 2024
Merged via the queue into p4lang:main with commit 4005380 Dec 23, 2024
19 checks passed
@maheswari-s maheswari-s deleted the dpdk_128b_const branch January 15, 2025 10:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dpdk Topics related to the DPDK back end
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants