Commit 69c5c387 by Nicolas Capens

Fix Clang warnings.

Change-Id: I9630093a14d0c1b2b6dc60ffb5866c7d2eaf4f02 Reviewed-on: https://swiftshader-review.googlesource.com/4552Tested-by: 's avatarNicolas Capens <capn@google.com> Reviewed-by: 's avatarAlexis Hétu <sugoi@google.com> Reviewed-by: 's avatarNicolas Capens <capn@google.com>
parent a810d0c8
...@@ -112,10 +112,14 @@ namespace sw ...@@ -112,10 +112,14 @@ namespace sw
} }
private: private:
// Ensure that the mutex variable is on its own 64-byte cache line to avoid false sharing struct
volatile int a[16]; {
volatile int mutex; // Ensure that the mutex variable is on its own 64-byte cache line to avoid false sharing
volatile int b[15]; // Padding must be public to avoid compiler warnings
volatile int padding1[16];
volatile int mutex;
volatile int padding2[15];
};
}; };
} }
......
...@@ -119,6 +119,7 @@ void *loadLibrary(const char *(&names)[n], const char *mustContainSymbol = nullp ...@@ -119,6 +119,7 @@ void *loadLibrary(const char *(&names)[n], const char *mustContainSymbol = nullp
if(!symbol) if(!symbol)
{ {
const char *reason = dlerror(); // Silence the error const char *reason = dlerror(); // Silence the error
(void)reason;
} }
return symbol; return symbol;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment