Patch to add 'volatile' to first argument of all
sync compare_and_swap to match them with gcc.
It also fixes a few incorrect argument defitions.
(fixes radar 7540291).

llvm-svn: 94607
diff --git a/clang/lib/AST/ASTContext.cpp b/clang/lib/AST/ASTContext.cpp
index c2eddcb..4c4e77a 100644
--- a/clang/lib/AST/ASTContext.cpp
+++ b/clang/lib/AST/ASTContext.cpp
@@ -4793,6 +4793,9 @@
       case 'C':
         Type = Type.withConst();
         break;
+      case 'D':
+        Type = Context.getVolatileType(Type);
+        break;
     }
   }