giac-1.9.0 build 19 is failing in s390x architecture

Librairie C++ de calcul formel/ C++ symbolic computation library

Modérateur : xcasadmin

sagitter
Messages : 31
Inscription : sam. mai 14, 2016 6:19 pm
Localisation : Italy

giac-1.9.0 build 19 is failing in s390x architecture

Message par sagitter » sam. août 13, 2022 10:19 am

Hi all.

I'm compiling giac-1.9.0 build-19 on Fedora 38 (devel branch) s390x with GCC-12; it's failing with this output:

Code : Tout sélectionner

/bin/sh ../libtool  --tag=CXX   --mode=compile g++ -DHAVE_CONFIG_H -I. -I..  -DIN_GIAC -I. -I.. -I. -I..       -std=gnu++14 -O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1  -m64 -march=zEC12 -mtune=z13 -fasynchronous-unwind-tables -fstack-clash-protection -DDOUBLEVAL -fno-strict-aliasing -DGIAC_GENERIC_CONSTANTS -DTIMEOUT -DHAVE_LIBMICROPYTHON -fpermissive -DQUICKJS -c -o lpsolve.lo lpsolve.cc
libtool: compile:  g++ -DHAVE_CONFIG_H -I. -I.. -DIN_GIAC -I. -I.. -I. -I.. -std=gnu++14 -O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -m64 -march=zEC12 -mtune=z13 -fasynchronous-unwind-tables -fstack-clash-protection -DDOUBLEVAL -fno-strict-aliasing -DGIAC_GENERIC_CONSTANTS -DTIMEOUT -DHAVE_LIBMICROPYTHON -fpermissive -DQUICKJS -c lpsolve.cc  -fPIC -DPIC -o .libs/lpsolve.o
libtool: compile:  g++ -DHAVE_CONFIG_H -I. -I.. -DIN_GIAC -I. -I.. -I. -I.. -std=gnu++14 -O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -m64 -march=zEC12 -mtune=z13 -fasynchronous-unwind-tables -fstack-clash-protection -DDOUBLEVAL -fno-strict-aliasing -DGIAC_GENERIC_CONSTANTS -DTIMEOUT -DHAVE_LIBMICROPYTHON -fpermissive -DQUICKJS -c lpsolve.cc -o lpsolve.o >/dev/null 2>&1
In file included from giacPCH.h:8,
                 from lpsolve.cc:20:
index.h:33: warning: ignoring '#pragma anon_unions ' [-Wunknown-pragmas]
   33 | #pragma anon_unions
      | 
In file included from poly.h:26,
                 from gen.h:71,
                 from giacPCH.h:32:
monomial.h:341:10: warning: 'template<class _Arg1, class _Arg2, class _Result> class std::pointer_to_binary_function' is deprecated [-Wdeprecated-declarations]
  341 |     std::pointer_to_binary_function < const monomial<T> &, const monomial<T> &, bool> strictly_greater ;
      |          ^~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /usr/include/c++/12/bits/refwrap.h:39,
                 from /usr/include/c++/12/vector:66,
                 from vector.h:474,
                 from index.h:21:
/usr/include/c++/12/bits/stl_function.h:1131:11: note: declared here
 1131 |     class pointer_to_binary_function
      |           ^~~~~~~~~~~~~~~~~~~~~~~~~~
monomial.h:342:28: warning: 'template<class _Arg1, class _Arg2, class _Result> class std::pointer_to_binary_function' is deprecated [-Wdeprecated-declarations]
  342 |     sort_helper(const std::pointer_to_binary_function < const monomial<T> &, const monomial<T> &, bool> is_strictly_greater):strictly_greater(is_strictly_greater) {};
      |                            ^~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/12/bits/stl_function.h:1131:11: note: declared here
 1131 |     class pointer_to_binary_function
      |           ^~~~~~~~~~~~~~~~~~~~~~~~~~
monomial.h:680:25: warning: 'template<class _Arg1, class _Arg2, class _Result> class std::pointer_to_binary_function' is deprecated [-Wdeprecated-declarations]
  680 |              const std::pointer_to_binary_function < const monomial<T> &, const monomial<T> &, bool> m_is_strictly_greater
      |                         ^~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/12/bits/stl_function.h:1131:11: note: declared here
 1131 |     class pointer_to_binary_function
      |           ^~~~~~~~~~~~~~~~~~~~~~~~~~
