This is the mail archive of the mailing list for the GCC project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Using MPC Library with GCC

On Tue, 5 May 2009, Mark Mitchell wrote:

> I personally think relying on MPC is a reasonable choice, given the fact
> that (as you say) the language specifications do in some cases require
> support for these kinds of manipulations of complex numbers at compile-time.
> In the past, however, other people have had objections.  I'd like to
> give them more time (let's say one more week) to comment.  If that week
> passes without negative comment, let's start coordinating how to move
> forward with it.

Okay, nobody spoke up so let's proceed.

The remaining issue is how and when to arrange for the MPC dependency to
be activated.  I think the consensus was to make MPC a hard-requirement.
However I'd also like to make the pain of getting the appropriate library
version to occur only once for GCC developers (or at most once per GCC
release cycle).

The current release mpc-0.6 has most but not all of the c99 complex
functions finished.  The remaining ones are supposed to be done in a
couple of months.  That should be in time for the 4.5 release, if not I'll
go with whatever we have and get the remainder for gcc-4.6.  We did
something similar for MPFR functions (like lgamma) that became available
in later versions of that library.

Here are options on how to proceed:

1.  Consider MPC as an optional library now, install all the code and make
    it hard-required only when all the complex math functions are made
    available in a future released version of the library or sometime in
    stage3, whichever is first.

2.  Hard-require mpc-0.6 now and hard require later versions when the
    remaining functions are done.  Requires at least two installs of MPC
    by everyone, possibly more.

3.  Hard-require mpc-0.6 now, future complex functions could be wrapped by
    #ifdef MPC_VERSION >= foo.  We did this with MPFR functions for a
    while until we eventually upgraded to later versions and got rid of
    the conditionals.

I prefer option 1 since it allows me to commit the majority of the patches
and get wider testing now without creating the installation pain more than

Option 2 is fine with me but will make other developers complain more.

Option 3 has the disadvantage that some optimizations will depend on the
version of MPC installed.  We have historical precedent for that with MPFR
but people expresed that they don't like it.  I like this one the least.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]