Changeset 14600 for trunk


Ignore:
Timestamp:
11/10/12 13:08:18 (12 years ago)
Author:
tbretz
Message:
Made lockers const and moved the chck for a valid main thread behin the locker; if the main thread was terminatd already set fThreadId to 0 so that no new thread will run.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/FACT++/src/InterpreterV8.cc

    r14599 r14600  
    2525
    2626// ==========================================================================
     27//                           Some documentation
     28// ==========================================================================
     29//
     30// Threads:
     31// --------
     32// In most cases Js* and other calls to native C++ code could be wrapped
     33// with an Unlocker to allow possible other JavaScipt 'threads' to run
     34// during that time. However, all of these calls should take much less than
     35// the preemption time of 10ms, so it would just be a waste of tim.
     36//
     37// Termination:
     38// ------------
     39// Each thread running V8 code needs to be signalled individually for
     40// termination.
     41//
     42
     43// ==========================================================================
    2744//                            Simple interface
    2845// ==========================================================================
     
    3047void InterpreterV8::Terminate()
    3148{
     49    /*
    3250    for (auto it=fThreadIds.begin(); it!=fThreadIds.end(); it++)
    3351        V8::TerminateExecution(*it);
    3452    fThreadIds.clear();
    35 
     53    */
    3654    if (fThreadId<0)
    3755        return;
Note: See TracChangeset for help on using the changeset viewer.