This is the mail archive of the gcc-patches@gcc.gnu.org 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: [fortran, patch] IEEE intrinsic modules (ping)


Dear Rainer,

> Unfortunately, while the patch works fine on Solaris/x86, it broke
> Solaris/SPARC bootstrap for trivial reasons: contrary to the ChangeLog,
> configure and config.h.in weren't regenerated, thus FPSETSTICKY
> wasn't defined.

I apologize. Thanks for checking in the fix.


> FAIL: gfortran.dg/ieee/ieee_6.f90   -Os  execution test
> 
> The test aborts at l.47, but unfortunately I cannot print mode in gdb 7.7.

That’s weird, especially if that one fails but ieee_rounding_1.f90 works. Let me know if I can do anything to help debug this.


> The following patch corrects this, at the same time fixing this warning:
> 
> /fpu-target.h:451:3: warning: implicit declaration of function 'assert' [-Wimplicit-function-declaration]
>   assert (sizeof(fpu_state_t) <= GFC_FPE_STATE_BUFFER_SIZE);

Actually, it makes a lot of sense to change these into static assertions: this way, any target-specific issues with FP-state buffer size will show up at libgfortran-building-time, rather than be swept under the rug.

Since libgfortran is compiled with GCC, which supports _Static_assert since 4.6, I propose the attached patch.
Built and tested on x86_64-linux, OK to commit?

FX


Attachment: static_assert.ChangeLog
Description: Binary data

Attachment: static_assert.diff
Description: Binary data


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