[llvm-dev] Is there a python binding, or any other script binding, that has access to individual instructions?

Matt P. Dziubinski via llvm-dev llvm-dev at lists.llvm.org
Mon Jan 1 08:18:16 PST 2018


Hi,

On 1/1/2018 07:26, Yuri via llvm-dev wrote:
> I was thinking to make a simple code analysis tool to, for example, 
> find all system calls that have unchecked return codes, but I can't 
> find a binding for any scripting language. And I am averse to writing 
> this in C++.
One possible choice would be llvmcpy -- Python bindings used by the 
rev.ng (https://rev.ng/) project:
https://github.com/revng/llvmcpy

Here's an example showing syscalls invocations tracing:
https://github.com/revng/revamb/blob/master/docs/PythonExample.rst#tracing-all-the-syscall-invocations

Best,
Matt


More information about the llvm-dev mailing list