Optimising version for Apple Silicone Platforms

Just wonder what be the best approach to optimise Godot for Apple Silicone chips ,

I can compile and make template following instructions , but amount of source code looks a large a bit :slight_smile:

Main goal is remove this bloat, remove x86_64 which is slowing down element, and remove other render’s then metal , also aiming to Rendering - Device , Textures only reduce to what metal supports.

Some tips where to start to not completely destroy source code ?

This is categorically false. When you run an application made for these platforms, the Intel / x86 code is COMPLETELY ignored, and only the arm instructions are loaded. Removing them will barely have any impact at all on the final file size, and will have zero impact on performance what so ever, since these parts aren’t even loaded on an apple silicone system.

1 Like

in info.plist it had massive impact when removed those lines which are default for universal built from official website

<key>LSArchitecturePriority</key>
	<array>
		<string>arm64</string>
		<string>x86_64</string>
	</array>
	<key>LSMinimumSystemVersionByArchitecture</key>
	<dict>
		<key>arm64</key>
		<string>11.00</string>
		<key>x86_64</key>
		<string>10.12</string>
	</dict>

This is probably right for the wrong reason. The performance gain was likely because previous builds might have been forced to run the x86_64 version through a translation layer. That will indeed be slower than the arm version, but that doesn’t mean removing these things will make the game faster because you removed anything x86_64 related.

1 Like

ok thanks ,

currently I’m trying to make arm export templates but for some reason it’s failing .

I want only arm64 , but zip -r9 macos.zip macos_template.app after this step I’m going into Editor to install it and there is .tpz option is it something new ?

I’m honestly not sure about that one, I didn’t run into that just yet, but I’ll be doing some automated builds soon, I’ll let you know if I discover anything that might help!

1 Like

I’m just trying to understand a bit more why Godot provides universal version on Mac and not separate like Blender for Silicone and Intel Macs for official download .

Because when you compile 4.5.1 stable it states to use Metal 4.0 but it need include moltenvk ?

Let just assume someone wants create game that will be running only in Apple Ecosystem with Apple Silicone chips (arm64) , how should they optimise game to perform and looks good ?

@tibaverus
So I have recorded whole process probably I have missed something ,or is not clear enough to me .

All from compile editor arm64
template debug
release

trouble where I manually copy it into official storage as .tpz doesn’t have instruction how to create it .

Which folder should I run

zip -r9 macos.zip macos_template.app

in sourcecode/bin ?
or sourcecode/misc/dist/?

generate_bundle=yes makes -

godot_macos.zip
godot.macos.template_debug.arm64
godot.macos.template_release.arm64

only