Replace QMetaObject::invokeMethod with atomic operations #127

pull hebasto wants to merge 1 commits into bitcoin-core:master from hebasto:201102-queued changing 2 files +6 −9
  1. hebasto commented at 1:29 PM on November 2, 2020: member

    No need to read/write a data member in one thread if it is atomic.

  2. promag commented at 9:21 PM on November 2, 2020: contributor

    An atomic bool would be enough?

    Didn't want to mess with this in #120 because I think ballon filtering doesn't belong in transaction model. IMO the right place should be aware of what wallets are open.

  3. qt: Replace QMetaObject::invokeMethod with atomic operations 6501bb3bdc
  4. hebasto force-pushed on Nov 7, 2020
  5. hebasto commented at 11:29 AM on November 7, 2020: member

    @promag

    An atomic bool would be enough?

    You're right. Reworked.

  6. hebasto renamed this:
    Replace QMetaObject::invokeMethod with Mutex locking
    Replace QMetaObject::invokeMethod with atomic operations
    on Nov 7, 2020
  7. promag commented at 8:53 AM on November 12, 2020: contributor

    This doesn't work: setProcessingQueuedTransactions needs to be enqueued and proceed in between transaction notifications.

  8. hebasto commented at 8:57 AM on November 12, 2020: member

    This doesn't work: setProcessingQueuedTransactions needs to be enqueued and proceed in between transaction notifications.

    Why?

  9. promag commented at 9:00 AM on November 12, 2020: contributor

    Transaction notifications are enqueued in TransactionNotification::invoke and by the time they are processed setProcessingQueuedTransactions(false) was already called.

  10. hebasto commented at 9:22 AM on November 12, 2020: member

    You mean that setProcessingQueuedTransactions must be placed into the same event queue as updateTransaction, i.e., coordinated?

  11. hebasto closed this on Nov 12, 2020

  12. promag commented at 9:27 AM on November 12, 2020: contributor

    @hebasto yes, processingQueuedTransactions() value is worthless.

  13. bitcoin-core locked this on Feb 15, 2022
Contributors

github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin-core/gui. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2026-05-01 13:20 UTC

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