I’ll have couple of python functions I must interface with from the assembly code. The solution doesn’t need to be a complete solution because I’m not going to interface with python code for too long. Anyway, I chewed it a bit:
- What does a python object look like in memory?
- How can I call a python function?
- How can I pass python objects as python objects for ctypes interface?
- Could ctypes interface make my work easier in any alternative way?
You will want to read and understand Extending and Embedding the Python Interpreter and the Python/C API Reference Manual. This describes how to interface with Python from C. Everything you can do in C you can equivalently do in assembly code too, but you’re on your own for this as it is not directly described from a Python perspective.