Vector35 / Vector35/binaryninja-api
PPC Switch Case identification
Open
Nobody has claimed this yet.
Arch: PowerPC
Component: Architecture
Component: Core
Effort: Medium
Impact: Medium
- Dominant language
- C++
- Stars
- 1.3k
- Forks
- 298
- Avg merge
- 5d 5h
- Merged PRs (30d)
- 19
Description
I'm looking at some PPC code that has a curious location-agnostic switch case style using the link register that seems to prevent correct detection and identification of the switch
bl <next instruction>
slwi r11, r26, 2
mflr r12
addi r11, r11, 0x18
add r11, r11, r12
mtctr r11
bctr
<table of branch instructions>
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the PPC switch pattern shown in the issue and trace how switch cases are detected and identified. Done means this link-register-based, location-agnostic pattern is correctly recognized as a switch rather than missed.
Written by the indexing model from the issue text.
Assessment
- Domain
- reverse-engineering
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100