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]

[PATCH, i386]: Fix PR71245, atomic load/store bounces the data to the stack using fild/fistp


Hello!

As shown in the PR, when moving DFmode value to/from a FP register, we
don't need to bounce it with an atomic DImode fild/fistp in case of
-march=pentium. DFmode move is atomic by itself.

2016-05-29  Uros Bizjak  <ubizjak@gmail.com>

    PR target/71245
    * config/i386/sync.md (define_peephole2 atomic_storedi_fpu):
    New peepholes to remove unneeded fild/fistp pairs.
    (define_peephole2 atomic_loaddi_fpu): Ditto.

testsuite/ChangeLog:

2016-05-29  Uros Bizjak  <ubizjak@gmail.com>

    PR target/71245
    * gcc.target/i386/pr71245-1.c: New test.
    * gcc.target/i386/pr71245-2.c: Ditto.

Bootstrapped on x86_64-linux-gnu and regression tested with -m32/march=pentium.

Committed to mainline SVN.

Uros.

Attachment: p.diff.txt
Description: Text document


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