Thanks Favios for finding the problem! I have applied a patch to
Makefile.rules, hopefully it now works without you editing some files.
About VMKIT_SRC_ROOT and PROJ_SRC_ROOT, it is fine to have both in the
code. I find it clearer to use VMKIT_SRC_ROOT.
Nicolas
On Sun, Jun 10, 2012 at 10:09 PM, Foivos S. Zakkak <foivos at
zakkak.net>wrote:
> Hi Nicolas,
>
> I finally found the root of the problem. Build was unable to locate
> llvm-build because it was looking for it in
> path/to/vmkit_src/utils/llvm-**build while it was located in
> path/to/llvm_src/utils/llvm-**build
>
> Actually llvm-build's path is defined by the
path/to/llvm_src/Makefile.**rules
> and looks like this
> LLVMBuildTool := $(PROJ_SRC_ROOT)/utils/llvm-**build/llvm-build
> however in the case of vmkit it should be
> LLVMBuildTool := $(LLVM_SRC_ROOT)/utils/llvm-**build/llvm-build
>
> i Also noticed that in the vmkit's generated (by configure)
> Makefile.config there are defined PROJ_SRC_ROOT and VMKIT_SRC_ROOT as well
> as PROJ_OBJ_ROOT and VMKIT_OBJ_ROOT. What should be the difference between
> PROJ_* and VMKIT_* paths? In my case they where equal (so what's the
need
> for 2 different variables?)
>
> I hope the first section will help you to create a patch
> (i edited my Makefile.rules just before configuring vmkit to make it work)
>
> Thank you
> Foivos
>
>
> On 08/06/12 00:32, Foivos S. Zakkak wrote:
>
>> Hi Nicolas,
>>
>> it looks like there are missing things
>>
>> $ more lib/j3/LLVMRuntime/**LLVMRuntime.inc
>> // Generated by llvm2cpp - DO NOT MODIFY!
>>
>>
>> Module* makeLLVMModuleContents(Module *mod) {
>>
>> mod->setModuleIdentifier("<**stdin>");
>>
>> // Type Definitions
>>
>> // Function Declarations
>>
>> // Global Variable Declarations
>>
>>
>> // Constant Definitions
>>
>> // Global Variable Definitions
>>
>> // Function Definitions
>>
>> return mod;
>>
>> }
>>
>> Foivos
>>
>> On 07/06/12 23:59, Nicolas Geoffray wrote:
>>
>>> Hi Fovios,
>>>
>>> Do you have a ./lib/j3/LLVMRuntime/**LLVMRuntime.inc file being
>>> generated?
>>> What does it contain?
>>>
>>> Nicolas
>>>
>>> On Thu, Jun 7, 2012 at 5:47 PM, Foivos S. Zakkak <foivos at
zakkak.net
>>> <mailto:foivos at zakkak.net>> wrote:
>>>
>>> Still the same.
>>>
>>> Is there any chance that the placement of my directories are
causing
>>> this?
>>>
>>> Also the exact command that fails is
>>>
>>> /home1/public/zakkak/java/__**vmkit/Release+Asserts/bin/vmjc
>>> -std-compile-opts
>>> -load=/home1/public/zakkak/__**java/vmkit/Release+Asserts/__**
>>> lib/MMTKRuntime.so
>>> -load=/home1/public/zakkak/__**java/vmkit/Release+Asserts/__**
>>> lib/MMTKMagic.so
>>> -LowerMagic
>>> /home1/public/zakkak/java/__**vmkit/mmtk/java/mmtk-vmkit.jar
>>> -disable-exceptions -disable-cooperativegc
>>> -with-clinit=org/mmtk/vm/VM,__**org/mmtk/utility/*,org/mmtk/__**
>>> policy/*,org/j3/config/*
>>> -Dmmtk.hostjvm=org.j3.mmtk.__**Factory -o mmtk-vmkit.bc
>>> -Dmmtk.properties=/home1/__**public/zakkak/java/vmkit/../..**
>>> __/llvm/vmkit/mmtk/java/vmkit.**__properties
>>> -disable-stubs -assume-compiled
>>>
>>> Thank you for your time
>>> Foivos
>>>
>>>
>>> On 07/06/12 18:12, Nicolas Geoffray wrote:
>>>
>>> On Thu, Jun 7, 2012 at 4:27 PM, Foivos S. Zakkak
>>> <foivos at zakkak.net <mailto:foivos at zakkak.net>
>>> <mailto:foivos at zakkak.net <mailto:foivos at
zakkak.net>>> wrote:
>>>
>>> Hi Nicolas,
>>>
>>> I thought MMTk is written in java and it is compiled by
javac.
>>>
>>>
>>> It is compiled by javac to produce Java bytecode. Then vmkit
>>> runs the
>>> initialization code of MMTk (through the JIT) and generates
the
>>> binary
>>> code through llvm.
>>>
>>>
>>> retried a clean build with JIT enabled
>>>
>>> llvm configuration
>>> ../../llvm/configure --enable-doxygen --enable-optimized
>>> --enable-jit
>>>
>>>
>>> vmkit configuration
>>> ../../llvm/vmkit/configure
>>> --with-llvmsrc=/home1/public/_**_zakkak/llvm/
>>> --with-llvmobj=/home1/public/_**_zakkak/java/llvm/
>>>
>>>
--with-gnu-classpath-glibj=/__**home1/public/zakkak/java/__**
>>> classpath-0.97.2/lib/glibj.__**zip--with-gnu-classpath-libs=/**
>>> __home1/public/zakkak/java/__**classpath-0.97.2/lib/
>>>
>>> and the problem persists
>>>
>>>
>>> Could you do make ENABLE_OPTIMIZED=1 clean and then make
>>> ENABLE_OPTIMIZED=1 ? Some files may have not been generated
>>> because of
>>> the missing JIT and that screwed up the Makefile.
>>>
>>> Nicolas
>>>
>>>
>>>
>>> Foivos
>>>
>>>
>>> On 07/06/12 16:54, Nicolas Geoffray wrote:
>>>
>>> Hi Fovios,
>>>
>>> On Thu, Jun 7, 2012 at 3:51 PM, Foivos <fivosz at
gmail.com
>>> <mailto:fivosz at gmail.com>
>>> <mailto:fivosz at gmail.com <mailto:fivosz at
gmail.com>>> wrote:
>>>
>>> Hi,
>>>
>>> My machine is running Ubuntu server 64-bit
>>> And the revision from the trunk is 158095 for
llvm,
>>> clang and
>>> vmkit
>>>
>>> llvm configuration
>>> ../../llvm/configure --enable-doxygen
>>> --enable-optimized
>>> --disable-jit
>>>
>>>
>>> Why do you disable the JIT? VMKit needs it to
compile
>>> MMTk.
>>>
>>> Cheers,
>>> Nicolas
>>>
>>> vmkit configuration
>>> ../../llvm/vmkit/configure
>>> --with-llvmsrc=/home1/public/_**_zakkak/llvm/
>>>
--with-llvmobj=/home1/public/_**_zakkak/java/llvm/
>>>
>>>
--with-gnu-classpath-glibj=/__**home1/public/zakkak/java/__
>>> **classpath-0.97.2/lib/glibj.__**zip--with-gnu-classpath-libs=/**
>>> __home1/public/zakkak/java/__**classpath-0.97.2/lib/
>>>
>>> Thank you
>>> Foivos
>>>
>>>
>>> On 06/06/12 22:35, Nicolas Geoffray wrote:
>>>
>>> Hi Fivos,
>>>
>>> I cannot reproduce on my machine (ubuntu
64bit,
>>> clang/llvm/vmkit on svn trunk). What's
your
>>> configuration?
>>>
>>> Cheers,
>>> Nicolas
>>>
>>> On Tue, Jun 5, 2012 at 3:08 PM, Fivos
>>> <fivosz at gmail.com <mailto:fivosz at gmail.com>
>>> <mailto:fivosz at gmail.com <mailto:fivosz at
gmail.com>>> wrote:
>>>
>>> Hello,
>>>
>>> after completing the build i get
>>>
>>> ...
>>> BUILD SUCCESSFUL
>>> Total time: 5 seconds
>>> llvm[2]: Building Release+Asserts
>>> mmtk-vmkit.jar all
>>> vmjc:
>>>
/home1/public/zakkak/llvm/lib/**__VMCore/Type.cpp:747:
>>> static
>>> llvm::PointerType
>>> *llvm::PointerType::get(llvm::**__Type *,
>>> unsigned int):
>>> Assertion `EltTy &&
"Can't get a pointer to
>>> <null>
>>> type!"' failed.
>>> 0 vmjc 0x0000000000d24e1f
>>> 1 vmjc 0x0000000000d25334
>>> 2 libpthread.so.0 0x00002b398f36b8f0
>>> 3 libc.so.6 0x00002b3990178a75
>>> gsignal + 53
>>> 4 libc.so.6 0x00002b399017c5c0
abort
>>> + 384
>>> 5 libc.so.6 0x00002b3990171941
>>> __assert_fail + 241
>>> 6 vmjc 0x0000000000cd7fde
>>> llvm::PointerType::get(llvm::_**_Type*,
>>> unsigned int) + 478
>>> 7 vmjc 0x0000000000564317
>>>
j3::J3Intrinsics::init(llvm::_**_Module*) +
>>> 199
>>> 8 vmjc 0x000000000054f86d
>>>
>>>
j3::JavaAOTCompiler::__**JavaAOTCompiler(std::string
>>> const&)
>>> + 1597
>>> 9 vmjc 0x0000000000502b8d
main +
>>> 141
>>> 10 libc.so.6 0x00002b3990163c4d
>>> __libc_start_main + 253
>>> 11 vmjc 0x0000000000502a39
>>> Aborted
>>> make[2]: *** [all] Error 134
>>> make[2]: Leaving directory
>>>
>>>
`/home1/public/zakkak/java/__**vmkit_build/mmtk/java'
>>> make[1]: *** [all] Error 1
>>> make[1]: Leaving directory
>>> `/home1/public/zakkak/java/__**
>>> vmkit_build/mmtk'
>>> make: *** [all] Error 1
>>>
>>> any ideas, how to fix this?
>>>
>>> Thank you
>>> Foivos
>>>
>>>
______________________________**___________________
>>> LLVM Developers mailing list
>>> LLVMdev at cs.uiuc.edu <mailto:LLVMdev at
cs.uiuc.edu>
>>> <mailto:LLVMdev at cs.uiuc.edu <mailto:LLVMdev at
cs.uiuc.edu>>
>>> http://llvm.cs.uiuc.edu
>>>
http://lists.cs.uiuc.edu/__**mailman/listinfo/llvmdev<http://lists.cs.uiuc.edu/__mailman/listinfo/llvmdev>
>>>
<http://lists.cs.uiuc.edu/**mailman/listinfo/llvmdev<http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev>
>>> >
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL:
<http://lists.llvm.org/pipermail/llvm-dev/attachments/20120611/9322da65/attachment.html>