[LLVMdev] MSVC compile error with trunk

OvermindDL1 overminddl1 at gmail.com
Tue May 12 23:19:31 PDT 2009


On Tue, May 12, 2009 at 11:55 PM, Chris Lattner <clattner at apple.com> wrote:
> Dan, can you add IVUsers.cpp to the appropriate cmakefile?
>
> -chris
>
>
> On May 12, 2009, at 10:54 PM, OvermindDL1 wrote:
>
>> On Tue, May 12, 2009 at 11:40 PM, Chris Lattner <clattner at apple.com>
>> wrote:
>>>
>>> On May 12, 2009, at 10:24 PM, OvermindDL1 wrote:
>>>
>>>> Does not seem to be a straight error with LLVM itself, but rather the
>>>> tools, linking issues, here are the errors:
>>>
>>> Please prepare a patch, thanks!
>>
>>
>> Still trying to hunt it down, but from what it seems so far, the file
>> IVUsers.cpp does not seem to be compiled into any library, not
>> compiled at all (using cmake).  I am not sure which library it is
>> supposed to be compiled into, LLVMAnalysis?  If so then IVUsers.cpp
>> needs to be added to the CMakeLists.txt in the lib/analysis/
>> directory.  And just checked, the IVStrideUse::deleter error is also
>> defined in the IVUser.cpp file as well, so including that will
>> probably fix it.  Going to resync to trunk again just to make sure,
>> add that to the analysis CMakeLists.txt file, and compile to see if
>> that works, if so I will submit a patch.


Confirmed, once IVUsers.cpp is added to the LLVMAnalysis library,
fixed some of those errors, but there are more still.  Patch is
attached for the IVUsers.cpp add to the CMakeLists.txt file.

32>   Creating library
R:\SDKs\llvm\trunk_VC8_building\lib\Debug\llc.lib and object
R:\SDKs\llvm\trunk_VC8_building\lib\Debug\llc.exp
32>LLVMCodeGen.lib(PrologEpilogInserter.obj) : error LNK2001:
unresolved external symbol "public: virtual void __thiscall
llvm::PEI::getAnalysisUsage(class llvm::AnalysisUsage &)const "
(?getAnalysisUsage at PEI@llvm@@UBEXAAVAnalysisUsage at 2@@Z)
32>LLVMCodeGen.lib(PrologEpilogInserter.obj) : error LNK2019:
unresolved external symbol "private: void __thiscall
llvm::PEI::clearAllSets(void)" (?clearAllSets at PEI@llvm@@AAEXXZ)
referenced in function "public: virtual bool __thiscall
llvm::PEI::runOnMachineFunction(class llvm::MachineFunction &)"
(?runOnMachineFunction at PEI@llvm@@UAE_NAAVMachineFunction at 2@@Z)
32>LLVMCodeGen.lib(PrologEpilogInserter.obj) : error LNK2019:
unresolved external symbol "private: void __thiscall
llvm::PEI::placeCSRSpillsAndRestores(class llvm::MachineFunction &)"
(?placeCSRSpillsAndRestores at PEI@llvm@@AAEXAAVMachineFunction at 2@@Z)
referenced in function "public: virtual bool __thiscall
llvm::PEI::runOnMachineFunction(class llvm::MachineFunction &)"
(?runOnMachineFunction at PEI@llvm@@UAE_NAAVMachineFunction at 2@@Z)
32>R:\SDKs\llvm\trunk_VC8_building\bin\Debug\llc.exe : fatal error
LNK1120: 3 unresolved externals


Do note, this linking error appears a few times, but they are all
identical to this one, looks like the last.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: IVUsers_cpp_to_CMakeLists.patch
Type: application/octet-stream
Size: 364 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20090513/ea76cf9a/attachment.obj>


More information about the llvm-dev mailing list