include/platform/Feature.h


Log

Author Commit Date CI Message
Shahbaz Youssefi a0586d6e 2024-10-26T00:32:27 Remove feature description / condition strings These strings show up in chrome://gpu so they can marginally be useful, but are otherwise dead weight for most uses of ANGLE / users of ANGLE. While slightly less convenient, the feature name can always be linked back to the source code if needed so the presence of such metadata is not necessary either. This shaves 40KB from the binary size of ANGLE when built with Vulkan only on Android. Bug: chromium:371512561 Change-Id: I3959961bb7de95cc60a85130d0ff38a7fd533fb7 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/5968453 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Steven Noonan f395f34b 2023-08-03T13:58:43 features: frontload feature overrides This allows us to have features that depend on the state of other features more reliably. For example, let's say you have two features: ANGLE_FEATURE_CONDITION(&mFeatures, allowX, (benefitsFromX || isSpecificHardware) && !isBadHardware); ANGLE_FEATURE_CONDITION(&mFeatures, supportsX, hardware.featureXSupported && mFeatures.allowX.enabled); Before this change, if you overrode allowX, the override would be applied too late for the supportsX test. This also helps with disabling dependent features via overrides. For example, if you disable "supportsRenderpass2", it will also disable features depending on it, such as "supportsDepthStencilResolve" and "supportsFragmentShadingRate". By frontloading the feature overrides, we can have cross-dependencies between "feature supported on this platform" and "allow this feature by policy". Bug: angleproject:8291 Change-Id: Id6da2c89428fa896d677fe8d5a41369277a21b31 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4749524 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Auto-Submit: Steven Noonan <steven@uplinklabs.net> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Mohan Maiya 0fe6f282 2023-06-24T14:06:17 Reset and then populate frontend features during display initialize Overwritten features were never reset even if a display was terminated. On platforms that reuse displays for all tests in the end2end suite, overridden feature would leak into subsequent tests causing unexpected failure. Bug: angleproject:8235 Change-Id: I1b359bc762a2bca8db4e4dbc7a587604e5bd6a5b Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4643453 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: mohan maiya <m.maiya@samsung.com>
Shahbaz Youssefi 163e56e4 2022-09-20T00:40:55 Allow feature overrides to end in * (wildcard) Makes it easier to apply overrides to features with long names. Also works around Android's limit of 92 characters for debug properties. Bug: b/238024366 Change-Id: I8f417287f92b2439de1a7b7d6abbaf9e61b405e8 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3906222 Reviewed-by: Amirali Abdolrashidi <abdolrashidi@google.com> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Yiwei Zhang <zzyiwei@chromium.org>
Chris Dalton 861149c7 2022-08-03T15:43:29 Make PLS coherent on desktop OpenGL Implements ANGLE_shader_pixel_local_storage_coherent using fragment shader synchronization extensions: NV_fragment_shader_interlock INTEL_fragment_shader_ordering ARB_fragment_shader_interlock With these extensions combined, we get coherency all 3 big desktop vendors: NVIDIA, Intel, and AMD. Bug: angleproject:7279 Change-Id: Ie20b251fb772898e89994b799640f1f2806581eb Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3773990 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Shahbaz Youssefi fcec6904 2022-04-13T14:18:06 Generate feature variable names from display names The json file now only contains the feature display name. The variable name is automaticaly derived. For consistence with Chromium and other Chromium-based projects, the display name is now always snake_case, and that's what's specified in the json files. This also makes camelCase variable name generation trivial (as opposed to the other way around). Feature overrides now accept both snake_case and camelCase names to ensure compatibility with existing scripts. This is done by removing _ and comparing override names with feature names in lower case. Bug: angleproject:6435 Change-Id: I0b6ed2bbf5c312bc4f4be7b3c7d55dbaca2a9886 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3584630 Reviewed-by: Amirali Abdolrashidi <abdolrashidi@google.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Shahbaz Youssefi 797e627e 2022-04-08T22:49:51 Autogenerate list of features as enum The WithX() and WithNoX() helpers are removed and replaced with enable() and disable() member functions that take the name of the feature (as a Feature::X enum constant). This has two benefits: - Adding tests that override a feature no longer requires additional helper functions to be written. - There's no mistaking the feature name. This change doesn't yet fix the main issue in anglebug.com/6435, but does fix the following helpers using an old feature name (so they were ineffective): - WithMetalForcedBufferGPUStorage - WithNoVulkanViewportFlip A follow up would remove the old way of overriding features in tests and replaces them with the new way. Bug: angleproject:6435 Change-Id: Ida02b26ec72bc40d7a8938c76a93815bb903ca05 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3580982 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Shahbaz Youssefi eeb39653 2022-04-08T16:09:48 Autogenerate features Features are now specified in a json file and autogenerated. This is in preparation for more autogeneration to support feature override in tests. This change doesn't yet fix the issues in anglebug.com/6435 and should be a no-op. Bug: angleproject:6435 Change-Id: Icdb63a94dc37b5fef0a356e0fc0b49937e083c8a Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3579941 Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Mohan Maiya 1b9774f5 2022-01-26T13:37:03 Vulkan: Force submit updates to immutable textures Submit immutable texture updates recorded in outside renderpass commands when the following conditions are met - 1. "forceSubmitImmutableTextureUpdates" feature is enabled 2. The texture is immutable This works around a problem that manifests in some applications that do not perform appropriate synchronization of shared contexts. Bug: angleproject:6929 Test: EGLContextSharingTestNoSyncTextureUploads.* Change-Id: I2a237046e2cc53650eb8dc07e3697f7481df9b02 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3418138 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Charlie Lao <cclao@google.com> Commit-Queue: mohan maiya <m.maiya@samsung.com>
Kenneth Russell da3db87e 2021-07-06T14:00:58 Upstream latest changes to Metal backend from Apple to 7/1/2021 This CL merges in the ANGLE changes between these two WebKit commits: https://git.webkit.org/?p=WebKit.git;a=commit;h=8648b353ab1d7730438c2e08319e1a4d64982c31 https://git.webkit.org/?p=WebKit.git;a=commit;h=166e4924a52971d6a32ad48247a439b16c00e062 Include provoking vertex buffer out of bounds fix from https://bugs.webkit.org/show_bug.cgi?id=230107 Fix bad merge of resetting of dirty bits, breaking DepthStencilFormatsTest.DepthTextureRender test and perhaps others. Disable GL_APPLE_clip_distance when the direct-to-Metal compiler is active. It can not yet handle the gl_ClipDistance array. Disable use of rectangular textures for IOSurfaces. Metal can bind IOSurfaces to 2D textures, and this was passing all tests in the SPIR-V Metal backend. Introducing rectangular textures breaks the SPIR-V Metal backend, and the tests currently fail on the direct-to-Metal backend. Fix several bugs with ProvokingVertex, which was causing both the SpirV and Direct backends to incorrectly draw indices. (https://bugs.webkit.org/show_bug.cgi?id=230107) Skip the following tests on the Metal backend which is still failing RobustResourceInitTestES3.BlitDepthStencilAfterClearBuffer GLSLTest_ES3.GLVertexIDIntegerTextureDrawArrays/ES3_Metal With these changes, angle_end2end_tests again runs to completion. Bug: angleproject:6395 Change-Id: I3cc58f531426a95fc8f177a4ad87f56c1855a546 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3167010 Reviewed-by: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Kenneth Russell <kbr@chromium.org> Commit-Queue: Kyle Piddington <kpiddington@apple.com>
Courtney Goeltzenleuchter 7616dfbd 2020-11-04T18:23:22 Vulkan: Allow Android properties to override features Can enable/disable ANGLE feature via Android properties: debug.angle.feature_overrides_enabled and debug.angle.feature_overrides_disabled which take a string of ':' separated feature strings. Bug: b/170328907 Change-Id: I815b42c5cfae85a39f0f753eabd56e264ea38baf Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2514200 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Tim Van Patten <timvp@google.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jonah Ryan-Davis 1ab73f0f 2020-09-10T14:32:58 Cleanup disable_program_binary workaround This workaround should also clear the shader binary formats. Also, we can use this workaround when disabling program binaries for capture/replay. Bug: angleproject:5007 Change-Id: I57c78e2cc95e7148cb8a1e7fb9bf3ed958fa69c8 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2404383 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jonah Ryan-Davis 6b2639b0 2020-08-31T16:00:29 Workaround to disable OES_get_program_binary This is a useful workaround for testing/diagnostics. Disabled by default. Bug: angleproject:5007 Change-Id: If459f60ae7f8a2cd4ea934fe3e54d890387d57db Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2385933 Commit-Queue: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Yuly Novikov 4609c4ac 2020-04-06T19:02:29 Feature::condition must not be NULL Since it's returned by eglQueryStringiANGLE, and the doc says: 1. eGLQueryStringiANGLE returns a pointer to a static, null-terminated string 2. On failure, NULL is returned So, we shouldn't be returning NULL when there is no failure. This was breaking 'chrome --enable-gpu-service-logging'. Bug: angleproject:3947 Change-Id: I2dcc7d479899dc1fc5fd59a502e84defe44f64c9 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2137939 Reviewed-by: Jonah Ryan-Davis <jonahr@google.com> Commit-Queue: Yuly Novikov <ynovikov@chromium.org>
Jamie Madill d03b15b2 2020-03-26T17:22:18 Vulkan: Mask out Depth/Stencil RTs in feedback loops. This should enable some cases of limited support for feedback loops with depth/stencil buffers. For example with Manhattan and the Vulkan back-end. Increases the number of RenderPasses in Manhattan slightly. This will regress performance slightly until we can work out a better solution that is also conformant with the spec. Bug: angleproject:4517 Change-Id: I2758e6b4c2a930474c09cdc0950f3b6c34541089 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2106670 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Courtney Goeltzenleuchter <courtneygo@google.com>
Le Quyen fe26bae4 2019-10-29T18:38:53 Metal backend implementation pt 2 This is without Metal specific shader translator implemented yet. Bug: angleproject:2634 Change-Id: I95d589442251c9ba111bd05a2dc379a36739046c Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1855069 Reviewed-by: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jonah Ryan-Davis ae1b7786 2019-10-16T16:42:53 Fix ANGLE_FEATURE_CONDITION style issue Macro should end with a ; Bug: angleproject:3976 Change-Id: I4aaa146464d9d7e6230a3de44c30cfd1179a89ae Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1864620 Commit-Queue: Jonah Ryan-Davis <jonahr@google.com> Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jonah Ryan-Davis 7dd03446 2019-09-30T13:50:12 Ensure Features* descriptions stay up to date Created a macro to help keep Features' descriptions up to date. This will avoid confusion in the future when conditions change. Also update all descriptions to match current state. Bug: angleproject:3947 Change-Id: Ifc65e7789c916fab79f1323798dfb59d7a4efad2 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1829584 Commit-Queue: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jonah Ryan-Davis fce1e2d1 2019-06-04T15:02:08 Extend eglGetPlatformDisplay to allow feature overrides. Add EGL_FEATURE_OVERRIDES_ENABLED_ANGLE and EGL_FEATURE_OVERRIDES_DISABLED_ANGLE to submit lists of strings naming the features that should be overridden (either enabled or disabled) on display creation. Bug: angleproject:1621 Change-Id: I4bb75c5dbab0e3b701a72069c38f8c60ecfffad2 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1646595 Commit-Queue: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jonah Ryan-Davis e431aaa1 2019-06-04T11:36:43 Rename EGL_ANGLE_workaround_control to EGL_ANGLE_feature_control. For consistency, call these ANGLE "features", a subset of which may be workarounds. Also, whether the feature is enabled/disabled should be publically visible as "status". Bug: angleproject:1621 Change-Id: I0de90a932fbfe1fc9b59138153d616d29fa7268b Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1643410 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Jonah Ryan-Davis <jonahr@google.com>
Jonah Ryan-Davis f52f2637 2019-05-23T13:52:52 Add EGL_ANGLE_workaround_control extension. This extension is used to query strings from an array based on index, which will be used to query all the information about workarounds in ANGLE. Bug: angleproject:1621 Change-Id: I27157f278f7f17c92c8b4fd7753e2a5ecd0528f6 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1627723 Commit-Queue: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jonah Ryan-Davis 776694cd 2019-05-08T10:28:55 Change all ANGLE workarounds to use struct definition with info. Change each workaround from a simple bool to a struct with info including name, workaround set, description, and bug IDs. This will help with future workaround integration with Chrome. Bug: angleproject:1621 Change-Id: Ia27c180abaf845e280060c803e5994cc3152a057 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1593917 Commit-Queue: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>