Skip to content

Commit

Permalink
Remove tests for MOVSX with immediate (#186)
Browse files Browse the repository at this point in the history
Per latest discussion on the mailing list at
https://mailarchive.ietf.org/arch/msg/bpf/uQiqhURdtxV_ZQOTgjCdm-seh74/
the MOVSX operation is only defined to support register extension.

Signed-off-by: Dave Thaler <[email protected]>
Co-authored-by: Alan Jowett <[email protected]>
  • Loading branch information
dthaler and Alan-Jowett authored Jan 22, 2024
1 parent a2799c0 commit e473aec
Show file tree
Hide file tree
Showing 6 changed files with 1 addition and 41 deletions.
7 changes: 1 addition & 6 deletions src/opcode_names.h
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ inline bool
needs_offset(uint8_t opcode)
{
return opcode == 0x34 || opcode == 0x37 || opcode == 0x3c || opcode == 0x3f || opcode == 0x94 || opcode == 0x97 ||
opcode == 0x9c || opcode == 0x9f || opcode == 0xb4 || opcode == 0xb7 || opcode == 0xbc || opcode == 0xbf;
opcode == 0x9c || opcode == 0x9f || opcode == 0xbc || opcode == 0xbf;
}

class bpf_conformance_instruction_t
Expand Down Expand Up @@ -309,14 +309,9 @@ static const std::set<bpf_conformance_instruction_t, InstCmp> instructions_from_
{bpf_conformance_test_cpu_version_t::v3, 0xae},
{bpf_conformance_test_cpu_version_t::v1, 0xaf},
{bpf_conformance_test_cpu_version_t::v1, 0xb4, 0x00, 0x00, 0x00},
{bpf_conformance_test_cpu_version_t::v4, 0xb4, 0x00, 0x00, 0x08},
{bpf_conformance_test_cpu_version_t::v4, 0xb4, 0x00, 0x00, 0x10},
{bpf_conformance_test_cpu_version_t::v2, 0xb5},
{bpf_conformance_test_cpu_version_t::v3, 0xb6},
{bpf_conformance_test_cpu_version_t::v1, 0xb7, 0x00, 0x00, 0x00},
{bpf_conformance_test_cpu_version_t::v4, 0xb7, 0x00, 0x00, 0x08},
{bpf_conformance_test_cpu_version_t::v4, 0xb7, 0x00, 0x00, 0x10},
{bpf_conformance_test_cpu_version_t::v4, 0xb7, 0x00, 0x00, 0x20},
{bpf_conformance_test_cpu_version_t::v1, 0xbc, 0x00, 0x00, 0x00},
{bpf_conformance_test_cpu_version_t::v4, 0xbc, 0x00, 0x00, 0x08},
{bpf_conformance_test_cpu_version_t::v4, 0xbc, 0x00, 0x00, 0x10},
Expand Down
7 changes: 0 additions & 7 deletions tests/movsx1632-imm.data

This file was deleted.

7 changes: 0 additions & 7 deletions tests/movsx1664-imm.data

This file was deleted.

7 changes: 0 additions & 7 deletions tests/movsx3264-imm.data

This file was deleted.

7 changes: 0 additions & 7 deletions tests/movsx832-imm.data

This file was deleted.

7 changes: 0 additions & 7 deletions tests/movsx864-imm.data

This file was deleted.

0 comments on commit e473aec

Please sign in to comment.