Changeset 139758 in webkit
- Timestamp:
- Jan 15, 2013 10:56:19 AM (11 years ago)
- Location:
- trunk/Source/ThirdParty/ANGLE
- Files:
-
- 12 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/ThirdParty/ANGLE/ChangeLog
r139717 r139758 1 2013-01-15 David Kilzer <ddkilzer@apple.com> 2 3 ANGLE should build with -Wshorten-64-to-32 4 <http://webkit.org/b/106798> 5 <http://code.google.com/p/angleproject/issues/detail?id=396> 6 7 Reviewed by Kenneth Russell. 8 9 Most changes below are simply to document issues with #pragma 10 statements per request by upstream. The change to osinclude.h 11 is the only bug fix, which defines OS_TLSIndex in terms of 12 pthread_key_t instead of unsigned int since pthread_key_t is a 13 64-bit value on 64-bit Mac OS X. 14 15 * Configurations/Base.xcconfig: Enable -Wshorten-64-to-32 by 16 setting GCC_WARN_64_TO_32_BIT_CONVERSION to YES. 17 * src/compiler/Intermediate.cpp: 18 (TIntermTraverser::hash): Add #pragmas for clang to ignore 19 -Wshorten-64-to-32 warning. 20 * src/compiler/MapLongVariableNames.cpp: 21 (LongNameMap::Size): Ditto. 22 * src/compiler/ShaderLang.cpp: 23 (getVariableInfo): Ditto. 24 (ShGetInfo): Ditto. 25 * src/compiler/ValidateLimitations.cpp: 26 (ValidateLimitations::validateFunctionCall): Ditto. 27 * src/compiler/glslang.l: Ditto. 28 * src/compiler/glslang_lex.cpp: Ditto. 29 * src/compiler/osinclude.h: Change type of OS_TLSIndex to 30 pthread_key_t. Define OS_INVALID_TLS_INDEX by using 31 static_cast<OS_TLSIndex>(-1). 32 * src/compiler/preprocessor/Input.cpp: 33 (pp::Input::Input): Add #pragmas for clang to ignore 34 -Wshorten-64-to-32 warning. 35 * src/compiler/preprocessor/Tokenizer.cpp: Ditto. 36 * src/compiler/preprocessor/Tokenizer.l: Ditto. 37 1 38 2013-01-14 David Kilzer <ddkilzer@apple.com> 2 39 -
trunk/Source/ThirdParty/ANGLE/Configurations/Base.xcconfig
r132925 r139758 20 20 GCC_TREAT_WARNINGS_AS_ERRORS = YES; 21 21 GCC_VERSION = com.apple.compilers.llvm.clang.1_0; 22 GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 22 23 GCC_WARN_ABOUT_DEPRECATED_FUNCTIONS = NO; 23 24 GCC_WARN_ABOUT_MISSING_NEWLINE = YES; -
trunk/Source/ThirdParty/ANGLE/src/compiler/Intermediate.cpp
r139665 r139758 1452 1452 if (hashFunction == NULL || name.empty()) 1453 1453 return name; 1454 #if defined(__clang__) 1455 #pragma clang diagnostic push 1456 #pragma clang diagnostic ignored "-Wshorten-64-to-32" 1457 #endif 1454 1458 khronos_uint64_t number = (*hashFunction)(name.c_str(), name.length()); 1459 #if defined(__clang__) 1460 #pragma clang diagnostic pop 1461 #endif 1455 1462 TStringStream stream; 1456 1463 stream << HASHED_NAME_PREFIX << std::hex << number; -
trunk/Source/ThirdParty/ANGLE/src/compiler/MapLongVariableNames.cpp
r122870 r139758 73 73 int LongNameMap::Size() const 74 74 { 75 #if defined(__clang__) 76 #pragma clang diagnostic push 77 #pragma clang diagnostic ignored "-Wshorten-64-to-32" 78 #endif 75 79 return mLongNameMap.size(); 80 #if defined(__clang__) 81 #pragma clang diagnostic pop 82 #endif 76 83 } 77 84 -
trunk/Source/ThirdParty/ANGLE/src/compiler/ShaderLang.cpp
r139665 r139758 63 63 64 64 const TVariableInfo& varInfo = varList[index]; 65 #if defined(__clang__) 66 #pragma clang diagnostic push 67 #pragma clang diagnostic ignored "-Wshorten-64-to-32" 68 #endif 65 69 if (length) *length = varInfo.name.size(); 70 #if defined(__clang__) 71 #pragma clang diagnostic pop 72 #endif 66 73 *size = varInfo.size; 67 74 *type = varInfo.type; … … 212 219 break; 213 220 case SH_ACTIVE_UNIFORMS: 221 #if defined(__clang__) 222 #pragma clang diagnostic push 223 #pragma clang diagnostic ignored "-Wshorten-64-to-32" 224 #endif 214 225 *params = compiler->getUniforms().size(); 226 #if defined(__clang__) 227 #pragma clang diagnostic pop 228 #endif 215 229 break; 216 230 case SH_ACTIVE_UNIFORM_MAX_LENGTH: … … 218 232 break; 219 233 case SH_ACTIVE_ATTRIBUTES: 234 #if defined(__clang__) 235 #pragma clang diagnostic push 236 #pragma clang diagnostic ignored "-Wshorten-64-to-32" 237 #endif 220 238 *params = compiler->getAttribs().size(); 239 #if defined(__clang__) 240 #pragma clang diagnostic pop 241 #endif 221 242 break; 222 243 case SH_ACTIVE_ATTRIBUTE_MAX_LENGTH: … … 242 263 break; 243 264 case SH_HASHED_NAMES_COUNT: 265 #if defined(__clang__) 266 #pragma clang diagnostic push 267 #pragma clang diagnostic ignored "-Wshorten-64-to-32" 268 #endif 244 269 *params = compiler->getNameMap().size(); 270 #if defined(__clang__) 271 #pragma clang diagnostic pop 272 #endif 245 273 break; 246 274 default: UNREACHABLE(); -
trunk/Source/ThirdParty/ANGLE/src/compiler/ValidateLimitations.cpp
r122870 r139758 428 428 TIntermSymbol* symbol = params[i]->getAsSymbolNode(); 429 429 if (symbol && isLoopIndex(symbol)) 430 #if defined(__clang__) 431 #pragma clang diagnostic push 432 #pragma clang diagnostic ignored "-Wshorten-64-to-32" 433 #endif 430 434 pIndex.push_back(i); 435 #if defined(__clang__) 436 #pragma clang diagnostic pop 437 #endif 431 438 } 432 439 // If none of the loop indices are used as arguments, -
trunk/Source/ThirdParty/ANGLE/src/compiler/glslang.l
r139665 r139758 24 24 25 25 // Ignore errors in auto-generated code. 26 #if defined(__clang__) 27 #pragma clang diagnostic ignored "-Wshorten-64-to-32" 28 #endif 26 29 #if defined(__GNUC__) 27 30 #pragma GCC diagnostic ignored "-Wunused-function" -
trunk/Source/ThirdParty/ANGLE/src/compiler/glslang_lex.cpp
r139665 r139758 9 9 10 10 // Ignore errors in auto-generated code. 11 #if defined(__clang__) 12 #pragma clang diagnostic ignored "-Wshorten-64-to-32" 13 #endif 11 14 #if defined(__GNUC__) 12 15 #pragma GCC diagnostic ignored "-Wunused-function" -
trunk/Source/ThirdParty/ANGLE/src/compiler/osinclude.h
r139665 r139758 45 45 #define OS_INVALID_TLS_INDEX (TLS_OUT_OF_INDEXES) 46 46 #elif defined(ANGLE_OS_POSIX) 47 typedef unsigned int OS_TLSIndex;48 #define OS_INVALID_TLS_INDEX 0xFFFFFFFF47 typedef pthread_key_t OS_TLSIndex; 48 #define OS_INVALID_TLS_INDEX (static_cast<OS_TLSIndex>(-1)) 49 49 #endif // ANGLE_OS_WIN 50 50 -
trunk/Source/ThirdParty/ANGLE/src/compiler/preprocessor/Input.cpp
r139665 r139758 27 27 { 28 28 int len = length ? length[i] : -1; 29 #if defined(__clang__) 30 #pragma clang diagnostic push 31 #pragma clang diagnostic ignored "-Wshorten-64-to-32" 32 #endif 29 33 mLength.push_back(len < 0 ? std::strlen(mString[i]) : len); 34 #if defined(__clang__) 35 #pragma clang diagnostic pop 36 #endif 30 37 } 31 38 } -
trunk/Source/ThirdParty/ANGLE/src/compiler/preprocessor/Tokenizer.cpp
r139665 r139758 521 521 #include "Token.h" 522 522 523 #if defined(__clang__) 524 #pragma clang diagnostic ignored "-Wshorten-64-to-32" 525 #endif 523 526 #if defined(__GNUC__) 524 527 // Triggered by the auto-generated yy_fatal_error function. -
trunk/Source/ThirdParty/ANGLE/src/compiler/preprocessor/Tokenizer.l
r139665 r139758 29 29 #include "Token.h" 30 30 31 #if defined(__clang__) 32 #pragma clang diagnostic ignored "-Wshorten-64-to-32" 33 #endif 31 34 #if defined(__GNUC__) 32 35 // Triggered by the auto-generated yy_fatal_error function.
Note: See TracChangeset
for help on using the changeset viewer.