[llvm-commits] Intrinsic address space patch

Dan Gohman gohman at apple.com
Wed Jul 23 08:44:43 PDT 2008


Hi Mon Ping,

Sorry for the delay on this patch. It looks good; I just have a few
minor style comments.

-  // suffix, to be checked at the end.
+  // suffix, to be checked at the end.  A function with a pointer
argument may
+  // or may not be overload.

s/overload/overloaded/

+      }
+      else {

LLVM style has the else on the same line as the }.

-        F->setName("llvm.atomic.cmp.swap"+Name.substr(delim));
+        F->setName( "llvm.atomic.cmp.swap" + Name.substr(delim)
+                   + ".p0" + Name.substr(delim+1));

A spurious space after a paren, and LLVM style has operators at
line breaks on the preceding line.

Dan

On Thu, July 17, 2008 3:56 pm, Mon P Wang wrote:
>
> Here is a patch to enable intrinsic to have pointers to different
> address spaces.  This changes overloaded intrinsics with pointer
> arguments to pass also an address space as part of their name.
>     For example,  atomic.load.add.i32 => atomic.load.add.i32.p0i32
>
> The above syntax indicates that the result is i32 with a pointer
> argument to address space 0 (generic address space) whose domain type
> is i32.  The patch here doesn't include the documentation change but
> that will be included as part of the checkin.  Let me know if you have
> any comments.
>
> -- Mon Ping
>
>
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
>





More information about the llvm-commits mailing list