src


Log

Author Commit Date CI Message
Corentin Wallez 2c58d81d 2015-07-21T13:31:23 Revert "Add an angle_link_glx that can be used for debugging" This reverts commit cddca5f204d9aa55c9810cf30c74997ca19a7f86. Change-Id: I07fa96a8b84308c77fb642a64f39fcacc471d96e Reviewed-on: https://chromium-review.googlesource.com/287123 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Corentin Wallez 6703b265 2015-07-20T14:05:32 Add an angle_link_glx that can be used for debugging This replaces the dlsyming of glX entry point with linking to libGL which in trun allows the ANGLE to be traced using apitrace. BUG=angleproject:892 Change-Id: Ic065582401e0e1e3fce1329cde216220a1e086a8 Reviewed-on: https://chromium-review.googlesource.com/286880 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Geoff Lang c4c7442d 2015-07-20T13:09:26 Fix missing uint cases for GLSL and ESSL output. These were causing assertions in several WebGL2 conformance tests. BUG=angleproject:882 BUG=angleproject:1084 BUG=483282 Change-Id: I7651c359a528c95469dcbfb5da2715ae4616b49b Reviewed-on: https://chromium-review.googlesource.com/286592 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Zhenyao Mo <zmo@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 9a4c8c46 2015-07-21T11:03:51 Initialize all members in the default TType constructor. This is an attempt to fix use-of-uninitialized-value errors. Example failure: https://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_msan_rel_ng/builds/68/steps/cc_unittests%20%28with%20patch%29/logs/EnlargedTextureWithAlphaThresholdFilter.GL BUG=angleproject:1044 Change-Id: I5906c67a55da553e2e5fd15320a5dd4186644e87 Reviewed-on: https://chromium-review.googlesource.com/287191 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Kimmo Kinnunen 8518e7f6 2015-07-16T14:54:08 Make all fragment shader out variables require location layout qualifier Make all fragment shader out variables require location layout qualifier. Previously, the last variable did not need a location layout qualifier if the previous variables had those. TEST=angle_unittests BUG=angleproject:1070 Change-Id: Ifb66ee52b811409f5278eaad330d6cd9b8ea059f Reviewed-on: https://chromium-review.googlesource.com/287100 Tested-by: Kimmo Kinnunen <kkinnunen@nvidia.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Geoff Lang 92139c25 2015-07-20T15:32:37 Always try to load the extension entry points. Despite many extensions being written against specific versions of the GL spec, some drivers (Intel) expose the extensions in much earlier versions. This leads to issues where the extension string would be present but the entry points were not loaded. BUG=angleproject:1038 Change-Id: Ia87bb3f038f310f6bc3e711a0b2d82717b67ae70 Reviewed-on: https://chromium-review.googlesource.com/286525 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang ecc9688d 2015-07-20T15:35:58 When the GL version is below 3.0, use GL_MAX_VARYING_FLOATS. It should be equivalent to GL_MAX_VARYING_COMPONENTS for ES2. BUG=angleproject:1038 Change-Id: Ic2fe6c27a0ebd6259d70f8d28edb7d4bdd5d0c35 Reviewed-on: https://chromium-review.googlesource.com/286526 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 8b0f0b3b 2015-07-20T15:59:28 Add a profile mask member to the FunctionsGL structure. BUG=angleproject:883 Change-Id: I3cdf88391e77a26a77e120de0fd32296a2b079d1 Reviewed-on: https://chromium-review.googlesource.com/286822 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill 90549e9d 2015-07-20T14:36:57 D3D: No-op ClearBufferfi calls with no DS attachments. The ES3 spec is clear that these calls should no-op, see page 187, "If a buffer is not present, then a Clear directed at that buffer has no effect." BUG=angleproject:1078 TEST=dEQP-GLES3.functional.fbo.msaa.2_samples.* Change-Id: Ic521f55785d10065e2ffe2e98a68c9d7da0c2c71 Reviewed-on: https://chromium-review.googlesource.com/286776 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill 6d276c8e 2015-07-20T19:00:38 Revert "Make all fragment shader out variables require location layout qualifier" Causes a warning on Windows: compiler\translator\ValidateOutputs.cpp(37): warning C4804: '>' : unsafe use of type 'bool' in operation BUG=angleproject:1070 This reverts commit 140941d066c11238ba4f2f15647fb2d65ae56faf. Change-Id: Ieed42cdda22f17c6e15c38ee1c059184869e6919 Reviewed-on: https://chromium-review.googlesource.com/286820 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Kimmo Kinnunen 140941d0 2015-07-16T14:54:08 Make all fragment shader out variables require location layout qualifier Make all fragment shader out variables require location layout qualifier. Previously, the last variable did not need a location layout qualifier if the previous variables had those. TEST=angle_unittests BUG=angleproject:1070 Change-Id: I3763b8ca38b1e14ee8456a54592c01e0fd89692c Reviewed-on: https://chromium-review.googlesource.com/286101 Tested-by: Kimmo Kinnunen <kkinnunen@nvidia.com> Reviewed-by: Zhenyao Mo <zmo@chromium.org>
Jamie Madill 2fdd3da9 2015-07-20T10:14:54 Add clang-format integration for 'git cl format'. This will allow us to eventually make a presubmit script for ANGLE, and also will help new contributors who aren't as familiar with the style guide. One outstanding issue is the lack of proper breaking before array initializers. We don't use arrays all over the place, but this will likely require a patch for clang. BUG=angleproject:762 Change-Id: I4702b1fcdfa10b7682b07316be59ec67bcf84943 Reviewed-on: https://chromium-review.googlesource.com/285901 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Zhenyao Mo <zmo@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 969194d4 2015-07-20T14:36:56 ES3-D3D11: Fix UBO vertex caching. There was a typo in the vertex shader cache which could trigger an overflow bug. TEST=dEQP-GLES3.functional.ubo.random.scalar_types.* BUG=angleproject:1077 Change-Id: I5652cf9675155b627f84531e09c01b42e29278fc Reviewed-on: https://chromium-review.googlesource.com/286775 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill cea74be4 2015-07-20T14:36:54 D3D11: Fix regression with R32I blits. The blit refactoring mislabeled one shader as GL_RED instead of GL_RED_INTEGER. BUG=angleproject:1076 TEST= dEQP-GLES3.functional.fbo.render.shared_depth_stencil.* Change-Id: I262b218c72d955a88a2d2c00b470d6a4f3568451 Reviewed-on: https://chromium-review.googlesource.com/286774 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 689325c2 2015-07-20T14:36:53 ES3: Add some missing unsized formats to the format tables. These were causing validation errors in the dEQP FBO tests. See Table 3.2 in the ES3 spec. BUG=angleproject:1074 TEST=dEQP-GLES3.functional.fbo.completeness.renderable.texture.color0.* Change-Id: Ifbf9199c54060eb3fc1a1dac7bbd74e19e013c61 Reviewed-on: https://chromium-review.googlesource.com/286773 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill f84159aa 2015-07-20T14:36:51 D3D11: Fix mapBufferRange not invalidating static data. This was causing several dEQP tests with index data to fail. BUG=angleproject:1073 TEST=dEQP-GLES3.functional.buffer.map.read_write.render_as_index_array.* Change-Id: Ic231a561202fbcda499b7584905b80252a7407de Reviewed-on: https://chromium-review.googlesource.com/286772 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 9d82be8f 2015-07-20T14:36:50 HLSL: Fix uniform packing for non-square matrices. We were neglecting to transpose the types here, so were getting incorrect registers counts for rows and columns. BUG=angleproject:1072 TEST=dEQP-GLES3.functional.shaders.matrix.* Change-Id: Ia0ab89bbba8b9e2d8f39e84ef4e8ad3c03bb118d Reviewed-on: https://chromium-review.googlesource.com/286771 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 3828b9e7 2015-07-20T14:36:48 D3D11: Use texture format, not SRV format, for mip gen test. Using the SRV format could lead to using R32F for D32F formats, which is incorrect. BUG=angleproject:1075 TEST=dEQP-GLES3.functional.fbo.blit.* Change-Id: Ic81d51b888897a7f7c79e2ba1a24ab69f18d981c Reviewed-on: https://chromium-review.googlesource.com/286770 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Geoff Lang 8b6587a7 2015-07-20T14:16:59 Use the type cache for the types used in the emulated GLSL functions. BUG=angleproject:1044 Change-Id: I7c4bde80448b2cd64921b809a3a0dfb37c4e0f47 Reviewed-on: https://chromium-review.googlesource.com/286643 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang bf067eff 2015-07-20T14:21:34 Fix order of Renderer11 initializer list. BUG=angleproject:916 Change-Id: I5be7460b737095eedb886be3e8978765c0940757 Reviewed-on: https://chromium-review.googlesource.com/286784 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Corentin Wallez b081e78b 2015-07-20T05:40:04 Compiler: avoid an undefined behavior when using erase-remove Using that idiom on an empty vector results in an undefined behavior that I have seen cause a vector to get length -1 with clang 3.6 on Linux. BUG= Change-Id: I3bb8d8884efa29a17672b458263067644dbf0fec Reviewed-on: https://chromium-review.googlesource.com/286740 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Geoff Lang a455824c 2015-07-17T14:25:01 Remove GetAttachmentSerial. Cascades to remove serials from many objects. BUG=angleproject:970 Change-Id: I0a74a14519da3203cd5df7ae0fa19f83393951ce Reviewed-on: https://chromium-review.googlesource.com/286554 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 35fff1ca 2015-07-17T14:01:48 Handle non-zero base level with mipmapping disabled in D3D9. BUG=angleproject:970 Change-Id: I33120ec8121dc1265360fbbe61103e03e593af3f Reviewed-on: https://chromium-review.googlesource.com/286550 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 26a6ea08 2015-07-17T14:07:13 Add mocks of TextureImpl and RenderbufferImpl. BUG=angleproject:970 Change-Id: I63a7d8363f90018827c5d8482c9d98f3fa61c573 Reviewed-on: https://chromium-review.googlesource.com/286553 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 054fce03 2015-07-17T14:05:24 Remove RenderbufferImpl.cpp BUG=angleproject:970 Change-Id: I1606df42e6423fe84d3ab69029a37224adb89a9b Reviewed-on: https://chromium-review.googlesource.com/286552 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang cdb94508 2015-07-17T14:03:27 Add a RefCountObject::getRefCount method for testing. BUG=angleproject:970 Change-Id: I4fae29766ee76512375872535dbaf2d31a379de0 Reviewed-on: https://chromium-review.googlesource.com/286551 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 1915652e 2015-06-18T09:40:14 Emulate the pack/unpack functions for unorms. BUG=angleproject:1044 Change-Id: I0e7bee366398159ae6b87a820f36cb51c05cb064 Reviewed-on: https://chromium-review.googlesource.com/280362 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill 4631111a 2015-07-16T16:31:36 Update WebGL test expectations. Change-Id: I24ea67f354191697d8a577c8b21ccc1689dd3536 Reviewed-on: https://chromium-review.googlesource.com/286016 Tested-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Corentin Wallez bb6a5f93 2015-07-16T17:30:04 WindowSurfaceGLX: swap after resizing the child window. This reverts ac2582d3aac25f2a5c504af146ca614761fc3f7e which was a speculative improvement. It turns out that resizing before the swap is important as it lets the driver know that it should resize the default framebuffer, making the following frame have a default framebuffer of the right size. BUG=angleproject:1050 BUG=angleproject:892 Change-Id: I84ec3728226fde9fb208f91c02a3d5a1ab71aef8 Reviewed-on: https://chromium-review.googlesource.com/286252 Reviewed-by: Kenneth Russell <kbr@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Corentin Wallez e7d8c80a 2015-07-16T17:28:10 WindowSurfaceGLX: Do not send an unused border_pixel to XCreateWindow This was a typo that never had any effect but it could cause problems in Debug but in release border_pixel could have contain garbage and cause an X11 error. BUG=angleproject:892 Change-Id: Id6dc24c726730d998b419101239b3a43d6675330 Reviewed-on: https://chromium-review.googlesource.com/286251 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Corentin Wallez b828b32d 2015-07-16T17:51:30 ANGLETest: swap after resizing the window, before running the test. This allows the test code to assume that the framebuffer size is equal to the window size. BUG=angleproject:1050 Change-Id: Ia4928d7a1d6cddb1ae330846bb44576db6a37533 Reviewed-on: https://chromium-review.googlesource.com/286253 Reviewed-by: Kenneth Russell <kbr@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Corentin Wallez 0bf58eab 2015-07-09T12:47:29 Renderer11: expose a metric for the Buffer11 CPU copies size This will allow us to measure the impact of subsequent optimizations on the memory consumption of Chrome. BUG=angleproject:916 Change-Id: Ib57fdfcc2950917eff33080bfb3db574595ecb6d Reviewed-on: https://chromium-review.googlesource.com/284637 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Jamie Madill 185fb403 2015-06-12T15:48:48 Move function prototypes and declarations out of the .y This will make the code easier to edit and maintain. BUG=none TEST=angle_unittests,angle_end2end_tests Change-Id: I955307d1209170fa99142103bc4d361c9eab1cc8 Reviewed-on: https://chromium-review.googlesource.com/286145 Tested-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Zhenyao Mo <zmo@chromium.org>
Geoff Lang b61e173a 2015-06-05T11:49:55 Only sync attributes used by the current program in RendererGL. Improves draw call overhead of RendererGL. DrawCallPerf_gl: Before: 136973 score After: 153317 score Improvement: 11.932% BUG=angleproject:959 Change-Id: Ib75f6fdd756648e4a07f6e970cda03abbdbcf009 Reviewed-on: https://chromium-review.googlesource.com/275409 Reviewed-by: Kenneth Russell <kbr@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang d5451f11 2015-06-05T10:59:04 Inline comparison operators of several small ANGLE structs. Improves draw call overhead of RendererGL. DrawCallPerf_gl: Before: 129779 score After: 136973 score Improvement: 5.543% No noticeable difference in DLL size or draw call perf of the D3D renderers. BUG=angleproject:959 Change-Id: Id54d49e9e2cfb69431ee26d632c58fee2c42b82c Reviewed-on: https://chromium-review.googlesource.com/275408 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 95137842 2015-06-02T15:38:43 Use a map to store uniform locations instead of a vector. Some intel drivers use seemingly arbitrary integers as uniform locations. This causes the location vector to be resized to arbitrarily large sizes. BUG=angleproject:882 Change-Id: I8db89178907dd6206eb8e646a0b426aa9bac0832 Reviewed-on: https://chromium-review.googlesource.com/274816 Reviewed-by: Kenneth Russell <kbr@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Corentin Wallez 31658f92 2015-07-15T12:57:34 Implement OSXWindow. BUG=angleproject:891 Change-Id: If8aefa4a37ba7d1b6b08921bee61463bb20550af Reviewed-on: https://chromium-review.googlesource.com/285834 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Kenneth Russell <kbr@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Jamie Madill 2453dbcb 2015-07-14T11:35:42 Fix 2D array texture redefinition. Only happens with texture formats that require initialization. BUG=angleproject:1069 TEST=dEQP-GLES3.functional.texture.format.sized.2d_array.* all pass Change-Id: I215d1262cddcde4ed218b6f023e67747cbc3eeaf Reviewed-on: https://chromium-review.googlesource.com/285347 Tested-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Brandon Jones <bajones@google.com>
Austin Kinross 02df796f 2015-07-01T10:03:42 Centralize renderer limitations for non-conformant renderers Some renderer configurations (e.g. D3D11 Feature Level 9_3) have some limitations and aren't quite conformant. This change generates errors when applications hit these limitations, and informs developers that they must work around them. BUG=angleproject:1055 Change-Id: I6a4a9e5cc71288ca366a54c769ca0eb82e79a7f7 Reviewed-on: https://chromium-review.googlesource.com/282814 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 09e2d93b 2015-07-14T16:40:31 D3D11: Futher optimize input layout cache. *re-land with fix for matrix attributes* *re-re-land with fix for attributes with BindAttribLocation* Using the new vertex format type enum, we can shrink the size of the input layout tables and reduce draw call overhead further. BUG=angleproject:959 Change-Id: I181acd3d7d519f5587cbe180fb1bca8530b7cfc2 Reviewed-on: https://chromium-review.googlesource.com/285348 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Olli Etuaho c1ac41bb 2015-07-10T13:53:46 Apply array restriction on qualified types only on ESSL1.00 Add a test that checks that uniforms with an array type are allowed in ESSL3.00. TEST=angle_unittests BUG=angleproject:1061 Change-Id: I6c9e8eeb3e8a6b81522c87039b93bcc0008ae317 Reviewed-on: https://chromium-review.googlesource.com/285481 Tested-by: Olli Etuaho <oetuaho@nvidia.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Zhenyao Mo <zmo@chromium.org>
Geoff Lang 8442a612 2015-06-05T16:43:27 Fix texture formats that only require extensions failing requirements checks. Unset version requirements equate to UINT_MAX causing requirements checks for fail for formats that only need extensions such as DXT formats. Fixes tests that require compressed formats. Passes conformance/extensions/webgl-compressed-texture-s3tc.html BUG=angleproject:884 Change-Id: Id810c477a359bf9d35a886c60735a91b51d1e931 Reviewed-on: https://chromium-review.googlesource.com/275693 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 6d45a999 2015-07-14T15:16:57 Revert "D3D11: Futher optimize input layout cache." Causing assertion failures in WebGL CTS in debug. Example build: https://build.chromium.org/p/chromium.gpu.fyi/builders/Win7%20Debug%20%28NVIDIA%29/builds/10215 This reverts commit 2ee580f10052c03a3a0e8c535bd7da82147133c3. Change-Id: Idffcd848adb6898f77b3c758b214eb31ca1f6e05 Reviewed-on: https://chromium-review.googlesource.com/285326 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Olli Etuaho abb0c381 2015-07-13T12:01:12 Check that layout qualifiers may only appear in declarations In the shading language grammar, layout qualifiers may appear in loop conditions and function declarations, but this is not valid ESSL 3.00 according to section 4.3.8. TEST=angle_unittests, dEQP-GLES3.functional.shaders.*layout* BUG=angleproject:1064 Change-Id: I73f805247bf6678b953f2e1d45a23391e9eacb96 Reviewed-on: https://chromium-review.googlesource.com/285040 Tested-by: Olli Etuaho <oetuaho@nvidia.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Zhenyao Mo <zmo@chromium.org>
Geoff Lang 8e17a496 2015-07-13T22:24:42 Revert "Fix memory layout of imageformats.h's 16-bit structs" Seeing failures in the new tests on Chrome's Intel bot: http://build.chromium.org/p/chromium.gpu.fyi/waterfall?builder=Win7%20Release%20(Intel) Also seeing failures in the BlendMinMaxTest.RGBA16F test, may be related. Reverting for now, can help diagnose the problems tomorrow if needed. This reverts commit 61d46d8740f1f93878ef324e11e4d72c57de8c3a. Change-Id: Id227f6ce8dafca24fbd2de92a2c4974e6a564c1f Reviewed-on: https://chromium-review.googlesource.com/285227 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 5ec53c82 2015-06-05T16:32:14 Handle the remaining pixel unpack parameters in TextureGL. BUG=angleproject:884 Change-Id: I9e248e623f3b342f878bf65c9686768b90cf5ed8 Reviewed-on: https://chromium-review.googlesource.com/275692 Tested-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Brandon Jones <bajones@chromium.org>
Geoff Lang afce829a 2015-06-05T16:25:16 Sync pixel pack state before glReadPixels in FramebufferGL. Fixes conformance/reading/read-pixels-pack-alignment.html BUG=angleproject:885 Change-Id: I48f1598d9a67f3980d2ff86307eb107ec7506776 Reviewed-on: https://chromium-review.googlesource.com/275691 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Kenneth Russell <kbr@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang aef1663f 2015-06-05T16:09:55 Add missing GL_STENCIL_INDEX8 format to the formatutilsgl table. Fixes conformance/renderbuffers/framebuffer-object-attachment.html BUG=angleproject:884 Change-Id: I421b563fa8549eb2edc42a9ac1c798fc457256ee Reviewed-on: https://chromium-review.googlesource.com/275690 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Brandon Jones <bajones@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Corentin Wallez 91f828e3 2015-07-13T11:08:19 LineLoopTest: Fix the test not rendering anything. BUG=angleproject:1063 Change-Id: Id0772b5c8479150a1e736aa7cd35ec6444753278 Reviewed-on: https://chromium-review.googlesource.com/285126 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Austin Kinross 61d46d87 2015-07-09T13:47:09 Fix memory layout of imageformats.h's 16-bit structs Change-Id: I87c363f68394d868d2a72e84bfdfd64db0c6e1d0 Reviewed-on: https://chromium-review.googlesource.com/284652 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Austin Kinross <aukinros@microsoft.com>
Jamie Madill 2ee580f1 2015-07-10T11:14:58 D3D11: Futher optimize input layout cache. *re-land with fix for matrix attributes* Using the new vertex format type enum, we can shrink the size of the input layout tables and reduce draw call overhead further. BUG=angleproject:959 Change-Id: I6d8ad78a003c41f40e7e1caa5972838f8ff4fce8 Reviewed-on: https://chromium-review.googlesource.com/284811 Tested-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Kenneth Russell <kbr@chromium.org> Reviewed-by: Olli Etuaho <oetuaho@nvidia.com> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Cooper Partin 75da1974 2015-06-16T15:03:14 Changed d3d11 desktop renderer to use d3d9 debug annotation interfaces. The D3D11 renderer must choose the D3D9 debug annotator because the D3D11 interface method ID3DUserDefinedAnnotation::GetStatus on desktop builds doesn't work with the Graphics Diagnostics tools in Visual Studio 2013. The D3D9 annotator works properly for both D3D11 and D3D9. Incorrect status reporting can cause ANGLE to log unnecessary debug events. Change-Id: I9a31c63cbc506904eb39577826fc4df8d503f03a Reviewed-on: https://chromium-review.googlesource.com/278162 Tested-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Cooper Partin <coopp@microsoft.com> Tested-by: Cooper Partin <coopp@microsoft.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Minmin Gong 03786d77 2015-05-27T11:22:30 After a create-on-bind, the subsequent glGen* should not waste handle space. Consider this calling sequence: glBindTexture(GL_TEXTURE_2D, 3); // create-on-bind glGenTextures(1, tex); Before this fix, mUnallocatedList in HandleAllocator is in reverse sorted order. It's split into (4, MAX_UINT) and (1, 3). The glGen gets tex = 4, and handles 1 and 2 will not be allocated until it reaches MAX_UINT. With this fix, the elements in mUnallocatedList is in sorted order (1, 3) and (4, MAX_UINT). So tex is 1, and we can have all rest handles. Change-Id: If408ea92f7c243791119fe386e3e0ea27954e55c Reviewed-on: https://chromium-review.googlesource.com/273886 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Minmin Gong <mgong@microsoft.com>
Jamie Madill a8bb9cdc 2015-07-13T09:59:53 Lazily load the HLSL compiler DLL. If the user is loading resources straight from the disk with the binary shader cache, they shouldn't need to load the compiler DLL at all. Note: might be a good idea to track more statistics here. BUG=angleproject:1014 Change-Id: Ie75dcce3eb249347c545f1bbca7d0977df7addee Reviewed-on: https://chromium-review.googlesource.com/282554 Reviewed-by: Kenneth Russell <kbr@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Olli Etuaho e0f623a4 2015-07-10T11:58:30 Check that block instance name isn't reserved BUG=angleproject:1060 TEST=dEQP-GLES3.functional.shaders.uniform_block.invalid.* Change-Id: I6de3aa0f714d585e7821798744530f3e51ddee7f Reviewed-on: https://chromium-review.googlesource.com/284259 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Zhenyao Mo <zmo@chromium.org> Tested-by: Olli Etuaho <oetuaho@nvidia.com>
Corentin Wallez 7ef89571 2015-07-10T11:08:03 EGLContextCompatibility: suppress test on Linux non-standalone The tests turn out to fail before we have a context current on AMD so we cannot use isAMD and have to resort to disabling for all Linuxes on the FYI bots. Using MAYBE like Chrome doesn't seem to work with TEST_P. BUG=angleproject:892 Change-Id: Ibabd2c359ce55c7677af0f8bd5723f845935f2be Reviewed-on: https://chromium-review.googlesource.com/284872 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/284749
Geoff Lang c3b57529 2015-07-10T20:22:42 Revert "EGLContextCompatibility: suppress test on Linux non-standalone" Causing gyp generation failures on FYI bots: https://build.chromium.org/p/chromium.gpu.fyi/builders/GPU%20Win%20Builder/builds/30490 This reverts commit af98f24aece19c3231d9e7300bbab5c323109b23. Change-Id: I0b3ea26ee02591588bda14676211658b42135cf2 Reviewed-on: https://chromium-review.googlesource.com/284910 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Corentin Wallez af98f24a 2015-07-10T11:08:03 EGLContextCompatibility: suppress test on Linux non-standalone The tests turn out to fail before we have a context current on AMD so we cannot use isAMD and have to resort to disabling for all Linuxes on the FYI bots. Using MAYBE like Chrome doesn't seem to work with TEST_P. BUG=angleproject:892 Change-Id: Ie964168eb0b1d830dd1fd0988869adf39bc2309a Reviewed-on: https://chromium-review.googlesource.com/284872 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Dmitry Skiba 01971113 2015-07-10T14:54:00 Cache TTypes. *re-land with build fix for Win/Release* This change saves us ~70KiB per compiler with just ~3KiB of cache. BUG=492725 Change-Id: I4382c55b2480f70b00c5d117fcb7e0c51d0dfbb4 Reviewed-on: https://chromium-review.googlesource.com/284735 Tested-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Dmitry Skiba <dskiba@google.com> Reviewed-by: Alexis Hétu <sugoi@chromium.org>
Jamie Madill 53b76107 2015-07-10T18:52:58 Revert "Cache TTypes." Unused variable warning in Release: warning C4189: 'MaxEnumValue' : local variable is initialized but not referenced I'll handle fixing this. BUG=492725 This reverts commit b25d14e4b39ee273fad3bb585c3a3a929b3f794c. Change-Id: I502fc5288d5d3c48ecd43f84acdf66b7e300ad22 Reviewed-on: https://chromium-review.googlesource.com/284863 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Corentin Wallez c70e1208 2015-07-10T10:53:01 egl::MakeCurrent: report platform's makeCurrent errors This caused the context to be current from ANGLE's point of view while it wasn't from the driver's point of view. BUG=angleproject:892 Change-Id: I0719b4702721916e9eb3a9f4cafc7a86dbc7a625 Reviewed-on: https://chromium-review.googlesource.com/284871 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Nico Weber 44897140 2015-07-10T09:50:00 clang/win: Fix -Wunused-private-field warnings in debug builds. No intended behavior change. BUG=505317 Change-Id: I5dfa1d67715b18133f3373ca00a6d1d96b678043 Reviewed-on: https://chromium-review.googlesource.com/284850 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Nico Weber <thakis@chromium.org>
Alexis Hetu 07e57df7 2015-06-16T16:55:52 Added non square matrix construction Added new construction operations for non square matrices, along with the required changes to the related translation functions. Change-Id: I04ae7d4b2d1bb363b35d088cea45c0e7c4bc8a13 Reviewed-on: https://chromium-review.googlesource.com/277729 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Dmitry Skiba b25d14e4 2015-06-23T17:43:14 Cache TTypes. This change saves us ~70KiB per compiler with just ~3KiB of cache. BUG=492725 Change-Id: I7b8053c032c9c68f646162baf61abf6db3afe52e Reviewed-on: https://chromium-review.googlesource.com/284003 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 8e34494f 2015-07-09T14:22:07 Share data between VertexArray and Impl. Using the same design as for the Framebuffer::Data helper, we can use a struct to share between the object and the Impl. This also gives the Impl access to the maxEnabledAttrib, and saves some duplicated storage. BUG=angleproject:1040 TEST=WebGL CTS, end2end_tests, unittests Change-Id: I55c91e8a5f3dcae302cab441182320aafd5375ef Reviewed-on: https://chromium-review.googlesource.com/283930 Tested-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Olli Etuaho 0d208976 2015-07-10T15:45:09 Revert "D3D11: Futher optimize input layout cache." This seems to have broken some dEQP tests in debug build, possibly uncovering a previously undetected bug. TEST=dEQP-GLES3.functional.shaders.linkage.varying.basic_types.* This reverts commit d2328a5246d8e0ab8a3dde1b30b80ce5e161e6f3. Change-Id: I9f082d7a6fca38b4c076fecc342ac40d5416ebef Reviewed-on: https://chromium-review.googlesource.com/284780 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Olli Etuaho <oetuaho@nvidia.com>
Olli Etuaho fb6ab2ce 2015-07-09T20:55:28 Matrix layout qualifiers are valid for non-matrices Uniform block members may be structs containing matrices, and there's no explicit mention in the spec that the matrix qualifiers would only be valid for matrix fields. Only generate a warning when an extraneous matrix layout qualifier is used. TEST=dEQP-GLES3.functional.shaders.*layout* (all pass with this patch) BUG=angleproject:1058 Change-Id: Ifb2f2392d84100d997cc2d68fd55e9ad17a17cea Reviewed-on: https://chromium-review.googlesource.com/284112 Reviewed-by: Zhenyao Mo <zmo@chromium.org> Tested-by: Olli Etuaho <oetuaho@nvidia.com>
Nico Weber cb8ff7fb 2015-07-09T21:52:54 clang/win: Fix a -Wreorder warning ..\..\third_party\angle\src\libANGLE\renderer\d3d\d3d11\SwapChain11.cpp(30,7) : error: field 'mDepthStencilRenderTarget' will be initialized after field 'mPassThroughResourcesInit' [-Werror,-Wreorder] mDepthStencilRenderTarget(this, renderer, true), ^ While here, also reorder the fields that are initialized in the constructor to match the order the fields are declared in, to make it easier to see if any are missing. No intended behavior change. BUG=505304 Change-Id: If48195c84161868d33d4361088d3ad22b7a0fc31 Reviewed-on: https://chromium-review.googlesource.com/284682 Reviewed-by: Nico Weber <thakis@chromium.org> Tested-by: Nico Weber <thakis@chromium.org>
Jamie Madill 06c5a646 2015-07-09T14:48:12 Suppress dEQP failure, only showing on the bot. Unsure why this is failing: functional.shaders.struct.local.dynamic_loop_struct_array_fragment BUG=angleproject:1059 Change-Id: I72e05269f831769a763c44354b95a7224edb72fa Reviewed-on: https://chromium-review.googlesource.com/284636 Tested-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill d2328a52 2015-07-09T11:30:30 D3D11: Futher optimize input layout cache. Using the new vertex format type enum, we can shrink the size of the input layout tables and reduce draw call overhead further. BUG=angleproject:959 Change-Id: Iea595fa64edbbd91f669138dfdeb9d2543b83929 Reviewed-on: https://chromium-review.googlesource.com/277291 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Kenneth Russell <kbr@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 0342253e 2015-07-09T11:30:29 D3D11: Refactor vertex format tables. Use switch statements based on the format type enum, instead of a map from the old VertexFormat structure to the info payload. This saves on lookup and initialization time. BUG=angleproject:959 Change-Id: I6d1bf282c88f67272ca067cb64bc71e77824a12e Reviewed-on: https://chromium-review.googlesource.com/277290 Tested-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Olli Etuaho b5841ef2 2015-07-08T17:25:22 Disallow texture lookup functions in global initializers Do this by simply disallowing all function calls in global initializers - all built-in math ops are handled as other ops, not function calls. This change was tested extensively with popular WebGL content, with no regressions found. TEST=angle_unittests BUG=angleproject:988 Change-Id: Id1107fa294ae4012d5dd3949539d0b7b4cd21943 Reviewed-on: https://chromium-review.googlesource.com/283703 Reviewed-by: Zhenyao Mo <zmo@chromium.org> Tested-by: Olli Etuaho <oetuaho@nvidia.com>
Corentin Wallez e9cc78a1 2015-07-06T07:17:00 Make Buffer11::mBuffersStorages an array instead of a map BUG=angleproject:516 Change-Id: I7f969435a89c0063b504628d2ec3321cc02df7ce Reviewed-on: https://chromium-review.googlesource.com/283243 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Corentin Wallez bc3b5e63 2015-07-07T10:08:05 D3D11: map index buffers only when needed. Before this patch, index buffers where always mapped in case we needed the index data for the indexed point sprites workaround. This patch makes it so the index buffer is only mapped in this case, when we need to stream index data or when we need to fill the static copies of the index buffers. This make the memory usage of http://alteredqualia.com/xg/examples/mammoth.html go down from 41MB to 28MB. BUG=angleproject:516 Change-Id: I937506d06fd6f074ef2120469dbd235e20245fca Reviewed-on: https://chromium-review.googlesource.com/283626 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Dmitry Skiba 58832204 2015-07-06T16:11:13 Calculate TFunction::mangledName lazily. This saves us ~15KiB per compiler instance on 32-bit Android. BUG=492725 Change-Id: I9db2998482941b5ab2eb5cb4925cbd1fb58ab4be Reviewed-on: https://chromium-review.googlesource.com/283584 Reviewed-by: Zhenyao Mo <zmo@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Arun Patole 0c5409f8 2015-07-08T15:17:53 Support constant folding of fragment processing built-ins This change adds constant folding support for following derivative functions: - dFdx, dFdy and fwidth. As per spec, derivatives of constant arguments should be 0, so this change just sets result components to zero when the above operations are performed on constant argument. BUG=angleproject:913 TEST=dEQP Tests dEQP-GLES3.functional.shaders.constant_expressions.builtin_functions. fragment_processing.* (All 12 tests started passing with this change.) Change-Id: I67b7c5abd970b740e15e3bd1ee56721e81bbecc4 Reviewed-on: https://chromium-review.googlesource.com/283759 Reviewed-by: Olli Etuaho <oetuaho@nvidia.com> Tested-by: Olli Etuaho <oetuaho@nvidia.com> Reviewed-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>
Corentin Wallez bcab6426 2015-07-06T07:35:14 Fix typo in Buffer11::getContantBufferRangeStorage BUG=angleproject:516 Change-Id: I907ec41ce5691300d17ca5b08a62b0d4579b01e5 Reviewed-on: https://chromium-review.googlesource.com/283244 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Corentin Wallez 2e62a9a8 2015-07-03T14:13:50 Simplify the flow of IndexDataManager::prepareIndexData This will simplify the work on follow up CLs a lot BUG=angleproject:516 Change-Id: Ie8374ec28fce2e01e76c711a4d280e1ed004a21f Reviewed-on: https://chromium-review.googlesource.com/283380 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Corentin Wallez 0b5a4a49 2015-07-08T11:59:46 EGLContextCompatibilityTest: check for suppression only when a context is bound. Otherwise glGetString(GL_RENDERER) returns "ANGLE" and doesn't provide information on the vendor. BUG=angleproject:892 Change-Id: I01899ca78656aaa8db860829c78bf3c61c355eae Reviewed-on: https://chromium-review.googlesource.com/284051 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Jamie Madill d3dfda2b 2015-07-06T08:28:49 Refactor how we store vertex formats. Instead of storing a vertex format as a struct with the full info, instead use an enum, and look up the info when we need it. This saves a lot of constructor initialization time, operator comparison time, and storage. It also will allow us to look up D3D format info more quickly. BUG=angleproject:959 Change-Id: I202fd1ea96981073bc1b5b232b1ec3efa91485cb Reviewed-on: https://chromium-review.googlesource.com/277289 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 2810a20c 2015-07-07T14:23:58 Fix the InputLayoutCache test on Windows 8. On some configs, this would use an RGBA4 16-bit backbuffer, which is not enough resolution for the test. Fix this by requiring 32-bit backbuffers. We might also want to figure out if we want to default to 16-bit on Windows 8 desktop, which seems less than ideal. BUG=angleproject:959 Change-Id: I53b3a9ef6cbecf76c7c764623e5eb1f454a6b72d Reviewed-on: https://chromium-review.googlesource.com/283773 Tested-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Austin Kinross <austin.kinross@gmail.com> Reviewed-by: Cooper Partin <coopp@microsoft.com> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Daniel Cheng fda3ec74 2015-07-08T08:22:04 Fix another clang warning with -Wmissing-braces in ANGLE. Clang warns if there are missing braces around a subobject initializer. The most common idiom that triggers this is: STRUCT s = {0}; which can be more simply written as: STRUCT s = {}; BUG=505297 Change-Id: Ie9f9037a1ba4b6303daa30424cdc24c1ecf18896 Reviewed-on: https://chromium-review.googlesource.com/284160 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Arun Patole ab2b9a23 2015-07-06T18:27:56 Refactor unary operation constant folding code This change splits TIntermConstantUnion::foldUnary into two functions: - foldUnaryWithDifferentReturnType: - Handles constant folding of operations where the return type has a different number of components compared to the operand type. - foldUnaryWithSameReturnType: - Handles constant folding of unary operations where the return type is the same as operand type. BUG=angleproject:913 TEST=angle_unittests, dEQP Tests (dEQP-GLES3.functional.shaders.constant_expressions.builtin_functions.*) Change-Id: I675891138d4e17fd2390c03e9f710e0be0b7c7b6 Reviewed-on: https://chromium-review.googlesource.com/283464 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>
Olli Etuaho 846fe05f 2015-07-07T17:41:21 Disable using globals as l-values in global initializers It should not be possible to use globals as l-values in global initializers. This change was tested extensively with popular WebGL content, with no regressions found. TEST=angle_unittests BUG=angleproject:988 Change-Id: I21ab731eb1d92aeae25795856ccae280792ad1f0 Reviewed-on: https://chromium-review.googlesource.com/283910 Tested-by: Olli Etuaho <oetuaho@nvidia.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Zhenyao Mo <zmo@chromium.org>
Kenneth Russell 6affeef6 2015-07-07T15:16:49 Suppress angle_end2end_tests failures on Linux/NVIDIA and Linux/AMD. Verified the NVIDIA suppression locally; assuming the AMD suppression will take effect on the bot. Thanks to geofflang@ and cwallez@ for the suggestion on the approach to take. BUG=angleproject:892 Change-Id: Ida4b6c1395185b0dfb0ea890395e35cb6db7ccd5 Reviewed-on: https://chromium-review.googlesource.com/283974 Tested-by: Kenneth Russell <kbr@chromium.org> Reviewed-by: Brandon Jones <bajones@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill 2f232370 2015-07-07T21:57:55 Revert "Cache TTypes." Lots of compile errors. BUG=492725 This reverts commit 5377720aae042c5bfae0e8a37032c90dc3ab78cf. Change-Id: I64889b99b1f1f48d39b87ebb668f6a32a3abac45 Reviewed-on: https://chromium-review.googlesource.com/283945 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Corentin Wallez e9336c0d 2015-07-07T16:46:26 EGLSurfaceTest: run d3d specific tests only on d3d. This is to help with the FYI bot and pending a refactor to use our test instantiation. BUG=angleproject:892 Change-Id: I56e772d7988a2172ad2384bdf408a8eaeab7129a Reviewed-on: https://chromium-review.googlesource.com/283971 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Kenneth Russell <kbr@chromium.org> Reviewed-by: Cooper Partin <coopp@microsoft.com> Tested-by: Corentin Wallez <cwallez@chromium.org>
Dmitry Skiba 5377720a 2015-06-23T17:43:14 Cache TTypes. This change saves us ~70KiB per compiler with just ~3KiB of cache. BUG=492725 Change-Id: I2ee748f7271b1afe0834083cbff6f0b84104aa53 Reviewed-on: https://chromium-review.googlesource.com/281411 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Dmitry Skiba <dskiba@google.com>
Austin Kinross da056468 2015-06-16T17:00:11 For WinRT, add EGLRenderSurfaceScaleProperty to specify swapchain scaling factor Change-Id: Iede6682306082346cf2a3a55fe58f732b7a453df Reviewed-on: https://chromium-review.googlesource.com/277931 Tested-by: Austin Kinross <aukinros@microsoft.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Olli Etuaho ce39f6ff 2015-07-06T15:25:19 Disallow user-defined function calls in global variable init Generate an error message when an user-defined function call is found in a global variable initializer. Even before this patch, the call graph already marked functions that were only called from the global scope as unused. This change was tested extensively with popular WebGL content, with no regressions found. TEST=angle_unittests BUG=angleproject:988 Change-Id: Iec1b16d2af386f1e5c383f86926d80cef553b694 Reviewed-on: https://chromium-review.googlesource.com/283291 Tested-by: Olli Etuaho <oetuaho@nvidia.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Zhenyao Mo <zmo@chromium.org>
Jamie Madill 8fc55c8e 2015-06-30T11:04:18 Lazily load SwapChain11 pass-through resources. This allows Chromium to avoid initializing a whole bunch of resources and a shader when it collects GPU information. This should speed up startup. BUG=angleproject:1014 Change-Id: Id1e777c6ea86d66ad812540f9d8494744cda64de Reviewed-on: https://chromium-review.googlesource.com/282553 Tested-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Brandon Jones <bajones@chromium.org> Reviewed-by: Zhenyao Mo <zmo@chromium.org>
Jamie Madill e62cedd0 2015-06-30T11:03:54 Load Clear11 resources lazily. Again this saves on startup time and memory use. BUG=angleproject:1014 Change-Id: I3890dc2ea50ff4e4f1ff9d7cb223e1ab57c330ce Reviewed-on: https://chromium-review.googlesource.com/282552 Reviewed-by: Brandon Jones <bajones@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 86a07aec 2015-06-30T11:03:18 Add LazyInputLayout to defer loading input layouts. Lazily loading input layouts can also save memory and startup time. There are several cases where we don't need these resources until later, or sometimes, at all. BUG=angleproject:1014 Change-Id: I4e0d45353b5d3969bd1ed86ad26f47d34e542ed5 Reviewed-on: https://chromium-review.googlesource.com/282551 Tested-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Brandon Jones <bajones@chromium.org>
Jamie Madill 531d5f45 2015-07-06T08:26:45 D3D11: Refactor InputLayout cache. *re-land with fix for cache overflowing* Using a much more compact input layout structure allows us to save quite a bit of time comparing input layouts, or computing hashes. A subsequent patch shrinks the size of the structure further. BUG=angleproject:959 Change-Id: If240bb7c84d78fc8c9fb6f9049bf71d8a81c97c6 Reviewed-on: https://chromium-review.googlesource.com/283227 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Corentin Wallez 01e4bfe7 2015-07-02T15:07:13 Update dEQP test expectations with Linux failures BUG=angleproject:1051 Change-Id: I5f397e230f0e56b1e6832c3dae5ae5c0c9a8b7c4 Reviewed-on: https://chromium-review.googlesource.com/283226 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Jamie Madill 16f99b74 2015-07-02T14:09:06 Fix warnings with code analysis tools. Variable shadowing and a few other non-bug warnings. BUG=None Change-Id: Ibf62d6e7fef91fc213a53a6902f494147ed30ebc Reviewed-on: https://chromium-review.googlesource.com/283223 Tested-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@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>
Ben Wells e6e8c7c5 2015-07-01T16:48:31 Fix 'unused private field' warnings for clang. BUG=505317 Change-Id: I731b6e5ae5d5eba50f556314eeeebc6a3d29fc7a Reviewed-on: https://chromium-review.googlesource.com/282932 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>