Bytepeep
Minimal bytecode peephole optimizer
Install / Use
/learn @kadenzipfel/BytepeepREADME
Bytepeep •

Bytecode in, optimized bytecode out.
About
Bytepeep is a minimal bytecode peephole optimizer. Like any other peephole optimizer, it works by passing pairs of opcodes, peepholes, through a pattern matching algorithm to be checked against a set of rules and optimized if possible.

This is not intended as a replacement for solidity's built-in optimizers. Rather it should serve as a quick and easy tool for low-level smart contract development.
Installation
Install Rust & Cargo:
curl https://sh.rustup.rs -sSf | sh
Install bytepeep:
cargo install bytepeep
Run:
bytepeep <bytecode>
Todo
Contributions welcome!
- [ ] Handle multi-variable rules, (stack/memory dependent)
- [ ] Reassign jumps
- [ ] Handle different inputs
- [ ] Mnemonics
- [x] Huff
- [ ] Return tips along with optimized bytecode
Disclaimer
This is experimental software and is provided on an "as is" and "as available" basis. We do not give any warranties and will not be liable for any loss incurred through any use of this codebase.
Related Skills
node-connect
346.4kDiagnose OpenClaw node connection and pairing failures for Android, iOS, and macOS companion apps
frontend-design
107.2kCreate distinctive, production-grade frontend interfaces with high design quality. Use this skill when the user asks to build web components, pages, or applications. Generates creative, polished code that avoids generic AI aesthetics.
openai-whisper-api
346.4kTranscribe audio via OpenAI Audio Transcriptions API (Whisper).
qqbot-media
346.4kQQBot 富媒体收发能力。使用 <qqmedia> 标签,系统根据文件扩展名自动识别类型(图片/语音/视频/文件)。
