5 comments

  • trueno15 hours ago
    interesting. id love an eclecticlight breakdown of this. they&#x27;re one of the few if only that write anything worth reading on apple hardware, i once found a QOS&#x2F;scheduler insight through those guys when I couldn&#x27;t get my c&#x2F;cpp project pinned to the cores I wanted on m-series. <a href="https:&#x2F;&#x2F;eclecticlight.co&#x2F;m1-macs&#x2F;" rel="nofollow">https:&#x2F;&#x2F;eclecticlight.co&#x2F;m1-macs&#x2F;</a>
    • saagarjha9 hours ago
      He doesn’t read code. Convert it to some log messages and he might explore it.
  • poige7 hours ago
    Darwin had bunch of schedulers except this one: dualq, multiq, etc<p>In fact here&#x27;s the one used in Sonoma: sysctl kern.sched -&gt; edge<p>which seems to be an extension over &quot;clutch&quot;:<p><a href="https:&#x2F;&#x2F;github.com&#x2F;apple-oss-distributions&#x2F;xnu&#x2F;blob&#x2F;main&#x2F;osfmk&#x2F;kern&#x2F;sched.h#L197" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;apple-oss-distributions&#x2F;xnu&#x2F;blob&#x2F;main&#x2F;osf...</a><p>&quot;… Single-cluster, symmetric (SMP) systems can run with just the Clutch policy, but multi-cluster, asymmetric (AMP) systems must further enable the Edge policy extension to Clutch in order to manage scheduling across the multiple CPU clusters. …&quot;
  • cadamsdotcom15 hours ago
    &gt; The XNU kernel runs on a variety of platforms<p>This is fascinating, would love to know where it’s used! (Besides macOS)
    • csb615 hours ago
      I believe it means Apple&#x27;s other hardware platforms (phones, tablets, smart TVs, VR headsets, smartwatches)
    • LoganDark13 hours ago
      It&#x27;s used in iOS as well. iOS runs in some unexpected places, like for example Studio Display. Also, the Apple Lightning Digital AV Adapter runs Darwin (because RTKit didn&#x27;t exist yet).
      • asimovDev1 hour ago
        that lightning AV adapter is crazy, iirc it creates an ethernet connection to airplay the display to the device
      • nxobject9 hours ago
        And touchbars too, strangely enough.
        • LoganDark9 hours ago
          For Intel platforms, the Touch Bar is driven by the trusted coprocessor (T1&#x2F;T2), but that itself runs bridgeOS which indeed is Darwin&#x2F;watchOS-based. With Apple Silicon I don&#x27;t know if bridgeOS is still used; the SEP runs an L4.
    • internet20009 hours ago
      All of Apple&#x27;s platforms.
    • electronsoup15 hours ago
      Perhaps they mean ISAs
      • xphos14 hours ago
        Well x86 at one point, arm both the 32 and 64 bit versions. I think they had RISCV support in their source tree at one point but not really at a commercial level. It does cover a lot different levels of hardware though
        • skissane8 hours ago
          Does Apple use macOS in servers in its datacentres? Or are they all Linux?<p>Surely at a minimum they need macOS for CI.<p>Apple does have one advantage here-they can legally grant themselves permission to run macOS internally on non-Apple hardware, and I don’t believe doing so legally obliges them to extend the same allowance to their customers.<p>But that might give them a reason to keep x86_64 alive for internal use, since that platform (still) gives you more options for server-class hardware than ARM does
          • jabwd4 hours ago
            They do run Apple Silicon in data centers, so perhaps another custom version of Darwin + their system frameworks. It is hard to tell without some leaks :)
          • therein4 hours ago
            They use Ubuntu on x86-64 servers, at least for iCloud. Backends for iCloud, Photos and Backups etc. are written in Java.
            • Longhanks1 hour ago
              Any sources or more information on that?
        • userbinator9 hours ago
          Which Apple products run arm32 XNU? Their first Apple Silicon CPUs were already arm64.
          • dagmx7 hours ago
            Well there were still the historical arm32 chips in their iOS devices, but until recently the watches were a cursed arm64_32 (or something like that) which is arm64 with 32 bit pointers iirc.
        • wiml13 hours ago
          PPC32&#x2F;64 of course, and for a long time Darwin still contained remnants of its predecessor&#x27;s support for SPARC, PA-RISC, and m68k.
        • kjs312 hours ago
          Is mc68k or PPC still in there anywhere?
          • monocasa10 hours ago
            I&#x27;m sure there&#x27;s vestiges of them somewhere, but the underlying support (the architecture specific parts of the mach portion of the kernel) is gone for those archs.
      • LoganDark13 hours ago
        IIRC, Apple uses &#x27;platform&#x27; to refer to an SoC integration. For example, M1, M2 and etc. are separate platforms. M5 in Vision Pro is a separate platform than M5 in MacBook Pro. I believe Apple&#x27;s XNU does somewhat still support non-Apple Silicon as well though.
        • fragmede13 hours ago
          Yeah they&#x27;re was that whole x86 thing thru did for quite a while.
          • simonh2 hours ago
            Twice, on the basis that NEXT used the same kernel and that ran on 68k and Intel when Apple bought them and later ported it for Power PC. When Steve Jobs went back to Apple, for a long time he ran NEXT on a Thinkpad.
  • almoni15 hours ago
    Does this contribute to macOS&#x27;s suitability for DAW applications or is that more the baked in low-latency audio drivers?
    • dcrazy13 hours ago
      Audio actually runs on a dedicated realtime thread. This used to be scheduled differently, but nowadays it might be implemented by the FIXPRI bucket described in this document.
    • bigyabai14 hours ago
      CoreAudio probably deserves most of the credit, there. Similar ASIO-style solutions like JACK, DirectSound and now Pipewire hit the sub-30ms mark without any big scheduler tweaks.
      • lukeh8 hours ago
        IOKit was designed to support CoreAudio from the start, cc gvdl.
  • MarginalGainz2 hours ago
    [dead]