|Re: [eigen] gcc 7.1 fails to build projects that depend on libeigen|
[ Thread Index | Date Index | More lists.tuxfamily.org/eigen Archives ]
I did not see that one because I only checked the devel branch and this piece of code does not exist anymore. I have to admit that these lines are very suspicious as I guess that what we wanted here was:alignmentPattern==FirstAlignedThis does not make much differences (which is why it worked so far), this is just more consistent. Nonetheless, perhaps I should simply backport my rewrite of these kernels (up to x2 speedup with AVX/FMA).gaelOn Mon, Jun 26, 2017 at 2:07 PM, Dmitry Rozhkov <dmitry.rozhkov@xxxxxxxxxxx.
com> wrote:Thanks! That helps a lot.
Now compilation fails at
h:186:26: error: enum constant in boolean context [-Werror=int-in-bool-
| const Index offset1 = (FirstAligned && alignmentStep==1)?3:1;
h:187:26: error: enum constant in boolean context [-Werror=int-in-bool-
| const Index offset3 = (FirstAligned && alignmentStep==1)?1:3;
IIUC FirstAligned is a constant always equal to 2. Isn't this first AND
operand redundant then?
On Mon, 2017-06-26 at 10:55 +0200, Gael Guennebaud wrote:
> ah, nevermind, I initially thought it complained about any usage of
> enums as boolean, but that's only the case if the enum value is not 0
> or 1, so here is the fix:
> On Sun, Jun 25, 2017 at 9:55 PM, Gael Guennebaud <gael.guennebaud@gma
> il.com> wrote:
> > Hi,
> > sorry for late replay, but that's not as easy as replacing them by
> > static const bool, see for instance this old thread: http://eigen.t
> > uxfamily.narkive..com/GatL7TiX/
> > class-members-instead-of-enum-
> > So the current workaround is to disable this warning: -Wno-int-in-
> > bool-context.
> > gael
> > On Fri, Jun 16, 2017 at 3:25 PM, Dmitry Rozhkov <dmitry.rozhkov@lin
> > ux.intel.com> wrote:
> > > Hi,
> > >
> > > The latest gcc seems to have problems with traits based on enum.
> > > Please
> > > find in the attachment a typical build log (for sophus in this
> > > case).
> > >
> > > What's the plan for them? Can we replace them with `static const
> > > bool`
> > > rather than `enum`?
> > >
> > > BR,
> > > Dmitry
> > >
|Mail converted by MHonArc 2.6.19+||http://listengine.tuxfamily.org/|