monomial.h: In function 'void giac::Mul(typename std::vector<monomial<T> >::const_iterator&, typename std::vector<monomial<T> >::const_iterator&, typename std::vector<monomial<T> >::const_iterator&, typename std::vector<monomial<T> >::const_iterator&, std::vector<monomial<T> >&, bool (*)(const index_m&, const index_m&), std::pointer_to_binary_function<const monomial<T>&, const monomial<T>&, bool>)':
monomial.h:729:44: warning: 'template<class _Arg1, class _Arg2, class _Result> class std::pointer_to_binary_function' is deprecated [-Wdeprecated-declarations]
  729 |     typedef std::map< index_t,T,const std::pointer_to_binary_function < const index_m &, const index_m &, bool> > application;
      |                                            ^~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/12/bits/stl_function.h:1131:11: note: declared here
 1131 |     class pointer_to_binary_function
      |           ^~~~~~~~~~~~~~~~~~~~~~~~~~
monomial.h:730:37: warning: 'std::pointer_to_binary_function<_Arg1, _Arg2, _Result> std::ptr_fun(_Result (*)(_Arg1, _Arg2)) [with _Arg1 = const giac::index_m&; _Arg2 = const giac::index_m&; _Result = bool]' is deprecated: use 'std::function' instead [-Wdeprecated-declarations]
  730 |     application produit(std::ptr_fun(is_strictly_greater));
      |                         ~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/12/bits/stl_function.h:1153:5: note: declared here
 1153 |     ptr_fun(_Result (*__x)(_Arg1, _Arg2))
      |     ^~~~~~~
poly.h: At global scope:
poly.h:43:10: warning: 'template<class _Arg1, class _Arg2, class _Result> class std::pointer_to_binary_function' is deprecated [-Wdeprecated-declarations]
   43 |     std::pointer_to_binary_function < const monomial<T> &, const monomial<T> &, bool> m_is_strictly_greater ;
      |          ^~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/12/bits/stl_function.h:1131:11: note: declared here
 1131 |     class pointer_to_binary_function
      |           ^~~~~~~~~~~~~~~~~~~~~~~~~~
gen.h: In constructor 'giac::eqwdata::eqwdata(int, int, int, int, const giac::attributs&, const giac::gen&)':
gen.h:1408:15: warning: 'giac::eqwdata::eqw_attributs' will be initialized after [-Wreorder]
 1408 |     attributs eqw_attributs;
      |               ^~~~~~~~~~~~~
gen.h:1401:9: warning:   'int giac::eqwdata::x' [-Wreorder]
 1401 |     int x,y,dx,dy;
      |         ^
gen.h:1409:5: warning:   when initialized here [-Wreorder]
 1409 |     eqwdata(int dxx,int dyy,int xx, int yy,const attributs & a,const gen& gg):g(gg),eqw_attributs(a),x(xx),y(yy),dx(dxx),dy(dyy),selected(false),active(false),hasbaseline(false),modifiable(true),baseline(0) {};
      |     ^~~~~~~
gen.h:1407:10: warning: 'giac::eqwdata::modifiable' will be initialized after [-Wreorder]
 1407 |     bool modifiable;
      |          ^~~~~~~~~~
gen.h:1402:9: warning:   'int giac::eqwdata::baseline' [-Wreorder]
 1402 |     int baseline;
      |         ^~~~~~~~
gen.h:1409:5: warning:   when initialized here [-Wreorder]
 1409 |     eqwdata(int dxx,int dyy,int xx, int yy,const attributs & a,const gen& gg):g(gg),eqw_attributs(a),x(xx),y(yy),dx(dxx),dy(dyy),selected(false),active(false),hasbaseline(false),modifiable(true),baseline(0) {};
      |     ^~~~~~~
gen.h: In constructor 'giac::eqwdata::eqwdata(int, int, int, int, const giac::attributs&, const giac::gen&, int)':
gen.h:1408:15: warning: 'giac::eqwdata::eqw_attributs' will be initialized after [-Wreorder]
 1408 |     attributs eqw_attributs;
      |               ^~~~~~~~~~~~~
gen.h:1401:9: warning:   'int giac::eqwdata::x' [-Wreorder]
 1401 |     int x,y,dx,dy;
      |         ^
gen.h:1410:5: warning:   when initialized here [-Wreorder]
 1410 |     eqwdata(int dxx,int dyy,int xx, int yy,const attributs & a,const gen& gg,int mybaseline):g(gg),eqw_attributs(a),x(xx),y(yy),dx(dxx),dy(dyy),selected(false),active(false),hasbaseline(true),modifiable(true),baseline(mybaseline) {};
      |     ^~~~~~~
gen.h:1407:10: warning: 'giac::eqwdata::modifiable' will be initialized after [-Wreorder]
 1407 |     bool modifiable;
      |          ^~~~~~~~~~
