src/common


Log

Author Commit Date CI Message
Jamie Madill 4a3c2341 2015-10-08T12:58:45 Program: Clean up UBO info gathering. The data size & block member info was getting messy, so clean up how we query this from the Impl layer. Also remove the register information from gl::UniformBlock, moving it into the D3D-only world. BUG=angleproject:1172 Change-Id: I40af658ebbd6b7c1a4251906a387ebcbb621cf77 Reviewed-on: https://chromium-review.googlesource.com/304150 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tryjob-Request: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Corentin Wallez 630d85cb 2015-09-30T14:35:48 Fix an undefined behavior in clampCast This undefined behavior appeared in angle_end2end_tests compiled with clang 3.6 on Mac. BUG=angleproject:891 Change-Id: I840b40a7bd54c9cfaeb0fe6784b73f875f9d5502 Reviewed-on: https://chromium-review.googlesource.com/303337 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
hendrikw 75782629 2015-09-25T11:28:50 Fix possible compiler errors on linux Change-Id: Ifc45446c749690eddc406f66f144304262f04664 Reviewed-on: https://chromium-review.googlesource.com/302478 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Geoff Lang 3edfe034 2015-09-04T16:38:24 Support primitive restart in RendererGL. Store index ranges in a new struct that tracks how many real indices were seen. Update index caching to key on primitive restart being enabled and update index counting functions to skip primitive restart indicies when needed. Passes dEQP-GLES3.functional.primitive_restart.* Change-Id: Id1e25a5adcdcd4e998836e8ff6679c64be4c3066 Reviewed-on: https://chromium-review.googlesource.com/297770 Tryjob-Request: Geoff Lang <geofflang@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang e5f735f9 2015-09-17T13:26:59 Revert "Try Sleep(1) instead of Sleep(0) while waiting for queries." Caused significant slowdown in some chrome use cases that used glFinish or synchronous fences. BUG=532571 This reverts commit a53000b09b012235af228f2b4f48cc9fb477a45a. Change-Id: Id260e9ced472c409b2fa0b28b2b3dea99d412fdf Reviewed-on: https://chromium-review.googlesource.com/300491 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill c38ae7df 2015-09-14T10:31:07 Rename Optional::None to Invalid. This fixes a name conflict with the XWindow headers on Linux. Only becomes an issue when using Optional inside GL-level libANGLE. BUG=angleproject:1123 Change-Id: I7f0eb278a8b6eb6fecd864e556428678cb90dcea Reviewed-on: https://chromium-review.googlesource.com/298892 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 62d31cb6 2015-09-11T13:25:51 Re^6-land "Move Uniform and UBO info to the gl::Program layer." This data was previously stored entirely in the Impl level. Move as much as possible to the GL level, using a read-only view in the Impl level. Some information in D3D-specific, and should be stored separately in the Impl. This patch has a lot of refactoring that splits the D3D and GL info, and moves as much validation as possible to the GL layer, where it is shared between the back-ends. Re-land with fix for dEQP unused uniforms. The fix involves storing a local copy of all uniform data in the GL layer. This will also let us validate sampler indexes during draw calls at the GL layer. Re-re-land with a fix for multiply defined symbols on Clang. Re-re-re-land with a fix for boolean uniforms and Uniform{1234}f. Re^4-land with a fix for boolean uniform arrays and UBO uniforms. Re^5-land with a fix for a test warning on Linux. Re^6-land with a fix for transposed matrix uniform arrays. BUG=angleproject:1123 TEST=end2end_tests, bots, dEQP GLES3.ubo and GLES2.uniform_api Change-Id: Ie6fcde1c16eb05d67191b629338b88302a2563f5 Reviewed-on: https://chromium-review.googlesource.com/298971 Tryjob-Request: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill fb53603c 2015-09-11T13:19:49 Revert "Re^5-land "Move Uniform and UBO info to the gl::Program layer."" Failing dEQP-GLES3.functional.uniform_api.random.22 and 23: There's a bug with arrays of tranpsosed matrix uniforms. BUG=angleproject:1123 This reverts commit 78d356929bd0441d81e2dd8a63130cd6788e2fde. Change-Id: If39b5908af39671dfe98965e6a1ba77fd18ea8fc Reviewed-on: https://chromium-review.googlesource.com/299320 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 78d35692 2015-09-11T08:32:51 Re^5-land "Move Uniform and UBO info to the gl::Program layer." This data was previously stored entirely in the Impl level. Move as much as possible to the GL level, using a read-only view in the Impl level. Some information in D3D-specific, and should be stored separately in the Impl. This patch has a lot of refactoring that splits the D3D and GL info, and moves as much validation as possible to the GL layer, where it is shared between the back-ends. Re-land with fix for dEQP unused uniforms. The fix involves storing a local copy of all uniform data in the GL layer. This will also let us validate sampler indexes during draw calls at the GL layer. Re-re-land with a fix for multiply defined symbols on Clang. Re-re-re-land with a fix for boolean uniforms and Uniform{1234}f. Re^4-land with a fix for boolean uniform arrays and UBO uniforms. Re^5-land with a fix for a test warning on Linux. BUG=angleproject:1123 TEST=end2end_tests, bots, dEQP GLES3.ubo and GLES2.uniform_api Change-Id: I03afcd446d9e74573c4d4c712ed7407b91d8001c Reviewed-on: https://chromium-review.googlesource.com/299180 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill a2eb02c9 2015-09-11T12:31:41 Revert "Re^4-land "Move Uniform and UBO info to the gl::Program layer."" Test has a warning on Linux: In file included from ../../third_party/angle/src/tests/test_utils/ANGLETest.h:13: ../../testing/gtest/include/gtest/gtest.h:1392:16: error: comparison of integers of different signs: 'const int' and 'const unsigned int' [-Werror,-Wsign-compare] if (expected == actual) { ~~~~~~~~ ^ ~~~~~~ ../../testing/gtest/include/gtest/gtest.h:1422:12: note: in instantiation of function template specialization 'testing::internal::CmpHelperEQ<int, unsigned int>' requested here return CmpHelperEQ(expected_expression, actual_expression, expected, ^ ../../third_party/angle/src/tests/gl_tests/UniformBufferTest.cpp:357:5: note: in instantiation of function template specialization 'testing::internal::EqHelper<false>::Compare<int, unsigned int>' requested here EXPECT_EQ(GL_FLOAT, type); ^ BUG=angleproject:1123 This reverts commit 2ae1ee6161c24aab065190b1528f6195e80e34d0. Change-Id: Ic3dabea54068377d1f2c5f722ba52966cf1a0491 Reviewed-on: https://chromium-review.googlesource.com/299170 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 2ae1ee61 2015-09-10T10:04:24 Re^4-land "Move Uniform and UBO info to the gl::Program layer." This data was previously stored entirely in the Impl level. Move as much as possible to the GL level, using a read-only view in the Impl level. Some information in D3D-specific, and should be stored separately in the Impl. This patch has a lot of refactoring that splits the D3D and GL info, and moves as much validation as possible to the GL layer, where it is shared between the back-ends. Re-land with fix for dEQP unused uniforms. The fix involves storing a local copy of all uniform data in the GL layer. This will also let us validate sampler indexes during draw calls at the GL layer. Re-re-land with a fix for multiply defined symbols on Clang. Re-re-re-land with a fix for boolean uniforms and Uniform{1234}f. Re^4-land with a fix for boolean uniform arrays and UBO uniforms. BUG=angleproject:1123 TEST=end2end_tests, bots, dEQP GLES3.ubo and GLES2.uniform_api Change-Id: I4c9f5ed31b81380507bef7981f97086d642801ae Reviewed-on: https://chromium-review.googlesource.com/298451 Tryjob-Request: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 61b8dd97 2015-09-09T19:04:04 Revert "Re-re-re-land "Move Uniform and UBO info to the gl::Program layer."" Seems to be failing the dEQP-GLES2.functional.uniform_api tests relating to boolean arrays. BUG=angleproject:1123 This reverts commit 892a6a4b17b35e89898be8b4605c1ee595d3ae13. Change-Id: Ifc4ce3ca806ef88a02ac6f693334ac37ce098a88 Reviewed-on: https://chromium-review.googlesource.com/298520 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 892a6a4b 2015-09-09T10:17:15 Re-re-re-land "Move Uniform and UBO info to the gl::Program layer." This data was previously stored entirely in the Impl level. Move as much as possible to the GL level, using a read-only view in the Impl level. Some information in D3D-specific, and should be stored separately in the Impl. This patch has a lot of refactoring that splits the D3D and GL info, and moves as much validation as possible to the GL layer, where it is shared between the back-ends. Re-land with fix for dEQP unused uniforms. The fix involves storing a local copy of all uniform data in the GL layer. This will also let us validate sampler indexes during draw calls at the GL layer. Re-re-land with a fix for multiply defined symbols on Clang. Re-re-re-land with a fix for boolean uniforms and Uniform{1234}f. BUG=angleproject:1123 TEST=end2end_tests,Canary WebGL (D3D11/GL), dEQP-GLES2+3.functional.uniform_api Change-Id: Ia40820a5ce2f34ec2d27648b1dc940a8955e9999 Reviewed-on: https://chromium-review.googlesource.com/298440 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill b654f659 2015-09-08T20:40:00 Revert "Re-re-land "Move Uniform and UBO info to the gl::Program layer."" Failes the gles2_conform_test: GLES2ConformTest.GL2Tests_glGetUniform_input_run Possibly also WebGL failures, will investigate. BUG=angleproject:1123 This reverts commit 10750cb936288d8dd09d49fadd592904c06c56f9. Change-Id: I1ae59325e1831589019bc5a27ffc2091d3994a65 Reviewed-on: https://chromium-review.googlesource.com/298200 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 10750cb9 2015-09-04T14:23:52 Re-re-land "Move Uniform and UBO info to the gl::Program layer." This data was previously stored entirely in the Impl level. Move as much as possible to the GL level, using a read-only view in the Impl level. Some information in D3D-specific, and should be stored separately in the Impl. This patch has a lot of refactoring that splits the D3D and GL info, and moves as much validation as possible to the GL layer, where it is shared between the back-ends. Re-land with fix for dEQP unused uniforms. The fix involves storing a local copy of all uniform data in the GL layer. This will also let us validate sampler indexes during draw calls at the GL layer. Re-re-land with a fix for multiply defined symbols on Clang. BUG=angleproject:1123 TEST=end2end_tests,Canary WebGL (D3D11/GL), dEQP-GLES2+3.functional.uniform_api Change-Id: I7b55e4964fbe64e0106c37928c894146937a2476 Reviewed-on: https://chromium-review.googlesource.com/298110 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 2119dd05 2015-09-08T19:30:37 Revert "Re-land "Move Uniform and UBO info to the gl::Program layer."" Problems with multiply defined symbols in the Linux builder. BUG=angleproject:1123 This reverts commit ff1abe63c3d8af28e9755c8d0c95b2aeca27a0d9. Change-Id: Ifcb2ad885d0841c128ffd69afb6594e37eba17fc Reviewed-on: https://chromium-review.googlesource.com/298100 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill ff1abe63 2015-09-04T14:23:52 Re-land "Move Uniform and UBO info to the gl::Program layer." This data was previously stored entirely in the Impl level. Move as much as possible to the GL level, using a read-only view in the Impl level. Some information in D3D-specific, and should be stored separately in the Impl. This patch has a lot of refactoring that splits the D3D and GL info, and moves as much validation as possible to the GL layer, where it is shared between the back-ends. Re-land with fix for dEQP unused uniforms. The fix involves storing a local copy of all uniform data in the GL layer. This will also let us validate sampler indexes during draw calls at the GL layer. BUG=angleproject:1123 TEST=end2end_tests,Canary WebGL (D3D11/GL), dEQP-GLES2+3.functional.uniform_api Change-Id: I9074c057c2c67d4d3221ec11c5556a26e07c7ceb Reviewed-on: https://chromium-review.googlesource.com/297070 Tryjob-Request: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Corentin Wallez 94d099d0 2015-09-01T13:56:56 BitSetIterator_unittest: fix an unreachable code warning Because gtest's FAIL macro does a return, MSVC complained that the update part of a range-based for loop was unreachable. Fixed this by having a boolean value set to true if we execute the loop body. BUG=angleproject:929 Change-Id: I6c1fec7ed6cf1a3aba6f02b68c1015bee2feebfd Reviewed-on: https://chromium-review.googlesource.com/296730 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Corentin Wallez 2c34a4b0 2015-08-25T16:26:02 VertexArrayGL: fix an off by one error for indexRange for drawElements DrawElements' range was of the form [start, end] while DrawArrays' was of the form [start, end), which caused an out of bound array access in the client vertex pointers. This issue was detected while running angle_end2end_tests with AddressSanitizer. BUG=angleproject:1137 Change-Id: Id9abddf29eaf73bacfd08d1616a999be2fe616b8 Reviewed-on: https://chromium-review.googlesource.com/295122 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Geoff Lang a53000b0 2015-05-26T10:50:35 Try Sleep(1) instead of Sleep(0) while waiting for queries. On a loaded machine, Sleep(0) can be very slow (40+ms) while Sleep(1) is consistantly 1-2ms. BUG=488571 Change-Id: I71de0b4cfc334a2476b7c613c103e77fe759041d Reviewed-on: https://chromium-review.googlesource.com/273183 Reviewed-by: Shannon Woods <shannonwoods@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill b3a60aa9 2015-08-14T14:44:06 Store iterator bitset by-value instead of by-reference. The by-reference method was giving strange problems when using a non- LValue as argument to IterateBitSet. BUG=angleproject:1040 Change-Id: Iec10f7256a5b19b239804e0beba4ae675f53f876 Reviewed-on: https://chromium-review.googlesource.com/293840 Tested-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Cooper Partin 4d61f7ed 2015-08-12T10:56:50 Reland Fixed compiler warning C4267 'conversion from 'size_t' to 'type', possible loss of data' Additional warnings found with more testing and added C4267 warning disable only for angle_libpng BUG=angleproject:1120 Change-Id: Ic403dcff5a8018056fa51a8c408e64207f3362eb Reviewed-on: https://chromium-review.googlesource.com/293028 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill b195643c 2015-08-12T17:35:20 Revert "Fixed compiler warning C4267 'conversion from 'size_t' to 'type', possible loss of data'" Seems to have quite a few warnings in 64-bit on my machine. BUG=angleproject:1120 This reverts commit c5cf9bc47d0ee028adbbf9e9f94ca567eec601dc. Change-Id: I86768b900aeba52e7a2242d9ae8949f93f1a5ba9 Reviewed-on: https://chromium-review.googlesource.com/293280 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Cooper Partin c5cf9bc4 2015-08-06T10:46:48 Fixed compiler warning C4267 'conversion from 'size_t' to 'type', possible loss of data' BUG=angleproject:1120 Change-Id: I01ef10bea7f487c2b394d030c76628f38d2ea645 Reviewed-on: https://chromium-review.googlesource.com/292780 Tested-by: Cooper Partin <coopp@microsoft.com> Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Geoff Lang a840617a 2015-07-21T16:53:39 Implement the egl and gl layers of EGL Image. Add end2end tests and unittests. BUG=angleproject:970 Change-Id: Ie8306971730a793f08dfd09ead1bfd6ff3e4623d Reviewed-on: https://chromium-review.googlesource.com/291260 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 4274f7d2 2015-08-05T23:07:38 Revert "Implement the egl and gl layers of EGL Image." This reverts commit 22a4f38c2ca9ca430b5f976fc7fc816d88918eba. Change-Id: I07acbfe28d11675236de2ea7f6b050c25f80579a Reviewed-on: https://chromium-review.googlesource.com/290960 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 22a4f38c 2015-07-21T16:53:39 Implement the egl and gl layers of EGL Image. Add end2end tests and unittests. BUG=angleproject:970 Change-Id: I13fc501b24c3f11bfedc810c1ff80fcf1318877c Reviewed-on: https://chromium-review.googlesource.com/287343 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill 6b2a0b0c 2015-08-03T14:15:08 Reland of "Add Iterable bitset class." This helper allows us to quickly iterate state bits from the Impl/Renderer layers. Re-land with no C++11 usage. BUG=angleproject:1040 TEST=angle_unittests (Mac/Win/Linux) Change-Id: I3b6d5beb2bcff7fa3d45c9220d7c026c64c45d2e Reviewed-on: https://chromium-review.googlesource.com/290153 Tested-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Jamie Madill 9988a028 2015-08-03T12:46:45 Revert "Add Iterable bitset class." std::to_ullong is c++11, failing on Mac. BUG=angleproject:1040 This reverts commit 37a9e71246e2a3343289267e5d7e123948924bd3. Change-Id: I5cecd1fe95b889feffb556f67d082cec585256f4 Reviewed-on: https://chromium-review.googlesource.com/290211 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 37a9e712 2015-07-30T11:21:55 Add Iterable bitset class. This class allows us to quickly notify Impl/Renderer layers of which state changed. BUG=angleproject:1040 TEST=angle_unittests (Mac/Win/Linux) Change-Id: I2f27bc65b4f627a261e94e3e3b7095b169986cc6 Reviewed-on: https://chromium-review.googlesource.com/289557 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Arun Patole 551279e5 2015-07-07T18:18:23 Support constant folding of more common built-ins This change adds const folding support for below mentioned common built-ins: - isnan, ininf, floatBitsToInt, floatBitsToUint, intBitsToFloat and uintBitsToFloat BUG=angleproject:913 TEST=angle_unittests(new: MathUtilTest.isNan/inInf), dEQP Tests dEQP-GLES3.functional.shaders.constant_expressions.builtin_functions.common.* (20 more tests started passing with this change) Change-Id: Ifdedb251cd8b183b4999314c0f5de857bc20702f Reviewed-on: https://chromium-review.googlesource.com/283767 Reviewed-by: Olli Etuaho <oetuaho@nvidia.com> Tested-by: Olli Etuaho <oetuaho@nvidia.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Arun Patole cdfa8f50 2015-06-30T17:48:25 Constant fold float pack/unpack functions This change adds constant folding support for following floating point pack and unpack functions: - packSnorm2x16, unpackSnorm2x16, packUnorm2x16, unpackUnorm2x16, packHalf2x16, and unpackHalf2x16. BUG=angleproject:913 TEST=angle_unittests(new: MathUtilTest.packAndUnpack*), dEQP Tests dEQP-GLES3.functional.shaders.constant_expressions.builtin_functions.float_pack_unpack.* (all 10 tests started passing with this change) Change-Id: I2b69faebee4127e5e13900b3a9485b7145950277 Reviewed-on: https://chromium-review.googlesource.com/282683 Reviewed-by: Olli Etuaho <oetuaho@nvidia.com> Tested-by: Olli Etuaho <oetuaho@nvidia.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Arun Patole 56eee79f 2015-07-01T15:23:54 Move Float16ToFloat32 implementation to common Float16ToFloat32 is now required by constant folding of float pack/unpack built-ins as well, moving it to commom so that it is available in libangle_common instead of libANGLE. BUG=angleproject:913 TEST=angle_unittests Change-Id: I1e23bb98c1b725c79f933a66ddb9986133fec19c Reviewed-on: https://chromium-review.googlesource.com/282961 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Olli Etuaho <oetuaho@nvidia.com> Tested-by: Olli Etuaho <oetuaho@nvidia.com>
Jamie Madill 4d06a24c 2015-06-26T11:12:24 dEQP: Extend GoogleTest support. *re-land after rebase on top of Chrome build fix* This patch will enable a Chromium-side CL to build dEQP/ANGLE with GoogleTest. BUG=angleproject:998 BUG=500736 Change-Id: Id02c66a260b0a7bab3de9cda624fe097322b2d3c Reviewed-on: https://chromium-review.googlesource.com/281824 Tested-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@google.com> Reviewed-by: Kenneth Russell <kbr@chromium.org>
Arun Patole 7fa3355f 2015-06-10T15:15:18 Add constant folding support for matrix built-ins This change adds constant folding support for following matrix built-ins: - matrixCompMult, outerProduct, transpose, determinant and inverse. BUG=angleproject:913 TEST=angle_unittests(new: MatrixUtilsTest, ConstantFoldingTest.*Matrix*), dEQP Tests: dEQP-GLES3.functional.shaders.constant_expressions.builtin_functions.matrix.* (All 54 tests started passing with this change) Change-Id: I7b9bf04b9a2cbff72c48216cab04df58c5f008d6 Reviewed-on: https://chromium-review.googlesource.com/276574 Reviewed-by: Olli Etuaho <oetuaho@nvidia.com> Tested-by: Olli Etuaho <oetuaho@nvidia.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 57cdc69c 2015-06-23T21:03:06 Revert "dEQP: Extend GoogleTest support." Causing runhooks failures: gyp: Undefined variable deqp_path in C:\b\build\slave\GPU_Win_Builder\build\src\third_party\angle\src\tests\tests.gyp BUG=angleproject:998 BUG=500736 This reverts commit 8edd75d1bb6680e7c2018ece9f5c81e3b87bf938. Change-Id: I8cd83bb5871dea81abea61554b182825145298e6 Reviewed-on: https://chromium-review.googlesource.com/281208 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 8edd75d1 2015-06-22T15:35:53 dEQP: Extend GoogleTest support. This patch will enable a Chromium-side CL to build dEQP/ANGLE with GoogleTest. BUG=angleproject:998 BUG=500736 Change-Id: Ie480e3319c1bd77dd1de2c964f78ef97297fcfe9 Reviewed-on: https://chromium-review.googlesource.com/280856 Tested-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Zhenyao Mo <zmo@chromium.org>
Jamie Madill aa9e9971 2015-06-22T13:57:16 D3D11: Reduce overhead of clearing unused textures. *re-land with compile fix* We would spend a fair bit of time iterating over the unused textures, setting them to null one-by-one, and updating our cache. We can reduce this time by smarter caching, and skipping unmodified ranges. BUG=angleproject:959 Change-Id: I4de20bc131c4a568108ad670a2ef491cfd4c50ed Reviewed-on: https://chromium-review.googlesource.com/280916 Tested-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill d4898490 2015-06-22T17:56:18 Revert "D3D11: Reduce overhead of clearing unused textures." Compile error on Windows: error C2561: 'rx::Renderer11::clearTextures' : function must return a value BUG=angleproject:959 This reverts commit 475e5b7f91f8ed9688b5a46efe54f15357096e3e. Change-Id: Id34ff9530a71ce43549e2eb78d2d927084d46a47 Reviewed-on: https://chromium-review.googlesource.com/280915 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 475e5b7f 2015-06-22T13:12:45 D3D11: Reduce overhead of clearing unused textures. We would spend a fair bit of time iterating over the unused textures, setting them to null one-by-one, and updating our cache. We can reduce this time by smarter caching, and skipping unmodified ranges. BUG=angleproject:959 Change-Id: I92f11cf63542c55bb3adbbb8276a54bcfe848f61 Reviewed-on: https://chromium-review.googlesource.com/277118 Tested-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Austin Kinross 6ee1e786 2015-05-29T17:05:37 Implement GL_EXT_debug_marker in D3D9/D3D11 renderers BUG=angleproject:1043 Change-Id: I7f3bfb35050662520b901828d0478719fa8d11b3 Reviewed-on: https://chromium-review.googlesource.com/274054 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Austin Kinross <aukinros@microsoft.com>
Austin Kinross 405f3471 2015-06-04T13:09:06 In D3D11, check for 16-bit texture support and use if possible BUG=angleproject:1002 The last patch added new tests which failed on some Intel Win7 machines. This was due to a driver bug. Windows Updates have been applied to the failing machine, and the tests now pass. Changes between second and current (third) failed 16-bit patch: - Reenable usage of 16-bit DXGI textures on all Intel cards - Disable 16bpp tests on Intel D3D11 until the bots are updated - Updated Win7 test machine. Tests now pass Changes between first and second failed 16-bit patch: - Disabled usage of 16-bit DXGI textures on all Intel cards - Added DXGI->GL conversion entries for 16-bit formats, which fixes FBO readback issues. The ES CTS and dEQP tests which failed with the last patch now pass. Change-Id: Id8ea89bfbc450beea54afdd398956bc97ecf3c01 Reviewed-on: https://chromium-review.googlesource.com/275082 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Austin Kinross <aukinros@microsoft.com>
Jamie Madill c7be82ae 2015-06-01T14:14:04 Change behaviour of string_utils, also fix file io. File IO tested manually in a follow-up patch. BUG=angleproject:998 Change-Id: I0bfa778d1787cdedfbf3cd68cd134477e6dcd23c Reviewed-on: https://chromium-review.googlesource.com/274030 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Geoff Lang 6bef4ff7 2015-06-01T21:08:31 Revert "In D3D11, check for 16-bit texture support and use if possible" Seeing failures on Win7 + Intel machines. Example build: https://build.chromium.org/p/chromium.gpu.fyi/builders/Win7%20Release%20%28Intel%29/builds/11756 This reverts commit 673115d9cc4251cd690e14a98ef0c717ba9de0b9. Change-Id: Ie2b6cc1ae9c4e83dde3a531e38252c95ac2e2a0a Reviewed-on: https://chromium-review.googlesource.com/274450 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Austin Kinross 673115d9 2015-05-28T09:27:57 In D3D11, check for 16-bit texture support and use if possible BUG=angleproject:1002 Changed since last failed 16-bit patch: - Disabled usage of 16-bit DXGI textures on all Intel cards - Added DXGI->GL conversion entries for 16-bit formats, which fixes FBO readback issues. The ES CTS and dEQP tests which failed with the last patch now pass. Change-Id: Ib66abf73f23dbb4329f0a32d7f3dafbbc23e6c08 Reviewed-on: https://chromium-review.googlesource.com/273712 Tested-by: Austin Kinross <aukinros@microsoft.com> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Shawn Hargreaves 7eabe51e 2015-05-14T17:00:41 Add ANGLE_REVISION sub-identifier to the DLL versioning scheme Change-Id: Ie9df84957801def2db72a382f4860bbe4e06002f Reviewed-on: https://chromium-review.googlesource.com/274051 Tested-by: Shawn Hargreaves <shawnhar@microsoft.com> Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Geoff Lang 8e7549bd 2015-05-27T14:05:10 Revert "In D3D11, check for 16-bit texture support and use if possible" Causing failures on Windows 8 bots running ES CTS and Windows 7 Intel bot running angle tests. Example failures: https://build.chromium.org/p/chromium.gpu.fyi/builders/Win8%20Release%20%28NVIDIA%29/builds/14442 https://build.chromium.org/p/chromium.gpu.fyi/builders/Win7%20Release%20%28Intel%29/builds/11627 This reverts commit d63f08fcc32ea17bac2b025f0ad3261664ff79c9. Change-Id: I841aee5fb0973432f249277126424b909d5b3e17 Reviewed-on: https://chromium-review.googlesource.com/273416 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Austin Kinross d63f08fc 2015-05-21T10:22:04 In D3D11, check for 16-bit texture support and use if possible BUG=angleproject:1002 Change-Id: I36a5ee774b38e9865b2eb6c6789afd316c4eff16 Reviewed-on: https://chromium-review.googlesource.com/272061 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Austin Kinross <aukinros@microsoft.com>
Corentin Wallez 7467b2b1 2015-05-21T10:51:01 Fix warning in string_utils.cpp in Win32 BUG= Change-Id: Ibb25d46c2ee5f361f6a948dc3efea38422a4573f Reviewed-on: https://chromium-review.googlesource.com/272559 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Jamie Madill 8c5aeb6c 2015-05-21T08:17:18 Add some string helper classes. *re-land with build fix for Clang* These helper functions mirror some utilities in Chrome, for splitting strings along whitespace, or reading file contents into a string. Also remove the hack for skipping the doubly-defined GLX header. BUG=angleproject:892,angleproject:998 Change-Id: Ife43fbf5035a3be7820460bea1b26d0e632a4fb0 Reviewed-on: https://chromium-review.googlesource.com/272518 Tested-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Jamie Madill a30c78ae 2015-05-21T12:15:43 Revert "Add some string helper classes." Build errors on Clang: FAILED: /b/build/goma/gomacc ../../third_party/llvm-build/Release+Asserts/bin/clang++ -MMD -MF obj/third_party/angle/src/common/angle_common.string_utils.o.d -DV8_DEPRECATION_WARNINGS -D__ASSERT_MACROS_DEFINE_VERSIONS_WITHOUT_UNDERSCORE=0 -DCHROMIUM_BUILD -DCR_CLANG_REVISION=233105-2 -DTOOLKIT_VIEWS=1 -DUSE_LIBJPEG_TURBO=1 -DENABLE_ONE_CLICK_SIGNIN -DENABLE_PRE_SYNC_BACKUP -DENABLE_REMOTING=1 -DENABLE_WEBRTC=1 -DENABLE_MEDIA_ROUTER=1 -DUSE_PROPRIETARY_CODECS -DENABLE_PEPPER_CDMS -DENABLE_CONFIGURATION_POLICY -DENABLE_NOTIFICATIONS -DENABLE_HIDPI=1 -DSYSTEM_NATIVELY_SIGNALS_MEMORY_PRESSURE -DDONT_EMBED_BUILD_METADATA -DDCHECK_ALWAYS_ON=1 -DENABLE_TASK_MANAGER=1 -DENABLE_EXTENSIONS=1 -DENABLE_PLUGIN_INSTALLATION=1 -DENABLE_PLUGINS=1 -DENABLE_SESSION_SERVICE=1 -DENABLE_THEMES=1 -DENABLE_AUTOFILL_DIALOG=1 -DENABLE_BACKGROUND=1 -DENABLE_GOOGLE_NOW=1 -DCLD_VERSION=2 -DENABLE_PRINTING=1 -DENABLE_BASIC_PRINTING=1 -DENABLE_PRINT_PREVIEW=1 -DENABLE_SPELLCHECK=1 -DENABLE_CAPTIVE_PORTAL_DETECTION=1 -DENABLE_APP_LIST=1 -DENABLE_SETTINGS_APP=1 -DENABLE_SUPERVISED_USERS=1 -DENABLE_SERVICE_DISCOVERY=1 -DENABLE_WIFI_BOOTSTRAPPING=1 -DV8_USE_EXTERNAL_STARTUP_DATA -DFULL_SAFE_BROWSING -DSAFE_BROWSING_CSD -DSAFE_BROWSING_DB_LOCAL -DSAFE_BROWSING_SERVICE -DUSE_LIBPCI=1 -DUSE_OPENSSL=1 -DNDEBUG -DNVALGRIND -DDYNAMIC_ANNOTATIONS_ENABLED=0 -Igen -I../../third_party/angle/src -I../../third_party/angle/include -isysroot /Applications/Xcode5.1.1.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk -O2 -gdwarf-2 -fvisibility=hidden -Werror -Wnewline-eof -mmacosx-version-min=10.6 -arch x86_64 -Wendif-labels -Wno-unused-parameter -Wno-missing-field-initializers -Wno-selector-type-mismatch -Wpartial-availability -Wheader-hygiene -Wno-char-subscripts -Wno-unneeded-internal-declaration -Wno-covered-switch-default -Wstring-conversion -Wno-c++11-narrowing -Wno-deprecated-register -Wno-inconsistent-missing-override -std=c++11 -fno-rtti -fno-exceptions -fvisibility-inlines-hidden -fno-threadsafe-statics -Xclang -load -Xclang /b/build/slave/GPU_Mac_Builder/build/src/third_party/llvm-build/Release+Asserts/lib/libFindBadConstructs.dylib -Xclang -add-plugin -Xclang find-bad-constructs -fcolor-diagnostics -fno-strict-aliasing -c ../../third_party/angle/src/common/string_utils.cpp -o obj/third_party/angle/src/common/angle_common.string_utils.o ../../third_party/angle/src/common/string_utils.cpp:72:19: error: no matching constructor for initialization of 'std::ifstream' (aka 'basic_ifstream<char>') std::ifstream inFile(path); ^ ~~~~ /Applications/Xcode5.1.1.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk/usr/include/c++/4.2.1/fstream:465:7: note: candidate constructor not viable: no known conversion from 'const std::string' (aka 'const basic_string<char>') to 'const char *' for 1st argument basic_ifstream(const char* __s, ios_base::openmode __mode = ios_base::in) ^ /Applications/Xcode5.1.1.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk/usr/include/c++/4.2.1/bits/fstream.tcc:894:25: note: candidate constructor (the implicit copy constructor) not viable: no known conversion from 'const std::string' (aka 'const basic_string<char>') to 'const std::basic_ifstream<char>' for 1st argument extern template class basic_ifstream<char>; ^ /Applications/Xcode5.1.1.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk/usr/include/c++/4.2.1/fstream:451:7: note: candidate constructor not viable: requires 0 arguments, but 1 was provided basic_ifstream() : __istream_type(), _M_filebuf() ^ 1 error generated. FAILED: /b/build/goma/gomacc ../../third_party/llvm-build/Release+Asserts/bin/clang++ -MMD -MF obj/third_party/angle/src/common/angle_unittests.string_utils_unittest.o.d -DV8_DEPRECATION_WARNINGS -D__ASSERT_MACROS_DEFINE_VERSIONS_WITHOUT_UNDERSCORE=0 -DCHROMIUM_BUILD -DCR_CLANG_REVISION=233105-2 -DTOOLKIT_VIEWS=1 -DUSE_LIBJPEG_TURBO=1 -DENABLE_ONE_CLICK_SIGNIN -DENABLE_PRE_SYNC_BACKUP -DENABLE_REMOTING=1 -DENABLE_WEBRTC=1 -DENABLE_MEDIA_ROUTER=1 -DUSE_PROPRIETARY_CODECS -DENABLE_PEPPER_CDMS -DENABLE_CONFIGURATION_POLICY -DENABLE_NOTIFICATIONS -DENABLE_HIDPI=1 -DSYSTEM_NATIVELY_SIGNALS_MEMORY_PRESSURE -DDONT_EMBED_BUILD_METADATA -DDCHECK_ALWAYS_ON=1 -DENABLE_TASK_MANAGER=1 -DENABLE_EXTENSIONS=1 -DENABLE_PLUGIN_INSTALLATION=1 -DENABLE_PLUGINS=1 -DENABLE_SESSION_SERVICE=1 -DENABLE_THEMES=1 -DENABLE_AUTOFILL_DIALOG=1 -DENABLE_BACKGROUND=1 -DENABLE_GOOGLE_NOW=1 -DCLD_VERSION=2 -DENABLE_PRINTING=1 -DENABLE_BASIC_PRINTING=1 -DENABLE_PRINT_PREVIEW=1 -DENABLE_SPELLCHECK=1 -DENABLE_CAPTIVE_PORTAL_DETECTION=1 -DENABLE_APP_LIST=1 -DENABLE_SETTINGS_APP=1 -DENABLE_SUPERVISED_USERS=1 -DENABLE_SERVICE_DISCOVERY=1 -DENABLE_WIFI_BOOTSTRAPPING=1 -DV8_USE_EXTERNAL_STARTUP_DATA -DFULL_SAFE_BROWSING -DSAFE_BROWSING_CSD -DSAFE_BROWSING_DB_LOCAL -DSAFE_BROWSING_SERVICE -DGTEST_HAS_POSIX_RE=0 -DGTEST_LANG_CXX11=0 -DGL_APICALL= -DGL_GLEXT_PROTOTYPES= -DEGLAPI= '-DANGLE_PRELOADED_D3DCOMPILER_MODULE_NAMES={ "d3dcompiler_47.dll", "d3dcompiler_46.dll", "d3dcompiler_43.dll" }' -DANGLE_TRANSLATOR_STATIC -DUSE_LIBPCI=1 -DUSE_OPENSSL=1 -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -DNDEBUG -DNVALGRIND -DDYNAMIC_ANNOTATIONS_ENABLED=0 -D_FORTIFY_SOURCE=2 -Igen -I../.. -I../../third_party/angle/include -I../../third_party/angle/src -I../../third_party/angle/src/compiler/preprocessor -I../../third_party/angle/src/tests -Igen/angle -I../../testing/gmock/include -I../../testing/gtest/include -isysroot /Applications/Xcode5.1.1.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk -O2 -gdwarf-2 -fvisibility=hidden -Werror -Wnewline-eof -mmacosx-version-min=10.6 -arch x86_64 -Wall -Wendif-labels -Wextra -Wno-unused-parameter -Wno-missing-field-initializers -Wno-selector-type-mismatch -Wpartial-availability -Wheader-hygiene -Wno-char-subscripts -Wno-unneeded-internal-declaration -Wno-covered-switch-default -Wstring-conversion -Wno-c++11-narrowing -Wno-deprecated-register -Wno-inconsistent-missing-override -std=c++11 -fno-rtti -fno-exceptions -fvisibility-inlines-hidden -fno-threadsafe-statics -Xclang -load -Xclang /b/build/slave/GPU_Mac_Builder/build/src/third_party/llvm-build/Release+Asserts/lib/libFindBadConstructs.dylib -Xclang -add-plugin -Xclang find-bad-constructs -fcolor-diagnostics -fno-strict-aliasing -c ../../third_party/angle/src/common/string_utils_unittest.cpp -o obj/third_party/angle/src/common/angle_unittests.string_utils_unittest.o In file included from ../../third_party/angle/src/common/string_utils_unittest.cpp:12: ../../testing/gtest/include/gtest/gtest.h:1481:16: error: comparison of integers of different signs: 'const int' and 'const unsigned int' [-Werror,-Wsign-compare] if (expected == actual) { ~~~~~~~~ ^ ~~~~~~ ../../testing/gtest/include/gtest/gtest.h:1511:12: note: in instantiation of function template specialization 'testing::internal::CmpHelperEQ<int, unsigned int>' requested here return CmpHelperEQ(expected_expression, actual_expression, expected, ^ ../../third_party/angle/src/common/string_utils_unittest.cpp:55:5: note: in instantiation of function template specialization 'testing::internal::EqHelper<false>::Compare<int, unsigned int>' requested here EXPECT_EQ(0xBADF00D, uintValue); ^ ../../testing/gtest/include/gtest/gtest.h:2017:67: note: expanded from macro 'EXPECT_EQ' EqHelper<GTEST_IS_NULL_LITERAL_(expected)>::Compare, \ ^ ../../testing/gtest/include/gtest/gtest_pred_impl.h:162:23: note: expanded from macro 'EXPECT_PRED_FORMAT2' GTEST_PRED_FORMAT2_(pred_format, v1, v2, GTEST_NONFATAL_FAILURE_) ^ ../../testing/gtest/include/gtest/gtest_pred_impl.h:147:17: note: expanded from macro 'GTEST_PRED_FORMAT2_' GTEST_ASSERT_(pred_format(#v1, #v2, v1, v2), \ ^ ../../testing/gtest/include/gtest/gtest_pred_impl.h:77:52: note: expanded from macro 'GTEST_ASSERT_' if (const ::testing::AssertionResult gtest_ar = (expression)) \ ^ BUG=angleproject:892,angleproject:998 This reverts commit fa5fb6f1ef685af316b320530ffbb425bb63446e. Change-Id: I949debbd365926301ec19225f262484fa3b8e13b Reviewed-on: https://chromium-review.googlesource.com/272548 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill fa5fb6f1 2015-05-20T16:13:48 Add some string helper classes. These helper functions mirror some utilities in Chrome, for splitting strings along whitespace, or reading file contents into a string. Also remove the hack for skipping the doubly-defined GLX header. BUG=angleproject:892,angleproject:998 Change-Id: Ie617be7e02c2ccc684028500aabb54561c9c6c14 Reviewed-on: https://chromium-review.googlesource.com/272436 Reviewed-by: Brandon Jones <bajones@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Geoff Lang f51bc795 2015-05-04T14:57:03 Optimize Texture binding by only applying referenced textures. Update ProgramGL to track which the current values of sampler uniforms so that only the currently applied texture units have to be bound for the draw call. BUG=angleproject:882 Change-Id: I280aa106172b13a5fbb31cdefba27b6691c0a0e4 Reviewed-on: https://chromium-review.googlesource.com/264803 Reviewed-by: Kenneth Russell <kbr@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 831b1953 2015-05-05T11:02:27 Move the IndexRangeCache and Range types to the gl namespace. BUG=angleproject:881 Change-Id: Ib05149facee9fcc7714cb957ca8647b3498a36b6 Reviewed-on: https://chromium-review.googlesource.com/269254 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Brandon Jones <bajones@chromium.org>
Jamie Madill 1377689c 2015-04-28T12:39:06 Cache validate samplers result. This gives ~23% increase in the validation-only draw call perf test. BUG=angleproject:959 Change-Id: I384a5c4fbb1c2cd47483bd7cf4bc1d39447a99bc Reviewed-on: https://chromium-review.googlesource.com/267750 Tested-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Brandon Jones <bajones@chromium.org>
Geoff Lang cfaeaa9f 2015-04-14T13:41:02 Refactor uniform array name parsing to a utility function. BUG=angleproject:882 Change-Id: I00fd6d3cfaa107561cee5e4c82d3c60438052963 Reviewed-on: https://chromium-review.googlesource.com/265723 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Kenneth Russell <kbr@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill d8b36d45 2015-04-09T11:12:43 Remove SetTraceFunctionPointers and update APIs. Now that Chromium is switched to ANGLE's new Platform tracing methods, we can junk the old APIs. BUG=angleproject:966 BUG=436191 Change-Id: Ie2564eed9e5ce4604e0dcd4582618e7467b2d590 Reviewed-on: https://chromium-review.googlesource.com/264934 Tested-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Kenneth Russell <kbr@chromium.org> Reviewed-by: Brandon Jones <bajones@chromium.org>
Minmin Gong 794e0009 2015-04-07T18:31:54 Fix and enable warning C4244 (Conversion from 'type1' to 'type2', possible loss of data) Change-Id: Id0e06d7d6600344d858f00dabc219d79289bbc82 Reviewed-on: https://chromium-review.googlesource.com/265020 Tested-by: Minmin Gong <mgong@microsoft.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill b3584fb4 2015-04-09T17:34:21 Revert "Fix and enable warning C4244 (Conversion from 'type1' to 'type2', possible loss of data)" Causing a build failure on Mac/Clang: ./Tokenizer.cpp:551:7: error: extra tokens at end of #else directive [-Werror,-Wextra-tokens] #else if defined(_MSC_VER) http://build.chromium.org/p/chromium.gpu.fyi/builders/GPU%20Mac%20Builder/builds/29136 This reverts commit 3b26e231d99154814eb428f75a67bbe7a21adadc. Change-Id: I2d11ddcc18130d908fd2ec3d6f5ab890cfccd5e7 Reviewed-on: https://chromium-review.googlesource.com/264983 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Minmin Gong 3b26e231 2015-04-07T18:31:54 Fix and enable warning C4244 (Conversion from 'type1' to 'type2', possible loss of data) Change-Id: I73d9a2b9ad16f032be974b9c819de0dc1247c2ea Reviewed-on: https://chromium-review.googlesource.com/264533 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill ae2d8a3a 2015-04-07T11:21:07 Add Platform methods for event tracing. Event tracing requires pulling in timing counters, so we can sync with Chromium's timestamps. It may require a bit more tricky stuff to sync ANGLE's GPU timestamps with trace timestamps, but should allow us to add GPU trace events in the future. BUG=chromium:436191 BUG=angleproject:966 Change-Id: Ie1dc2981650d96888f988fa74b6fa435fbe8edc2 Reviewed-on: https://chromium-review.googlesource.com/263781 Reviewed-by: Brandon Jones <bajones@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 8c25cdec 2015-04-01T16:37:48 Only check dynamic type in Impl casting helpers. We can use the Impl casting helper methods to clean up dynamic type casting. Change-Id: I5706da74eedd9f3cdc5a728420074a91ad7c95cb Reviewed-on: https://chromium-review.googlesource.com/263520 Tested-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 6c7a80d8 2015-04-02T13:00:32 Detect RTTI properly on Clang. This was giving a compile error on OSX. Also update the logic slightly. BUG=angleproject:963 Change-Id: I1ac64aa0908a58d9780054084d5c205c61848763 Reviewed-on: https://chromium-review.googlesource.com/263730 Tested-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill f0d10f89 2015-03-31T12:56:52 Replace non-copyable macro with a helper class. This class provides a simpler scheme for blocking default copy and assignment operators. It also reduces the amount of code needed since it's inherited to child classes. This also fixes the conflict between our macro and the same-named macro in Chromium code. BUG=angleproject:956 Change-Id: If0dc72aa3f63fbc7b8fa34907418821c64c39e2f Reviewed-on: https://chromium-review.googlesource.com/263257 Tested-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Brandon Jones <bajones@chromium.org>
Jamie Madill e4ea202a 2015-03-26T20:35:05 Revert "Compile the D3D11 VS and PS on separate threads at GL link time" Causing a high-volume crashe in Chrome. This reverts commit 434953e20002666f66d721aaacbcb8410f7dbd56. BUG=470695 Change-Id: I2062c706ab6ca6b4c3117685df67c33572518da5 Reviewed-on: https://chromium-review.googlesource.com/262704 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jacek Caban e842eabd 2015-03-26T16:50:35 Fixed compilation with mingw. Change-Id: I027cedc383efbd215e55a7ddf4e41eb1c368a1ae Reviewed-on: https://chromium-review.googlesource.com/262590 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Jacek Caban <cjacek@gmail.com>
Jamie Madill 64af27bd 2015-03-19T13:42:14 Make Optional a proper helper class. Move this to a common area, out of perf tests. Change-Id: I53d36accfe0c53789c007edfb20ba7e964947def Reviewed-on: https://chromium-review.googlesource.com/260643 Tested-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Geoff Lang d4475816 2015-03-18T10:53:05 Always use static_assert for compile-time assertions and remove META_ASSERT. BUG=468139 Change-Id: I696ef307f2faa54bb72df66784bc79a055499987 Reviewed-on: https://chromium-review.googlesource.com/260776 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 2c7c625a 2015-03-12T14:15:38 Refactor D3D Debug Annotations code. This encapsultates the different implementations and allows us to compile debug.cpp in the common libraries without link errors. BUG=angleproject:513 Change-Id: I16dc4c666fb4266ee5146d64d77eb9925c7584a8 Reviewed-on: https://chromium-review.googlesource.com/256450 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Austin Kinross b8af723d 2015-03-16T22:33:25 Fix and enable warning C4245 (signed/unsigned mismatch) Change-Id: If48043835fcc98341a0626e3ece7d0e3f7958059 Reviewed-on: https://chromium-review.googlesource.com/260630 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Cooper Partin <coopp@microsoft.com> Tested-by: Austin Kinross <aukinros@microsoft.com> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Austin Kinross 434953e2 2015-02-20T10:49:51 Compile the D3D11 VS and PS on separate threads at GL link time Change-Id: Ib534483f2ec3922cfeaf71cf1d9e9c433fe04b08 Reviewed-on: https://chromium-review.googlesource.com/251612 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill fd67b1bf 2015-03-10T16:13:24 Move implementation unit tests to angle_unittests. Now that libANGLE is cross-platform, this should work on OSX/Linux and Android. Includes a warning fixes for test comparisons, and fix to our META_ASSERT wrapper macro for clang. BUG=angleproject:773 Change-Id: I6b88a85c62a2e07734ae81fb8276c28c5f8f9f47 Reviewed-on: https://chromium-review.googlesource.com/258300 Tested-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Kenneth Russell <kbr@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 7825f619 2014-11-26T16:19:41 Update ANGLE_platform_angle_d3d to use a device type enum instead of WARP bool. BUG=angle:490 Change-Id: I1555e7f09b23138753e52ddf720d088587f7cadb Reviewed-on: https://chromium-review.googlesource.com/232104 Reviewed-by: Shannon Woods <shannonwoods@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill 6df9b37d 2015-02-18T21:28:19 Revert "Re-resubmit "Compile the D3D11 VS and PS on separate threads at GL link time"" Fails clang-win again. Apparently Clang mimics MSVS. This reverts commit af1bdff62ec4cc80b47fbac7e5d973f6f7225036. Change-Id: I48a503889a9e905fcdc9f101dbf98f7cb7912279 Reviewed-on: https://chromium-review.googlesource.com/250882 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Austin Kinross af1bdff6 2015-02-17T11:07:46 Re-resubmit "Compile the D3D11 VS and PS on separate threads at GL link time" The latest version of this change disables multithreaded D3D shader compilation with any C++ compiler other than VC (e.g. Clang). Change-Id: If3ef5fd650055ae66397ea2c9121bfcf1792892a Reviewed-on: https://chromium-review.googlesource.com/250328 Tested-by: Austin Kinross <aukinros@microsoft.com> Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Cooper Partin <coopp@microsoft.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill d2d21dca 2015-02-17T18:07:01 Revert "Resubmit "Compile the D3D11 VS and PS on separate threads at GL link time"" Causes errors in Clang-Win. We can fix the error and then resubmit, but need to do a roll now. This reverts commit 310184861bab5e95139e0f34b1f8e88fe8c677b8. Change-Id: I1c91b0a97031df33c2261089f6b54ccd3270306b Reviewed-on: https://chromium-review.googlesource.com/250430 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 959ad9a8 2015-02-09T10:51:39 Fix cstdint include in MemoryBuffer.h. This syntax isn't compatible with OSX. Change-Id: I3ec2bc856843637c4e1e7afb96a93ff6ea8296da Reviewed-on: https://chromium-review.googlesource.com/247660 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 74ba76c4 2015-02-09T10:31:23 Move rx::MemoryBuffer to common library. This class is not D3D-specific so can be shared among other back-ends, or other parts of the ANGLE codebase. Change-Id: Ie00760eb5dae4db52e465ee7a2f97789bae8c0b0 Reviewed-on: https://chromium-review.googlesource.com/246500 Tested-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Austin Kinross 31018486 2015-01-30T13:06:52 Resubmit "Compile the D3D11 VS and PS on separate threads at GL link time" The original change caused a Chromium build break due to "__uncaught_exception" not being defined in concrt.h. This is because Chromium defines "_HAS_EXCEPTIONS=0" in its GYP, but ANGLE doesn't do this. This change defines "_HAS_EXCEPTIONS=0" in ANGLE's GYP to match Chromium, and refines it in ProgramD3D.cpp before including <future>. Change-Id: Ic324702569bac8f4ae1381f308c4f3f11f190f9e Reviewed-on: https://chromium-review.googlesource.com/244860 Tested-by: Austin Kinross <aukinros@microsoft.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 9d294c33 2015-01-30T19:58:39 Revert "Compile the D3D11 VS and PS on separate threads at GL link time" Failing compile on Chromium bots: FAILED: ninja -t msvc -e environment.x86 -- C:\b\build\goma/gomacc "C:\b\depot_tools\win_toolchain\vs2013_files\VC\bin\amd64_x86\cl.exe" /nologo /showIncludes /FC @obj\third_party\angle\src\libANGLE\renderer\d3d\libANGLE.ProgramD3D.obj.rsp /c ..\..\third_party\angle\src\libANGLE\renderer\d3d\ProgramD3D.cpp /Foobj\third_party\angle\src\libANGLE\renderer\d3d\libANGLE.ProgramD3D.obj /Fdobj\third_party\angle\src\libANGLE.cc.pdb c:\b\depot_tools\win_toolchain\vs2013_files\vc\include\concrt.h(4774) : error C3861: '__uncaught_exception': identifier not found ninja: build stopped: subcommand failed. This reverts commit 6d51f2629a8118f7afd450ea832c93143a84c330. Change-Id: Iebb2843dfbc3795290fbb33e1a111ddad59c3126 Reviewed-on: https://chromium-review.googlesource.com/244792 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Austin Kinross 6d51f262 2015-01-26T16:34:48 Compile the D3D11 VS and PS on separate threads at GL link time BUG=angle:900 Change-Id: Iad5dbbcc676e2a2b6dfc3d7bc6ab5957154de33e Reviewed-on: https://chromium-review.googlesource.com/240490 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Austin Kinross <aukinros@microsoft.com>
Austin Kinross 2bdcbb9a 2015-01-16T11:12:15 Enable Windows Phone 8.1 project generation Change-Id: Iab44f6d634bdcd01348aa49de28b96c3b6086df7 Reviewed-on: https://chromium-review.googlesource.com/241945 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Austin Kinross <aukinros@microsoft.com>
Geoff Lang 691e58cd 2014-12-19T17:03:25 Merge all gl::Texture* classes. The validation for sampler completeness had a lot of duplicated code. The special cases have been merged into the base class by checking mTarget. BUG=angle:681 Change-Id: I11d94c1432f8fc70a1edaaf8228bbc43c3c8fff3 Reviewed-on: https://chromium-review.googlesource.com/236932 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill dd806c2b 2015-01-14T14:26:35 Use emmintrin.h for SSE includes. This header should work on all available platforms, instead of the platform-specific intrin.h or x86intrin.h. BUG=angle:773 Change-Id: Ia012053064838f9893aa647d872e136a47cfad1a Reviewed-on: https://chromium-review.googlesource.com/240552 Tested-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Cooper Partin ffe38e1c 2015-01-14T08:32:19 Fixed WinRT ARM build break. ARM cannot use SSE. Change-Id: I9a55d37db148f82b255e2c7ff414e79259e2c4e1 Reviewed-on: https://chromium-review.googlesource.com/240476 Tested-by: Cooper Partin <coopp@microsoft.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 9e0478f6 2015-01-13T11:13:54 Move the block layout code to translator. This code is easily accessible from the translator, with the proper export calls. This facilitates adding a common static library, since this code calls some methods in translator. BUG=angle:773 Change-Id: I0c50098ec3f67c2df7749b3c2518be0a9fd939e2 Reviewed-on: https://chromium-review.googlesource.com/240093 Reviewed-by: Zhenyao Mo <zmo@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 0875f85d 2015-01-12T16:27:11 Don't use SSE functions on Android. These methods are unavailable on ARM platforms. Also fix a sequencing bug that caused us to incorrectly define the Android platform as Linux. BUG=angle:773 Change-Id: Id2b47acdd5b574c618ac86641a1a8238fbb4a2c3 Reviewed-on: https://chromium-review.googlesource.com/240095 Tested-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Cooper Partin 7318b7cb 2015-01-08T09:15:35 Fixed failed compilation for WinRT to use OutputDebugStringA for non wide strings. Change-Id: If012660d4b895399fe5e3226dea25a8c7f78c8ac Reviewed-on: https://chromium-review.googlesource.com/239504 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Cooper Partin <coopp@microsoft.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 14aa40f0 2015-01-07T15:12:47 Print ERR() errors to the debug output on Windows. We can switch this on for Debug only. This will help developers catch bugs more easily, and will only show up for internal errors and major performance caveats. Currently it's far too easy to miss these messages - it requires manually modifying debug.h, looking at a text file and potentially also running Chromium with an special flag. BUG=angle:663 Change-Id: I75b3bd05fbc75d21607b9957134db8e8990c77b1 Reviewed-on: https://chromium-review.googlesource.com/239191 Tested-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill 01675d80 2015-01-05T16:09:08 Use correct SSE header on OSX. This fixes the compile errors in loadImageSSE2.cpp. BUG=angle:773 This reverts commit a93192369eb448e932bcdd1e08ae791aacfbe0c4. Change-Id: I31bc419cd3930ae129903b935f49a3c9b27fc887 Reviewed-on: https://chromium-review.googlesource.com/238448 Tested-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill 3b9bb72b 2015-01-05T16:17:02 Add a cross-platform rotl implementation. The _rotl method is unavailable on any platform but Windows, so we can implement the method ourselves. BUG=angle:773 Change-Id: I1342f4cf8a996daf11a36553c3bf7a01a2b182b3 Reviewed-on: https://chromium-review.googlesource.com/238500 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 3011c25b 2014-12-04T13:48:46 Fix event tracer linking on Linux. We were including the cpp in multiple targets, which was causing a multiply defined error. BUG=angle:773 Change-Id: I1e31756faee2d7734f1fc6cfb086d0e7ec6519bc Reviewed-on: https://chromium-review.googlesource.com/232966 Tested-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Brandon Jones <bajones@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 2ec386bb 2014-12-03T14:44:38 Rename IsSampler to IsSamplerType. BUG=angle:733 Change-Id: I62aece16c11aefdbf13c0b5faf83040fdb8555e6 Reviewed-on: https://chromium-review.googlesource.com/232960 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 8bc361e1 2014-11-20T16:23:31 Support compiling libANGLE as a static or shared library. BUG=angle:733 Change-Id: If27d3330534bce0f5b691010ea7d97bcb7579122 Reviewed-on: https://chromium-review.googlesource.com/231052 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill 55573e13 2014-11-25T11:21:13 Use cross-platform enum for Vendor ID. BUG=angle:795 Change-Id: Ibe9bbb79b92730ba80ca7275528c8b61d5d44c59 Reviewed-on: https://chromium-review.googlesource.com/228914 Tested-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 2207213b 2014-11-20T15:15:01 Move as many files as possible from common to libANGLE. BUG=angle:733 Change-Id: If01c91cd52ac5c2102276a9fdc4b68ebc13e47f9 Reviewed-on: https://chromium-review.googlesource.com/231850 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 4349ab85 2014-11-25T15:53:34 Revert "Move as many files as possible from common to libANGLE." Chromium directly includes our common/version.h and couldn't build after this change. This reverts commit f0a2c7727f9863c38a435a16a69d513c481fbbdd. Change-Id: Iafc41b1a3973f609518fe3588fdb64cecc285332 Reviewed-on: https://chromium-review.googlesource.com/231840 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang f0a2c772 2014-11-20T15:15:01 Move as many files as possible from common to libANGLE. BUG=angle:733 Change-Id: I40cee6e2e305ac493acbc8649f858785c0569aed Reviewed-on: https://chromium-review.googlesource.com/231051 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 0a73dd85 2014-11-19T16:18:08 Fix include guards. BUG=angle:733 Change-Id: I08b2c11c4831f1161c178c1842b10e807185aced Reviewed-on: https://chromium-review.googlesource.com/230831 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Kenneth Russell b23deb26 2014-11-21T14:53:56 Fixed Mac and Linux build breakage. Introduced in 1edac3b1bdcc54a4b0f0449cb727bda84ab3ee53 . BUG=none Change-Id: Ia5c5e38b794e9c991ec8624de34681dcf13a651f Reviewed-on: https://chromium-review.googlesource.com/231441 Tested-by: Kenneth Russell <kbr@chromium.org> Reviewed-by: Brandon Jones <bajones@chromium.org>