Rust tools for PowerPC 750CL
Go to file
Richard Patel fd94a6c493 fuzz: add threads flag 2022-04-07 06:11:03 +02:00
.github/workflows Fix CI 2021-08-17 01:21:08 +02:00
disasm bump version to 0.2.0 2022-04-07 05:45:01 +02:00
disasm-py disasm-py: add opcode getter 2022-04-07 06:01:25 +02:00
dol switch from macro to ahead-of-time generated code 2022-04-06 15:13:55 +02:00
flow-graph bump version to 0.2.0 2022-04-07 05:45:01 +02:00
fuzz fuzz: add threads flag 2022-04-07 06:11:03 +02:00
genisa fuzz: add threads flag 2022-04-07 06:11:03 +02:00
rand bump version to 0.2.0 2022-04-07 05:45:01 +02:00
.gitignore Read from DOL 2021-08-22 04:09:51 +02:00
Cargo.lock fuzz: add threads flag 2022-04-07 06:11:03 +02:00
Cargo.toml disasm-py: temporarily remove field accessors 2022-04-07 05:40:22 +02:00
LICENSE Create LICENSE 2021-08-14 10:18:38 +02:00
README.md document Python module 2022-04-07 05:58:09 +02:00
isa.yaml more flexible modifier handling 2022-04-07 05:33:38 +02:00

README.md

ppc750cl

Rust tools for working with the PowerPC 750CL family of processors.

Rust crates

rustup components add rustfmt
cargo run --package ppc750cl-genisa
cargo build --release

Python module

python -m venv env
source ./env/bin/activate
pip install maturin
maturin build -m ./disasm-py/Cargo.toml

Install module in dev env

maturin develop -m ./disasm-py/Cargo.toml
python
>>> import ppc750cl
>>> str(ppc750cl.Ins(addr=0x80006969, code=0x10400420))
'ps_merge00 f2, f0, f0'

Instruction Set

For those unfamiliar with PowerPC, here are some basics.

  • PowerPC 7xx is a family of RISC CPUs produced from 1997 to 2012.
    • They operate with 32-bit words and every instruction is 32-bits wide.
  • This project focuses (only) on compatibility with the PowerPC 750CL.
    • This chip is famously packaged as codename "Broadway" for the Nintendo Wii.
    • Its predecessor PowerPC 750CXe is used in the Nintendo GameCube.
    • It adds a "paired-singles" SIMD unit and a bunch of other instructions.

isa.yaml

The file isa.yaml contains a full definition of the PowerPC 750CL instruction set.

It powers the disassembler, assembler, and Rust/Python bindings code analysis tools.

Similarly to LLVM TableGen, the program ppc750cl-genisa generates a Rust file implementing an instruction decoder.