Changeset 4314

Show
Ignore:
Timestamp:
06/15/08 04:41:56 (2 months ago)
Author:
pmoura
Message:

Changed the thread cancellation process to not automatically releasing any locks, leaving that task to a catcher associated to the thread goal.

Location:
trunk
Files:
3 modified

Legend:

Unmodified
Added
Removed
  • trunk/compiler/logtalk.pl

    r4312 r4314  
    1337413374    (   catch(thread_peek_message(Id, '$lgt_master'), _, fail) -> 
    1337513375        catch(thread_send_message(Id, '$lgt_status'(_, terminate)), _, true) 
    13376     ;   catch(thread_signal(Id, '$lgt_mt_thread_abort'), _, true) 
     13376    ;   catch(thread_signal(Id, throw('$lgt_terminated')), _, true) 
    1337713377    ), 
    1337813378    '$lgt_mt_threaded_call_abort'(Ids). 
     
    1339313393    catch(thread_join(Id, _), _, true), 
    1339413394    '$lgt_mt_threaded_call_join'(Ids, Results). 
    13395  
    13396  
    13397 '$lgt_mt_thread_abort' :- 
    13398     mutex_unlock_all, 
    13399     throw('$lgt_terminated'). 
    1340013395 
    1340113396 
  • trunk/examples/threads/mtbatch/mtbatch.lgt

    r4313 r4314  
    33 
    44    :- info([ 
    5         version is 1.0, 
     5        version is 1.1, 
    66        author is 'Paulo Moura', 
    7         date is 2008/03/04, 
     7        date is 2008/06/14, 
    88        comment is 'Multi-threading benchmarks.', 
    99        parameters is ['Prolog'- 'Prolog backend compiler. Supported compilers are SWI-Prolog (swi), YAP (yap), and XSB (xsb).']]). 
  • trunk/RELEASE_NOTES.txt

    r4311 r4314  
    2626    threaded/1 when canceling individual threads. The first bug resulted from  
    2727    out-of-order thread status messages. The second bug resulted from a leak  
    28     of thread results between calls to the threaded/1 predicate. 
     28    of thread results between calls to the threaded/1 predicate. Changed the  
     29    thread cancellation process to not automatically releasing any locks,  
     30    leaving that task to a catcher associated to the thread goal. 
    2931 
    3032    Added a new default compiler option, multifile_directive, to all config