Uploaded image for project: 'Qpid Dispatch'
  1. Qpid Dispatch
  2. DISPATCH-2134

qdr_link_process_initial_delivery_CT race clearing link pointer

Agile BoardAttach filesAttach ScreenshotAdd voteVotersWatch issueWatchersCreate sub-taskLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    Description

      TSAN detects a race between an I/O thread clearing a deliveries' safe pointer to its owning link while the core thread is setting the same safe pointer
       

      70: WARNING: ThreadSanitizer: data race (pid=644088) 
      70: Write of size 8 at 0x7b500000feb0 by thread T1: 
      70: #0 qd_alloc_set_safe_ptr /home/kgiusti/work/dispatch/qpid-dispatch/include/qpid/dispatch/alloc_pool.h:96 (libqpid-dispatch.so+0xeed90) 
      70: #1 set_safe_ptr_qdr_link_t /home/kgiusti/work/dispatch/qpid-dispatch/src/router_core/router_core.c:35 (libqpid-dispatch.so+0xef449) 
      70: #2 qdr_link_process_initial_delivery_CT /home/kgiusti/work/dispatch/qpid-dispatch/src/router_core/connections.c:1678 (libqpid-dispatch.so+0xcccbe) 
      70: #3 qdr_link_inbound_first_attach_CT /home/kgiusti/work/dispatch/qpid-dispatch/src/router_core/connections.c:1801 (libqpid-dispatch.so+0xcd6cb) 
      70: #4 router_core_thread /home/kgiusti/work/dispatch/qpid-dispatch/src/router_core/router_core_thread.c:239 (libqpid-dispatch.so+0xfb2ae) 
      70: #5 _thread_init /home/kgiusti/work/dispatch/qpid-dispatch/src/posix/threading.c:172 (libqpid-dispatch.so+0xad37a) 
      70: #6 <null> <null> (libtsan.so.0+0x2d33f) 
      70: 
      70: Previous write of size 8 at 0x7b500000feb0 by thread T3 (mutexes: write M333): 
      70: #0 qd_nullify_safe_ptr /home/kgiusti/work/dispatch/qpid-dispatch/include/qpid/dispatch/alloc_pool.h:91 (libqpid-dispatch.so+0x103843) 
      70: #1 qdr_link_process_deliveries /home/kgiusti/work/dispatch/qpid-dispatch/src/router_core/transfer.c:239 (libqpid-dispatch.so+0x105033) 
      70: #2 qdr_http_push /home/kgiusti/work/dispatch/qpid-dispatch/src/adaptors/http2/http2_adaptor.c:1607 (libqpid-dispatch.so+0x147bfd) 
      70: #3 qdr_connection_process /home/kgiusti/work/dispatch/qpid-dispatch/src/router_core/connections.c:414 (libqpid-dispatch.so+0xc4bec) 
      70: #4 handle_connection_event /home/kgiusti/work/dispatch/qpid-dispatch/src/adaptors/http2/http2_adaptor.c:2435 (libqpid-dispatch.so+0x14ee55) 
      70: #5 handle_event_with_context /home/kgiusti/work/dispatch/qpid-dispatch/src/server.c:802 (libqpid-dispatch.so+0x12ecb6) 
      70: #6 do_handle_raw_connection_event /home/kgiusti/work/dispatch/qpid-dispatch/src/server.c:808 (libqpid-dispatch.so+0x12ed08) 
      70: #7 handle /home/kgiusti/work/dispatch/qpid-dispatch/src/server.c:1089 (libqpid-dispatch.so+0x1304e6) 
      70: #8 thread_run /home/kgiusti/work/dispatch/qpid-dispatch/src/server.c:1121 (libqpid-dispatch.so+0x13063a) 
      70: #9 _thread_init /home/kgiusti/work/dispatch/qpid-dispatch/src/posix/threading.c:172 (libqpid-dispatch.so+0xad37a) 
      70: #10 <null> <null> (libtsan.so.0+0x2d33f)
      

      Attachments

        Issue Links

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            kgiusti Ken Giusti
            kgiusti Ken Giusti

            Dates

              Created:
              Updated:

              Slack

                Issue deployment