parameters: (options)
docstring: Implements the 'all' action of this tool.
docstring_summary: Implements the 'all' action of this tool.
docstring_tokens: Implements the all action of this tool .
function: def write_instrumented(options):
    """Implements the 'all' action of this tool."""
    exe_list = list(executables(options.build_dir))
    logging.info('Reading instrumented lines from %d executables.',
                 len(exe_list))
    pool = Pool(CPUS)
    try:
      results = pool.imap_unordered(get_instrumented_lines, exe_list)
    finally:
      pool.close()
  
    # Merge multiprocessing results and prepare output data.
    data = merge_instrumented_line_results(exe_list, results)
  
    logging.info('Read data from %d executables, which covers %d files.',
                 len(data['tests']), len(data['files']))
    logging.info('Writing results to %s', options.json_output)
  
    # Write json output.
    with open(options.json_output, 'w') as f:
      json.dump(data, f, sort_keys=True)
function_tokens: def write_instrumented ( options ) : exe_list = list ( executables ( options . build_dir ) ) logging . info ( 'Reading instrumented lines from %d executables.' , len ( exe_list ) ) pool = Pool ( CPUS ) try : results = pool . imap_unordered ( get_instrumented_lines , exe_list ) finally : pool . close ( ) # Merge multiprocessing results and prepare output data. data = merge_instrumented_line_results ( exe_list , results ) logging . info ( 'Read data from %d executables, which covers %d files.' , len ( data [ 'tests' ] ) , len ( data [ 'files' ] ) ) logging . info ( 'Writing results to %s' , options . json_output ) # Write json output. with open ( options . json_output , 'w' ) as f : json . dump ( data , f , sort_keys = True )