Neither a web browser, nor the iPhone are remotely comparable to a general purpose computer in terms of free use
As far as I’m aware you can’t do that with iOS devices (potentially including the AR ones).
Sure you can. You can fire up Xcode right now and build a self signed app to your phone with whatever the heck you want in it. Distributing that on the App Store is another story, but there's nothing stopping you from executing whatever arbitrary code you'd like on your own phone.
Try altering the iOS home screen behaviour, directly accessing the filesystem, writing your own device driver or tweaking the kernel. You certainly don't have "bare metal access" except by voiding your warranty and risking bricking your device by jailbreaking it, if there even is a jailbreak exploit that currently works on your device.