Posts

Showing posts with the label Header Files

Quick Progress!

Parsing for fun and profit I remember creating parsers to be a bit harder. I tried using Antlr when doing the JavaFX DLR project and failed at it miserably. It felt messy. I couldnt get a feel for how to structure the document, etc. I was drawn to the Irony parser framework because declaring the grammar in C# somehow felt (at the time) cleaner and it seemed to allow for more expressive statements and character logic. I am not sure if it was my previous experience with parsing and Antlr (or Irony), or how clean and expressive the GOLD parser framework is, but I've been able to create a working parser in just a few days of coding. And by working, I mean it parses and understands valid LLVM IR straight from the project's documentation:  I actually implemented a a lot more operations and keywords needed to parse the example. It was just easier that way. I am going to now start building an AST. I've decided to be a bit aggressive because I think the AST will drive ...

Tracking down Signal codes

Ok. I've been trying to tracked down the error's meaning. specifically SIGSEGV code=2. I found it listed in the header file located at    sys/siginfo.h  : * SIGSEGV codes (si_addr == address of faulting memory reference)  */ #define SEGV_MAPERR     1       /* Address not mapped */ #define SEGV_ACCERR     2       /* No permissions */ #define SEGV_STKERR     3       /* ?? Stack exception */ #define SEGV_GPERR      4       /* ?? General protection */ #define SEGV_IRQERR     5       /* ?? Interrupt handler fault */ #if defined(__EXT_QNX) #define NSIGSEGV        5 #endif It seems to be SEGV_ACCERR. No permissions. Very interesting. I am not sure what it is trying to access, or why i dont have permissions as a developer. Hmmm... Update:  Found addr2line. seems like there are some errors in aot-compiler.c,...