diff -Naur orig/aclocal.m4 my/aclocal.m4 diff -Naur orig/build-aux/ltmain.sh my/build-aux/ltmain.sh diff -Naur orig/build-aux/missing my/build-aux/missing diff -Naur orig/ChangeLog my/ChangeLog diff -Naur orig/config.in.h my/config.in.h --- orig/config.in.h 2014-06-06 17:45:58.000000000 +0200 +++ my/config.in.h 2014-06-11 11:06:48.000000000 +0200 @@ -1167,6 +1167,9 @@ /* Define to 1 if you have the header file. */ #undef HAVE_LLVM_IR_IRBUILDER_H +/* Define to 1 if you have the header file. */ +#undef HAVE_LLVM_IR_VERIFIER_H + /* Define to 1 if you have the header file. */ #undef HAVE_LLVM_SUPPORT_IRBUILDER_H @@ -2805,6 +2808,9 @@ /* Define as the word index where to find the sign of 'long double'. */ #undef LDBL_SIGNBIT_WORD +/* Define to 1 if LLVM::legacy::PassManager exists. */ +#undef LEGACY_PASSMANAGER + /* Define to 1 if lseek does not detect pipes. */ #undef LSEEK_PIPE_BROKEN @@ -2886,6 +2892,9 @@ 'ptrdiff_t'. */ #undef PTRDIFF_T_SUFFIX +/* Define to 1 if LLVM::raw_fd_ostream arg type is llvm::sys:fs. */ +#undef RAW_FD_OSTREAM_ARG_IS_LLVM_SYS_FS + /* Define to 1 if readlink fails to recognize a trailing slash. */ #undef READLINK_TRAILING_SLASH_BUG diff -Naur orig/configure my/configure --- orig/configure 2014-06-06 17:46:07.000000000 +0200 +++ my/configure 2014-06-11 11:06:52.000000000 +0200 @@ -15093,6 +15093,19 @@ warn_llvm="Missing LLVM file TargetData.h. JIT compiler is disabled." fi + for ac_header in llvm/IR/Verifier.h +do : + ac_fn_cxx_check_header_mongrel "$LINENO" "llvm/IR/Verifier.h" "ac_cv_header_llvm_IR_Verifier_h" "$ac_includes_default" +if test "x$ac_cv_header_llvm_IR_Verifier_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_LLVM_IR_VERIFIER_H 1 +_ACEOF + +fi + +done + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking check llvm::Function::addAttribute arg type is llvm::Attributes" >&5 $as_echo_n "checking check llvm::Function::addAttribute arg type is llvm::Attributes... " >&6; } @@ -15293,6 +15306,129 @@ fi + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking check LLVM::raw_fd_ostream arg type is llvm::sys:fs" >&5 +$as_echo_n "checking check LLVM::raw_fd_ostream arg type is llvm::sys:fs... " >&6; } +if ${octave_cv_raw_fd_ostream_arg_is_llvm_sys_fs+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_ext=cpp +ac_cpp='$CXXCPP $CPPFLAGS' +ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_cxx_compiler_gnu + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + #include + +#ifdef F77_DUMMY_MAIN + +# ifdef __cplusplus + extern "C" +# endif + int F77_DUMMY_MAIN() { return 1; } + +#endif +int +main () +{ + + std::string str; + llvm::raw_fd_ostream fout ("", str, llvm::sys::fs::F_Binary); + + ; + return 0; +} +_ACEOF +if ac_fn_cxx_try_compile "$LINENO"; then : + octave_cv_raw_fd_ostream_arg_is_llvm_sys_fs=yes +else + octave_cv_raw_fd_ostream_arg_is_llvm_sys_fs=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + ac_ext=cpp +ac_cpp='$CXXCPP $CPPFLAGS' +ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_cxx_compiler_gnu + + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $octave_cv_raw_fd_ostream_arg_is_llvm_sys_fs" >&5 +$as_echo "$octave_cv_raw_fd_ostream_arg_is_llvm_sys_fs" >&6; } + if test $octave_cv_raw_fd_ostream_arg_is_llvm_sys_fs = yes; then + +$as_echo "#define RAW_FD_OSTREAM_ARG_IS_LLVM_SYS_FS 1" >>confdefs.h + + fi + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking check for LLVM::legacy::PassManager" >&5 +$as_echo_n "checking check for LLVM::legacy::PassManager... " >&6; } +if ${octave_cv_legacy_passmanager+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_ext=cpp +ac_cpp='$CXXCPP $CPPFLAGS' +ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_cxx_compiler_gnu + + save_LIBS="$LIBS" + LIBS="$LLVM_LIBS $LIBS" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + #include + +#ifdef F77_DUMMY_MAIN + +# ifdef __cplusplus + extern "C" +# endif + int F77_DUMMY_MAIN() { return 1; } + +#endif +int +main () +{ + + llvm::Module *module; + llvm::legacy::PassManager *module_pass_manager; + llvm::legacy::FunctionPassManager *pass_manager; + module_pass_manager = new llvm::legacy::PassManager (); + pass_manager = new llvm::legacy::FunctionPassManager (module); + + ; + return 0; +} +_ACEOF +if ac_fn_cxx_try_link "$LINENO"; then : + octave_cv_legacy_passmanager=yes +else + octave_cv_legacy_passmanager=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + LIBS="$save_LIBS" + ac_ext=cpp +ac_cpp='$CXXCPP $CPPFLAGS' +ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_cxx_compiler_gnu + + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $octave_cv_legacy_passmanager" >&5 +$as_echo "$octave_cv_legacy_passmanager" >&6; } + if test $octave_cv_legacy_passmanager = yes; then + +$as_echo "#define LEGACY_PASSMANAGER 1" >>confdefs.h + + fi + ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' @@ -20111,7 +20247,7 @@ rm -rf conftest* ;; -x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \ +x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \ s390*-*linux*|s390*-*tpf*|sparc*-*linux*) # Find out which ABI we are using. echo 'int i;' > conftest.$ac_ext @@ -20136,7 +20272,10 @@ ;; esac ;; - ppc64-*linux*|powerpc64-*linux*) + powerpc64le-*) + LD="${LD-ld} -m elf32lppclinux" + ;; + powerpc64-*) LD="${LD-ld} -m elf32ppclinux" ;; s390x-*linux*) @@ -20155,7 +20294,10 @@ x86_64-*linux*) LD="${LD-ld} -m elf_x86_64" ;; - ppc*-*linux*|powerpc*-*linux*) + powerpcle-*) + LD="${LD-ld} -m elf64lppc" + ;; + powerpc-*) LD="${LD-ld} -m elf64ppc" ;; s390*-*linux*|s390*-*tpf*) diff -Naur orig/configure.ac my/configure.ac --- orig/configure.ac 2014-06-06 17:42:41.000000000 +0200 +++ my/configure.ac 2014-06-11 11:05:44.000000000 +0200 @@ -865,9 +865,13 @@ warn_llvm="Missing LLVM file TargetData.h. JIT compiler is disabled." fi + AC_CHECK_HEADERS([llvm/IR/Verifier.h]) + OCTAVE_LLVM_FUNCTION_ADDATTRIBUTE_API OCTAVE_LLVM_FUNCTION_ADDFNATTR_API OCTAVE_LLVM_CALLINST_ADDATTRIBUTE_API + OCTAVE_LLVM_RAW_FD_OSTREAM_API + OCTAVE_LLVM_LEGACY_PASSMANAGER_API AC_LANG_POP(C++) CPPFLAGS="$save_CPPFLAGS" CXXFLAGS="$save_CXXFLAGS" diff -Naur orig/doc/doxyhtml/Makefile.in my/doc/doxyhtml/Makefile.in diff -Naur orig/doc/icons/Makefile.in my/doc/icons/Makefile.in diff -Naur orig/doc/interpreter/convhull.eps my/doc/interpreter/convhull.eps diff -Naur orig/doc/interpreter/convhull.pdf my/doc/interpreter/convhull.pdf diff -Naur orig/doc/interpreter/convhull.png my/doc/interpreter/convhull.png diff -Naur orig/doc/interpreter/delaunay.eps my/doc/interpreter/delaunay.eps diff -Naur orig/doc/interpreter/delaunay.pdf my/doc/interpreter/delaunay.pdf diff -Naur orig/doc/interpreter/delaunay.png my/doc/interpreter/delaunay.png diff -Naur orig/doc/interpreter/doc-cache my/doc/interpreter/doc-cache diff -Naur orig/doc/interpreter/errorbar.eps my/doc/interpreter/errorbar.eps diff -Naur orig/doc/interpreter/errorbar.pdf my/doc/interpreter/errorbar.pdf diff -Naur orig/doc/interpreter/errorbar.png my/doc/interpreter/errorbar.png diff -Naur orig/doc/interpreter/extended.eps my/doc/interpreter/extended.eps diff -Naur orig/doc/interpreter/extended.pdf my/doc/interpreter/extended.pdf diff -Naur orig/doc/interpreter/extended.png my/doc/interpreter/extended.png diff -Naur orig/doc/interpreter/gplot.eps my/doc/interpreter/gplot.eps diff -Naur orig/doc/interpreter/gplot.pdf my/doc/interpreter/gplot.pdf diff -Naur orig/doc/interpreter/gplot.png my/doc/interpreter/gplot.png diff -Naur orig/doc/interpreter/griddata.eps my/doc/interpreter/griddata.eps diff -Naur orig/doc/interpreter/griddata.pdf my/doc/interpreter/griddata.pdf diff -Naur orig/doc/interpreter/griddata.png my/doc/interpreter/griddata.png diff -Naur orig/doc/interpreter/grid.eps my/doc/interpreter/grid.eps diff -Naur orig/doc/interpreter/grid.pdf my/doc/interpreter/grid.pdf diff -Naur orig/doc/interpreter/grid.png my/doc/interpreter/grid.png diff -Naur orig/doc/interpreter/hist.eps my/doc/interpreter/hist.eps diff -Naur orig/doc/interpreter/hist.pdf my/doc/interpreter/hist.pdf diff -Naur orig/doc/interpreter/hist.png my/doc/interpreter/hist.png \ Kein Zeilenumbruch am Dateiende. diff -Naur orig/doc/interpreter/inpolygon.eps my/doc/interpreter/inpolygon.eps diff -Naur orig/doc/interpreter/inpolygon.pdf my/doc/interpreter/inpolygon.pdf diff -Naur orig/doc/interpreter/inpolygon.png my/doc/interpreter/inpolygon.png diff -Naur orig/doc/interpreter/interpderiv1.eps my/doc/interpreter/interpderiv1.eps diff -Naur orig/doc/interpreter/interpderiv1.pdf my/doc/interpreter/interpderiv1.pdf diff -Naur orig/doc/interpreter/interpderiv1.png my/doc/interpreter/interpderiv1.png diff -Naur orig/doc/interpreter/interpderiv2.eps my/doc/interpreter/interpderiv2.eps diff -Naur orig/doc/interpreter/interpderiv2.pdf my/doc/interpreter/interpderiv2.pdf diff -Naur orig/doc/interpreter/interpderiv2.png my/doc/interpreter/interpderiv2.png diff -Naur orig/doc/interpreter/interpft.eps my/doc/interpreter/interpft.eps diff -Naur orig/doc/interpreter/interpft.pdf my/doc/interpreter/interpft.pdf diff -Naur orig/doc/interpreter/interpft.png my/doc/interpreter/interpft.png diff -Naur orig/doc/interpreter/interpn.eps my/doc/interpreter/interpn.eps diff -Naur orig/doc/interpreter/interpn.pdf my/doc/interpreter/interpn.pdf diff -Naur orig/doc/interpreter/interpn.png my/doc/interpreter/interpn.png diff -Naur orig/doc/interpreter/Makefile.in my/doc/interpreter/Makefile.in diff -Naur orig/doc/interpreter/mesh.eps my/doc/interpreter/mesh.eps diff -Naur orig/doc/interpreter/mesh.pdf my/doc/interpreter/mesh.pdf diff -Naur orig/doc/interpreter/mesh.png my/doc/interpreter/mesh.png diff -Naur orig/doc/interpreter/octave.dvi my/doc/interpreter/octave.dvi diff -Naur orig/doc/interpreter/octave.html/convhull.png my/doc/interpreter/octave.html/convhull.png diff -Naur orig/doc/interpreter/octave.html/delaunay.png my/doc/interpreter/octave.html/delaunay.png diff -Naur orig/doc/interpreter/octave.html/errorbar.png my/doc/interpreter/octave.html/errorbar.png diff -Naur orig/doc/interpreter/octave.html/extended.png my/doc/interpreter/octave.html/extended.png diff -Naur orig/doc/interpreter/octave.html/gplot.png my/doc/interpreter/octave.html/gplot.png diff -Naur orig/doc/interpreter/octave.html/griddata.png my/doc/interpreter/octave.html/griddata.png diff -Naur orig/doc/interpreter/octave.html/grid.png my/doc/interpreter/octave.html/grid.png diff -Naur orig/doc/interpreter/octave.html/hist.png my/doc/interpreter/octave.html/hist.png \ Kein Zeilenumbruch am Dateiende. diff -Naur orig/doc/interpreter/octave.html/inpolygon.png my/doc/interpreter/octave.html/inpolygon.png diff -Naur orig/doc/interpreter/octave.html/interpderiv1.png my/doc/interpreter/octave.html/interpderiv1.png diff -Naur orig/doc/interpreter/octave.html/interpderiv2.png my/doc/interpreter/octave.html/interpderiv2.png diff -Naur orig/doc/interpreter/octave.html/interpft.png my/doc/interpreter/octave.html/interpft.png diff -Naur orig/doc/interpreter/octave.html/interpn.png my/doc/interpreter/octave.html/interpn.png diff -Naur orig/doc/interpreter/octave.html/mesh.png my/doc/interpreter/octave.html/mesh.png diff -Naur orig/doc/interpreter/octave.html/plot3.png my/doc/interpreter/octave.html/plot3.png diff -Naur orig/doc/interpreter/octave.html/plot.png my/doc/interpreter/octave.html/plot.png diff -Naur orig/doc/interpreter/octave.html/polar.png my/doc/interpreter/octave.html/polar.png diff -Naur orig/doc/interpreter/octave.html/spcholperm.png my/doc/interpreter/octave.html/spcholperm.png diff -Naur orig/doc/interpreter/octave.html/spchol.png my/doc/interpreter/octave.html/spchol.png diff -Naur orig/doc/interpreter/octave.html/splinefit1.png my/doc/interpreter/octave.html/splinefit1.png \ Kein Zeilenumbruch am Dateiende. diff -Naur orig/doc/interpreter/octave.html/splinefit2.png my/doc/interpreter/octave.html/splinefit2.png \ Kein Zeilenumbruch am Dateiende. diff -Naur orig/doc/interpreter/octave.html/splinefit3.png my/doc/interpreter/octave.html/splinefit3.png \ Kein Zeilenumbruch am Dateiende. diff -Naur orig/doc/interpreter/octave.html/splinefit4.png my/doc/interpreter/octave.html/splinefit4.png \ Kein Zeilenumbruch am Dateiende. diff -Naur orig/doc/interpreter/octave.html/splinefit6.png my/doc/interpreter/octave.html/splinefit6.png \ Kein Zeilenumbruch am Dateiende. diff -Naur orig/doc/interpreter/octave.html/spmatrix.png my/doc/interpreter/octave.html/spmatrix.png diff -Naur orig/doc/interpreter/octave.html/triplot.png my/doc/interpreter/octave.html/triplot.png diff -Naur orig/doc/interpreter/octave.html/voronoi.png my/doc/interpreter/octave.html/voronoi.png diff -Naur orig/doc/interpreter/octave.pdf my/doc/interpreter/octave.pdf diff -Naur orig/doc/interpreter/octave.ps my/doc/interpreter/octave.ps diff -Naur orig/doc/interpreter/plot3.eps my/doc/interpreter/plot3.eps diff -Naur orig/doc/interpreter/plot3.pdf my/doc/interpreter/plot3.pdf diff -Naur orig/doc/interpreter/plot3.png my/doc/interpreter/plot3.png diff -Naur orig/doc/interpreter/plot.eps my/doc/interpreter/plot.eps diff -Naur orig/doc/interpreter/plot.pdf my/doc/interpreter/plot.pdf diff -Naur orig/doc/interpreter/plot.png my/doc/interpreter/plot.png diff -Naur orig/doc/interpreter/polar.eps my/doc/interpreter/polar.eps diff -Naur orig/doc/interpreter/polar.pdf my/doc/interpreter/polar.pdf diff -Naur orig/doc/interpreter/polar.png my/doc/interpreter/polar.png diff -Naur orig/doc/interpreter/spchol.eps my/doc/interpreter/spchol.eps diff -Naur orig/doc/interpreter/spchol.pdf my/doc/interpreter/spchol.pdf diff -Naur orig/doc/interpreter/spcholperm.eps my/doc/interpreter/spcholperm.eps diff -Naur orig/doc/interpreter/spcholperm.pdf my/doc/interpreter/spcholperm.pdf diff -Naur orig/doc/interpreter/spcholperm.png my/doc/interpreter/spcholperm.png diff -Naur orig/doc/interpreter/spchol.png my/doc/interpreter/spchol.png diff -Naur orig/doc/interpreter/splinefit1.eps my/doc/interpreter/splinefit1.eps diff -Naur orig/doc/interpreter/splinefit1.pdf my/doc/interpreter/splinefit1.pdf diff -Naur orig/doc/interpreter/splinefit1.png my/doc/interpreter/splinefit1.png \ Kein Zeilenumbruch am Dateiende. diff -Naur orig/doc/interpreter/splinefit2.eps my/doc/interpreter/splinefit2.eps diff -Naur orig/doc/interpreter/splinefit2.pdf my/doc/interpreter/splinefit2.pdf diff -Naur orig/doc/interpreter/splinefit2.png my/doc/interpreter/splinefit2.png \ Kein Zeilenumbruch am Dateiende. diff -Naur orig/doc/interpreter/splinefit3.eps my/doc/interpreter/splinefit3.eps diff -Naur orig/doc/interpreter/splinefit3.pdf my/doc/interpreter/splinefit3.pdf diff -Naur orig/doc/interpreter/splinefit3.png my/doc/interpreter/splinefit3.png \ Kein Zeilenumbruch am Dateiende. diff -Naur orig/doc/interpreter/splinefit4.eps my/doc/interpreter/splinefit4.eps diff -Naur orig/doc/interpreter/splinefit4.pdf my/doc/interpreter/splinefit4.pdf diff -Naur orig/doc/interpreter/splinefit4.png my/doc/interpreter/splinefit4.png \ Kein Zeilenumbruch am Dateiende. diff -Naur orig/doc/interpreter/splinefit6.eps my/doc/interpreter/splinefit6.eps diff -Naur orig/doc/interpreter/splinefit6.pdf my/doc/interpreter/splinefit6.pdf diff -Naur orig/doc/interpreter/splinefit6.png my/doc/interpreter/splinefit6.png \ Kein Zeilenumbruch am Dateiende. diff -Naur orig/doc/interpreter/spmatrix.eps my/doc/interpreter/spmatrix.eps diff -Naur orig/doc/interpreter/spmatrix.pdf my/doc/interpreter/spmatrix.pdf diff -Naur orig/doc/interpreter/spmatrix.png my/doc/interpreter/spmatrix.png diff -Naur orig/doc/interpreter/stamp-vti my/doc/interpreter/stamp-vti diff -Naur orig/doc/interpreter/triplot.eps my/doc/interpreter/triplot.eps diff -Naur orig/doc/interpreter/triplot.pdf my/doc/interpreter/triplot.pdf diff -Naur orig/doc/interpreter/triplot.png my/doc/interpreter/triplot.png diff -Naur orig/doc/interpreter/version.texi my/doc/interpreter/version.texi diff -Naur orig/doc/interpreter/voronoi.eps my/doc/interpreter/voronoi.eps diff -Naur orig/doc/interpreter/voronoi.pdf my/doc/interpreter/voronoi.pdf diff -Naur orig/doc/interpreter/voronoi.png my/doc/interpreter/voronoi.png diff -Naur orig/doc/liboctave/liboctave.dvi my/doc/liboctave/liboctave.dvi diff -Naur orig/doc/liboctave/liboctave.pdf my/doc/liboctave/liboctave.pdf diff -Naur orig/doc/liboctave/liboctave.ps my/doc/liboctave/liboctave.ps diff -Naur orig/doc/liboctave/Makefile.in my/doc/liboctave/Makefile.in diff -Naur orig/doc/liboctave/stamp-vti my/doc/liboctave/stamp-vti diff -Naur orig/doc/liboctave/version.texi my/doc/liboctave/version.texi diff -Naur orig/doc/Makefile.in my/doc/Makefile.in diff -Naur orig/doc/refcard/Makefile.in my/doc/refcard/Makefile.in diff -Naur orig/doc/refcard/refcard-a4.dvi my/doc/refcard/refcard-a4.dvi diff -Naur orig/doc/refcard/refcard-a4.pdf my/doc/refcard/refcard-a4.pdf diff -Naur orig/doc/refcard/refcard-a4.ps my/doc/refcard/refcard-a4.ps diff -Naur orig/doc/refcard/refcard-legal.dvi my/doc/refcard/refcard-legal.dvi diff -Naur orig/doc/refcard/refcard-legal.pdf my/doc/refcard/refcard-legal.pdf diff -Naur orig/doc/refcard/refcard-legal.ps my/doc/refcard/refcard-legal.ps diff -Naur orig/doc/refcard/refcard-letter.dvi my/doc/refcard/refcard-letter.dvi diff -Naur orig/doc/refcard/refcard-letter.pdf my/doc/refcard/refcard-letter.pdf diff -Naur orig/doc/refcard/refcard-letter.ps my/doc/refcard/refcard-letter.ps diff -Naur orig/examples/Makefile.in my/examples/Makefile.in diff -Naur orig/libgnu/Makefile.in my/libgnu/Makefile.in diff -Naur orig/libgui/Makefile.in my/libgui/Makefile.in diff -Naur orig/libinterp/corefcn/jit-typeinfo.cc my/libinterp/corefcn/jit-typeinfo.cc --- orig/libinterp/corefcn/jit-typeinfo.cc 2014-06-06 15:48:37.000000000 +0200 +++ my/libinterp/corefcn/jit-typeinfo.cc 2014-06-11 11:05:44.000000000 +0200 @@ -34,7 +34,12 @@ #include "jit-typeinfo.h" +#ifdef HAVE_LLVM_IR_VERIFIER_H +#include +#else #include +#endif + #include #ifdef HAVE_LLVM_IR_FUNCTION_H diff -Naur orig/libinterp/corefcn/jit-util.h my/libinterp/corefcn/jit-util.h --- orig/libinterp/corefcn/jit-util.h 2014-06-06 15:48:37.000000000 +0200 +++ my/libinterp/corefcn/jit-util.h 2014-06-11 11:05:44.000000000 +0200 @@ -42,8 +42,15 @@ { class Value; class Module; +#ifdef LEGACY_PASSMANAGER + namespace legacy { + class FunctionPassManager; + class PassManager; + } +#else class FunctionPassManager; class PassManager; +#endif class ExecutionEngine; class Function; class BasicBlock; diff -Naur orig/libinterp/corefcn/oct-tex-lexer.cc my/libinterp/corefcn/oct-tex-lexer.cc diff -Naur orig/libinterp/corefcn/oct-tex-parser.cc my/libinterp/corefcn/oct-tex-parser.cc diff -Naur orig/libinterp/corefcn/oct-tex-parser.h my/libinterp/corefcn/oct-tex-parser.h diff -Naur orig/libinterp/corefcn/pt-jit.cc my/libinterp/corefcn/pt-jit.cc --- orig/libinterp/corefcn/pt-jit.cc 2014-06-06 15:48:37.000000000 +0200 +++ my/libinterp/corefcn/pt-jit.cc 2014-06-11 11:05:44.000000000 +0200 @@ -48,11 +48,22 @@ #include #include + +#ifdef HAVE_LLVM_IR_VERIFIER_H +#include +#else #include +#endif + #include #include #include + +#ifdef LEGACY_PASSMANAGER +#include +#else #include +#endif #ifdef HAVE_LLVM_IR_FUNCTION_H #include @@ -1888,10 +1899,15 @@ if (! engine) return false; +#ifdef LEGACY_PASSMANAGER + module_pass_manager = new llvm::legacy::PassManager (); + pass_manager = new llvm::legacy::FunctionPassManager (module); +#else module_pass_manager = new llvm::PassManager (); + pass_manager = new llvm::FunctionPassManager (module); +#endif module_pass_manager->add (llvm::createAlwaysInlinerPass ()); - pass_manager = new llvm::FunctionPassManager (module); #ifdef HAVE_LLVM_DATALAYOUT pass_manager->add (new llvm::DataLayout (*engine->getDataLayout ())); #else @@ -2006,8 +2022,13 @@ if (Vdebug_jit) { std::string error; +#ifdef RAW_FD_OSTREAM_ARG_IS_LLVM_SYS_FS + llvm::raw_fd_ostream fout ("test.bc", error, + llvm::sys::fs::F_Binary); +#else llvm::raw_fd_ostream fout ("test.bc", error, llvm::raw_fd_ostream::F_Binary); +#endif llvm::WriteBitcodeToFile (module, fout); } } diff -Naur orig/libinterp/corefcn/pt-jit.h my/libinterp/corefcn/pt-jit.h --- orig/libinterp/corefcn/pt-jit.h 2014-06-06 15:48:37.000000000 +0200 +++ my/libinterp/corefcn/pt-jit.h 2014-06-11 11:05:44.000000000 +0200 @@ -384,8 +384,13 @@ size_t trip_count (const octave_value& bounds) const; llvm::Module *module; +#ifdef LEGACY_PASSMANAGER + llvm::legacy::PassManager *module_pass_manager; + llvm::legacy::FunctionPassManager *pass_manager; +#else llvm::PassManager *module_pass_manager; llvm::FunctionPassManager *pass_manager; +#endif llvm::ExecutionEngine *engine; }; diff -Naur orig/libinterp/Makefile.in my/libinterp/Makefile.in diff -Naur orig/libinterp/parse-tree/lex.cc my/libinterp/parse-tree/lex.cc diff -Naur orig/libinterp/parse-tree/oct-parse.cc my/libinterp/parse-tree/oct-parse.cc diff -Naur orig/libinterp/parse-tree/oct-parse.h my/libinterp/parse-tree/oct-parse.h diff -Naur orig/liboctave/cruft/Makefile.in my/liboctave/cruft/Makefile.in diff -Naur orig/liboctave/Makefile.in my/liboctave/Makefile.in diff -Naur orig/m4/acinclude.m4 my/m4/acinclude.m4 --- orig/m4/acinclude.m4 2014-06-06 15:48:37.000000000 +0200 +++ my/m4/acinclude.m4 2014-06-11 11:05:44.000000000 +0200 @@ -1713,6 +1713,58 @@ fi ]) dnl +dnl Check for raw_fd_ostream API +dnl +AC_DEFUN([OCTAVE_LLVM_RAW_FD_OSTREAM_API], [ + AC_CACHE_CHECK([check LLVM::raw_fd_ostream arg type is llvm::sys:fs], + [octave_cv_raw_fd_ostream_arg_is_llvm_sys_fs], + [AC_LANG_PUSH(C++) + AC_COMPILE_IFELSE( + [AC_LANG_PROGRAM([[ + #include + ]], [[ + std::string str; + llvm::raw_fd_ostream fout ("", str, llvm::sys::fs::F_Binary); + ]])], + octave_cv_raw_fd_ostream_arg_is_llvm_sys_fs=yes, + octave_cv_raw_fd_ostream_arg_is_llvm_sys_fs=no) + AC_LANG_POP(C++) + ]) + if test $octave_cv_raw_fd_ostream_arg_is_llvm_sys_fs = yes; then + AC_DEFINE(RAW_FD_OSTREAM_ARG_IS_LLVM_SYS_FS, 1, + [Define to 1 if LLVM::raw_fd_ostream arg type is llvm::sys:fs.]) + fi +]) +dnl +dnl Check for legacy::PassManager API +dnl +AC_DEFUN([OCTAVE_LLVM_LEGACY_PASSMANAGER_API], [ + AC_CACHE_CHECK([check for LLVM::legacy::PassManager], + [octave_cv_legacy_passmanager], + [AC_LANG_PUSH(C++) + save_LIBS="$LIBS" + LIBS="$LLVM_LIBS $LIBS" + AC_LINK_IFELSE( + [AC_LANG_PROGRAM([[ + #include + ]], [[ + llvm::Module *module; + llvm::legacy::PassManager *module_pass_manager; + llvm::legacy::FunctionPassManager *pass_manager; + module_pass_manager = new llvm::legacy::PassManager (); + pass_manager = new llvm::legacy::FunctionPassManager (module); + ]])], + octave_cv_legacy_passmanager=yes, + octave_cv_legacy_passmanager=no) + LIBS="$save_LIBS" + AC_LANG_POP(C++) + ]) + if test $octave_cv_legacy_passmanager = yes; then + AC_DEFINE(LEGACY_PASSMANAGER, 1, + [Define to 1 if LLVM::legacy::PassManager exists.]) + fi +]) +dnl dnl Check for ar. dnl AC_DEFUN([OCTAVE_PROG_AR], [ diff -Naur orig/m4/libtool.m4 my/m4/libtool.m4 --- orig/m4/libtool.m4 2014-06-06 17:40:43.000000000 +0200 +++ my/m4/libtool.m4 2014-06-11 11:06:01.000000000 +0200 @@ -1312,7 +1312,7 @@ rm -rf conftest* ;; -x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \ +x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \ s390*-*linux*|s390*-*tpf*|sparc*-*linux*) # Find out which ABI we are using. echo 'int i;' > conftest.$ac_ext @@ -1333,7 +1333,10 @@ ;; esac ;; - ppc64-*linux*|powerpc64-*linux*) + powerpc64le-*) + LD="${LD-ld} -m elf32lppclinux" + ;; + powerpc64-*) LD="${LD-ld} -m elf32ppclinux" ;; s390x-*linux*) @@ -1352,7 +1355,10 @@ x86_64-*linux*) LD="${LD-ld} -m elf_x86_64" ;; - ppc*-*linux*|powerpc*-*linux*) + powerpcle-*) + LD="${LD-ld} -m elf64lppc" + ;; + powerpc-*) LD="${LD-ld} -m elf64ppc" ;; s390*-*linux*|s390*-*tpf*) diff -Naur orig/Makefile.in my/Makefile.in --- orig/Makefile.in 2014-06-06 17:46:01.000000000 +0200 +++ my/Makefile.in 2014-06-11 11:06:49.000000000 +0200 @@ -1,4 +1,4 @@ -# Makefile.in generated by automake 1.14 from Makefile.am. +# Makefile.in generated by automake 1.14.1 from Makefile.am. # @configure_input@ # Copyright (C) 1994-2013 Free Software Foundation, Inc. @@ -2337,9 +2337,10 @@ && dc_destdir="$${TMPDIR-/tmp}/am-dc-$$$$/" \ && am__cwd=`pwd` \ && $(am__cd) $(distdir)/_build \ - && ../configure --srcdir=.. --prefix="$$dc_install_base" \ + && ../configure \ $(AM_DISTCHECK_CONFIGURE_FLAGS) \ $(DISTCHECK_CONFIGURE_FLAGS) \ + --srcdir=.. --prefix="$$dc_install_base" \ && $(MAKE) $(AM_MAKEFLAGS) \ && $(MAKE) $(AM_MAKEFLAGS) dvi \ && $(MAKE) $(AM_MAKEFLAGS) check \ diff -Naur orig/scripts/java/octave.jar my/scripts/java/octave.jar \ Kein Zeilenumbruch am Dateiende. diff -Naur orig/scripts/Makefile.in my/scripts/Makefile.in diff -Naur orig/src/Makefile.in my/src/Makefile.in diff -Naur orig/test/Makefile.in my/test/Makefile.in