gen.h:1402:9: warning:   'int giac::eqwdata::baseline' [-Wreorder]
 1402 |     int baseline;
      |         ^~~~~~~~
gen.h:1410:5: warning:   when initialized here [-Wreorder]
 1410 |     eqwdata(int dxx,int dyy,int xx, int yy,const attributs & a,const gen& gg,int mybaseline):g(gg),eqw_attributs(a),x(xx),y(yy),dx(dxx),dy(dyy),selected(false),active(false),hasbaseline(true),modifiable(true),baseline(mybaseline) {};
      |     ^~~~~~~
In file included from sym2poly.h:27,
                 from giacPCH.h:38:
gausspol.h: At global scope:
gausspol.h:96:29: warning: 'template<class _Arg1, class _Arg2, class _Result> class std::pointer_to_binary_function' is deprecated [-Wdeprecated-declarations]
   96 |                  const std::pointer_to_binary_function < const monomial<gen> &, const monomial<gen> &, bool> m_is_greater
      |                             ^~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/12/bits/stl_function.h:1131:11: note: declared here
 1131 |     class pointer_to_binary_function
      |           ^~~~~~~~~~~~~~~~~~~~~~~~~~
lpsolve.cc: In member function 'bool giac::lp_node::rounding_heuristic(giac::vecteur&, giac::gen&) const':
lpsolve.cc:850:12: warning: unused variable 'viol' [-Wunused-variable]
  850 |     double viol;
      |            ^~~~
lpsolve.cc:851:9: warning: unused variable 'vc' [-Wunused-variable]
  851 |     int vc,j,last_j=-1,pass=0;
      |         ^~
lpsolve.cc:851:24: warning: unused variable 'pass' [-Wunused-variable]
  851 |     int vc,j,last_j=-1,pass=0;
      |                        ^~~~
lpsolve.cc: In member function 'int giac::lp_problem::solve()':
lpsolve.cc:1678:35: warning: unused variable 'fr' [-Wunused-variable]
 1678 |                 double opt_lbound,fr,max_score;
      |                                   ^~
lpsolve.cc: In member function 'giac::lp_node::change_basis(giac::dbgprint_vector<giac::gen>&, giac::dbgprint_vector<giac::gen> const&, std::vector<bool, std::allocator<bool> >&, std::vector<int, std::allocator<int> >&, std::vector<int, std::allocator<int> >&)':
lpsolve.cc:369:13: warning: 'lr' may be used uninitiamake[2]: Leaving directory '/builddir/build/BUILD/giac-1.9.0/src'
lized [-Wmaybe-uninitialized]
  369 |     basis[lr]=ev;
      |             ^
lpsolve.cc:303:15: note: 'lr' was declared here
  303 |     int ec,ev,lr,lv,nc=cols.size(),nr=basis.size();
      |               ^~
lpsolve.cc:354:31: warning: 'ec' may be used uninitialized [-Wmaybe-uninitialized]
  354 |             a=it->_VECTptr->at(ec);
      |               ~~~~~~~~~~~~~~~~^~~~
lpsolve.cc:303:9: note: 'ec' was declared here
  303 |     int ec,ev,lr,lv,nc=cols.size(),nr=basis.size();
      |         ^~
lpsolve.cc: In member function 'giac::lp_problem::glpk_solve()':
lpsolve.cc:2214:16: warning: 'solution_status' may be used uninitialized [-Wmaybe-uninitialized]
 2214 |         return solution_status;
      |                ^~~~~~~~~~~~~~~
lpsolve.cc:2118:18: note: 'solution_status' was declared here
 2118 |     int result=0,solution_status;
      |                  ^~~~~~~~~~~~~~~
lpsolve.cc:2212:22: warning: 'term_old' may be used uninitialized [-Wmaybe-uninitialized]
 2212 |     else glp_term_out(term_old);
      |          ~~~~~~~~~~~~^~~~~~~~~~
lpsolve.cc:2113:9: note: 'term_old' was declared here
 2113 |     int term_old;
      |         ^~~~~~~~
lpsolve.cc: In member function 'giac::lp_node::solve_relaxation()':
lpsolve.cc:731:37: warning: 'cuts0' may be used uninitialized [-Wmaybe-uninitialized]
  731 |         if (prob->stats.cuts_applied-cuts0>=prob->settings.max_cuts)
      |             ~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~
lpsolve.cc:647:16: note: 'cuts0' was declared here
  647 |     int pass=0,cuts0;
      |                ^~~~~
