Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 226645 - dev-libs/crypto++-5.5.2: does not compile with -O2 and -funroll-loops CXXFLAGS option
Summary: dev-libs/crypto++-5.5.2: does not compile with -O2 and -funroll-loops CXXFLAG...
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Library (show other bugs)
Hardware: AMD64 Linux
: High minor (vote)
Assignee: Crypto team [DISABLED]
Depends on:
Reported: 2008-06-14 13:28 UTC by François Agrech
Modified: 2008-06-24 05:21 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Note You need to log in before you can comment on or make changes to this bug.
Description François Agrech 2008-06-14 13:28:44 UTC
emerge of dev-libs/crypto++-5.5.2 with "-O2 -funroll-loops" CXXFLAGS fails at vmac.cpp, line 690.
Removing either option work.
I have gcc version 4.1.2

The easy workaround is to create the file /etc/portage/env/dev-libs/crypto++ and put a CXXFLAGS without one of the two options.

Reproducible: Always

Steps to Reproduce:
1. put CXXFLAGS="-O2 -funroll-loops" in /etc/make.conf
2. emerge =dev-libs/crypto++-5.5.2

Actual Results:  
x86_64-pc-linux-gnu-g++ -O2 -funroll-loops -c xtrcrypt.cpp
vmac.cpp: In member function ‘void CryptoPP::VMAC_Base::VHASH_Update_Template(const CryptoPP::word64*, size_t) [with bool T_128BitTag = true]’:
vmac.cpp:690: erreur fatale: internal consistency failure

Expected Results:  
The ebuild should filter those options so emerge succeeds with this CXXFLAGS, or the source should be patched by ebuild so it compiles with those options.
Comment 1 Daniel Black (RETIRED) gentoo-dev 2008-06-22 21:32:47 UTC
as per url funroll-loops is prone with faults. Other documentation indicates that funroll-loops as a concept make stuff slower.

as such i'm not going to fix this.
Comment 2 François Agrech 2008-06-23 07:25:55 UTC
What about adding a warning about that in the ebuild? This could save some time searching for the problem for some people.
Comment 3 Daniel Black (RETIRED) gentoo-dev 2008-06-23 12:51:59 UTC
(In reply to comment #2)
> What about adding a warning about that in the ebuild?
> This could save some time searching for the problem for some people.
The valuable learning experience is to drop silly CFLAGS.

By putting a warning some people will just keep using it and expecting every other package to work with a silly broken cflag.

Comment 4 François Agrech 2008-06-24 05:21:29 UTC
I was thinking about a message along the line of:
"You have enabled funroll-loops, this package won't compile with this flag. Moreover, it is not wise to enable this flag as it has been proven to make things slower. Please unset this flag in your make.conf flag and reemerge"
I mean a message that inform the user about the problem and at the same time that discourage from using this flag in other packages.