]> git.proxmox.com Git - mirror_edk2.git/blobdiff - MdePkg/Library/BaseSynchronizationLib/Ia32/GccInline.c
Minor grammatical work--mostly adding periods. Items with ONLY period added did...
[mirror_edk2.git] / MdePkg / Library / BaseSynchronizationLib / Ia32 / GccInline.c
index dcaaa6a8a285ee758759baeb6c0653f8bb47846a..b5a7827fc0e87e6db19eba8fdc528575f4685b08 100644 (file)
@@ -1,12 +1,12 @@
 /** @file\r
   GCC inline implementation of BaseSynchronizationLib processor specific functions.\r
   \r
-  Copyright (c) 2006 - 2009, Intel Corporation. All rights reserved.<BR>\r
+  Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>\r
   Portions copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>\r
   This program and the accompanying materials\r
   are licensed and made available under the terms and conditions of the BSD License\r
   which accompanies this distribution.  The full text of the license may be found at\r
-  http://opensource.org/licenses/bsd-license.php\r
+  http://opensource.org/licenses/bsd-license.php.\r
 \r
   THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
   WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
@@ -114,13 +114,6 @@ InternalSyncCompareExchange32 (
   )\r
 {\r
 \r
-// GCC 4.1 and forward supports atomic builtins  \r
-#if ((__GNUC__ > 4) || ((__GNUC__ == 4) && (__GNUC_MINOR__ >= 1)))\r
-\r
-  return __sync_val_compare_and_swap (Value, CompareValue, ExchangeValue);\r
-\r
-#else\r
-\r
   __asm__ __volatile__ (\r
     "                     \n\t"\r
     "lock                 \n\t"\r
@@ -133,9 +126,7 @@ InternalSyncCompareExchange32 (
       "cc"\r
     );\r
 \r
-    return CompareValue;\r
-\r
-#endif\r
+  return CompareValue;\r
 }\r
 \r
 /**\r
@@ -163,13 +154,6 @@ InternalSyncCompareExchange64 (
   IN      UINT64                    ExchangeValue\r
   )\r
 {\r
-// GCC 4.1 and forward supports atomic builtins  \r
-#if ((__GNUC__ > 4) || ((__GNUC__ == 4) && (__GNUC_MINOR__ >= 1)))\r
-\r
-  return __sync_val_compare_and_swap (Value, CompareValue, ExchangeValue);\r
-\r
-#else\r
-\r
   __asm__ __volatile__ (\r
     "                       \n\t"\r
     "push        %%ebx      \n\t" \r
@@ -186,8 +170,4 @@ InternalSyncCompareExchange64 (
     );\r
   \r
   return CompareValue;\r
-\r
-#endif\r
 }\r
-\r
-\r