Bitcoin-qt using 100% cpu on Mac #889

issue gavinandresen opened this issue on February 23, 2012
  1. gavinandresen commented at 8:28 PM on February 23, 2012: contributor

    Michael Gronager has figured out why:

    I now exit the ipc thread at startup by inserting:

    void ipcThread(void* parg) { ipcShutdown(); return; ...

    Bitcoin-Qt is now running nicely using around 0.9% CPU. So it seems like the culprit was indeed line 31:

    if(mq->timed_receive(&strBuf, sizeof(strBuf), nSize, nPriority, d))

  2. gavinandresen commented at 6:57 PM on February 24, 2012: contributor

    More research into what's going on:

    boost::interprocess is busy-waiting (at low priority), because it is emulating Posix functionality. See the comment is in boost/interprocess/detail/workaround.hpp : //Mac Os X >= Leopard defines _POSIX_THREAD_PROCESS_SHARED but does not seems to work.

    ... or google for "osx _POSIX_THREAD_PROCESS_SHARED"

    I'm still thinking about the best way to workaround this; having Bitcoin-Qt use 100% cpu whenever running will trigger too many bug reports to release it the way it is.

  3. gavinandresen referenced this in commit a2b31571f7 on Feb 24, 2012
  4. gavinandresen referenced this in commit dda60d4e57 on Feb 24, 2012
  5. gavinandresen closed this on Feb 27, 2012

  6. sje397 referenced this in commit b2a88315bb on Feb 28, 2012
  7. coblee referenced this in commit d1673ac84c on Jul 17, 2012
  8. destenson referenced this in commit 7b931e1e9d on Jun 26, 2016
  9. ptschip referenced this in commit 4dbd06a26f on Jan 7, 2018
  10. sipa referenced this in commit bdca9bcb6c on Apr 23, 2021
  11. rebroad referenced this in commit 6e13b4e771 on Jun 23, 2021
  12. DrahtBot locked this on Sep 8, 2021
Contributors

github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin/bitcoin. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2026-04-21 18:16 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me