ВходНаше всё Теги codebook 无线电组件 Поиск Опросы Закон Пятница
19 июля
653101
Evgeny_CD, Архитектор (15.02.2016 01:19, просмотров: 2559)
Однако. Начиная с 5 версии GCC поддерживает libgccjit -> --> Я пока толком не вкурил, но вроде как можно встроить и оно нагенерит код, котором можно передать управление.... Наверно, это будет круто для отладки.... https://gcc.gnu.org/onlinedocs/gcc-5.1.0/jit/index.html
https://gcc.gnu.org/gcc-5/changes.html
New in GCC 5 is the ability to build GCC as a shared library for embedding in other processes (such as interpreters), suitable for Just-In-Time compilation to machine code. The shared library has a C API and a C++ wrapper API providing some "syntactic sugar". There are also bindings available from 3rd parties for Python and for D. For example, this library can be used by interpreters for compiling functions from bytecode to machine code. The library can also be used for ahead-of-time compilation, enabling GCC to be plugged into a pre-existing frontend. An example of using this to build a compiler for an esoteric language we'll refer to as "brainf" can be seen here.