Ticket #1974 (closed: fixed)

Opened 10 years ago

Last modified 5 years ago

EventWorkspace: MRUList makes reading data (e.g. dataY() ) not thread safe even when reading data.

Reported by: Janik Zikovsky Owned by: Janik Zikovsky
Priority: major Milestone: Iteration 26
Component: Mantid Keywords:
Cc: Blocked By:
Blocking: Tester: Vickie Lynch

Description

A segfault occurs when trying to clear up memory in the MRU list from concurrent threads!

Is there a way around this? This means that even sorted event lists are not thread safe.

Perhaps an operation-dependant "threadsafe" function???

Change History

comment:1 Changed 10 years ago by Nick Draper

I would be concerned that this suggests that this is not implmented properly. As long as you have at least 2* the number of threads in your MRUlist then you should be fine.

Russell may be able to help you with this as he has tracked several similar issues down at ISIS.

comment:2 Changed 10 years ago by Janik Zikovsky

  • Status changed from new to accepted

comment:3 Changed 10 years ago by Janik Zikovsky

(In [7777]) Refs #1974: fix so that reading EventWorkspace dataY() and dataE() does not segfault if done in parallel. The problem was in freeing memory by one thread that was still used by another thread. Fixed by having one MRU list per thread.

comment:4 Changed 10 years ago by Janik Zikovsky

  • Status changed from accepted to verify
  • Resolution set to fixed

Unit tests all pass and my tests in MantidPlot too. Problem solved (at the expense of memory)!

comment:5 Changed 10 years ago by Nick Draper

  • Milestone changed from Iteration 26 to Iteration 27

Bulk move of tickets to iteration 27, if your ticket is essential for Iteration 26 then move it back.

comment:6 Changed 10 years ago by Nick Draper

  • Milestone changed from Iteration 27 to Iteration 26

Sorry I didn't mean to move these ones reverting back to It 26

comment:7 Changed 10 years ago by Vickie Lynch

  • Status changed from verify to verifying
  • Tester set to Vickie Lynch

comment:8 Changed 10 years ago by Vickie Lynch

  • Status changed from verifying to closed

Did not see segfault so this must be working.

comment:9 Changed 5 years ago by Stuart Campbell

This ticket has been transferred to github issue 2821

Note: See TracTickets for help on using tickets.