From: Chris Lattner Date: Mon, 28 Feb 2005 19:24:19 +0000 (+0000) Subject: Document llvm.prefetch, patch contributed by Justin Wick! X-Git-Url: http://plrg.eecs.uci.edu/git/?a=commitdiff_plain;h=9a9d7ac8350f8b371b78ff179ecf918c162fd307;p=oota-llvm.git Document llvm.prefetch, patch contributed by Justin Wick! git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@20373 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/docs/LangRef.html b/docs/LangRef.html index 88cf2a63237..38229f55a11 100644 --- a/docs/LangRef.html +++ b/docs/LangRef.html @@ -125,6 +125,7 @@
  1. 'llvm.returnaddress' Intrinsic
  2. 'llvm.frameaddress' Intrinsic
  3. +
  4. 'llvm.prefetch' Intrinsic
  • Operating System Intrinsics @@ -2499,6 +2500,52 @@ source-language caller.

    + + + +
    + +
    Syntax:
    +
    +  call void (sbyte *, uint, uint)* %llvm.prefetch(sbyte * <address>,
    +                                                  uint <rw>, 
    +                                                  uint <locality>)
    +
    + +
    Overview:
    + + +

    +The 'llvm.prefetch' intrinsic is a hint to the code generator to insert +a prefetch instruction if supported, otherwise it is a noop. Prefetches have no +behavior affect on the program, but can change the performance characteristics +of the code. +

    + +
    Arguments:
    + +

    +address is the address to be prefetched, rw is the specifier +determining if the fetch should be for a read (0) or write (1), and +locality is a temporal locality specifier ranging from (0) - no +locality, to (3) - exteremely local keep in cache. The rw and +locality arguments must be constant integers. +

    + +
    Semantics:
    + +

    +This intrinsic does not modify the behavior of the program. In particular, +prefetches cannot trap and do not produce a value. On targets that support this +intrinsic, the prefetch can provide hints to the processor cache for better +performance. +

    + +
    + +