Skip to content
Snippets Groups Projects
  • Enrico Guiraud's avatar
    e1d0fce9
    [TDF] Let TColumnValue support interleaved task execution · e1d0fce9
    Enrico Guiraud authored
    Each TDF node keeps a thread-local tuple of TColumnValues. TColumnValues
    read the values of a column for a certain entry, but entry ranges and
    TTreeReader-related objects are _task_ local.
    
    Before this change, in case of interleaved task execution, the second
    task starting in a thread would re-initialize the TColumnValues and
     overwrite the previous task's settings.
    
    Now TColumnValues deal with multiple initializations by keeping their
    internal state in a stack: when a new task initializes a TColumnValue
    it pushes the required values in the stack, when a task completes
    execution it pops its values from the stack.
    
    Note that interleaved TBB tasks always follow a last-to-start,
    first-to-finish pattern, which allows us to use a LIFO structure for
    TColumnValue.
    e1d0fce9
    History
    [TDF] Let TColumnValue support interleaved task execution
    Enrico Guiraud authored
    Each TDF node keeps a thread-local tuple of TColumnValues. TColumnValues
    read the values of a column for a certain entry, but entry ranges and
    TTreeReader-related objects are _task_ local.
    
    Before this change, in case of interleaved task execution, the second
    task starting in a thread would re-initialize the TColumnValues and
     overwrite the previous task's settings.
    
    Now TColumnValues deal with multiple initializations by keeping their
    internal state in a stack: when a new task initializes a TColumnValue
    it pushes the required values in the stack, when a task completes
    execution it pops its values from the stack.
    
    Note that interleaved TBB tasks always follow a last-to-start,
    first-to-finish pattern, which allows us to use a LIFO structure for
    TColumnValue.