Log

Author Commit Date CI Message
Corentin Wallez 37c3979e 2015-08-20T14:19:46 Revert "Revert "Make the default framebuffer owned by Surface"" Reland the commit after fixing a bug in FramebufferAttachment. This reverts commit 18fdcbcf1d02d3b3b4b5c712f05058f2e8d629c6. BUG=angleproject:891 Change-Id: I07e08de52bfce8d84d070fc7bc15883009298a4d Reviewed-on: https://chromium-review.googlesource.com/294831 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Corentin Wallez 314f9b33 2015-08-20T14:13:20 FramebufferAttachment: do not attach with an uninitialized mResource Otherwise attach will try to call onDetach on mResource, causing an UB (and a segfault in most cases). This fixes a crash when running angle_unittests on Mac with another patch. BUG=angleproject:891 Change-Id: I09d34d7246849059a13bc2fb00a61837cccd97d7 Reviewed-on: https://chromium-review.googlesource.com/294830 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Corentin Wallez b5d61dac 2015-08-20T13:43:02 Revert "Add deep copying support for typed AST nodes" This reverts commit d0d59aa4cbce2da92deaa0f4021dfed8885e8d01 and commit 760379532b02ae039790f1e8f1c89e03481aab4b To be fixed will be the newline at the end of IntermNode_tests.cpp and the -Winconsistent-missing-override BUG= Change-Id: I57693bdff01f9e3f03b2fbb5dc53fa21e68c2789 Reviewed-on: https://chromium-review.googlesource.com/294820 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Olli Etuaho a7b6db7f 2015-08-19T14:26:30 Only apply Appendix A limitations to ESSL 1.00 shaders ESSL 1.00 specifies a set of minimum functionality, and ANGLE automatically checks that WebGL shaders stay within this minimum functionality. However, this should only apply to ESSL 1.00. ESSL 3.00 shaders compiled for WebGL 2.0 should not be subject to these restrictions, since there is no similar spec for minimum functionality for ESSL 3.00. In case a non-WebGL based shader spec is used, the restrictions can be toggled from outside by specifying the SH_VALIDATE_LOOP_INDEXING flag, same as before this patch. BUG=angleproject:1116 TEST=WebGL 2 conformance tests Change-Id: Idaec0fb4c7c85cd72020d0b23112fddb1b020571 Reviewed-on: https://chromium-review.googlesource.com/293933 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Olli Etuaho <oetuaho@nvidia.com>
Corentin Wallez 76037953 2015-08-20T13:18:44 Fix compilation on Mac, adding a newline in IntermNode_test.cpp BUG= Change-Id: Ie935486bf44bacb89660419c0dabd0ff38838c90 Reviewed-on: https://chromium-review.googlesource.com/294800 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Jamie Madill 5f116e5d 2015-08-20T11:13:32 Fix regression with GetNextGLSLAttributeType. A refactoring bug slipped in that used the non-transposed row count for non-square matrices, causing an ASSERT failure in Debug. It's unfortunately not easy to revert the previous change, so instead fix it here. BUG=angleproject:1129 Change-Id: I0de66de46a24b402c93da68f189a2c65616c2006 Reviewed-on: https://chromium-review.googlesource.com/294641 Tested-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Corentin Wallez d538e56e 2015-08-19T13:19:19 Make Release compile with c++11 on Mac standalone BUG=angleproject:891 Change-Id: Id61e61a2efff019e92316adbe34fc2378302aff5 Reviewed-on: https://chromium-review.googlesource.com/294600 Tested-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Corentin Wallez ec1be6d5 2015-08-19T15:07:43 Suppress dEQP negative_api compressedtexsubimage2d_invalid_size on Linux Temporarily suppress this test as it might be caused by a dEQP bug. BUG=angleproject:1128 Change-Id: I9c6f1b95edca55f54f3292227ebc81d4ddc57f0a Reviewed-on: https://chromium-review.googlesource.com/294580 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Olli Etuaho d0d59aa4 2015-08-18T13:49:45 Add deep copying support for typed AST nodes Removing dynamic indexing of vectors and matrices will require copying the indexed nodes in case they are written. Any type of l-value node that doesn't have side effects may need to be copied. Add a copying function for all typed node classes so that this copying can be performed. Private copy constructors are used to implement the deepCopy function in order to make maintenance easier. With copy constructors, each subclass only needs to take care of copying its own members, and not the base class members, which reduces the possibility of errors. Copy constructors are disabled for all node classes that don't support deep copying by inheriting TIntermNode from angle::NonCopyable. Assignment operator is disabled for all node classes through inheriting angle::NonCopyable. This applies also to classes that now get the private copy constructor. Explicit copy constructor and assignment operator declarations are added to some classes which show up in node member variables to make code clearer. BUG=angleproject:1116 TEST=angle_unittests Change-Id: Ia757b69397837f8309f0e7511c0cd24ca2c7a721 Reviewed-on: https://chromium-review.googlesource.com/293931 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Olli Etuaho <oetuaho@nvidia.com>
Jamie Madill 5c42266e 2015-08-18T10:46:15 Make Program::usesPointSize D3D-only. This test is only used in the D3D code, so we can remove this Impl method. If we need it in the future we can always support it more generally from the translator, or handle it differently on each Renderer. BUG=angleproject:1123 Change-Id: Ic4a22ad6cec93726195e68200fc25cc2956be44c Reviewed-on: https://chromium-review.googlesource.com/293822 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 31c8c56a 2015-08-19T14:08:03 Make ProgramImpl::compileProgramExecutables D3D-only. Finally we can isolate this method into the D3D-only code, and remove the interface from ProgramImpl. BUG=angleproject:1123 Change-Id: I253b15d44d4cf8bbb5dbeaa78bbcc431a5267bf7 Reviewed-on: https://chromium-review.googlesource.com/293765 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 18fdcbcf 2015-08-19T18:12:44 Revert "Make the default framebuffer owned by Surface" Seems to be causing failures on the Mac GPU FYI bots. SurfaceTest.DestructionDeletesImpl seems to crash. BUG=angleproject:891 BUG=522557 This reverts commit 264ab56f2e70431e8310f9353952acd3b22b466f. Change-Id: I80aeecb8e191de011d9afe6534d0285dcffa82a3 Reviewed-on: https://chromium-review.googlesource.com/294540 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Corentin Wallez 1661fde6 2015-08-18T11:29:46 ProgramGL: Mark all columns of matrix attributes as active The active attributes are used to determine which of the vertex attributes to enable. Matrices take up several attributes depending on the number of column they have; this patch marks all the columns of active matrix attributes as active. TEST=dEQP-GLES2.functional.shaders.linkage.varying_type_mat* BUG=angleproject:1127 Change-Id: I82f548f329f872c4e66aa0e4e71c6061a55b9987 Reviewed-on: https://chromium-review.googlesource.com/294261 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Olli Etuaho 26e355b8 2015-08-14T14:16:19 Add full support for line continuation in the preprocessor Re-landing earlier change with constant signedness fixed (was causing build issues on Linux). Line continuation in ESSL 3.00 needs to be processed before tokenization, since tokens can span the line continuation. On the other hand, ANGLE's tokenizer keeps track of line numbers, and whenever a line continuation appears the line number still needs to be incremented by one, just like on a regular newline. That's why line continuation is now implemented as follows: when the shader strings are concatenated in Input, they are also checked for line continuation. Whenever line continuation is encountered, the string is cut before that point. When the tokenizer asks for more input, the string starting from the character after line continuation is passed to it, and the line number is incremented from Input. This way the tokenizer can parse tokens that span multiple lines - it never sees the line continuation - but still keeps track of the line number correctly. Relevant spec is in ESSL 3.00 section 3.2 "Source strings". Support for line continuation also applies to ESSL 1.00. ESSL 3.00 spec section 1.5 says that line continuation support is mandated when an ESSL 1.00 shader is used with the OpenGL ES 3.0 API, and is optional when ESSL 1.00 is used with the OpenGL ES 2.0 API. TEST=dEQP-GLES3.functional.shaders.preprocessor.line_continuation.* (all pass), angle_unittests BUG=angleproject:1125 Change-Id: Ic086aacac53cd75bf93c0fda782416501d2f842b Reviewed-on: https://chromium-review.googlesource.com/294200 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Olli Etuaho <oetuaho@nvidia.com>
Corentin Wallez 264ab56f 2015-08-12T12:39:52 Make the default framebuffer owned by Surface Reland with a fix for SurfaceTest in angle_unittests and fixes for signed-unsigned warnings In CGL there is no notion of default Framebuffer and MakeCurrent only makes a context current but not a drawable. Instead, everything is done via render to texture. For that reason, different surfaces will have different FBOs as default framebuffers, which causes that change. BUG=angleproject:891 Change-Id: I0664896bc335b1a757226aaa212536b8f9d0f08f Reviewed-on: https://chromium-review.googlesource.com/293752 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Jamie Madill ccdf74b8 2015-08-18T10:46:12 Move TF Feedback linked varyings into D3D-only. The LinkedVarying structure is a D3D-specific type, and the GL back-end doesn't need the extra info. Isolate this into the D3D back-end so we can clean up the Impl inteface. BUG=angleproject:1123 Change-Id: I76d77ac505876d865e3e02f47acbfd6665a9507e Reviewed-on: https://chromium-review.googlesource.com/293764 Tested-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Corentin Wallez 11cd6af6 2015-08-18T15:54:01 Revert "Make the default framebuffer owned by Surface" Compilation warning on Windows This reverts commit 6cb2ae8292e69aa110c89e0465366b9f049c1168. Change-Id: I4ecadf5d8e909f986da186a7326cfa0922ae8710 Reviewed-on: https://chromium-review.googlesource.com/294241 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Corentin Wallez 6cb2ae82 2015-08-12T12:39:52 Make the default framebuffer owned by Surface Reland with a fix for SurfaceTest in angle_unittests and fixes for signed-unsigned warnings In CGL there is no notion of default Framebuffer and MakeCurrent only makes a context current but not a drawable. Instead, everything is done via render to texture. For that reason, different surfaces will have different FBOs as default framebuffers, which causes that change. BUG=angleproject:891 Change-Id: Ie9a72de01a58e583a1bfa3f4a055debb860b912f Reviewed-on: https://chromium-review.googlesource.com/293713 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Jamie Madill e473deee 2015-08-18T14:49:01 Clean up uniform block Program Impl APIs. The D3D-specific code we can split into D3D-only methods, and the GL-level shared code we can place in Program instead of making Impl methods. This cleans up the Impl inteface significantly. BUG=angleproject:1123 Change-Id: Ibcb7d07733eb939adf5bb4f5395a661875a60238 Reviewed-on: https://chromium-review.googlesource.com/293763 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 39939686 2015-08-18T10:37:22 Fix improper error handling in Image11. A device lost event would improperly skip returning an error, which could lead us down a code path that would read/write to invalid locations. BUG=519642 Change-Id: Iba437b9b24cdf44320a944a85146f5f73be9f7a6 Reviewed-on: https://chromium-review.googlesource.com/293903 Tested-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Kenneth Russell <kbr@chromium.org>
Jamie Madill ea918db9 2015-08-18T14:48:59 Clean up Program::linkUniforms. This method previously relied on output from the D3D back-end from ProgramImpl::link. Split the D3D-specific code into its own method, and do the linking validation before we call link. BUG=angleproject:1123 Change-Id: I582671e21af605af9f4451b02fc96ad29c923048 Reviewed-on: https://chromium-review.googlesource.com/293762 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Geoff Lang 70022972 2015-08-18T17:53:00 Revert "Work around deprecated LUMA formats in the core profile." Caused failures in the WebglConformance.conformance_textures_misc_copy_tex_image_2d_formats test on the ATI FYI waterfall bot. This reverts commit 61f51dc1b7d383bcb3632218cd2434f65cac4b7a. Change-Id: Iddea03d53ae2a9b639e36931f01c1e889e550af4 Reviewed-on: https://chromium-review.googlesource.com/294262 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Nico Weber 1e949799 2015-08-18T09:58:23 Fix build after https://chromium-review.googlesource.com/#/c/293865 Change-Id: I691d80deff03b49463b08d093934b44b049a0606 Reviewed-on: https://chromium-review.googlesource.com/294163 Reviewed-by: Nico Weber <thakis@chromium.org> Tested-by: Nico Weber <thakis@chromium.org>
Nico Weber 33d71f58 2015-08-18T09:31:59 Rename TextureD3D::setImage() to setImageImpl(). This makes it clear that this is not an attempted override of the virtual base class's method rx::TextureImpl::setImage(). Do the same for TextureD3D::setCompressedImage(). No intended behavior change. BUG=angleproject:1083 Change-Id: I874e4101e8138c7c5000f5966afed6a339523c02 Reviewed-on: https://chromium-review.googlesource.com/293865 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Nico Weber <thakis@chromium.org>
Austin Kinross a818776e 2015-08-12T10:54:37 Fix warning C4312 (x64) - reinterpret_cast conversion to greater size Change-Id: I90504b00e8f3af208511ec393ddfb0da267f56bc Reviewed-on: https://chromium-review.googlesource.com/293341 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Austin Kinross <aukinros@microsoft.com>
Cooper Partin 66d6313e 2015-08-13T10:22:42 Add target platform version for generating Windows 10 WinRT projects BUG=angleproject:1122 Change-Id: Ia6a79ef1b4e94e15830981f0cee6269c9f0c71ca Reviewed-on: https://chromium-review.googlesource.com/293401 Tested-by: Cooper Partin <coopp@microsoft.com> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang f4e794ec 2015-08-12T14:10:36 In TextureD3D_2D, don't call Image::redefine directly. Call the TextureD3D_2D::redefine member which will not make unnecessary modifications to the image and lets the member serve as a callback for redefined images. BUG=angleproject:970 Change-Id: I511310ebfd4d6133219bbef82c53747f9454aee0 Reviewed-on: https://chromium-review.googlesource.com/293904 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 87d3fe04 2015-08-18T14:38:43 Revert "In TextureD3D_2D, don't call Image::redefine directly." Warnings in 64-bit. This reverts commit a0633a7e4124473d67538053cba3ebdc44f71687. Change-Id: I5b3f31b261b947cd295e9f4a9abbbdbc00740183 Reviewed-on: https://chromium-review.googlesource.com/293841 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang a0633a7e 2015-08-12T14:10:36 In TextureD3D_2D, don't call Image::redefine directly. Call the TextureD3D_2D::redefine member which will not make unnecessary modifications to the image and lets the member serve as a callback for redefined images. BUG=angleproject:970 Change-Id: I280c18b993ef4dfac2efe1b28bf28c34aa4b6bcc Reviewed-on: https://chromium-review.googlesource.com/293222 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 61f51dc1 2015-08-13T16:16:56 Work around deprecated LUMA formats in the core profile. Use R and RG textures with swizzle states to emulate them. Fixes the following tests when using the core profile: * conformance/extensions/oes-texture-float.html * conformance/extensions/oes-texture-half-float.html * conformance/textures/misc/tex-sub-image-2d.html * conformance/textures/misc/texture-formats-test.html * conformance/textures/misc/texture-npot.html * conformance/more/functions/copyTexImage2D.html * conformance/more/functions/copyTexSubImage2D.html BUG=angleproject:1113 Change-Id: Iaf4b7b2b0000052b1747f46d90ad45d4cb1f6b50 Reviewed-on: https://chromium-review.googlesource.com/293530 Reviewed-by: Kenneth Russell <kbr@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Corentin Wallez 51706eae 2015-08-07T14:39:22 Make FramebufferAttachmentObject not refcountable Re-land with a fix for an unitialized variable Instead the refcount is done via callbacks. This allows Surface to ignore this refcounting which will be useful in a follow-up CL. BUG=angleproject:891 Change-Id: I1925ccaa4ce7b502b33088660d31c404b8313cb5 Reviewed-on: https://chromium-review.googlesource.com/293712 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Jamie Madill ada9ecc3 2015-08-17T12:53:37 Make TF Feedback buffer mode a GL-level variable. Don't query this as an Impl method, since it exists on the GL level. Also some related refactorings and cleanups. BUG=angleproject:1123 Change-Id: I3610bc0db2bcaa96408506e06a65a2f4dab93150 Reviewed-on: https://chromium-review.googlesource.com/293761 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 5c6b7bfe 2015-08-17T12:53:35 Add a Program::Data shared state structure. Similar to the Framebuffer and other classes, this gives the Impl class a read-only view of the object's state. BUG=angleproject:1123 Change-Id: I580eaebe2de236adf8131d6e3f54633cecce8c25 Reviewed-on: https://chromium-review.googlesource.com/293760 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 3b040eb8 2015-08-17T16:51:33 Revert "Add full support for line continuation in the preprocessor" Warning in the Linux/Mac builders: In file included from ../../third_party/angle/src/tests/preprocessor_tests/input_test.cpp:7: In file included from ../../third_party/angle/src/tests/preprocessor_tests/PreprocessorTest.h:7: ../../testing/gtest/include/gtest/gtest.h:1392:16: error: comparison of integers of different signs: 'const int' and 'const unsigned long' [-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 long>' requested here return CmpHelperEQ(expected_expression, actual_expression, expected, ^ ../../third_party/angle/src/tests/preprocessor_tests/input_test.cpp:171:5: note: in instantiation of function template specialization 'testing::internal::EqHelper<false>::Compare<int, unsigned long>' requested here EXPECT_EQ(3, input.read(buf, maxSize, &lineNo)); ^ BUG=angleproject:1125 This reverts commit c1157d1963170c7411eb6c32e2b2fbce02c5a170. Change-Id: Ic6fa286d190b006cccc5154d86e21ecc03175763 Reviewed-on: https://chromium-review.googlesource.com/294080 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Olli Etuaho c1157d19 2015-08-14T14:16:19 Add full support for line continuation in the preprocessor Line continuation in ESSL 3.00 needs to be processed before tokenization, since tokens can span the line continuation. On the other hand, ANGLE's tokenizer keeps track of line numbers, and whenever a line continuation appears the line number still needs to be incremented by one, just like on a regular newline. That's why line continuation is now implemented as follows: when the shader strings are concatenated in Input, they are also checked for line continuation. Whenever line continuation is encountered, the string is cut before that point. When the tokenizer asks for more input, the string starting from the character after line continuation is passed to it, and the line number is incremented from Input. This way the tokenizer can parse tokens that span multiple lines - it never sees the line continuation - but still keeps track of the line number correctly. Relevant spec is in ESSL 3.00 section 3.2 "Source strings". Support for line continuation also applies to ESSL 1.00. ESSL 3.00 spec section 1.5 says that line continuation support is mandated when an ESSL 1.00 shader is used with the OpenGL ES 3.0 API, and is optional when ESSL 1.00 is used with the OpenGL ES 2.0 API. TEST=dEQP-GLES3.functional.shaders.preprocessor.line_continuation.* (all pass), angle_unittests BUG=angleproject:1125 Change-Id: I1c1de49602e7cd755d6072c3c0aa5524cd0313b4 Reviewed-on: https://chromium-review.googlesource.com/293721 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Olli Etuaho <oetuaho@nvidia.com>
Corentin Wallez f0435bc8 2015-08-17T11:24:37 Surface_unittest: fix a gmock warning getSwapBehavior was being called in Surface's constructor but masn't expected, causing a warning. Add it as an expect call. BUG=angleproject:1126 Change-Id: Idf4a7e0ff66ba5741d3773e09ade4a1335b355ae Reviewed-on: https://chromium-review.googlesource.com/293902 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Jamie Madill 0b9e9032 2015-08-17T11:51:52 Revert "Revert "Implement dirty bits acceleration for VertexArrayGL."" Should be fixed with the Iterator change. BUG=angleproject:1040 This reverts commit 5b21ed5fd030d33ae379b8cc493746244d2928b4. Change-Id: Ibb77775b6b2ce5a49cee7dd81efc62d8c3ba3c62 Reviewed-on: https://chromium-review.googlesource.com/293901 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@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>
Jamie Madill 5b21ed5f 2015-08-14T18:12:50 Revert "Implement dirty bits acceleration for VertexArrayGL." Seems to cause an exception in Release, in end2end_tests. BUG=angleproject:1040 This reverts commit 6d51c70ccf63a2c5ec240d960ff1bc179d36c92c. Change-Id: I6548bc68dce07d2d85e40afdb604157e689c1d6c Reviewed-on: https://chromium-review.googlesource.com/293821 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 6d51c70c 2015-08-14T10:38:10 Implement dirty bits acceleration for VertexArrayGL. BUG=angleproject:1040 TEST=angle_end2end_tests,angle_perftests,WebGL Change-Id: I91d9aea5eefb58ecaf5b1cc95926fddb2aa846ea Reviewed-on: https://chromium-review.googlesource.com/289570 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 49e8de70 2015-08-14T10:50:17 Fix remaining size_t conversion warnings. BUG=angleproject:1120 Change-Id: If4fba903511dcd57d21f8f8178e772cf3cae4187 Reviewed-on: https://chromium-review.googlesource.com/293750 Tested-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Austin Kinross 5cf0f982 2015-08-12T09:35:10 Reland "Fix memory layout of imageformats.h's 16-bit structs" Changes since last patch: - Disable tests on D3D11 Intel Change-Id: Ie65f56b7ed107f8901ea3be7d96036d7c882d189 Reviewed-on: https://chromium-review.googlesource.com/285218 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Austin Kinross <aukinros@microsoft.com>
Cooper Partin 9e1b879e 2015-08-13T08:21:45 Roll GYP for Windows 10 project generation. BUG=angleproject:1122 Change-Id: I8b7a33fb8e7d1200e655c73c7d1a5502cac955c6 Reviewed-on: https://chromium-review.googlesource.com/293335 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Cooper Partin <coopp@microsoft.com> Commit-Queue: Cooper Partin <coopp@microsoft.com>
Olli Etuaho 59f9a641 2015-08-06T20:38:26 Remove EOpInternalFunctionCall It's cleaner to mark internal functions by using the TName class, similarly to TIntermSymbol. TEST=angle_unittests BUG=angleproject:1116 Change-Id: I12a03a3dea42b3fc571fa25a1b11d0161f24de72 Reviewed-on: https://chromium-review.googlesource.com/291621 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Olli Etuaho <oetuaho@nvidia.com>
Olli Etuaho f5cfc8df 2015-08-06T16:36:39 Track whether a name is internal to ANGLE in a separate class The AST contains identifiers in a few different places: besides symbols, there are also function names, which show up in function signatures and function calls. Any of these can be coming either from the original shader or from inside ANGLE. A class that encapsulates a string and its internalness will be useful for implementing a unified way of handling all names in shader translation. Start implementing this by splitting the functionality out of TSymbol. TEST=angle_unittests BUG=angleproject:1116 Change-Id: I0a1b5936dcccd0d5fc1c0c13c712102fbfff2a79 Reviewed-on: https://chromium-review.googlesource.com/291280 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Olli Etuaho <oetuaho@nvidia.com>
Nico Weber ec17d54a 2015-08-13T12:19:28 Fix angle miscompiling shaders on x86_64 Android. BUG=487341 Change-Id: I792e0c9419566facb0bec0ad93f3646294e5a2a7 Reviewed-on: https://chromium-review.googlesource.com/293500 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Nico Weber <thakis@chromium.org> Reviewed-by: Nico Weber <thakis@chromium.org>
Olli Etuaho 217fe6ec 2015-08-05T13:25:08 Detect when built-in modf requires an l-value in AST traversal This fixes an omission that out parameter tracking had inherited from EmulatePrecision. Accurate tracking of when values are written is required for converting dynamic indexing of vectors and matrices to function calls. A new test covering this is added to angle_unittests. TEST=angle_unittests BUG=angleproject:1116 Change-Id: I05c5fd60355117d0053b84110748ae221375a790 Reviewed-on: https://chromium-review.googlesource.com/290562 Reviewed-by: Zhenyao Mo <zmo@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Olli Etuaho <oetuaho@nvidia.com>
Olli Etuaho 3fc9337f 2015-08-11T14:50:59 Refactor l-value tracking to a separate traverser parent class This makes TIntermTraverser implementation easier to understand and removes the overhead of maintaining the user-defined GLSL function table from the traversers that don't need it. Some logic is duplicated between TIntermTraverser and its new subclass TLValueTrackingTraverser, but duplication is hard to eliminate completely since there are some differences scattered throughout the code. BUG=angleproject:1116 TEST=angle_unittests Change-Id: Iab4a0c1d4320ecfafaf18ea3a45824d756890774 Reviewed-on: https://chromium-review.googlesource.com/292721 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Olli Etuaho <oetuaho@nvidia.com>
Olli Etuaho 6cb4c7f0 2015-08-13T11:27:17 Set __VERSION__ macro when the #version directive is parsed __VERSION__ macro needs to be set to 300 when #version 300 es is on the first line of the shader, since section 3.4 of ESSL 3.00.4 spec mentions that the value of __VERSION__ should match the shading language being parsed. The value from parsing the version directive replaces the default value 100. BUG=angleproject:524 TEST=dEQP-GLES3.functional.shaders.preprocessor.predefined_macros.* (4 tests start passing, 2 still fail) dEQP-GLES3.functional.shaders.preprocessor.conditionals.* (2 tests start passing) dEQP-GLES2.functional.shaders.preprocessor.predefined_macros.* (no regression) Change-Id: I15bfdeb73d1e343d131ded56b1fd52ca5ef32408 Reviewed-on: https://chromium-review.googlesource.com/293440 Reviewed-by: Zhenyao Mo <zmo@chromium.org> Tested-by: Olli Etuaho <oetuaho@nvidia.com>
Geoff Lang bc384230 2015-08-13T15:24:20 Revert "Add tests for streaming client side data." This reverts commit 656b0d45cd4758be67202aded9783d536b00e611. Change-Id: I0b6ad5e1fa788ffc698029410aa98e13a061902d Reviewed-on: https://chromium-review.googlesource.com/293450 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 6238e353 2015-08-12T13:26:19 Generate the egl Display extensions in Renderer9 and Renderer11. With the addition of EGL Image, the display extensions generated by Renderer9 and Renderer11 become significantly different. Instead of generating them via getXSupport() methods, generate them inside the renderers themselves. BUG=angleproject:970 Change-Id: Ib3fffabcca3e3cdef13ef994aa0b06dba0f00362 Reviewed-on: https://chromium-review.googlesource.com/293271 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang bbc02470 2015-08-12T13:21:36 Add a common base function for getSurfaceLevel in TextureStorage9. Instead of casting to the specific TextureStorage9 type before calling getSurfaceLevel, merge the prototypes into a pure method in TextureStorage9. BUG=angleproject:970 Change-Id: I07b24b6cc470fc8cb6ba9bd9a8f178c3b43be36a Reviewed-on: https://chromium-review.googlesource.com/293270 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 656b0d45 2015-08-12T11:51:23 Add tests for streaming client side data. BUG=angleproject:880 Change-Id: Ief76f3011ce18ad0ca396af0bc36e69a30ae143b Reviewed-on: https://chromium-review.googlesource.com/293220 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-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>
Austin Kinross fd00ccff 2015-08-12T10:19:46 Disable some VS2015 warnings for dEQP projects Change-Id: I036084b2fea20d4f1712bc34b161fb3be604af0d Reviewed-on: https://chromium-review.googlesource.com/293009 Tested-by: Austin Kinross <aukinros@microsoft.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Corentin Wallez 0020426e 2015-08-12T19:07:29 Revert "Make FramebufferAttachmentObject not refcountable" BUG= This reverts commit 19ba57469aa02074d094a9aef104f84d0b6d881e. Change-Id: I5dce6c8a81570e22affbcaf32183a97c97849718 Reviewed-on: https://chromium-review.googlesource.com/293351 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Corentin Wallez 1bf40bfe 2015-08-12T15:52:04 Revert "Make the default framebuffer owned by Surface" This reverts commit 87e63a9982803b5e4c12afa9a40ff0e2b04a7369. Speculative revert to fix the webgl cts on Windows D3D9 and the unittests on Linux. BUG= Change-Id: I488f4e0b2dc67270eed45f1c10bfba1d13c98739 Reviewed-on: https://chromium-review.googlesource.com/293350 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Corentin Wallez 87e63a99 2015-08-12T12:39:52 Make the default framebuffer owned by Surface In CGL there is no notion of default Framebuffer and MakeCurrent only makes a context current but not a drawable. Instead, everything is done via render to texture. For that reason, different surfaces will have different FBOs as default framebuffers, which causes that change. BUG=angleproject:891 Change-Id: I3f6da7b587353316026ea39a5c87f91265e0f1ba Reviewed-on: https://chromium-review.googlesource.com/289872 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Corentin Wallez 8b76e9fb 2015-08-12T15:22:58 Fix warnings on Linux BUG= Change-Id: I24ed2a2ee85a152ef79fc9cb2c3b067bbbaedf05 Reviewed-on: https://chromium-review.googlesource.com/293310 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Corentin Wallez 19ba5746 2015-08-07T14:39:22 Make FramebufferAttachmentObject not refcountable Instead the refcount is done via callbacks. This allows Surface to ignore this refcounting which will be useful in a follow-up CL. BUG=angleproject:891 Change-Id: I39b028476e0e3ab1837c033e1121ea21e54d7970 Reviewed-on: https://chromium-review.googlesource.com/291651 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Corentin Wallez 18a2fb3a 2015-08-10T12:58:14 ValidateDrawElements: check count > 0 then compute the index range Otherwise glDrawElements(GL_TRIANGLES, -1, nullptr) would crash. This was found by an ASSERT in ComputeIndexRange triggered by dEQP-GLES2.functional.negative_api.vertex_array.draw_elements BUG= Change-Id: I5269031fa35aa6403c844561e04158361ee7950f Reviewed-on: https://chromium-review.googlesource.com/292710 Tested-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Jamie Madill <jmadill@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>
Nico Weber 61902ece 2015-07-25T20:12:23 clang/win: Fix -Wunused-function warning in angle. Also inline a function that wasn't pulling its weight. No intended behavior change. BUG=chromium:505316 Change-Id: If059700062a38c45971397311af7a2a4037b815e Reviewed-on: https://chromium-review.googlesource.com/288399 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Nico Weber <thakis@chromium.org>
Tomasz Moniuszko 319fb898 2015-07-30T14:34:54 Use default commit.h file if git index is not available The solution is the same as in GYP version: 1. Check if .git/index is available in angle directory. 2. Use generated commit.h file if git is available or copy the default file instead. Change-Id: Ic3cedf6793c368070228a63c0eb270ca6fb47f81 Reviewed-on: https://chromium-review.googlesource.com/289391 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Tomasz Moniuszko <tmoniuszko@opera.com>
Olli Etuaho 56193ce3 2015-08-12T15:55:09 Clean up parseMatrixFields Applying field selection directly on matrices is not mentioned in ESSL 1.00 or 3.00 specs. Remove erroneous code that generated odd error messages when a shader tried to apply certain kinds of field selection on a matrix. BUG=angleproject:1118 TEST=angle_unittests, dEQP-GLES3.functional.shaders.swizzles.* Change-Id: I7bbf5d0cbaee3f21d20b830d904c0feef445dd78 Reviewed-on: https://chromium-review.googlesource.com/293190 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Olli Etuaho <oetuaho@nvidia.com>
Olli Etuaho 391befef 2015-08-12T16:30:38 Revert "Add pragma errors for malformed pragmas." Since this commit was made, dEQP tests were fixed to check that unrecognized pragma tokens only generate warnings, not errors. This applies to both ESSL1.00 and ESSL3.00, which specify this behavior in section 3.4 Preprocessor. BUG=angleproject:989 TEST=dEQP-GLES2.functional.shaders.preprocessor.pragmas.* This reverts commit d3c29f57aaeb451b149bbb9fd17b3f1f99101c52. Change-Id: Ie4e0ec061fa3164d6f3872ac0016a063056ed110 Reviewed-on: https://chromium-review.googlesource.com/293181 Tested-by: Olli Etuaho <oetuaho@nvidia.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill 77a90c26 2015-08-11T16:33:17 Reland of "Store the applied element array buffer as a binding pointer." To be consistent with how we start vertex attributes. A null pointer indicates we're using the streaming buffer. Will also aid the dirty state bits refactor. The re-land fixes a crash with WebGL related to element array buffers. BUG=angleproject:1040 TEST=WebGL CTS, end2end_tests, unittests Change-Id: I9b82e06825bf95f0fc2b7c7427e1eb6dd257c1ee Reviewed-on: https://chromium-review.googlesource.com/290044 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Geoff Lang <geofflang@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>
Olli Etuaho 27446bda 2015-08-10T14:59:53 Move traverse functions under TIntermTraverser This enables implementing specialized variants of TIntermTraverser. Intermediate subclasses of TIntermTraverser are expected to maintain contextual information in their traverse* functions, which is then used by the visit* functions in the actual traversers. This approach is better than adding a flag to TIntermTraverser, since it will make the code cleaner and easier to understand. Traverse() functions in TIntermNode subclasses are still kept around to redirect calls to TIntermTraverser traversal functions. This is less hacky than choosing the function with switch/case in TIntermTraverser would be, and if new TIntermNode subclasses get added, it's not as likely that adding the traversal support would be forgotten. TEST=angle_unittests BUG=angleproject:1116 Change-Id: Ie6889be1d7e955518f13cd3390dce17871ba49b5 Reviewed-on: https://chromium-review.googlesource.com/292720 Tested-by: Olli Etuaho <oetuaho@nvidia.com> Reviewed-by: Zhenyao Mo <zmo@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Geoff Lang b4b0b482 2015-08-11T13:45:52 Fix missing and incorrect ordering of FunctionsWGL member initialization. BUG=angleproject:890 Change-Id: Id55d941a95cf38f825b9a52fc8043e0e129f7a82 Reviewed-on: https://chromium-review.googlesource.com/292631 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Cooper Partin 4f488494 2015-08-07T16:05:25 Fixed compiler warning C4457 'declaration of 'node' hides function parameter'. BUG=angleproject:1119 Change-Id: Ie3de5a776b5860b1ca502cee9e2b19c41cd3bfb2 Reviewed-on: https://chromium-review.googlesource.com/292051 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Cooper Partin <coopp@microsoft.com>
Cooper Partin b459fb04 2015-08-07T16:12:39 Fixed compiler warning C4456 'declaration of variable hides previous local declaration'. BUG=angleproject:1119 Change-Id: I99572711ceeae94fb920d197c86e741945d3b60b Reviewed-on: https://chromium-review.googlesource.com/292279 Tested-by: Cooper Partin <coopp@microsoft.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Cooper Partin 8168b4bd 2015-08-07T16:02:10 Fixed compiler warning C4838 'conversion from size_t to LONG requires a narrowing conversion'. BUG=angleproject:1119 Change-Id: I2c879193dc122e6c45d0462abc91f39f5d332506 Reviewed-on: https://chromium-review.googlesource.com/292156 Tested-by: Cooper Partin <coopp@microsoft.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Cooper Partin 149e6e69 2015-08-07T16:18:18 Fixed compiler warning C4458 'declaration of variable hides class member'. BUG=angleproject:1119 Change-Id: Ibc7cfdea72abe402cbfa1c10e0ada7576fa1cfa2 Reviewed-on: https://chromium-review.googlesource.com/292052 Tested-by: Cooper Partin <coopp@microsoft.com> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill 1e0bc3ad 2015-08-11T08:12:21 Implement dirty bits acceleration for Current Values. BUG=angleproject:1040 TEST=angle_end2end_tests,angle_perftests,WebGL Change-Id: If471cfb9676795d5cc985eea52ad7144d4544ed1 Reviewed-on: https://chromium-review.googlesource.com/289559 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 3dfcdcb6 2015-08-10T14:28:54 D3D: Fix buffer overflow in VertexBuffer.cpp. Under certain situations an integer overflow could lead to ANGLE writing to places where it shouldn't. BUG=518206 Change-Id: I9217685daecb160a4072fbf79c26e5bee9f4621e Reviewed-on: https://chromium-review.googlesource.com/292391 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill bd136f9a 2015-08-10T14:51:37 Reland of "D3D11: Fix draw perf regression with input layouts." f8dd7b10 fixed unnecessary shader compiles, but introduced a draw call perf regression. Fix the regression robustly by storing a minimal set of input layout elements/vertex attribute info, but also handle the case where the vector sizes mismatch between a cached and new vertex layout. Reland with fix for comparison warning. BUG=510151 Change-Id: I578ddbb5b5bb12e7c1a901f23c7b5fcbd64b5d23 Reviewed-on: https://chromium-review.googlesource.com/292460 Tested-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Geoff Lang 194814e3 2015-08-10T14:34:46 Fix missing colon in codereview.settings. BUG=504872 Change-Id: Ib69830a556fe06c111f41d78811c7115b0d8314c Reviewed-on: https://chromium-review.googlesource.com/292450 Tryjob-Request: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill 00c782e8 2015-08-10T17:54:30 Revert "D3D11: Fix draw perf regression with input layouts." size_t comparison warning in Win32. src\libangle\renderer\d3d\programd3d.cpp(2084) : warning C4018: '<' : signed/unsigned mismatch BUG=510151 This reverts commit bf3f780c0a281cfe6192aa5635b02a01314f7fd3. Change-Id: I5565b697ca29270375049f3e855437fa19157de9 Reviewed-on: https://chromium-review.googlesource.com/292331 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill bf3f780c 2015-08-10T10:47:57 D3D11: Fix draw perf regression with input layouts. f8dd7b10 fixed unnecessary shader compiles, but introduced a draw call perf regression. Fix the regression robustly by storing a minimal set of input layout elements/vertex attribute info, but also handle the case where the vector sizes mismatch between a cached and new vertex layout. BUG=510151 Change-Id: If5e9ea4a4c9edaa7a78c8daa44bbe7d9927dc4e4 Reviewed-on: https://chromium-review.googlesource.com/292390 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Corentin Wallez 14ecb13f 2015-08-10T11:06:04 libGLESv2.gypi move the link to X11 to libANGLE (vs. libGLESv2) This fixes a bot compilation failure that started happening after unittest started using Display stuff that use X11. Because angle_unittests was linking against libANGLE and not libGLESv2, it didn't get linked to X11, which produced a link error. BUG= Change-Id: I8f1f0dbcb13bb7c9897f235b72c4d4896a7b8a6c Reviewed-on: https://chromium-review.googlesource.com/292380 Tested-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Kenneth Russell <kbr@chromium.org>
Kimmo Kinnunen 19b890af 2015-08-07T15:01:04 Import new MurmurHash3 to fix g++ 4.9.2 errors The code is from http://smhasher.googlecode.com/svn/trunk/ revision 152. Fixes error: ../../src/third_party/murmurhash/MurmurHash3.cpp:57:41: error: inlining failed in call to always_inline ‘uint32_t getblock(const uint32_t*, int)’: function body can be overwritten at link time FORCE_INLINE uint32_t getblock ( const uint32_t * p, int i ) The error was previously fixed by adding a pragma to ignore the warning. The problem the compiler is complaining is that the function is visible to outside of the compilation unit. This can be fixed by making the function inline (as in the new version of the MurmurHash3.cpp) or static. Change-Id: I7a1262964489d72de8b4707ca2284363c8b46e20 Reviewed-on: https://chromium-review.googlesource.com/291620 Tested-by: Kimmo Kinnunen <kkinnunen@nvidia.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Dongseong Hwang <dongseong.hwang@intel.com> Tested-by: Dongseong Hwang <dongseong.hwang@intel.com> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Olli Etuaho 8afe1e1b 2015-08-05T18:00:01 Track that indices of l-values are not required to be l-values In an expression like a[ind]++, a[ind] is required to be an l-value but ind is not. Reset the l-value required flags before traversing the index of an indexing operation, so that this is accurately tracked. After the index has been traversed, the previous state of the l-value required flags is restored. New tests are added to angle_unittests cover this functionality. TEST=angle_unittests BUG=angleproject:1116 Change-Id: I8929ec01e85e672c83ef7d385e455b7df8682f4b Reviewed-on: https://chromium-review.googlesource.com/290561 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Zhenyao Mo <zmo@chromium.org> Tested-by: Olli Etuaho <oetuaho@nvidia.com>
Olli Etuaho a26ad58d 2015-08-04T13:51:47 Track where l-values are required in AST traversal This functionality is refactored out of EmulatePrecision to be a common feature of TIntermTraverser. This is done since tracking where l-values are required will be useful for other traversers. For example, it will be needed for converting dynamic indexing of matrices and vectors to function calls. This change adds some overhead to all tree traversers, but the overhead is expected to be small for typical shaders which don't contain too many user-defined functions. BUG=angleproject:1116 TEST=angle_unittests Change-Id: I54d34c2b5093ef028f2b24d854c11c0195dc1dbb Reviewed-on: https://chromium-review.googlesource.com/290514 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Olli Etuaho <oetuaho@nvidia.com> Reviewed-by: Zhenyao Mo <zmo@chromium.org>
Geoff Lang 45808a17 2015-08-07T13:05:12 Use WGL_ARB_pixel_format to choose the pixel format when available. BUG=angleproject:890 Change-Id: If10ea7e1cb670bb3cd6fdcf40344d1c1e0acd862 Reviewed-on: https://chromium-review.googlesource.com/291650 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill 1b94d432 2015-08-07T13:23:23 Implement dirty bits for RendererGL's basic state. BUG=angleproject:1040 TEST=angle_end2end_tests,angle_perftests,WebGL Change-Id: I72beaf7e178e042440337fbb8b9669638c5ad016 Reviewed-on: https://chromium-review.googlesource.com/289558 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 519a5be2 2015-07-23T11:07:29 Update ANGLE's GPU test expectations code. Pull over the more recent changes from Chromium which include the graphics API, which we can use for specific API suppressions for the dEQP tests. Also update the docs with detailed steps for updating from Chrome. BUG=None Change-Id: I0cb7d8268fbb2778c0160a58f1a10ef4a92c9c61 Reviewed-on: https://chromium-review.googlesource.com/287810 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Zhenyao Mo <zmo@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Kimmo Kinnunen b18609b9 2015-07-16T14:13:11 Implement ES 2,3 parts of EXT_blend_func_extended for shader translation Exposes gl_SecondaryFragColor, glSecondaryFragData[] and gl_MaxDualSourceDrawBuffers to GLES SL 1.0. Relaxes rules for undefined output locations for GLES SL 3.0 and exposes gl_MaxDualSourceDrawBuffers. If the output GL context is GL ES 2.0 or 3.0: The emulation layer is expected to turn on EXT_blend_func_extended if the output GL context supports it. If the output GL context is GL: The emulation layer is expected to turn on EXT_blend_func_extended if the output GL context supports ARB_blend_func_extended or if GL context is 3.2 or later. If the source shader spec is GLES SL 2.0: The emulation layer is expected to inspect the shader compilation output variables upon linking. If output target is GL SL, the emulation layer should bind color location 0, index 1 to "angle_SecondaryFragColor" if variable "gl_SecondaryFragColorEXT" is used. Alternatively, emulation layer should bind "angle_SecondaryFragData" to locations 0,1,2,3,..., all color index 1, if "gl_SecondaryFragData" array is used. (The caller can not bind the locations or specify output variables.) If the source shader spec is GLES SL 3.0: The emulation layer is expected to do location auto-resolve of the the output variables that have undefined output locations that have not been bound by the caller. (The caller can not use gl_ built-ins, so nothing to do with those.) BUG=angleproject:1085 TEST=angle_unittest Change-Id: I5cafe205b0c29478b0dcd24aa89a7b0000f5d046 Reviewed-on: https://chromium-review.googlesource.com/287580 Reviewed-by: Zhenyao Mo <zmo@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Kimmo Kinnunen <kkinnunen@nvidia.com>
Corentin Wallez 3574c614 2015-08-07T10:37:24 Fix warnings caused by gmock on linux When mocking functions gmock uses the keyword virtual instead of override and this conflicted with our usage of override for the destructor (there is a warning for using all one or the other). BUG= Change-Id: I9dd9204d5755dd3a588a32d438de3c1018ba07cd Reviewed-on: https://chromium-review.googlesource.com/291630 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Corentin Wallez b44440d8 2015-07-22T17:54:20 ANGLETest::SetUp: resize the window only if needed. This avoids a flickering of the window at the start of every test. Reland with a speculative fix for ViewportTest BUG=angleproject:1105 Change-Id: I83e89881de5b6f58cfb3e14cbe324fd9547f2836 Tested-by: Corentin Wallez <cwallez@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/288533 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Corentin Wallez b4191c3e 2015-08-06T10:29:12 ViewportTest::SetUp set the scissor to the default value Previously ViewportTest would rely on the scissor being set to the size of the window by default, which is a fragile assumption as the scissor is set to the size of the window only on the first makeCurrent. BUG=angleproject:1105 Change-Id: I088565c7032fe817eb5c48a5351cc678fe42b376 Reviewed-on: https://chromium-review.googlesource.com/291310 Tested-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill f8dd7b10 2015-08-05T13:50:08 Refactor input layout & vertex signatures. Always size input layouts to gl::MAX_VERTEX_ATTRIBS, and use '1' bits to signal where we have a GPU conversion. The simplification allows us to more cleanly match the vertex executable signatures and makes our default VertexExecutable hit much more often. BUG=510151 TEST=angle_end2end_tests,Canary WebGL, manual testing with Chromium Change-Id: I5009323c4e7e208e7a2595be46658c344517a4ff Reviewed-on: https://chromium-review.googlesource.com/290740 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@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 35ab4299 2015-08-05T23:05:54 Revert "Fix warnings on gcc builds in ImageTest.cpp." This reverts commit 52ff4ac92ef5dfe77e14221726a0f0ab57dc57d5. Change-Id: I11ec6e7e343dd6579f7aa13106facc65b05eb795 Reviewed-on: https://chromium-review.googlesource.com/290940 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 52ff4ac9 2015-08-05T18:20:44 Fix warnings on gcc builds in ImageTest.cpp. BUG=angleproject:970 Change-Id: Ic7f451fb4c2378c7574ede7c513a5bb9d903c908 Reviewed-on: https://chromium-review.googlesource.com/290920 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>
Olli Etuaho 43613b03 2015-08-04T11:02:21 Make sure that the AST root is always a sequence node This enables inserting helper functions as an AST transformation. BUG=angleproject:1116 TEST=angle_unittests Change-Id: I169d4d3a726d0e389cb3444fe9dfb4c6c5d80155 Reviewed-on: https://chromium-review.googlesource.com/290513 Tested-by: Olli Etuaho <oetuaho@nvidia.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Zhenyao Mo <zmo@chromium.org>
Corentin Wallez ef1eb273 2015-08-03T10:14:44 DisplayGLX: factor redundant getFBConfigAttribs This is very tiny code cleanup and is a noop behavior change. BUG= Change-Id: Ib850ff88eafa0bd45bb389de1b74b1e9fe4c6d8b Reviewed-on: https://chromium-review.googlesource.com/290146 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>