marcan changed the topic of #asahi to: Asahi Linux: porting Linux to Apple Silicon macs | General project discussion | GitHub: https://alx.sh/g | Wiki: https://alx.sh/w | Topics: #asahi-dev #asahi-re #asahi-gpu #asahi-offtopic | Keep things on topic | Logs: https://alx.sh/l/asahi
BaughnLogBot has joined #asahi
BaughnLogBot has quit [Client Quit]
BaughnLogBot has joined #asahi
BaughnLogBot has quit [Quit: ZNC 1.6.2+deb1 - http://znc.in]
<Glanzmann>
When I close the lid on my macbook air, I assume macos destages the RAM to the NVMe in order to save battery on memory consumption, is that true? I assume that is the reason it can stay like forever on 'standby' without drawing battery?
Bublik has quit [Ping timeout: 256 seconds]
Bublik has joined #asahi
<mjg59>
Glanzmann: Memory in self refresh takes very little power
VinDuv has joined #asahi
<Glanzmann>
mjg59: I didn't know. I see.
<mjg59>
Glanzmann: If you only get something like ~3GB/sec, it'd take ~5 seconds to restore RAM from NVMe
<mjg59>
(Actually more than that, because if you've powered down RAM you're going to need to go through firmware and start a bootloader that's able to start restoring that image and there's probably going to be some relocation involved as well)
<mjg59>
Pushing RAM out to non-volatile storage is great if you're expecting to be asleep for an extended period of time, but in general this is implemented by suspending to RAM (and keeping the RAM in self refresh) and then setting a wakeup timer for some point in the future, and if that goes off then suspending to storage instead
<bkero>
It's also great if you need a lot of RAM. What's the price of 1TB DRAM versus 1TB NVMe or whatever Intel's thing is called again
<bkero>
Optane Persistent Memory
<bkero>
...that's probably not very relevant to these machine sthough
maor26 has joined #asahi
amw has joined #asahi
<mats>
didnt intel kill that product line recently?
<mats>
ah just the consumer lines
M0_osx[m] is now known as osxre
osxre is now known as M0_osx[m]
ephe_meral has joined #asahi
amw has quit [Ping timeout: 246 seconds]
bisko has quit [Ping timeout: 240 seconds]
redbluescreen[m] has quit [Quit: Idle for 30+ days]
rockinrobstar[m] has quit [Quit: Idle for 30+ days]
crafteck[m] has quit [Quit: Idle for 30+ days]
ifthenelse has joined #asahi
Lumi[m] has quit [Quit: issued !quit command]
TheJollyRoger has quit [Remote host closed the connection]
TheJollyRoger has joined #asahi
bisko has joined #asahi
<Glanzmann>
~
<Glanzmann>
mjg59: Yes, makes sense. I also benchmarked the nvme speed on macbook and it seems to be like 3 gb/s for linear read with large block/page size.
<Glanzmann>
And the macbook is always instead on, at least it feels that way.
<Glanzmann>
About marcan serial cable, is there a part list yet that I can order in order to assemble one?
<Glanzmann>
I think there was alread one in the wiki, wasn't it?
<Glanzmann>
unignore 1
amw has joined #asahi
<marcan>
Glanzmann: not yet, not for the new one
<marcan>
for the old one, you can cobble it together from a FUSB302, an arduino, some kind of 1.2V serial interface, and a USB-C breakout board
<j`ey>
marcan: is the diagram you posted enough to start on schematics? or is there more design left
<marcan>
mostly just narrowing down specific parts, but I can start on part of the schematics already
<marcan>
the big parts to choose are STM32, muxes (and exact layout, could be one or two chained), and USB hub
amw has quit [Ping timeout: 256 seconds]
<j`ey>
marcan: what is the hub for?
<j`ey>
(I havent watched the stream (yet))
<marcan>
so upstream can talk to both the mac target, and the stm32
<marcan>
potentially up to two ports on the mac target
<j`ey>
ah
<marcan>
and a fourth, different port if you use it as a chromebook suzy cable
<marcan>
(which, since 4-port hubs are standard, makes sense to do)
ephe_meral has quit [Ping timeout: 246 seconds]
ephe_meral has joined #asahi
bisko_ has joined #asahi
bisko has quit [Read error: Connection reset by peer]
xarkes has quit [Ping timeout: 240 seconds]
xarkes has joined #asahi
<Glanzmann>
marcan: I see.
JTL has quit [Ping timeout: 246 seconds]
JTL has joined #asahi
ephe_meral has quit [Ping timeout: 246 seconds]
bisko_ has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
xarkes has quit [Ping timeout: 264 seconds]
xarkes has joined #asahi
nebh^ has quit []
<never_released>
Data Units Written: 35,121,211 [17.9 TB]
<never_released>
macOS continuing to be macOS
<never_released>
sigh
<never_released>
800GB/day
<davidrysk[m]>
never_released: is it primarily kernel_task that's doing it?
<marcan>
davidrysk[m]: btw, did you see that tweet I RTed?
<davidrysk[m]>
I'm at 461.80GB of kernel_task writing in 20h29m of uptime
<marcan>
of the guy with the same volume as you, but a 256GB SSD
<davidrysk[m]>
yep
<davidrysk[m]>
wonder what typical uptimes are
<davidrysk[m]>
never_released: do you avoid rebooting?
<arnd>
I wonder if you can move the swap file to an external ssd to see if the remaining I/O within the expected range
<arnd>
I tried to see what it's actually doing, but I don't seem to have permissions to run iosnoop
<delroth>
I wonder how much of the "kernel_task is writing a lot of data" is swapping vs. bad accounting :)
<delroth>
e.g. syncs being accounted to kernel_task for some reason
<luca020400>
does mac os x has something zram like?
<marcan>
it does
<luca020400>
and it concurrently does swap to disk?
<marcan>
I'm not entirely sure what the logic is
<luca020400>
interesting, I've never had a setup with both
xarkes has quit [Ping timeout: 260 seconds]
<never_released>
davidrysk[m]: yeah I don't reboot all the time
<never_released>
just on OS updates mostly
<davidrysk[m]>
my hypothesis is that there's something leak-like that causes the problem to happen after 24-48h of uptime
<never_released>
luca020400: WKdm
<davidrysk[m]>
at 517.16GB written now
<never_released>
aka page-level compression
<never_released>
it's done through a CPU extension
<never_released>
but XNU has an implementation using regular assembly
<davidrysk[m]>
55.36GB in 26 minutes
<davidrysk[m]>
is 100GBW per hour excessive?
<never_released>
davidrysk[m]: kernel_task is at 4.05TB here
<never_released>
yes it is
<never_released>
very excessive
<davidrysk[m]>
I thought so :)
<never_released>
inb4 iOS has this bug too
<never_released>
who knows
<davidrysk[m]>
I thought iOS doesn't swap
<davidrysk[m]>
but freezes processes instead
<never_released>
no swap doesn't mean that file-backed mappings can't cause issues like this one
<davidrysk[m]>
no backing store so there's no paging
<davidrysk[m]>
never_released: can you try `sudo zprint`?
<davidrysk[m]>
I can't get it to work (but I do have security on)
<never_released>
davidrysk[m]: SIP on here
<never_released>
zprint only works with SIP off
<davidrysk[m]>
ahhhh
<davidrysk[m]>
it's SIP that blocks it? okay
<davidrysk[m]>
guess I'll have to turn SIP off
<davidrysk[m]>
I was going to make a script that captures zprint output every minute or so
<davidrysk[m]>
and then look for a leak
<never_released>
not a good idea generally
<davidrysk[m]>
oh I know the downsides of turning off SIP
<never_released>
you have vm_stat, davidrysk[m]
<davidrysk[m]>
not too worried about that... what I'm not doing is amfi_get_out_of_my_way=1 because that breaks a lot of things
<davidrysk[m]>
vm_stat doesn't give enough detail
<davidrysk[m]>
though zprint might not either
<never_released>
amfi_get_out_of_my_way is a bad idea in general
xarkes has joined #asahi
macc24 has joined #asahi
<davidrysk[m]>
already at 536.05GB
<never_released>
it's nuts
<davidrysk[m]>
so yeah, 100GBW per hour
<davidrysk[m]>
and I'm only looking at kernel_task's writes
<davidrysk[m]>
how dangerous is it to turn off swap with bootargs?
<luca020400>
never_released: thanks, headers explains enough to understand what it does
mndza has quit [Read error: Connection reset by peer]
mndza has joined #asahi
Helikoptere has joined #asahi
<davidrysk[m]>
never_released: do you use little snitch or blockblock?
<Glanzmann>
Does someone know if macos runs in parallels or the macos hypervisor on m1?
<davidrysk[m]>
Glanzmann: it doesn't
<Glanzmann>
I see.
odmir has quit [Remote host closed the connection]
bisko has joined #asahi
odmir has joined #asahi
<davidrysk[m]>
parallels or the hypervisor would have to support the peripherals needed for it (or well, enough of them)
odmir has quit []
jato_ is now known as jato
ephe_meral has joined #asahi
odmir has joined #asahi
ephe_meral has quit [Ping timeout: 272 seconds]
ephe_meral has joined #asahi
Mrmaxmeier has quit [Remote host closed the connection]
mndza has quit [Ping timeout: 260 seconds]
vimal has joined #asahi
VinDuv has joined #asahi
<Glanzmann>
davidrysk[m]: Of course, writing device simulators without documentation is almost the same problem we have. :-)
vimal has quit [Remote host closed the connection]
raster has joined #asahi
<davidrysk[m]>
I have parallels running a Windows 10 VM with 4GB of allocated RAM and the kernel_task memory usage is rapidly increasing
arekm has quit [Ping timeout: 264 seconds]
arekm has joined #asahi
mndza has joined #asahi
<Glanzmann>
Any idea what this paging is about?
<Glanzmann>
Last time I heard about a unix paging without memory pressure, is when there wasn't MMU and process was paged to the disk on cotext switch. :-)
bisko has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<modwizcode>
It's interesting that apple has (in addition to their generic Hypervisor acceleration extension framework) a second API just for easily bootstrapping Linux VMs, but it's specific to Linux VMs.
Namidairo has quit [Read error: Connection reset by peer]
Namidairo has joined #asahi
<never_released>
modwizcode: in past versions, had some entry points for macOS ones
<never_released>
but seems to be gone for now
mndza has quit [Ping timeout: 240 seconds]
vimal has joined #asahi
<modwizcode>
interesting
ephe_meral has quit [Ping timeout: 272 seconds]
vimal has quit [Ping timeout: 272 seconds]
vimal has joined #asahi
ephe_meral has joined #asahi
odmir has quit []
brandas[m] has joined #asahi
<davidrysk[m]>
modwizcode: are you talking about Virtualization.framework?