xref: /aosp_15_r20/external/autotest/server/site_tests/telemetry_AFDOGenerate/control (revision 9c5db1993ded3edbeafc8092d69fe5de2ee02df7)
1# Copyright (c) 2013 The Chromium OS Authors. All rights reserved.
2# Use of this source code is governed by a BSD-style license that can be
3# found in the LICENSE file.
4
5from autotest_lib.client.common_lib import utils
6
7AUTHOR = "[email protected] [email protected]"
8NAME = "telemetry_AFDOGenerate"
9PURPOSE = "Produce profile (AFDO format) of normal browsing for optimization."
10ATTRIBUTES = "suite:AFDO_record"
11TIME = "LONG"
12MAX_RESULT_SIZE_KB = 512000
13TEST_CATEGORY = "Benchmark"
14TEST_CLASS = "telemetry"
15TEST_TYPE = "server"
16PY_VERSION = 3
17
18DOC = """
19Run a pre-defined set of benchmarks on the DUT and create a sampled profile
20of the chrome execution. The profile is generated in AFDO format.
21See go/chromeos-toolchain and search for AFDO for more information about AFDO.
22For now, this test can only run on devices that support LBR PMU events and
23that have at lest 2GB of space in /tmp (autotest limitation).
24
25Example invocation:
26/usr/bin/test_that --debug --board=lumpy <DUT IP>
27  --args="ignore_failures=True local=True gs_test_location=True"
28  telemetry_AFDOGenerate
29"""
30
31args_dict = utils.args_to_dict(args)
32
33
34def run_telemetry_AFDOGenerate(machine):
35    run_host = hosts.create_host(machine)
36
37    # TODO (llozano):
38    # Pass "disable_sysinfo=True" to run_test since it would be nice
39    # to avoid copying all the logs back to the server. However, we
40    # cannot do this because of crosbug 308646
41    job.run_test('telemetry_AFDOGenerate', host=run_host, args=args_dict)
42
43
44job.parallel_simple(run_telemetry_AFDOGenerate, machines)
45