Hi,
I'm trying to make a simple llvm backend for Epiphany CPU (originally based on Hoenchen's code, later decided to rewrite it from scratch using Cpu0 backend writing manual as a reference), and I'm getting stuck at some places.
As subject states, it's about arch reference doc. In the instruction set table (Appendix C of the PDF) there's a number of empty spaces, e.g. in MOV(imm)32 instruction. I originally assumed those spaces to be zeros, but after compiling the same code with e-gcc and my backend it turned out that bits 16-19 (empty ones) should be assigned to 0b0010, similar to MOV(reg)32 instructions. There's also a number of empty spaces in math-related instructions, so i want to ask if i'm missing something, or maybe there's a full table somewhere with those spaces filled?
BR,
Petr
P.S. I'm working with LLVM 3.9.0, the code is partially available at https://github.com/upcFrost/Epiphany. Partially, as it also requires some changes in the other parts of the LLVM tree except /lib/Target. I'll publish them as a patch later. Atm, the backend can resolve asm for basic algebra (int/float) and simple moves/ldr/str, and it can generate ELFs which i'm currently trying to fix. No array/struct/branching support atm, working on it.
P.P.S. Btw, is it ok if i'll use some algorithms for missing functions from e-gcc, such as div or srem?