OpenCL/Metal Rendering on Intel GPUs Works !

Fractal Architect version 4.5.0 submitted to Apple today (Dec 14, 2016) makes it possible to use either OpenCL or Metal GPU rendering with Intel processors.  This capability requires Mac OS Sierra.

With Mac OS Sierra, it seems that all Intel CPUs (2013 and later) having Intel HD, Intel Iris, or Intel Iris Pro GPUS can now take advantage of either OpenCL or Metal  rendering for HUGE speed increases. For example, a 2013 MacBook Air gets approx. a 9x speed increase !  That is like a baby going from crawling to Olympic sprinting.

On Macbook Pros and iMacs having both a discrete AMD GPU and an Intel processor with its integrated GPU, you can use both GPUs together for rendering. This gives you almost twice the rendering speed !

Thank you Apple for giving us great OpenCL and Metal drivers on Mac OS Sierra !!

Note: Older versions of Mac OS and Macs produced in 2012 or earlier may have compatibility problems. (But CPU rendering works fine.)

Mac OS Sierra and GPU Rendering

Now that it is release day, how does Sierra handle GPU rendering using Fractal Architect 4 ?

Fractal Architect is a hard core test for GPU compute drivers and seems to the best test tool available for GPU vendors to evaluate the quality of their driver/runtime APIs.

We tested with 5 different Mac configurations, and this is what we found (over 100 different Mac configurations have been released by Apple that have Metal/OpenCL compatible GPUs).

Evaluating Sierra Before Updating to It

You should evaluate Sierra with your favorite apps before committing to a full upgrade.

Doing a full Time Machine backup before doing a full upgrade is a very good idea. There is no easy way back to El Capitan, once you have committed to a full upgrade

You can install Sierra on to an external hard drive and then boot off that external hard drive to try it out. I recommend using a Samsung T3 Portable Flash SSD drive because of its great performance. Traditional external hard drives can be painfully slow.

Metal Rendering

Metal rendering on recent Intel GPUs works very well. Render speed on Intel Iris Pro close to that of AMD GPU on 2015 Macbook Pro.

2013 and earlier Intel GPUs have a compile problem  on Sierra, but not on El Capitan. 

If you only have a Intel GPU in your Mac, you will want to evaluate Sierra first (before upgrading to it), to see if your Intel GPU is compatible with Metal rendering

Metal rendering on AMD GPUs is much faster on Sierra than El Capitan.

Metal rendering on older 2012 Nvidia GPU works. Other years Nvidia GPUs were not tested.

OpenCL Rendering

OpenCL on older Nvidia and AMD GPUs works (unlike El Capitan where they were broken). On more recent GPUs, OpenCL works about the same as in El Capitan.

OpenCL on Intel GPUs still broken – but of course Metal can now be used on more recent Intel GPUs.

CUDA Rendering on Nvidia GPUs

CUDA does not work on any sandboxed app sold through the Mac App Store. Fractal Architect 4-CUDA adds CUDA as an alternate rendering platform. (It was written for users affected by the horrible Nvidia OpenCL drivers released with Mac OS El Capitan.)

Bad News for Sierra: Nvidia has not yet released usable CUDA drivers for Sierra. Stay on El Capitan if you need CUDA support.

Dual Metal GPU Rendering on 2015 Macbook Pro

For a laptop to offer dual GPU rendering, this is a big deal. You can render on both the AMD and Intel Iris Pro GPUs at the same time.

You could do this too on El Capitan, but the AMD Metal drivers are much faster on Sierra.

Dual Metal GPU Rendering on 2013 Mac Pro

This works very well.  Rendering video animations on this Mac is very fast.

Dual OpenCL rendering is not recommended due to a critical kernel dispatching bug present in recent versions of Mac OS. (Metal does not have this bug.)

Score:  Kickass with Caveats

Apple has clearly made a big effort to improve the Metal compute drivers for Sierra. OpenCL drivers (which had so many issues in EL Capitan) now seem to work as well as they did with Mac OS Yosemite.

Apple engineers actually found the cause of a bug preventing Metal rendering from working on Intel GPUs. We found the cause of a core bug in Metal preventing Metal Rendering on AMD/Nvidia. Hopefully, this collaboration can continue so Apple can achieve 100% rock solid GPU compute platform across all of its Mac configurations.

Probably 90% of Macs released in the last 3 years can now  use GPU rendering –( that is a guesstimate since we have no means to actually test 100 different Mac model configurations). This is a huge improvement over the El Capitan release, when we estimated then that only 30% of Macs could use GPU rendering.

We found issues on Sierra only with older Intel GPUs (i.e. 2013 Macbook Air). Workaround: Stay on El Capitan for now.

Intel CPU rendering has always worked. But when you can get 10x  faster rendering on a laptop with Metal, who wants to use CPU rendering ?

Meeting with Matt Feemster

Matt Feemster is the author of Fractorium, a GPU accelerated flame fractal renderer for Windows and Ubuntu Linux.

My son and I attended Nvidia’s CUDA conference and got to meet Matt since he lives in the Bay Area too.

The 3 Amigos – the only people on Planet Earth that have released apps that support GPU flame fractal rendering to date.

Left: Steven Brodhead Jr   – author of Flam4
Center: Steven Brodhead – author of Fractal Architect
Right: Matt Feemster         – author of Fractorium

img_1876

Fractal Architect 4 Version 4.4 – Metal Rendering on AMD + Nvidia

This release is almost ready.

I figured out how to workaround a key Apple Metal bug and now Metal rendering works on AMD and Nvidia GPUs too! With Mac OS Sierra, the Metal rendering has great performance.

Metal can render on 2 GPUs at the same time. For instance, the 2013 Mac Pro with its twin GPUs renders almost twice as fast.

