Tagha
Tagha copied to clipboard
Implement compiler backend (Clang/LLVM)
implement a compiler or compiler backend that generates bytecode for this VM. Possibility: Make GCC output Tagha bytecode using a custom GCC Backend but will take alot of effort. Maybe use Clang/LLVM backend to output Tagha bytecode?
alternative, quick build a compiler via flex + bison?
writing down some advice someone gave me considering this.
"You don't embed clang though. You build a backend so you can write binaries for tagha in any llvm language. You write an os kernel for tagha, allowing the compiler to be run in the machine.
A kernel is a program written for the machine that manages the filesystem, peripherals, and programs running on the machine. With a kernel, you can run compiling systems that are entirely contained in the machine. Otherwise, you use an external machine to compile the binary, then move the binary into the machine to be run as its program."
saving this for later -> https://github.com/lowRISC/riscv-llvm/tree/master/docs