linux-riscv.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* prefetchw()
@ 2021-06-27  3:31 Paul Campbell
  2021-06-27  3:44 ` prefetchw() Paul Campbell
  0 siblings, 1 reply; 2+ messages in thread
From: Paul Campbell @ 2021-06-27  3:31 UTC (permalink / raw)
  To: linux-riscv

i noticed today that __builtin_prefetch() emits nothing (at least in my gcc)

i wonder if it makes sense to do this for riscv linux?

static inline void prefetchw( volatile void  *addr)
{
        asm volatile("lb x0, 0(%0)" : : "r" (addr));
}

	Paul



_______________________________________________
linux-riscv mailing list
linux-riscv@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-riscv

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

end of thread, other threads:[~2021-06-27  3:44 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-06-27  3:31 prefetchw() Paul Campbell
2021-06-27  3:44 ` prefetchw() Paul Campbell

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 NNTP newsgroup(s).