superhighfives / pika

An open-source colour picker app for macOS
https://superhighfives.com/pika
MIT License
1.68k stars 55 forks source link

Memory consumption #115

Open Hydro8 opened 6 months ago

Hydro8 commented 6 months ago

Describe the bug On my Mac mini m2 8go, on sonoma, Pika seems to use a lot of memory. Now, it use 480mo of memory where shottr use 58mo and Spotify use 120mo.

image

Is it normal ?

thanks

superhighfives commented 5 months ago

Oooh, thanks for flagging @Hydro8. For me Pika is using 22mb. If you restart it, or your computer, does it drop down? Wondering if maybe there's a memory leak somewhere. 🤔

image
Hydro8 commented 5 months ago

I will retry tomorrow but I rebooted today and here the result :

IMG_1528

superhighfives commented 5 months ago

Hmmm, are you able to check the total memory PIka is using? Thanks for digging into this.

Hydro8 commented 5 months ago

This morning :

image

With Pika in the background.

Hydro8 commented 1 month ago

Hi Did you have time to look for this issue ? Thanks

superhighfives commented 1 month ago

I haven't been able to recreate it, unfortunately. I'll leave the issue open in case someone else comes across the same issue. Could you tell me a little more about your setup? Is there anything that seems to cause the memory usage to increase? What's the memory usage when you start the app, and how quickly does it increase?

Environment (please complete the following information):

Additional context Add any other context about the problem here.

Hydro8 commented 1 month ago

What is funny is that I reinstalled my mac many days ago and I still have this issue...

Here a gif to show you the usage after killing and restart the app :

CleanShot 2024-05-30 at 16 56 23

Environment (please complete the following information):

OS: Mac OS Sonoma App Version: Sonoma 14.5 Architecture: Mac Mini M2 8go ram

superhighfives commented 1 month ago

That is bananas. I've tried Pika on an M1 Mac, and an Intel. Same results:

image

Especially for it to start that high, it definitely seems like something is wrong.

If anyone has a better idea of how to benchmark this, I'd love to hear it. I'm afraid my knowledge of memory handling in Swift is pretty basic. I've tried looking for spikes or issues in the Xcode debugger, but it stays consistent, within expectations. I can't get it to push far past 80mb.

In the meantime, @Hydro8, you might be better off using something like https://www.sipapp.io/, https://colorslurp.com/, or https://contrasteapp.com/ I'm really sorry that I don't have a better answer for you.

Hydro8 commented 1 month ago

Thanks for taking the time to look into the issue. I really like your app so I'll continue to use it ;)