In member function 'giac::gen::operator=(giac::gen const&)',
    inlined from 'giac::gen::operator=(giac::gen const&)' at gen.h:747:11,
    inlined from 'giac::lp_problem::glpk_load_from_file(char const*)' at lpsolve.cc:2287:40:
gen.h:767:17: warning: 'D.270177.subtype' may be used uninitialized [-Wmaybe-uninitialized]
  767 |       subtype=a.subtype;
      |               ~~^~~~~~~
lpsolve.cc: In member function 'giac::lp_problem::glpk_load_from_file(char const*)':
lpsolve.cc:2287:40: note: '<anonymous>' declared here
 2287 |                     row[ind[j]-1]=val[j];
      |                                        ^
In file included from /usr/include/c++/12/cmath:47,
                 from first.h:538,
                 from giacPCH.h:4:
In function 'std::abs(double)',
    inlined from 'giac::lp_problem::solve()' at lpsolve.cc:1780:100:
/usr/include/c++/12/bits/std_abs.h:72:30: warning: 'opt_approx' may be used uninitialized [-Wmaybe-uninitialized]
   72 |   { return __builtin_fabs(__x); }
      |                              ^
lpsolve.cc: In member function 'giac::lp_problem::solve()':
lpsolve.cc:1658:20: note: 'opt_approx' was declared here
 1658 |             double opt_approx;
      |                    ^~~~~~~~~~
