-
Notifications
You must be signed in to change notification settings - Fork 5
LoongArch: BPF: Optimize sign-extention mov instructions #5817
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
LoongArch: BPF: Optimize sign-extention mov instructions #5817
Conversation
|
Upstream branch: f4c227c |
3a9c841 to
f4881a6
Compare
|
Upstream branch: d0f27ff |
e40c621 to
cbad2ba
Compare
f4881a6 to
8f9c214
Compare
|
Upstream branch: 2465bb8 |
cbad2ba to
2148a57
Compare
|
Upstream branch: 2465bb8 |
2148a57 to
2069d09
Compare
8f9c214 to
c9c941d
Compare
|
Upstream branch: 2660b9d |
2069d09 to
6b0c1ee
Compare
c9c941d to
c640618
Compare
|
Upstream branch: d3abefe |
6b0c1ee to
e34e44a
Compare
c640618 to
721f1da
Compare
|
Upstream branch: 4c229f3 |
For 8-bit and 16-bit sign-extention mov instructions, it can use the native instructions ext.w.b and ext.w.h directly, no need to use the temporary t1 register, just remove the redundant operations. Here are the test results: # modprobe test_bpf test_range=81,84 # dmesg -t | tail -5 test_bpf: #81 ALU_MOVSX | BPF_B jited:1 5 PASS test_bpf: #82 ALU_MOVSX | BPF_H jited:1 5 PASS test_bpf: #83 ALU64_MOVSX | BPF_B jited:1 5 PASS test_bpf: #84 ALU64_MOVSX | BPF_H jited:1 5 PASS test_bpf: Summary: 4 PASSED, 0 FAILED, [4/4 JIT'ed] Signed-off-by: Tiezhu Yang <[email protected]> Acked-by: Hengqi Chen <[email protected]>
e34e44a to
c2d81b4
Compare
721f1da to
c2e9835
Compare
|
At least one diff in series https://patchwork.kernel.org/project/netdevbpf/list/?series=995518 irrelevant now. Closing PR. |
Pull request for series with
subject: LoongArch: BPF: Optimize sign-extention mov instructions
version: 1
url: https://patchwork.kernel.org/project/netdevbpf/list/?series=995518