-
Notifications
You must be signed in to change notification settings - Fork 160
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support macOS 13 #44
base: main
Are you sure you want to change the base?
Support macOS 13 #44
Conversation
Changed the 4 memory bandwiths to disk r/w and network i/o
Thanks for the PR. It’s finally working again! About the i/o bandwidth changes. I don’t think they belong in here. The focus on asitop was entirely on the SoC and IMO, I think it should stay that way. Nothing wrong with removing the bandwidth section entirely. BTW, not related to this but it seems like it’s underreporting power usage by about 5 watts or Ventura is being more power efficient. I can create a consistent load and it used to use up 7w. Now it’s down to 2w. |
Good point! But what do you think should belong here? Those are as far as I can get. Looking for ideas!
I indeed made some changes to that. The 🤔What does
Your GPU load is high, that's correct; but its frequency is very low --- The lowest frequency, as far as I know. So maybe it's normal that its power consumption is low. BTW, I remember seeing something like 6MHz or 9MHz GPU on macOS 12. However, on macOS13 the |
I wouldn’t mind if the section was removed entirely. Bandwidth was really useful and I’m sad to see it go but a possible replacement could be a swap memory graph. It would be in the perfect spot under memory. It shouldn’t be that big though since I seldom swap, lol. but it seems like it could be useful extension of the memory even though it’s not related to the SoC.
Package power I think included the memory controller. Possibly other components but I’m not certain. Combined power sums up cpu, gpu and ane according to powermetrics output.
asitop often shows the “Package Power” being lower than CPU Power. They don’t add up so I don’t think it’s only because of the change to
That makes sense. I know Activity Monitor can be misleading but the discrepancy between Activity Monitor and asitop was never to this degree. |
Just wanted to pipe up as a user, unsolicited; the memory bandwidth area was quite useful, particularly for gaining some visibility into what the media engine is up to. Understand if it goes away based on reading here, but it would be nice if there is some other way to peek into media engine usage in particular. |
Temporary files in /tmp not being deleted on start up. Get the error on startup: rm: "/tmp/asitop_powermetrics1666643878": No such file or directory |
Well, that’s a little problem. I changed os.rmfile to subprocess.Popen(“sudo rm …”) so that you can run asitop without sudo. This makes debugging easier. But I don’t think it means that the files are not being deleted; it means that they have already been deleted by the OS (I guess).
Temporary files in /tmp not being deleted on start up. Get the error on startup:
rm: "/tmp/asitop_powermetrics1666643878": No such file or directory
rm: "/tmp/asitop_powermetrics1666646351": No such file or directory
rm: "/tmp/asitop_powermetrics1666646428": No such file or directory
—Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you authored the thread.Message ID: ***@***.***>
|
Noted the change made and yes definitely makes debugging easier but checked the directory:
Tried on my MBA and MSU and I get the same results after the first execution. Tried the following fix which seems to work:
|
I think you are spot on. I now have the suspicion that powermetrics never really reported the actual package power (as in, SoC power), in the old versions it was CPU+GPU+ANE+DRAM but it was still missing the power usage of the interconnect and other processors. So they probably renamed it to make it less confusing. Rather annoying that they dropped the DRAM info at the same time, that was really useful. |
I have a genius (stupid) idea. Can we use the powermetrics binary from macOS 12 directly on macOS 13? Are all the system calls still there?
|
Now fixed. |
This never happened to me. The code for |
cpu_metric_dict["cpu_W"] = cpu_metrics["cpu_energy"]/1000 | ||
cpu_metric_dict["gpu_W"] = cpu_metrics["gpu_energy"]/1000 | ||
cpu_metric_dict["package_W"] = cpu_metrics["package_energy"]/1000 | ||
cpu_metric_dict["package_W"] = cpu_metrics["combined_power"]/1000 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
combined_power
is not a direct replacement for package_energy
. This is why I was getting bad “Package power” readings.
cpu/gpu/ane _energy has to be added manually to get the combined_energy
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Well, according to (command-line invoked) powermetrics, combined_energy IS cpu+gpu+ane.
This actually works. I assumed it wouldn’t and didn’t try until I was informed by someone who actually tried it. So, if you have a copy of Monterey, you can copy it over to Ventura. What I did was rename it to It’s not something that can be included with asitop so it’s something you have to fix locally. |
Wow!
I think we can let asitop download that thing automatically. macOS 12 won’t change anymore, so powermetrics would be in a fixed position in the recovery image I guess. Would that be possible?
|
Well, most importantly, are memory bandwidths available?
|
The license isn't compatible and it can’t be hosted on GitHub. And yes, memory bandwidth is working again. |
Yeah but I think it's ok to download it from apple. We can write the script to download from Apple. |
Thats kinda amazing, Windows users can only wish! Maybe a cli flag could be added to invoke a custom |
Hi there - it seems googling for I figure until it gets merged/fixed and someone still wants to run/test
|
Can we merge this in? |
@SuperKenVery |
Yeah powermetrics runs but doesn’t report memory bandwidth anymore, at least on my machine. One of our ideas is to run macOS 12’s powermetrics on macOS 13 but I haven’t had time to verify/work on that. 发自我的 iPhone在 2022年12月10日,22:40,nlgtuankiet ***@***.***> 写道:
@SuperKenVery
FYI I can invoke the sudo powermetrics on my local machine running Ventura without any issue.
I didn't download anything. My Ventura is upgraded from Monterey.
And please keep the memory bandwidth or make a command line args for replacing the memory bandwidth with disk bandwidth.
—Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you were mentioned.Message ID: ***@***.***>
|
Please, something is better than nothing.
@SuperKenVery any other blocker? can we merge this? |
The author doesn't seem to love my approach and removed the bandwidth chart altogether. Now it supports all the way up to macOS 15 so this PR isn't needed anymore. BTW the author doesn't seem to be very active :D And it's not me who decide to merge this, it's the author of this repo (tlkh). I would have merged it two years ago if I could lol |
I changed the bandwidths to disk r/w and network i/o.
I think those are more useful, and they avoided the problem that bandwiths are not available on macOS 13.