lpsolve.cc: In function 'giac::_lpsolve(giac::gen const&, giac::context const*)':
lpsolve.cc:2697:28: warning: 'is_solver_exact' may be used uninitialized [-Wmaybe-uninitialized]
 2697 |     switch (is_solver_exact?prob.solve():prob.glpk_solve()) {
      |             ~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
lpsolve.cc:2677:10: note: 'is_solver_exact' was declared here
 2677 |     bool is_solver_exact;
      |          ^~~~~~~~~~~~~~~
make[1]: *** [Makefile:500: all-recursive] Error 1
Full build log: https://kojipkgs.fedoraproject.org//wor ... /build.log
mailto: sagitter 'at' fedoraproject 'dot' org
https://fedoraproject.org/wiki/User:Sagitter

parisse
Messages : 5731
Inscription : mar. déc. 20, 2005 4:02 pm
Contact :

Re: giac-1.9.0 build 19 is failing in s390x architecture

Message par parisse » sam. août 13, 2022 2:58 pm

I must miss something because I can only see warnings, therefore I don't understand why the compilation fails.

sagitter
Messages : 31
Inscription : sam. mai 14, 2016 6:19 pm
Localisation : Italy

Re: giac-1.9.0 build 19 is failing in s390x architecture

Message par sagitter » dim. août 14, 2022 4:02 pm

Yes, the error is not showed in my post but it's displayed in the full build log. I guess it is:

Code : Tout sélectionner

optimization.cc: In member function 'bool giac::nlp_problem::de_initialize(giac::iterateur&, const giac::iterateur&, giac::iterateur&, giac::iterateur&, int&)':
optimization.cc:4828:73: error: cannot convert 'giac::iterateur' {aka 'std::vector<giac::gen, std::allocator<giac::gen> >::iterator'} to 'giac::gen*'
 4828 |         if ((i>=ips || !ok) && !make_random_initial_point(*kt->_VECTptr,ft))
      |                                                                         ^~
      |                                                                         |
      |                                                                         giac::iterateur {aka std::vector<giac::gen, std::allocator<giac::gen> >::iterator}
Inside of:

Code : Tout sélectionner

/bin/sh ../libtool  --tag=CXX   --mode=compile g++ -DHAVE_CONFIG_H -I. -I..  -DIN_GIAC -I. -I.. -I. -I..       -std=gnu++14 -O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1  -m64 -march=zEC12 -mtune=z13 -fasynchronous-unwind-tables -fstack-clash-protection -DDOUBLEVAL -fno-strict-aliasing -DGIAC_GENERIC_CONSTANTS -DTIMEOUT -DHAVE_LIBMICROPYTHON -fpermissive -DQUICKJS -c -o optimization.lo optimization.cc
libtool: compile:  g++ -DHAVE_CONFIG_H -I. -I.. -DIN_GIAC -I. -I.. -I. -I.. -std=gnu++14 -O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -m64 -march=zEC12 -mtune=z13 -fasynchronous-unwind-tables -fstack-clash-protection -DDOUBLEVAL -fno-strict-aliasing -DGIAC_GENERIC_CONSTANTS -DTIMEOUT -DHAVE_LIBMICROPYTHON -fpermissive -DQUICKJS -c optimization.cc  -fPIC -DPIC -o .libs/optimization.o
In file included from giacPCH.h:8,
                 from optimization.cc:21:
index.h:33: warning: ignoring '#pragma anon_unions ' [-Wunknown-pragmas]
   33 | #pragma anon_unions
      | 
In file included from poly.h:26,
                 from gen.h:71,
                 from giacPCH.h:32:
monomial.h:341:10: warning: 'template<class _Arg1, class _Arg2, class _Result> class std::pointer_to_binary_function' is deprecated [-Wdeprecated-declarations]
  341 |     std::pointer_to_binary_function < const monomial<T> &, const monomial<T> &, bool> strictly_greater ;
      |          ^~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /usr/include/c++/12/bits/refwrap.h:39,
                 from /usr/include/c++/12/vector:66,
                 from vector.h:474,
                 from index.h:21:
/usr/include/c++/12/bits/stl_function.h:1131:11: note: declared here
 1131 |     class pointer_to_binary_function
      |           ^~~~~~~~~~~~~~~~~~~~~~~~~~
monomial.h:342:28: warning: 'template<class _Arg1, class _Arg2, class _Result> class std::pointer_to_binary_function' is deprecated [-Wdeprecated-declarations]
  342 |     sort_helper(const std::pointer_to_binary_function < const monomial<T> &, const monomial<T> &, bool> is_strictly_greater):strictly_greater(is_strictly_greater) {};
      |                            ^~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/12/bits/stl_function.h:1131:11: note: declared here
 1131 |     class pointer_to_binary_function
      |           ^~~~~~~~~~~~~~~~~~~~~~~~~~
monomial.h:680:25: warning: 'template<class _Arg1, class _Arg2, class _Result> class std::pointer_to_binary_function' is deprecated [-Wdeprecated-declarations]
  680 |              const std::pointer_to_binary_function < const monomial<T> &, const monomial<T> &, bool> m_is_strictly_greater
      |                         ^~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/12/bits/stl_function.h:1131:11: note: declared here
 1131 |     class pointer_to_binary_function
      |           ^~~~~~~~~~~~~~~~~~~~~~~~~~
monomial.h: In function 'void giac::Mul(typename std::vector<monomial<T> >::const_iterator&, typename std::vector<monomial<T> >::const_iterator&, typename std::vector<monomial<T> >::const_iterator&, typename std::vector<monomial<T> >::const_iterator&, std::vector<monomial<T> >&, bool (*)(const index_m&, const index_m&), std::pointer_to_binary_function<const monomial<T>&, const monomial<T>&, bool>)':
monomial.h:729:44: warning: 'template<class _Arg1, class _Arg2, class _Result> class std::pointer_to_binary_function' is deprecated [-Wdeprecated-declarations]
  729 |     typedef std::map< index_t,T,const std::pointer_to_binary_function < const index_m &, const index_m &, bool> > application;
      |                                            ^~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/12/bits/stl_function.h:1131:11: note: declared here
 1131 |     class pointer_to_binary_function
      |           ^~~~~~~~~~~~~~~~~~~~~~~~~~
monomial.h:730:37: warning: 'std::pointer_to_binary_function<_Arg1, _Arg2, _Result> std::ptr_fun(_Result (*)(_Arg1, _Arg2)) [with _Arg1 = const giac::index_m&; _Arg2 = const giac::index_m&; _Result = bool]' is deprecated: use 'std::function' instead [-Wdeprecated-declarations]
  730 |     application produit(std::ptr_fun(is_strictly_greater));
      |                         ~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/12/bits/stl_function.h:1153:5: note: declared here
 1153 |     ptr_fun(_Result (*__x)(_Arg1, _Arg2))
      |     ^~~~~~~
poly.h: At global scope:
poly.h:43:10: warning: 'template<class _Arg1, class _Arg2, class _Result> class std::pointer_to_binary_function' is deprecated [-Wdeprecated-declarations]
   43 |     std::pointer_to_binary_function < const monomial<T> &, const monomial<T> &, bool> m_is_strictly_greater ;
      |          ^~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/12/bits/stl_function.h:1131:11: note: declared here
 1131 |     class pointer_to_binary_function
      |           ^~~~~~~~~~~~~~~~~~~~~~~~~~
gen.h: In constructor 'giac::eqwdata::eqwdata(int, int, int, int, const giac::attributs&, const giac::gen&)':
gen.h:1408:15: warning: 'giac::eqwdata::eqw_attributs' will be initialized after [-Wreorder]
 1408 |     attributs eqw_attributs;
      |               ^~~~~~~~~~~~~
gen.h:1401:9: warning:   'int giac::eqwdata::x' [-Wreorder]
 1401 |     int x,y,dx,dy;
      |         ^
gen.h:1409:5: warning:   when initialized here [-Wreorder]
 1409 |     eqwdata(int dxx,int dyy,int xx, int yy,const attributs & a,const gen& gg):g(gg),eqw_attributs(a),x(xx),y(yy),dx(dxx),dy(dyy),selected(false),active(false),hasbaseline(false),modifiable(true),baseline(0) {};
      |     ^~~~~~~
gen.h:1407:10: warning: 'giac::eqwdata::modifiable' will be initialized after [-Wreorder]
 1407 |     bool modifiable;
      |          ^~~~~~~~~~
gen.h:1402:9: warning:   'int giac::eqwdata::baseline' [-Wreorder]
 1402 |     int baseline;
      |         ^~~~~~~~
gen.h:1409:5: warning:   when initialized here [-Wreorder]
 1409 |     eqwdata(int dxx,int dyy,int xx, int yy,const attributs & a,const gen& gg):g(gg),eqw_attributs(a),x(xx),y(yy),dx(dxx),dy(dyy),selected(false),active(false),hasbaseline(false),modifiable(true),baseline(0) {};
      |     ^~~~~~~
gen.h: In constructor 'giac::eqwdata::eqwdata(int, int, int, int, const giac::attributs&, const giac::gen&, int)':
gen.h:1408:15: warning: 'giac::eqwdata::eqw_attributs' will be initialized after [-Wreorder]
 1408 |     attributs eqw_attributs;
      |               ^~~~~~~~~~~~~
gen.h:1401:9: warning:   'int giac::eqwdata::x' [-Wreorder]
 1401 |     int x,y,dx,dy;
      |         ^
gen.h:1410:5: warning:   when initialized here [-Wreorder]
 1410 |     eqwdata(int dxx,int dyy,int xx, int yy,const attributs & a,const gen& gg,int mybaseline):g(gg),eqw_attributs(a),x(xx),y(yy),dx(dxx),dy(dyy),selected(false),active(false),hasbaseline(true),modifiable(true),baseline(mybaseline) {};
      |     ^~~~~~~
gen.h:1407:10: warning: 'giac::eqwdata::modifiable' will be initialized after [-Wreorder]
 1407 |     bool modifiable;
      |          ^~~~~~~~~~
gen.h:1402:9: warning:   'int giac::eqwdata::baseline' [-Wreorder]
 1402 |     int baseline;
      |         ^~~~~~~~
gen.h:1410:5: warning:   when initialized here [-Wreorder]
 1410 |     eqwdata(int dxx,int dyy,int xx, int yy,const attributs & a,const gen& gg,int mybaseline):g(gg),eqw_attributs(a),x(xx),y(yy),dx(dxx),dy(dyy),selected(false),active(false),hasbaseline(true),modifiable(true),baseline(mybaseline) {};
      |     ^~~~~~~
In file included from sym2poly.h:27,
                 from giacPCH.h:38:
gausspol.h: At global scope:
gausspol.h:96:29: warning: 'template<class _Arg1, class _Arg2, class _Result> class std::pointer_to_binary_function' is deprecated [-Wdeprecated-declarations]
   96 |                  const std::pointer_to_binary_function < const monomial<gen> &, const monomial<gen> &, bool> m_is_greater
      |                             ^~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/12/bits/stl_function.h:1131:11: note: declared here
 1131 |     class pointer_to_binary_function
      |           ^~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from optimization.cc:25:
graphe.h: In static member function 'static void giac::graphe::clear_point_coords(point&)':
graphe.h:817:48: warning: label 'std' defined but not used [-Wunused-label]
  817 |     static void clear_point_coords(point &p) { std:fill(p.begin(),p.end(),0); }
      |                                                ^~~
optimization.cc: In function 'void giac::rand_multinormal(const vecteur&, const gen&, vecteur&, const context*)':
optimization.cc:741:21: warning: unused variable 'i' [-Wunused-variable]
  741 |     int n=mu.size(),i;
      |                     ^
optimization.cc: In function 'void giac::find_local_extrema(vecteur&, const gen&, const vecteur&, const vecteur&, const ipdiff::ivector&, const vecteur&, const vecteur&, bool, const vecteur&, const gen_map&, int, bool, bool, const context*)':
optimization.cc:1905:36: warning: unused variable 'cpt' [-Wunused-variable]
 1905 |                     const vecteur &cpt=*it->_VECTptr;
      |                                    ^~~
optimizationmake[2]: Leaving directory '/builddir/build/BUILD/giac-1.9.0/src'
.cc: In member function 'void giac::nlp_problem::initialize(int, const meth_parm&)':
optimization.cc:3570:28: warning: suggest parentheses around assignment used as truth value [-Wparentheses]
 3570 |             if (_smooth_obj=!has_diff(obj_gradient,vars) && !has_breaks(obj_gradient))
      |                 ~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
optimization.cc: In member function 'void giac::nlp_problem::remove_redundant_constraints()':
optimization.cc:3682:14: warning: unused variable 'ch' [-Wunused-variable]
 3682 |     int rm=0,ch=0;
      |              ^~
optimization.cc: In member function 'bool giac::nlp_problem::preprocess()':
optimization.cc:3989:20: warning: suggest parentheses around assignment used as truth value [-Wparentheses]
 3989 |         if (changed=!fxv.names.empty()) {
      |             ~~~~~~~^~~~~~~~~~~~~~~~~~~
optimization.cc: In member function 'bool giac::nlp_problem::nelder_mead(const meth_parm&, optima_t&)':
optimization.cc:4683:41: warning: unused variable 'has_ips' [-Wunused-variable]
 4683 |     bool no_gsl=has_bounded_variables(),has_ips=!initp.empty(),fixed_penalty=false;
      |                                         ^~~~~~~
optimization.cc: In member function 'bool giac::nlp_problem::de_initialize(giac::iterateur&, const giac::iterateur&, giac::iterateur&, giac::iterateur&, int&)':
optimization.cc:4828:73: error: cannot convert 'giac::iterateur' {aka 'std::vector<giac::gen, std::allocator<giac::gen> >::iterator'} to 'giac::gen*'
 4828 |         if ((i>=ips || !ok) && !make_random_initial_point(*kt->_VECTptr,ft))
      |                                                                         ^~
      |                                                                         |
      |                                                                         giac::iterateur {aka std::vector<giac::gen, std::allocator<giac::gen> >::iterator}
optimization.cc:4367:61: note:   initializing argument 2 of 'bool giac::nlp_problem::make_random_initial_point(giac::vecteur&, giac::gen*, int, double)'
 4367 | bool nlp_problem::make_random_initial_point(vecteur &x,gen *fval,int nsamp,double sigma_scale) {
      |                                                        ~~~~~^~~~
In file included from optimization.cc:23:
optimization.h: In constructor 'giac::nlp_problem::ipt_solver::ipt_solver(giac::nlp_problem&, const giac::nlp_problem::meth_parm&)':
optimization.h:375:22: warning: 'giac::nlp_problem::ipt_solver::prob' will be initialized after [-Wreorder]
  375 |         nlp_problem &prob;
      |                      ^~~~
optimization.h:374:24: warning:   'const giac::context* giac::nlp_problem::ipt_solver::ctx' [-Wreorder]
  374 |         const context *ctx;
      |                        ^~~
optimization.cc:5040:1: warning:   when initialized here [-Wreorder]
 5040 | nlp_problem::ipt_solver::ipt_solver(nlp_problem &p,const meth_parm &parm) : prob(p), ctx(p.ctx) {
      | ^~~~~~~~~~~
optimization.cc: In member function 'bool giac::nlp_problem::ipt_solver::IC(const giac::matrice&)':
optimization.cc:5135:30: warning: unused variable 'j' [-Wunused-variable]
 5135 |     int n_pos,n_neg,n_zero,i,j;
      |                              ^
optimization.cc: In member function 'int giac::nlp_problem::ipt_solver::ls_filter_barrier_method(giac::vecteur&, giac::vecteur&, giac::vecteur&, double)':
optimization.cc:5316:52: warning: unused variable 'feas_restored' [-Wunused-variable]
 5316 |     bool prev_iter_full_step=false,converged=false,feas_restored=false,first_trial_stepsize_rejected,accepted;
      |                                                    ^~~~~~~~~~~~~
optimization.cc: In member function 'int giac::nlp_problem::optimize(int, const meth_parm&, const giac::vecteur&, giac::vecteur&, giac::gen&)':
optimization.cc:6345:29: warning: unused variable 'gslm' [-Wunused-variable]
 6345 |                 gsl_matrix *gslm=gsl_matrix_alloc(n,n);
      |                             ^~~~
optimization.cc:6346:24: warning: unused variable 'j' [-Wunused-variable]
 6346 |                 size_t j,k;
      |                        ^
optimization.cc:6346:26: warning: unused variable 'k' [-Wunused-variable]
 6346 |                 size_t j,k;
      |                          ^
optimization.cc:6154:13: warning: unused variable 'max_tries' [-Wunused-variable]
 6154 |         int max_tries=5,tries=0;
      |             ^~~~~~~~~
optimization.cc:6154:25: warning: unused variable 'tries' [-Wunused-variable]
 6154 |         int max_tries=5,tries=0;
      |                         ^~~~~
optimization.cc:6155:14: warning: unused variable 'direct_meth' [-Wunused-variable]
 6155 |         bool direct_meth=method>_NLP_INTERIOR_POINT;
      |              ^~~~~~~~~~~
optimization.cc:6305:14: warning: unused variable 'has_failed' [-Wunused-variable]
 6305 |         bool has_failed;
      |              ^~~~~~~~~~
optimization.cc: In static member function 'static bool giac::nlp_problem::ampl_load(const std::string&, giac::vecteur&, giac::vecteur&, giac::vecteur&, std::string&, const giac::context*)':
optimization.cc:6581:16: warning: unused variable 'p' [-Wunused-variable]
 6581 |     size_t pos,p;
      |                ^
optimization.cc: In function 'giac::gen giac::_nlpsolve(const gen&, const context*)':
optimization.cc:6802:9: warning: unused variable 'wc' [-Wunused-variable]
 6802 |     int wc=0,method=_NLP_AUTOMATIC;
      |         ^~
optimization.cc: In function 'giac::gen giac::_numdiff(const gen&, const context*)':
optimization.cc:8466:13: warning: unused variable 'N' [-Wunused-variable]
 8466 |     int M=1,N=X.size()-1;
      |             ^
optimization.cc: In function 'int giac::kmeans(const matrice&, int&, int, int&, int, std::vector<int>&, vecteur*, matrice*, const context*)':
optimization.cc:10887:13: warning: unused variable 'best_k' [-Wunused-variable]
10887 |         int best_k=0,meth=-k;
      |             ^~~~~~
optimization.h: In constructor 'giac::FDWeights::FDWeights(const giac::vecteur&, int, const giac::context*)':
optimization.h:665:20: warning: 'giac::FDWeights::ctx' will be initialized after [-Wreorder]
  665 |     const context *ctx;
      |                    ^~~
optimization.h:661:20: warning:   'const giac::vecteur& giac::FDWeights::z' [-Wreorder]
  661 |     const vecteur &z;
      |                    ^
optimization.cc:12764:1: warning:   when initialized here [-Wreorder]
12764 | FDWeights::FDWeights(const vecteur &grid_points,int diff_order,GIAC_CONTEXT) : ctx(contextptr),z(grid_points) {
      | ^~~~~~~~~
make[2]: *** [Makefile:993: optimization.lo] Error 1
mailto: sagitter 'at' fedoraproject 'dot' org
https://fedoraproject.org/wiki/User:Sagitter

parisse
Messages : 5731
Inscription : mar. déc. 20, 2005 4:02 pm
Contact :

Re: giac-1.9.0 build 19 is failing in s390x architecture

Message par parisse » lun. août 15, 2022 12:30 pm

Then it should work with

Code : Tout sélectionner

        if ((i>=ips || !ok) && !make_random_initial_point(*kt->_VECTptr,&*ft))

sagitter
Messages : 31
Inscription : sam. mai 14, 2016 6:19 pm
Localisation : Italy

Re: giac-1.9.0 build 19 is failing in s390x architecture

Message par sagitter » jeu. août 18, 2022 4:43 pm

parisse a écrit :
lun. août 15, 2022 12:30 pm
Then it should work with

Code : Tout sélectionner

        if ((i>=ips || !ok) && !make_random_initial_point(*kt->_VECTptr,&*ft))
This patch is working. Thank you.

Code : Tout sélectionner

--- a/src/optimization.orig.cc	2022-04-11 09:52:40.000000000 +0200
+++ b/src/optimization.cc	2022-08-18 17:58:16.714974337 +0200
@@ -4825,7 +4825,7 @@
             *kt=initp[i];
             ok=compute_obj_val(*kt->_VECTptr,*ft);
         } else *kt=vecteur(0);
-        if ((i>=ips || !ok) && !make_random_initial_point(*kt->_VECTptr,ft))
+        if ((i>=ips || !ok) && !make_random_initial_point(*kt->_VECTptr,&*ft))
             return false;
         if (is_strictly_greater(best_obj_val,*ft,ctx)) {
             best_obj_val=*ft;
mailto: sagitter 'at' fedoraproject 'dot' org
https://fedoraproject.org/wiki/User:Sagitter

Répondre