compiler

Compilers- 3-address generation.

I was trying to generate a compiler(part there of) that will take a file(as of now, written in C ) and will generate the corresponding 3-address code for the file (into another file). So if I have a structure of the form : struct myStructure { int a; char c; }myStruct; So What should be the symbol table for the above?? A...

Is it possible to use Closure Compiler ADVANCED_OPTIMIZATIONS with jQuery?

I keep getting errors that the function (renamed) does not exist for the given object. Is there a release or setting or something to make it work? ...

Free AOT Java compiler

Does anyone know some free AOT Java compiler? I have found just one - http://gcc.gnu.org/java/. ...

Compiling SDL on a MAC

#include "ffmpeg/libavcodec/avcodec.h" #include "ffmpeg/libavformat/avformat.h" #include "ffmpeg/libswscale/swscale.h" #include "ffmpeg/libswscale/rgb2rgb.h" #include "ffmpeg/libswscale/swscale_internal.h" #include <stdio.h> #ifdef __MINGW32__ #undef main /* Prevents SDL from overriding main() */ #endif #include "SDL.framework/Heade...

Compile codes with my own compiler in VS2010?

Hi Anybody knows how can I use VS2010 IDE to write my own language codes and compile it with my own compiler? ...

c++ how to write code the compiler can easily optimize for SIMD?

hello there! i'm working in Visual Studio 2008 and in the project settings I see the option for "activate Extended Instruction set" which I can set to None, SSE or SSE2 So the compiler will try to batch instructions together in order to make use of SIMD instructions? Are there any rules one can follow in how to optimize code such that...

Compile GCC with Code Sourcery

Hi, Is it possible to compile native GCC for ARM (host == target == ARM) using Code Sourcery G++? If it is not possible, could I use crosstool-NG to build the cross-compile and then using this one for compiling the native ARM GCC? Thank you, Edit: as to why: I'm creating my own distro for beagleboard... ...

Is there a library that can compile C++ or C

Hi There, I came here to ask this question because this site has been very useful to me in the past, seems to have very knowledgeable users who are willing to discuss a question even if it is metaphysical at times. And also because googling it did not work. Java has a compiler and then it has a JDT library that can compile java on the ...

Toolchain question: How do you add a header/lib so the compiler knows where to find it?

I have made a toolchain using this script: http://gist.github.com/403608 (more or less modified to get it to work) Everything is installed and now when I try to compile using it I get an error when I ./configure it says that my C compiler cannot create exeicutables. I'm thinking that my compiler just doesn't know where to look for all ...

Should I avoid instanceof when working with a tree of objects?

I have a class hierarchy representing different language constructs: Expression <- NumericLiteral UnaryExpression BinaryExpression IndexingExpression IteratedExpression ... The objects of these classes form complex tree hierarchies on which I have to perform va...

Trace changes to variables automatically

I am debugging a C program (GCC and GDB in Linux and Visual Studio in Windows) that gives different results on two different architectures. I'd like to compare execution on each architecture by tracing the changes to the values stored in variables in order to locate differences. file main.c, line 234. Variable A changes from 34 to 23 f...

Does Java include comments on the compiled code?

Well, the title is self-explanatory. I wondered this while compiling a project which has a lot of lines commented. It's a bit silly because the jar file wouldn't increase much (some bytes) but I'm curious if this could affect a program with a lot of code and comments. Thanks ...

Integrating 3rd party C++ compilers with Microsoft Visual Studio

Duplicate issue: I have read this thread and this thread and these didn't quite answer my question. Question:: Is there a way I could make Visual Studio use g++ or comeau or other as the C++ compiler. If so, has anyone tried it? Any feedback? Reason: Love microsoft's IDE, hate their compiler. ...

Tilera cross compilation - Any idea about this Error: unknown asm constraint letter

We are getting these constraint errors wherver OSAF calls like m_NCS_SEL_OBJ_ZERO(&nSelObjSet) is called in our code. This is while cross compiling using tilera compiler - tile-g++. With g++ it always compiles fine. Any pointers would be helpful. Note: m_NCS_SEL_OBJ_ZERO is a macro and replaced by FD_ZERO Sample Code: // initialise a...

compiler for my web site

Hi, I am planning to build an algorithm web site that compiles the c and other language programs. I want to know is there any readymade tools/libraries for that?. ...

x86 MUL Instruction from VS 2008/2010

Will modern (2008/2010) incantations of Visual Studio or Visual C++ Express produce x86 MUL instructions (unsigned multiply) in the compiled code? I cannot seem to find or contrive an example where they appear in compiled code, even when using unsigned types. If VS does not compile using MUL, is there a rationale why? ...

How are classes implemented in compilers

I'd like to implement a class type for my own little language but what I thought at first wouldn't be too hard has got me stumped. I have the parser in place and it's the code generation side of things I'm having problems with. Can anyone shed any light on the best/correct way to go about this? Specifically I'd like to do this in LLVM so...

How to interpret a custom language

Hi I have an app in C++ which actually processes a binary file. The binary file is a collection of events say A/B/C, and on detecting event A in the file, the app handles the event in "handler A". Now i need to write another script in a custom language, which gets executed orthogonally to the binary file processing. The script can hav...

.net command-line compiler mutiple projects

I need to build a batch file that runs on a directory and digs inside for suitable c# projects to compile. (and compile them of course). I don't know the name of the projects inside the directory. I can assume all project are in c# and written in VS2008 and above (if that helps). I could really use your help on this, thanks. ...

Can I squeez my own program between the preprocessor and compiler?

Is this a stupid question? Or can I specify g++ to use a program between the preprocessor and compiler? Alternatively, I know that I can just run the preprocessor on a file (hence all the files). Then I am guessing there is a switch to run only the compiler. So I can manually invoke these two and put my program between. If so, how do I ...