public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug tree-optimization/95747] New: [OpenMP/Builtin] nontemporal store support
@ 2020-06-18 17:30 jed at 59A2 dot org
  2023-08-09 21:27 ` [Bug tree-optimization/95747] " freddie at witherden dot org
  0 siblings, 1 reply; 2+ messages in thread
From: jed at 59A2 dot org @ 2020-06-18 17:30 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95747

            Bug ID: 95747
           Summary: [OpenMP/Builtin] nontemporal store support
           Product: gcc
           Version: 10.1.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: tree-optimization
          Assignee: unassigned at gcc dot gnu.org
          Reporter: jed at 59A2 dot org
  Target Milestone: ---

My understanding is that GCC currently has no analog of Clang's
__builtin_nontemporal_store
(https://clang.llvm.org/docs/LanguageExtensions.html#non-temporal-load-store-builtins)
and I don't see a ticket to add support for OpenMP-5's pragma omp simd
nontemporal. This leaves developers stuck with needing intrinsics to generate
vmovntpd and related instructions. Proper use of nontemporal stores can make
circa 50% performance improvement in bandwidth-limited workloads.

^ permalink raw reply	[flat|nested] 2+ messages in thread

* [Bug tree-optimization/95747] [OpenMP/Builtin] nontemporal store support
  2020-06-18 17:30 [Bug tree-optimization/95747] New: [OpenMP/Builtin] nontemporal store support jed at 59A2 dot org
@ 2023-08-09 21:27 ` freddie at witherden dot org
  0 siblings, 0 replies; 2+ messages in thread
From: freddie at witherden dot org @ 2023-08-09 21:27 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95747

Freddie Witherden <freddie at witherden dot org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |freddie at witherden dot org

--- Comment #1 from Freddie Witherden <freddie at witherden dot org> ---
It looks as if recent versions of GCC support the nontemporal OpenMP 5
attribute as:

typedef double aligned_double __attribute__ ((aligned (64)));

void f(int n, aligned_double * a, aligned_double * b)
{
    #pragma omp simd nontemporal(b)
    for (int i = 0; i < n; i++)
        b[i] = 2*a[i];
}

But do not actually generate non-temporal store instructions (even though the
data is suitably aligned).

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2023-08-09 21:27 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-06-18 17:30 [Bug tree-optimization/95747] New: [OpenMP/Builtin] nontemporal store support jed at 59A2 dot org
2023-08-09 21:27 ` [Bug tree-optimization/95747] " freddie at witherden dot org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).