Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. what is thread affinity
Forum Updated to NodeBB v4.3 + New Features

what is thread affinity

Scheduled Pinned Locked Moved Unsolved General and Desktop
5 Posts 3 Posters 1.4k Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • J Offline
    J Offline
    JadeN001
    wrote on last edited by
    #1

    I have read all about threadAffinity in Qtfrom all over google but i really do not understand what actually it is.what is meanning of "threadAffinity".please tell me based on your understanding.

    JonBJ 1 Reply Last reply
    0
    • J JadeN001

      I have read all about threadAffinity in Qtfrom all over google but i really do not understand what actually it is.what is meanning of "threadAffinity".please tell me based on your understanding.

      JonBJ Offline
      JonBJ Offline
      JonB
      wrote on last edited by JonB
      #2

      @JadeN001
      https://forum.qt.io/topic/58928/what-is-the-meaning-of-thread-affinity
      https://stackoverflow.com/questions/23931492/confusion-regarding-qthread-qobject-thread-affinity-and-event-loop
      https://en.wikipedia.org/wiki/Processor_affinity
      ?

      J 1 Reply Last reply
      2
      • JonBJ JonB

        @JadeN001
        https://forum.qt.io/topic/58928/what-is-the-meaning-of-thread-affinity
        https://stackoverflow.com/questions/23931492/confusion-regarding-qthread-qobject-thread-affinity-and-event-loop
        https://en.wikipedia.org/wiki/Processor_affinity
        ?

        J Offline
        J Offline
        JadeN001
        wrote on last edited by
        #3

        @JonB i already read all these link.but i don't understand its proper meaning.

        JonBJ 1 Reply Last reply
        0
        • J JadeN001

          @JonB i already read all these link.but i don't understand its proper meaning.

          JonBJ Offline
          JonBJ Offline
          JonB
          wrote on last edited by
          #4

          @JadeN001
          I thoguht https://forum.qt.io/topic/58928/what-is-the-meaning-of-thread-affinity/2 from @JKSH made it clear:

          If the receiver QObject has an affinity for Thread B, then the slot function runs in Thread B.
          You can change the QObject's thread affinity by calling QObject::moveToThread().

          It's a way of choosing which thread a QObject's slot functions run in.

          1 Reply Last reply
          5
          • mrjjM Offline
            mrjjM Offline
            mrjj
            Lifetime Qt Champion
            wrote on last edited by
            #5

            Hi
            If you think of affinity as "belongs to/run on/in that context" it might make more sense.

            1 Reply Last reply
            2

            • Login

            • Login or register to search.
            • First post
              Last post
            0
            • Categories
            • Recent
            • Tags
            • Popular
            • Users
            • Groups
            • Search
            • Get Qt Extensions
            • Unsolved