Prepare gpu/config/gpu_info_collector_mac.mm for 10.9 deployment target. |
|||
Issue description
FAILED: obj/gpu/config/config_sources/gpu_info_collector_mac.o
/Users/erikchen/goma/gomacc ../../third_party/llvm-build/Release+Asserts/bin/clang++ -MMD -MF obj/gpu/config/config_sources/gpu_info_collector_mac.o.d -DV8_DEPRECATION_WARNINGS -DENABLE_NOTIFICATIONS -DENABLE_PEPPER_CDMS -DENABLE_PLUGINS=1 -DENABLE_PDF=1 -DENABLE_PRINTING=1 -DENABLE_BASIC_PRINTING=1 -DENABLE_PRINT_PREVIEW=1 -DENABLE_SPELLCHECK=1 -DUSE_BROWSER_SPELLCHECKER=1 -DNO_TCMALLOC -DUSE_EXTERNAL_POPUP_MENU=1 -DENABLE_WEBRTC=1 -DENABLE_EXTENSIONS=1 -DENABLE_TASK_MANAGER=1 -DENABLE_THEMES=1 -DENABLE_CAPTIVE_PORTAL_DETECTION=1 -DENABLE_SESSION_SERVICE=1 -DENABLE_PLUGIN_INSTALLATION=1 -DENABLE_SUPERVISED_USERS=1 -DENABLE_SERVICE_DISCOVERY=1 -DFULL_SAFE_BROWSING -DSAFE_BROWSING_CSD -DSAFE_BROWSING_DB_LOCAL -DCHROMIUM_BUILD -DENABLE_MEDIA_ROUTER=1 -DFIELDTRIAL_TESTING_ENABLED -DCR_CLANG_REVISION=282097-1 -DCR_XCODE_VERSION=0720 -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__ASSERT_MACROS_DEFINE_VERSIONS_WITHOUT_UNDERSCORE=0 -D_DEBUG -DDYNAMIC_ANNOTATIONS_ENABLED=1 -DWTF_USE_DYNAMIC_ANNOTATIONS=1 -DGPU_IMPLEMENTATION -DMESA_EGL_NO_X11_HEADERS -DSK_IGNORE_DW_GRAY_FIX -DSK_IGNORE_LINEONLY_AA_CONVEX_PATH_OPTS -DSK_SUPPORT_GPU=1 -DSK_BUILD_FOR_MAC -DU_USING_ICU_NAMESPACE=0 -DU_ENABLE_DYLOAD=0 -DU_NOEXCEPT= -DU_STATIC_IMPLEMENTATION -DICU_UTIL_DATA_IMPL=ICU_UTIL_DATA_FILE -I../../third_party/mesa/src/include -I../.. -Igen -I../../third_party/re2/src -I../../third_party/khronos -I../../gpu -I../../third_party/mesa/src/include -I../../skia/config -I../../skia/ext -I../../third_party/skia/include/c -I../../third_party/skia/include/config -I../../third_party/skia/include/core -I../../third_party/skia/include/effects -I../../third_party/skia/include/images -I../../third_party/skia/include/lazy -I../../third_party/skia/include/pathops -I../../third_party/skia/include/pdf -I../../third_party/skia/include/pipe -I../../third_party/skia/include/ports -I../../third_party/skia/include/utils -I../../third_party/skia/include/gpu -I../../third_party/skia/src/gpu -I../../third_party/skia/src/sksl -I../../third_party/icu/source/common -I../../third_party/icu/source/i18n -fno-strict-aliasing -fstack-protector-strong -fcolor-diagnostics -arch x86_64 -Wall -Werror -Wextra -Wpartial-availability -Wno-missing-field-initializers -Wno-unused-parameter -Wno-c++11-narrowing -Wno-covered-switch-default -Wno-deprecated-register -Wno-unneeded-internal-declaration -Wno-inconsistent-missing-override -Wno-shift-negative-value -Wno-undefined-var-template -Wno-nonportable-include-path -Wno-address-of-packed-member -O0 -g1 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk -mmacosx-version-min=10.9 -fvisibility=hidden -Xclang -load -Xclang ../../third_party/llvm-build/Release+Asserts/lib/libFindBadConstructs.dylib -Xclang -add-plugin -Xclang find-bad-constructs -Wheader-hygiene -Wstring-conversion -fno-threadsafe-statics -fvisibility-inlines-hidden -Wno-undefined-bool-conversion -Wno-tautological-undefined-compare -std=c++11 -stdlib=libc++ -fobjc-call-cxx-cdtors -Wobjc-missing-property-synthesis -fno-rtti -fno-exceptions -c ../../gpu/config/gpu_info_collector_mac.mm -o obj/gpu/config/config_sources/gpu_info_collector_mac.o
../../gpu/config/gpu_info_collector_mac.mm:60:34: error: 'CGDisplayIOServicePort' is deprecated: first deprecated in macOS 10.9 [-Werror,-Wdeprecated-declarations]
io_registry_entry_t dsp_port = CGDisplayIOServicePort(kCGDirectMainDisplay);
^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk/System/Library/Frameworks/CoreGraphics.framework/Headers/CGDisplayConfiguration.h:355:24: note: 'CGDisplayIOServicePort' has been explicitly marked deprecated here
CG_EXTERN io_service_t CGDisplayIOServicePort(CGDirectDisplayID display)
^
1 error generated.
,
Oct 4 2016
,
Oct 5 2016
ccameron: This code does a check using a CGDirectDisplayID: https://github.com/glfw/glfw/pull/192/files We could get main or active display with one of the methods at: https://developer.apple.com/reference/coregraphics/1655858-quartz_display_services Would that work?
,
Oct 5 2016
The check at line 84 https://github.com/glfw/glfw/pull/192/files#diff-178a04c4ac668d2ed934c20424a86f34R84 is true for both displays -- they have the same model and vendor.
,
Oct 10 2016
Maybe a suppression is the way to go, and we should UMA how often that coincides with the ordering on multi-GPU machines (and, if they do, we can go with it).
,
Oct 12 2016
That sounds reasonable. Can you put up a CL?
,
Oct 22 2016
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/5bbf3c6317574a1b6b3798863d0b50299aff9070 commit 5bbf3c6317574a1b6b3798863d0b50299aff9070 Author: ccameron <ccameron@chromium.org> Date: Sat Oct 22 02:42:05 2016 Add suppression for deprecated CGDisplayIOServicePort call This has no obviously correct replacement TBR=zmo BUG= 650837 CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:linux_optional_gpu_tests_rel;master.tryserver.chromium.mac:mac_optional_gpu_tests_rel;master.tryserver.chromium.win:win_optional_gpu_tests_rel Review-Url: https://chromiumcodereview.appspot.com/2443783002 Cr-Commit-Position: refs/heads/master@{#426956} [modify] https://crrev.com/5bbf3c6317574a1b6b3798863d0b50299aff9070/gpu/config/gpu_info_collector_mac.mm
,
Oct 24 2016
|
|||
►
Sign in to add a comment |
|||
Comment 1 by ccameron@chromium.org
, Oct 4 2016Owner: ccameron@chromium.org
Status: Assigned (was: Untriaged)
This is a bit hairy. There is some discussion online that you can just iterate through the entries of IODisplayConnect ... but ... on multi-GPU systems, that contains an entry for each GPU. When I do this: { CFMutableDictionaryRef match_dictionary = IOServiceMatching("IODisplayConnect"); io_iterator_t entry_iterator; if (IOServiceGetMatchingServices(kIOMasterPortDefault, match_dictionary, &entry_iterator) == kIOReturnSuccess) { base::mac::ScopedIOObject<io_registry_entry_t> entry; while (entry.reset(IOIteratorNext(entry_iterator)), entry) { base::ScopedCFTypeRef<CFDictionaryRef> display_info( IODisplayCreateInfoDictionary(entry, kIODisplayOnlyPreferredName)); if (!display_info) continue; UInt32 vendor_id = GetEntryProperty(entry, CFSTR("vendor-id")); UInt32 device_id = GetEntryProperty(entry, CFSTR("device-id")); printf(" Vendor:%x Product:%x\n", vendor_id, device_id); } IOObjectRelease(entry_iterator); } } I always get the currently active GPU last ... but I'm not sure how much I can trust that.