You can also combine rendering using both Intel Iris Pro and AMD GPUs on a 2015 Macbook Pro. Tested on Mac OS El Capitan 10.11.6.

Both GPUs: 159.75 Mips      8.5X
AMD:                93.14 Mips       4.9X
Intel Iris Pro: 84.64 Mips       4.5X
CUP (4 core): 18.84 Mips      1X

Bug Fix: Fixed image gamma for Resume renders (restart render to add higher quality)

Metal Rendering on Intel, AMD, & Nvidia GPUs Works!

Sierra Metal is Working Well on AMD and Nvidia

With Sierra coming out shortly, Metal renders can be made on all 3 GPU platforms: Intel, AMD, and Nvidia using Fractal Architect 4 version 4.4.0.

Apple has done a very good job on the Sierra release. In general, Metal is working well, and for some older GPUs, OpenCL rendering now works again (El Capitan’s OpenCL drivers were so broken).

Both Mac OS El Capitan and Sierra support Metal rendering, but the quality of the Metal drivers varies depends on the specific GPU configuration and OS version used.

For example, on Sierra the AMD drivers are much faster than on El Capitan.

On 2013 Mac Pro, with 2 AMD GPUs, you can use both GPUs for even more speed using Metal (but OpenCL driver has a critical bug preventing usage of more than 1 GPU).

Warning – Sierra Metal may not work on your GPU

On El Capitan, my 2013 Macbook Air renders 10.5 X faster than CPU. On Sierra, the Metal compiler cannot compile the app’s kernels on the 2013 Macbook Air, resulting in no GPU rendering at all !

But 2015 Intel Iris Pro in Macbook Pro works great with Metal !

Evaluating Sierra First

Since GPU compatibility is so hit and miss, I recommend installing Sierra first on an external hard drive and trying it out on your Mac(s).

You boot off that external drive by holding down the Option key at boot and select the external drive from the list shown at boot time.

Since normal hard drives are so SLOW, I recommend the following external drive: Samsung 250 GB T3 Portable SSD. This has worked very well for me, and the cost is reasonable.

Evaluate both OpenCL and Metal

Apple’s OpenCL drivers have been very good on AMD GPUs, but don’t work at all on Intel GPUs. But that OpenCL on AMD, may be faster than Metal on AMD. So remember to try both to see what works better.

Intel GPU Rendering now works on all Macs since 2012

This is BIG News !

Fractal Architect 4  now fully supports Metal GPU rendering on all Macs built since 2012 (using the Mac’s Intel GPU). Version 4.3.3 of FA 4 has some critical fixes.

Last October, we reported issues with Metal rendering. Those issues have been resolved in version 4.3.3 of Fractal Architect 4.

With the latest Sierra Beta, OpenCL GPU rendering now works on Intel GPUs for the first time too.

The rendering performance increase is HUGE.

El Capitan 10.11.6  Performance using Intel Metal

2013 Macbook Air     10.5 X faster than CPU
2015 Macbook Pro      4.8 X faster than CPU

Deep Chains on top of Brokat3D

Andreas Maschke’s Brokat3D script is a great script to create a very beautiful type of fractal that resembles cloth brocade patterns.

With FA4, you can create a Variant script list that is applied to every fractal created by the main script.

Lets see what this Variant script list does on top of the Brokat3D main script:

  • prependNewPreGroup
  • addPreLinear
  • prependNewPreGroup
  • addPreLoonie

A script list is a list of 1 or more variant scripts that will all be applied (in order) to the fractals created by the main script.

The script list is easily created by simply selecting a script in the table and clicking the Add script to List button.

This script list randomly adds (66% chance) 2 Pre variation groups to some of the transforms created by the main script.

You can see that the Deep chain approach, using Variant script lists, is a simple, easy way to get exciting new fractals based on other random fractal creation scripts.

Power of Lua Variant Script Lists

Its so easy to explore Deep variation chains, by using a Custom Lua script list.

Pick a handful of variant scripts and just add them to the Script list. The variant scripts will be run from top-to-bottom.

To add a script to the list, select the script name to add, then click the Add Selected Script to List button.

See how I have created a list of 7 scripts to apply to every fractal produced by the main Lua script.

You will be amazed how powerful this technique is.

ScriptList

The coup-de-grace is to add a randomizeChains script to the end of the list. This script scrambles the variation group chain and can find some really different fractals.

With this fractal:

Standard
Standard

I ran some variants using Color gradient and the randomizeChains script. Result:

randChains

Matrix Variations

Matrix variations work just like ordinary transform Pre and Post transformation matrixes. They allow you to avoid linked transforms. Linked transforms require special Xaos matrix configuration, which is so easy to mess up in practice.

Special Support in Triangle Editor

If you select Variation for Which Matrix, and select the matrix variation instance in the Variations table, you can manipulate the Triangle representing that matrix variation.

Matrix Variation Types

  • matrix2d – embed in its own group
  • pre_matrix2d – embed in group containing other variations
  • post_matrix2d – embed in group containing other variations

For 3D variation sets, these are available:

  • matrix3d, pre_matrix3d, post_matrix3d

No special transform editing support in the Triangle editor  is available yet for the 3D matrix variations.

The best way to use matrix2d variations is to embed them in their own variation group and insert them between two other variation groups.

Example

As you can see in this image, the second transform has a chain of 5 variation groups.

The Post #1 group has a transformation Matrix variation, matrix2d.

Note how the Triangle editor allows you to manipulate that matrix variation just like a standard Pre or Post transformation matrix.

Using these inline transform matrixes is so much simpler, than traditional linked transforms.

MatrixVarExample

Standard
Standard

Fractaling Across the Universe