This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc 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]

libm to-do list addition


On 05/09/2013 12:23 PM, Joseph S. Myers wrote:
>  static const long double c[] = {
> +/* 113 bits of pi/2 */
>  #define PI_2_1 c[0]
> + 0x1.921fb54442d18469898cc51701b8p+0L,

Putting compile-time constants into static data variables, as is done here, is
probably self-defeating.  If we use the literals directly, gcc ought to be
putting them into mergable .rodata sections.  Then common constants like PI/2
can be shared between math object files.

Whether this increases the code size for symbol lookup is target-specific.  But
I would hope that most targets would do well with got- or pc-relative relocations.


r~


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