Re: Strange: Rosetta faster than M1


Glenn L. Austin
 

It's a bit unusual for emulated code to run faster, but not impossible.

Depending upon the operation, the order of execution could end up pre-loading values or accessing devices in such a way that the emulated code isn't blocked waiting for a device/memory while the non-emulated code has to wait.

-- 
Glenn L. Austin, Computer Wizard and Race Car Driver         <><
<http://www.austinsoft.com>


On Sep 19, 2022, at 5:21 AM, Tom Landrum <tomlandrum@...> wrote:

Perhaps something is cached from the first run?  Do you get the same results if you reverse the order?

Tom


On Sep 19, 2022, at 7:02 AM, Gerriet M. Denkmann <gerriet@...> wrote:

I have a simple C command line tool.

This takes 16 seconds when I run it in Xcode with “My Mac”.
But only 11 seconds when run with “My Mac (Rosetta)”

How can this be? 
I always assumed that emulating Intel-Code on a M1 must of course be slower than running native M1-Code directly.

Am I making some silly mistake?

Gerriet.










Join cocoa@apple-dev.groups.io to automatically receive all group messages.