sc-machine icon indicating copy to clipboard operation
sc-machine copied to clipboard

Solve problem with deadlocks in iterators

Open ShunkevichDV opened this issue 4 years ago • 2 comments

When several agents work with the same sc-element, a deadlock is likely to occur

Possibly the problem (or one of them) is somewhere in sc_iterator...._next functions

https://github.com/ostis-dev/sc-machine/blob/master/sc-memory/sc-core/sc-store/sc_iterator3.c

ShunkevichDV avatar Jun 23 '21 17:06 ShunkevichDV

Possibly same issue with #267

ShunkevichDV avatar Jun 23 '21 17:06 ShunkevichDV

sc-machine deadlock test

https://github.com/Vikort/sc-machine/tree/bug/sc-machine-deadlock-test

To run tests

  • Clone repository

    git clone https://github.com/Vikort/sc-machine.git
    cd sc-machine
    git checkout bug/sc-machine-deadlock-test
    git submodule update --init --recursive
    
  • Build sc-machine

    In sc-machine folder

    mkdir build
    cd build
    cmake ..
    make
    
  • Run

    In sc-machine folder

    cd bin
    ./sc-machine-deadlock
    

Vikort avatar Jul 27 '21 11:07 Vikort