[llvm-commits] PBQP: alloca causing problems on MingW32
Chris Lattner
clattner at apple.com
Sun Oct 5 20:54:56 PDT 2008
On Oct 5, 2008, at 7:51 PM, Kenneth Boyd wrote:
> Kenneth Boyd wrote:
>> Configure line:
>> sh-3.1$ ../llvm.svn/configure --enable-assertions --enable-
>> expensive-checks --disable-threads --disable-cbe-printf-a --
>> disable-shared --enable-static
>>
>> Compile error is:
>> llvm[2]: Compiling PBQP.cpp for Debug+Checks build
>> c:/CPP_App/llvm.svn/lib/CodeGen/PBQP.cpp: In function 'void
>> llvm::compute_tc_info(llvm::pbqp*, llvm::adjnode*)':
>> c:/CPP_App/llvm.svn/lib/CodeGen/PBQP.cpp:1053: error: 'alloca' was
>> not declared in this scope
>> make[2]: *** [/CPP_App/llvm.svn.obj/lib/CodeGen/Debug+Checks/
>> PBQP.o] Error 1
>>
>> Ideally, I'll be taking a look at this later tonight (assuming I
>> don't get swamped). It seems that most of the files that use
>> alloca also #include <malloc.h> somewhere (haven't checked how this
>> works for ExecutionEngine/ExecutionEngine.cpp yet, but all of the
>> uses in the System subdirectory are this way).
>>
> It appears that the correct fix is #include "llvm/Config/alloca.h" .
>
> I'm attaching two patches to choose from:
> * PBQP.minimal.patch is a one-line change.
> * PBQP.standardize.patch puts the #includes in PBQP.cpp into
> "standard order".
Thanks! applied:
http://lists.cs.uiuc.edu/pipermail/llvm-commits/Week-of-Mon-20080929/068093.html
http://lists.cs.uiuc.edu/pipermail/llvm-commits/Week-of-Mon-20080929/068094.html
-Chris
More information about the llvm-commits
mailing list