Skip to content

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

License

Notifications You must be signed in to change notification settings

sh4m2hwz/triton_ast_llvm_ir_translator

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

it is fork from https://github.com/fvrmatteo/TritonASTLLVMIRTranslator

*WARNINGS: tested only linux(ubuntu 20.04) and only llvm and clang version 10*

how to compile lib?
`
clang -fPIC -shared Translator.cpp `llvm-config-10 --ldflags --cxxflags --libs core --system-libs`  -lboost_system -L<path to boost libraries> -ltriton -L <path to triton> -lcapstone -L<path to capstone> -o libtransTritonLLVM.so

by sample cmd:

clang -fPIC -shared Translator.cpp `llvm-config-10 --ldflags --cxxflags --libs core --system-libs`  -lboost_system -L/usr/lib/x86_64-linux-gnu -ltriton -L/home/user/Triton/build/src/ -lcapstone -L/home/user/capstone/build -o libtransTritonLLVM.so
`

how to compile C++ sample?
`
clang main.cpp `llvm-config-10 --ldflags --cxxflags --libs core --system-libs` -lboost_system -L<path to boost> -ltriton -L<path to triton> -ltransTritonLLVM -L<path to libtransTritonLLVM.so> -lstdc++ -o main

by example:
clang main.cpp `llvm-config-10 --ldflags --cxxflags --libs core --system-libs` -lboost_system -L/usr/lib/x86_64-linux-gnu -ltriton -L/home/user/Triton/build/src/ -ltransTritonLLVM -L /home/user/TritonASTLLVMIRTranslator/ -lstdc++ -o main
`

how to run C++ sample?
`
 LD_LIBRARY_PATH=<absolute path to libtransTritonLLVM.so> ./main
by example:
 LD_LIBRARY_PATH=/home/user/TritonASTLLVMIRTranslator/ ./main
`

About

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

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages