From ed60ff1c7fb2bbc7890991e5e59e9fe785cad3cb Mon Sep 17 00:00:00 2001 From: Roland Levillain Date: Fri, 21 May 2021 17:18:46 +0100 Subject: [PATCH] Print the coverage report location at the end of `acov-llvm.py report`. This makes it easier to identify the directory where the coverage report data of the latest `acov-llvm.py report` was written, especially when the current directory already contains previous coverage reports. (cherry picked from commit d2f1236a6e9c74d866ece65bfa9513ee864fb541) Test: acov-llvm.py report Bug: 160401633 Change-Id: I96fc860940f5be11c4c3b702dfce74226afabfce Merged-In: I96fc860940f5be11c4c3b702dfce74226afabfce --- scripts/acov-llvm.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/scripts/acov-llvm.py b/scripts/acov-llvm.py index a5b34c0d4..063911f1a 100755 --- a/scripts/acov-llvm.py +++ b/scripts/acov-llvm.py @@ -183,12 +183,16 @@ def do_report(args): object_flags = [args.binary[0]] + ['--object=' + b for b in args.binary[1:]] source_dirs = ['/proc/self/cwd/' + s for s in args.source_dir] + output_dir = f'{temp_dir}/html' + check_output([ str(LLVM_COV_PATH), 'show', f'--instr-profile={profdata}', - '--format=html', f'--output-dir={temp_dir}/html', + '--format=html', f'--output-dir={output_dir}', '--show-region-summary=false' ] + object_flags + source_dirs) + print(f'Coverage report data written in {output_dir}') + def parse_args(): parser = argparse.ArgumentParser()