RFR: 8259825: Find a better way to detect Metal framework availability on system

Ajit Ghaisas aghaisas at openjdk.java.net
Tue Mar 9 14:00:22 UTC 2021


On Tue, 9 Mar 2021 12:18:23 GMT, Kevin Rushforth <kcr at openjdk.org> wrote:

>> **Issue :** 
>> In Lanai code-base, system profiler command was used to detect Metal framework availability. This implementation although works as expected, is slower.
>> 
>> **Fix :** 
>> I have replaced the logic that was using system profiler command with @available check for macOS Mojave (10.14)
>> 
>> **More Info :** 
>> https://support.apple.com/en-us/HT205073 - mentions the HW that supports Metal framework. It is practically difficult to detect HW and then decide whether Metal framework is supported or not.
>> Instead, it is appropriate to check for OS version that guarantees Metal framework availability.
>> Please refer - https://support.apple.com/en-us/HT208898 - It is mentioned in the first line @ this link that "macOS Mojave requires a graphics card that supports Metal"
>
> This only downside of this is that it will be no longer possible to run the Metal pipeline on macOS 10.13 systems. Since Apple no longer supports macOS 10.13, this is probably fine, but I recommend waiting to integrate this until @prrace approves it.

I have raised this PR now as a response to the review comment at https://github.com/openjdk/jdk/pull/2403#discussion_r572284716
I will wait for the consensus regarding the approach before integrating.

-------------

PR: https://git.openjdk.java.net/lanai/pull/212


More information about the lanai-dev mailing list