Skip to content

A simple pluggable tool to convert an unrolled TritonAST to LLVM-IR, optimize it and get back to TritonAST.

Notifications You must be signed in to change notification settings

sdancer/TritonASTLLVMIRTranslator

This branch is 3 commits behind fvrmatteo/TritonASTLLVMIRTranslator:master.

Repository files navigation

TritonAST to LLVM-IR and back

This code has been developed as a quick test in a weekend to evaluate how feasible it would have been to use LLVM-IR optimizations to simplify a TritonAST.

The steps are:

  1. getting an unrolled TritonAST;
  2. convert it to LLVM-IR via the TritonAstToLLVMIR function;
  3. get the simplified TritonAST as output with the LLVMIRToTritonAst function.

Inspiration

It's important to note that this is just an experiment to take the Triton + Arybo efforts in converting TritonAST to LLVM-IR a step further. Optimizing an AST is quite useful sometime, especially when attacking obfuscation or opaque predicates.

TODO

  1. Provide a C++ example showing the described steps.
  2. Verify the consistency of all the translations.

About

A simple pluggable tool to convert an unrolled TritonAST to LLVM-IR, optimize it and get back to TritonAST.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • C++ 100.0%