Tim Foley
2008-Jun-05 01:08 UTC
[LLVMdev] Enabling x86-64 JIT under Visual Studio compiler
I built the LLVM 2.2 distribution under Visual Studio for x86-64 just fine, but then trying to run my first "hello world" application, found that the JIT compiler was not enabled. I'm completely new to LLVM, so I didn't know exactly where to look to see why the JIT for my platform wasn't being built (is it in the configure steps, or in the C++ code itself?). My educated guess is currently that X86_64TargetMachine::getJITMatchQuality is the interesting point. I have noticed that all the points in the codebase that try to detect x86-64 are currently using the gcc-style "__x86_64__" preprocessor symbol. The Visual Studio compiler, instead, defines _M_X64 (similar to the _M_IX86 define that matches __x86__). Adding a defined(_M_X64) case to all the existing #ifdefs is no big deal, but I notice that two of them (one in X86JitInfo.cpp and one in X86Subtarget.cpp) are guarding inline assembly blocks written in the gcc-style inline assembly syntax. Would adding cases for these assembly blocks that are in Visual Studio syntax be enough to enable a working x86-64 JIT target under Windows builds? I can't pretend to understand this codebase, so if there are more roadblocks stopping 64-bit JIT on Windows targets I'd be interested to hear... - Tim Foley -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20080604/bc4cdb0f/attachment.html>
Seemingly Similar Threads
- [LLVMdev] [PATCH] Detect Haswell subarchitecture (i.e. using -march=native)
- [LLVMdev] Enabling x86-64 JIT under Visual Studio compiler
- [LLVMdev] Building LLVM under Mingw. Part I: tools-only
- [LLVMdev] Fix for non-standard variable length array + Visual C X86 specific code
- [LLVMdev] Why do X86_32TargetMachine and X86_64TargetMachine classes exist?