octave-maintainers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Octave 3.8.2 released - llvm


From: Tatsuro MATSUOKA
Subject: Re: Octave 3.8.2 released - llvm
Date: Tue, 26 Aug 2014 15:43:56 +0900 (JST)

----- Original Message -----

> From: Tatsuro MATSUOKA 
> To: John D ; "address@hidden" <address@hidden>
> Cc: 
> Date: 2014/8/26, Tue 12:35
> Subject: Re: Octave 3.8.2 released - llvm
> 
> ----- Original Message -----
> 
>>  From: John D 
>>  To: 'Tatsuro MATSUOKA'; address@hidden
>>  Cc: 
>>  Date: 2014/8/26, Tue 09:23
>>  Subject: RE: Octave 3.8.2 released - llvm
>> 
>> 
>> 
>>  -----Original Message-----
>>  From: Tatsuro MATSUOKA [mailto:address@hidden 
>>  Sent: Monday, August 25, 2014 7:41 PM
>>  To: John D; address@hidden
>>  Subject: Re: Octave 3.8.2 released - llvm
>> 
>>  ----- Original Message -----
>> 
>>>   From: John D
>>>   To: 'Tatsuro MATSUOKA' ; address@hidden
>>>   Cc: 
>>>   Date: 2014/8/26, Tue 08:29
>>>   Subject: RE: Octave 3.8.2 released - llvm -----Original Message-----
>>>   From: Tatsuro MATSUOKA [mailto:address@hidden
>>>   Sent: Monday, August 25, 2014 7:27 PM
>>>   To: John D; address@hidden
>>>   Subject: Re: Octave 3.8.2 released - llvm
>>>   ----- Original Message -----
>>> 
>>>>    From: John D
>>>>    To: 'Tatsuro MATSUOKA' ; address@hidden
>>>>    Cc: 
>>>>    Date: 2014/8/25, Mon 19:39
>>>>    Subject: RE: Octave 3.8.2 released - llvm -----Original 
> Message-----
>>>>    From: Tatsuro MATSUOKA [mailto:address@hidden
>>>>    Sent: Monday, August 25, 2014 5:21 AM
>>>>    To: John D; address@hidden
>>>>    Subject: Re: Octave 3.8.2 released - llvm
>>>> 
>>>>>>     To my knowledge, Octave-3.8 does not support llvm-3.4.I 
> am 
>>  using
>>>>>>     llvm-3.2
>>>> 
>>>>>>     built myself. Perhaps, llvm-3.3 is OK for Octave-3.8 
> though I 
>> 
>>>>>>   have
>>>>>>     not tested yet.
>>>>>>     The develepment version octave perhaps supports 
> llvm-3.4. 
>>  Perhaps
>>>>>>     much experienced persons will give the correct replies.
>>>>>     ---
>>>>> 
>>>>>     It was fixed in the devel version [1]
>>>>> 
>>>>>     [1] http://savannah.gnu.org/bugs/?41061
>>>>> 
>>>> 
>>>>    As I wrote, I could not build the develoment soource of octave  
>>>>   (changeset
>>>>    19048:ec28b7216501) with llvm-3.4.2.
>>>> 
>>>>    
>>>>   
> http://octave.1599824.n4.nabble.com/Octave-3-8-1-Released-td4662831.h
>>>>   t
>>>>    ml#a4666164
>>>> 
>>>>    The configration
>>>>    cd ~/work/Octave/develop/build
>>>> 
>>>>    PATH=$PATH:/opt/clang+llvm-3.4.2/bin ../octave/configure 
>>>>   --enable-jit  --prefix=/opt/octave-dev \  
>>>>   LLVM_CONFIG=/opt/clang+llvm-3.4.2/bin/llvm-config
>>>>    \ CPPFLAGS="-I/usr/include/mpi -DMPICH_SKIP_MPICXX
>>>   -DOMPI_SKIP_MPICXX"
>>>> 
>>>>    PATH=$PATH:/opt/clang+llvm-3.4.2/bin LC_ALL=C make
>>>> 
>>>>    7-zipped config.log is attached.
>>>>    Perhaps my build of clang+llvm-3.4.2 might be wrong.
>>>> 
>>>>    Any suggestions?
>>>> 
>>>>    # If I use clang+llvm-3.3, octave build was done w/o problem.
>>>> 
>>>>    Tatsuro
>>>> 
>>>>    --
>>>>    What was the hg head changeset and which branch?
>>> 
>>>   I do not know what is hg head changeset and branch name.
>>> 
>>>   How can I see from the cloned source?
>>> 
>>> 
>>>   I cloned repository at Aug.25, 2014 by:
>>>   hg clone http://www.octave.org/hg/octave (perhaps I have cloned the 
>>>   default branch? Right?)
>>> 
>>>   At the time I accessed http://www.octave.org/hg/octave I found that 
>>>   top of the changeset.
>>>   changeset 19048:ec28b7216501
>>>   test.m: Overhaul function (also fixes bug #39703).
>>> 
>>>   I used gcc-4.8.2 (Ubuntu 14.04 LTS amd64).
>>> 
>>>   Tatsuro
>>> 
>>>   --
>>>   hg head  - which would show the top change set hg branch - show the 
>>>   current branch
>> 
>>  Hmmm. I failed the above commands because ".hg" is missing in the 
> 
>>  cloned
>>  directory.
>> 
>> 
>>>   Do you have the config.log from running configure
>> 
>>  That was already attached (7-zipped) in the first mail.
>>  I show the Nabble address to get it.
>> 
>> 
> http://octave.1599824.n4.nabble.com/Re-Octave-3-8-2-released-llvm-td4666106.
>>  html#a4666195
>>  The last part of the pointed post you can see:
>>  (config.log.7z (92K) Download Attachment)
>> 
>>  Tatsuro
>> 
>> 
>>  ----
>> 
>>  configure:15052: checking for LLVMBuildAdd in -lLLVM-3.4.2
>>  configure:15085: gcc -o conftest -g -O2 -pthread -I/usr/include/mpi
>>  -DMPICH_SKIP_MPICXX -DOMPI_SKIP_MPICXX  -L/opt/clang+llvm-3.4.2/lib
>>  conftest.c -lLLVM-3.4.2  -lm   >&5
>>  /usr/bin/ld: cannot find -lLLVM-3.4.2
>>  collect2: error: ld returned 1 exit statu
>> 
>> 
>>  It cant find the library
> 
> For llvm-3.3 config.log (7-zipped archive attatched config.log.llvm33.7z),
> similar results found in config.log
> 
> configure:15052: checking for LLVMBuildAdd in -lLLVM-3.3
> configure:15085: gcc -o conftest -g -O2 -pthread -I/usr/include/mpi 
> -DMPICH_SKIP_MPICXX -DOMPI_SKIP_MPICXX  -L/opt/clang+llvm-3.3/lib conftest.c 
> -lLLVM-3.3  -lm   >&5
> /usr/bin/ld: cannot find -lLLVM-3.3
> 
> However, jit build is fine.
> 
> Quick check from octave prompt.
>>>  a = 1; b = 1; tic; for i=1:1000; for j=1:1000; a = a + b; end; end; toc
> Elapsed time is 4.28941 seconds.
>>>  jit_enable(1)
>>>  a = 1; b = 1; tic; for i=1:1000; for j=1:1000; a = a + b; end; end; toc
> Elapsed time is 0.0362439 seconds.
> 
> Thus the configure fail the above seems not to be an origin of octave-dev + 
> llvm-3.4.2 build fail for my case.
> 
> The build failure happened in compling pt-jit.cc but not link prcess.
> 
> Full errors is given the below
> http://octave.1599824.n4.nabble.com/Octave-3-8-1-Released-td4662831.html#a4666164
> 
> One of the error is shown:
> 
> /opt/clang+llvm-3.4.2/include/llvm/PassManager.h:34:15: error: 
> 'PassManager' is already declared in this scope 
>  using legacy::PassManager; 
> 
> Tatsuro

Looking into the error messages and pt-jit.cc.

I added "-DLEGACY_PASSMANAGER" flag to CPPFLAGS, development source + 
llvm-3.4.2 build went well.
In addtion a simple test went well:

>> a = 1; b = 1; tic; for i=1:1000; for j=1:1000; a = a + b; end; end; toc
Elapsed time is 4.0523 seconds.
>> jit_enable(1)
>> a = 1; b = 1; tic; for i=1:1000; for j=1:1000; a = a + b; end; end; toc
Elapsed time is 0.0166121 seconds.

Thank you for your advised and paticince.

Tatsuro



reply via email to

[Prev in Thread] Current Thread [Next in Thread]