Skip to content

L6 (pre-release): latest nxnative, smooth on iPhone again, no long shader freezes, cache tidy-up (includes L4-L5)

Pre-release
Pre-release

Choose a tag to compare

@cheemu21 cheemu21 released this 16 Nov 16:32

Pre-release: source code only. No IPA and nothing from the game are attached or in the repository. Build your own from your own dump of the game (base game + update v131072) with the steps in the README, using the env file under "Build settings" below.

The Legend of Zelda: Ocarina of Time (Switch 2) as a native iPhone app, on top of nxnative.

L6 (includes L4 and L5)

Highlights

  • The latest nxnative engine again (61 changes): mesh-shader memory reworked so more foliage and geometry runs at once on the GPU, cheaper thread wake-ups, a fix for a GPU driver memory stall, and the movie player keeping its picture with the sound at 30 fps.
  • Smooth on iPhone again (L4). The render threads may claim at most half (the game's thread) and 30% (the others) of each frame on an iPhone, so the game's own threads keep the two fast cores: dropped frames fell from about 100 to 0-12 per 300 (logs 35 and 36).
  • The right brightness (L4): the upscaler no longer darkens the picture.
  • No more long freezes for new shaders (L5): a new pipeline gets at most 50 ms of a frame, then its object is skipped until it is built (freezes of up to 1 s before, log 36).
  • No black picture at some render scales (L5).
  • The shader cache cleans itself up (L6): the tidy-up now finishes even if you leave the app. On an iPhone 18 Pro it went from 186 files to 95 (log 42).
  • Frame generation costs less: about 2.7 ms per in-between frame on an iPhone 18 Pro (log 42).
  • A stall watchdog: if the picture stops for 5 s, the log records what each game thread waits for.
  • Dynamic Resolution stays off: measured, it costs this game more than it saves.

Build settings

DM_UPSCALER=metalfx
DM_FPS_HOLD=off
DM_THERMAL_CAP=0
DM_QOS_MAP=1
DM_QOS_EDGES=45,59
DM_NVN_GPUPROF=every:600
DM_BOOTPROF=1
DM_GUEST_FILE=1
DM_WAKE_UNLOCKED=0

DM_WAKE_UNLOCKED=0 keeps L5's guest thread wake-ups: with the new ones, an iPhone at 30 fps with frame generation hitched once a second after about a minute (log 42).

Status

  • First start: the phone rebuilds its shader cache for the new shaders (30-60 min, keep it plugged in); the second start tidies the cache for a few minutes.
  • iPhone 18 Pro, 30 fps with frame generation (log 44): no hitches in a 65 s test, which then froze; the watchdog is there to catch the next one.
  • Mac, cooled: a locked 60 fps (p95 16.8 ms).

Credits

Not affiliated with Nintendo.