Skip to content

Commit

Permalink
Merge branch 'xuchen-amd-rocprof-compute_branding_update' into amd-st…
Browse files Browse the repository at this point in the history
…aging
  • Loading branch information
xuchen-amd committed Sep 24, 2024
2 parents e6747da + 30bc37e commit 86cd141
Show file tree
Hide file tree
Showing 20 changed files with 865 additions and 405 deletions.
2 changes: 1 addition & 1 deletion AUTHORS
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# This is the list of Omniperf's significant contributors.
# This is the list of rocprof-compute's significant contributors.
#
# This does not necessarily list everyone who has contributed code,
# especially since many employees of one corporation may be contributing.
Expand Down
22 changes: 11 additions & 11 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,22 +1,22 @@
[![Ubuntu 22.04](https://github.com/ROCm/omniperf/actions/workflows/ubuntu-jammy.yml/badge.svg)](https://github.com/ROCm/omniperf/actions/workflows/ubuntu-jammy.yml)
[![RHEL 8](https://github.com/ROCm/omniperf/actions/workflows/rhel-8.yml/badge.svg)](https://github.com/ROCm/omniperf/actions/workflows/rhel-8.yml)
[![Instinct](https://github.com/ROCm/omniperf/actions/workflows/mi-rhel9.yml/badge.svg)](https://github.com/ROCm/omniperf/actions/workflows/mi-rhel9.yml)
[![Docs](https://github.com/ROCm/omniperf/actions/workflows/docs.yml/badge.svg)](https://rocm.github.io/omniperf/)
[![Ubuntu 22.04](https://github.com/ROCm/rocprofiler-compute/actions/workflows/ubuntu-jammy.yml/badge.svg)](https://github.com/ROCm/rocprofiler-compute/actions/workflows/ubuntu-jammy.yml)
[![RHEL 8](https://github.com/ROCm/rocprofiler-compute/actions/workflows/rhel-8.yml/badge.svg)](https://github.com/ROCm/rocprofiler-compute/actions/workflows/rhel-8.yml)
[![Instinct](https://github.com/ROCm/rocprofiler-compute/actions/workflows/mi-rhel9.yml/badge.svg)](https://github.com/ROCm/rocprofiler-compute/actions/workflows/mi-rhel9.yml)
[![Docs](https://github.com/ROCm/rocprofiler-compute/actions/workflows/docs.yml/badge.svg)](https://rocm.github.io/rocprofiler-compute/)
[![DOI](https://zenodo.org/badge/561919887.svg)](https://zenodo.org/badge/latestdoi/561919887)

# Omniperf
# rocprof-compute

## General

Omniperf is a system performance profiling tool for machine
rocprof-compute is a system performance profiling tool for machine
learning/HPC workloads running on AMD MI GPUs. The tool presently
targets usage on MI100, MI200, and MI300 accelerators.

* For more information on available features, installation steps, and
workload profiling and analysis, please refer to the online
[documentation](https://rocm.docs.amd.com/projects/omniperf/en/latest/).
[documentation](https://rocm.docs.amd.com/projects/rocprofiler-compute/en/latest/).

* Omniperf is an AMD open source research project and is not supported
* rocprof-compute is an AMD open source research project and is not supported
as part of the ROCm software stack. We welcome contributions and
feedback from the community. Please see the
[CONTRIBUTING.md](CONTRIBUTING.md) file for additional details on our
Expand All @@ -26,7 +26,7 @@ contribution process.

## Development

Omniperf follows a
rocprof-compute follows a
[main-dev](https://nvie.com/posts/a-successful-git-branching-model/)
branching model. As a result, our latest stable release is shipped
from the `main` branch, while new features are developed in our
Expand All @@ -50,8 +50,8 @@ style reference is provided below for convenience:
Keith Lowery and
Nicholas Curtis and
Cristian Di Pietrantonio},
title = {AMDResearch/omniperf: v2.0.1 (03 June 2024)},
month = june,
title = {AMDResearch/rocprof-compute: v2.0.1 (23 September 2024)},
month = september,
year = 2024,
publisher = {Zenodo},
version = {v2.0.1},
Expand Down
8 changes: 4 additions & 4 deletions src/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
This directory contains all the source code files for the Omniperf project.
The top-level `omniperf` executable is the entry point and defines the flow for subsequent execution modes.
This directory contains all the source code files for the rocprof-compute project.
The top-level `rocprof-compute` executable is the entry point and defines the flow for subsequent execution modes.

To build Omniperf as a developer (from source) please add this directory to `PATH`.
You will find utilities and logic specific to Omniperf's different execution modes in their
To build rocprof-compute as a developer (from source) please add this directory to `PATH`.
You will find utilities and logic specific to rocprof-compute's different execution modes in their
respective subdirectories.
34 changes: 17 additions & 17 deletions src/argparser.py
Original file line number Diff line number Diff line change
Expand Up @@ -79,15 +79,15 @@ def omniarg_parser(parser, omniperf_home, supported_archs, omniperf_version):
help="Profile the target application",
usage="""
omniperf profile --name <workload_name> [profile options] [roofline options] -- <profile_cmd>
rocprof-compute profile --name <workload_name> [profile options] [roofline options] -- <profile_cmd>
---------------------------------------------------------------------------------
Examples:
\tomniperf profile -n vcopy_all -- ./vcopy -n 1048576 -b 256
\tomniperf profile -n vcopy_SPI_TCC -b SQ TCC -- ./vcopy -n 1048576 -b 256
\tomniperf profile -n vcopy_kernel -k vecCopy -- ./vcopy -n 1048576 -b 256
\tomniperf profile -n vcopy_disp -d 0 -- ./vcopy -n 1048576 -b 256
\tomniperf profile -n vcopy_roof --roof-only -- ./vcopy -n 1048576 -b 256
\trocprof-compute profile -n vcopy_all -- ./vcopy -n 1048576 -b 256
\trocprof-compute profile -n vcopy_SPI_TCC -b SQ TCC -- ./vcopy -n 1048576 -b 256
\trocprof-compute profile -n vcopy_kernel -k vecCopy -- ./vcopy -n 1048576 -b 256
\trocprof-compute profile -n vcopy_disp -d 0 -- ./vcopy -n 1048576 -b 256
\trocprof-compute profile -n vcopy_roof --roof-only -- ./vcopy -n 1048576 -b 256
---------------------------------------------------------------------------------
""",
prog="tool",
Expand Down Expand Up @@ -272,14 +272,14 @@ def omniarg_parser(parser, omniperf_home, supported_archs, omniperf_version):
## ----------------------------
db_parser = subparsers.add_parser(
"database",
help="Interact with Omniperf database",
help="Interact with rocprof-compute database",
usage="""
\nomniperf database <interaction type> [connection options]
\nrocprof-compute database <interaction type> [connection options]
\n\n-------------------------------------------------------------------------------
\nExamples:
\n\tomniperf database --import -H pavii1 -u temp -t asw -w workloads/vcopy/mi200/
\n\tomniperf database --remove -H pavii1 -u temp -w omniperf_asw_sample_mi200
\n\trocprof-compute database --import -H pavii1 -u temp -t asw -w workloads/vcopy/mi200/
\n\trocprof-compute database --remove -H pavii1 -u temp -w rocprof-compute_asw_sample_mi200
\n-------------------------------------------------------------------------------\n
""",
prog="tool",
Expand All @@ -300,15 +300,15 @@ def omniarg_parser(parser, omniperf_home, supported_archs, omniperf_version):
required=False,
dest="upload",
action="store_true",
help="\t\t\t\tImport workload to Omniperf DB",
help="\t\t\t\tImport workload to rocprof-compute DB",
)
interaction_group.add_argument(
"-r",
"--remove",
required=False,
dest="remove",
action="store_true",
help="\t\t\t\tRemove a workload from Omniperf DB",
help="\t\t\t\tRemove a workload from rocprof-compute DB",
)

connection_group.add_argument(
Expand Down Expand Up @@ -366,13 +366,13 @@ def omniarg_parser(parser, omniperf_home, supported_archs, omniperf_version):
"analyze",
help="Analyze existing profiling results at command line",
usage="""
omniperf analyze --path <workload_path> [analyze options]
rocprof-compute analyze --path <workload_path> [analyze options]
-----------------------------------------------------------------------------------
Examples:
\tomniperf analyze -p workloads/vcopy/mi200/ --list-metrics gfx90a
\tomniperf analyze -p workloads/mixbench/mi200/ --dispatch 12 34 --decimal 3
\tomniperf analyze -p workloads/mixbench/mi200/ --gui
\trocprof-compute analyze -p workloads/vcopy/mi200/ --list-metrics gfx90a
\trocprof-compute analyze -p workloads/mixbench/mi200/ --dispatch 12 34 --decimal 3
\trocprof-compute analyze -p workloads/mixbench/mi200/ --gui
-----------------------------------------------------------------------------------
""",
prog="tool",
Expand Down Expand Up @@ -454,7 +454,7 @@ def omniarg_parser(parser, omniperf_home, supported_archs, omniperf_version):
type=int,
nargs="?",
const=8050,
help="\t\tActivate a GUI to interate with Omniperf metrics.\n\t\tOptionally, specify port to launch application (DEFAULT: 8050)",
help="\t\tActivate a GUI to interate with rocprof-compute metrics.\n\t\tOptionally, specify port to launch application (DEFAULT: 8050)",
)
analyze_advanced_group.add_argument(
"--random-port",
Expand Down
2 changes: 1 addition & 1 deletion src/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,4 +26,4 @@

# NB: Creating a new module to share global vars across modules
omniperf_home = Path(__file__).resolve().parent
prog = "omniperf"
prog = "rocprof-compute"
2 changes: 1 addition & 1 deletion src/omniperf_analyze/analysis_base.py
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,7 @@ def sanitize(self):
def pre_processing(self):
"""Perform initialization prior to analysis."""
console_debug("analysis", "prepping to do some analysis")
console_log("analysis", "deriving Omniperf metrics...")
console_log("analysis", "deriving rocprof-compute metrics...")
# initalize output file
self._output = (
open(self.__args.output_file, "w+") if self.__args.output_file else sys.stdout
Expand Down
20 changes: 11 additions & 9 deletions src/omniperf_base.py
Original file line number Diff line number Diff line change
Expand Up @@ -92,12 +92,12 @@ def __init__(self):
def print_graphic(self):
"""Log program name as ascii art to terminal."""
ascii_art = r"""
___ _ __
/ _ \ _ __ ___ _ __ (_)_ __ ___ _ __ / _|
| | | | '_ ` _ \| '_ \| | '_ \ / _ \ '__| |_
| |_| | | | | | | | | | | |_) | __/ | | _|
\___/|_| |_| |_|_| |_|_| .__/ \___|_| |_|
|_|
__ _
_ __ ___ ___ _ __ _ __ ___ / _| ___ ___ _ __ ___ _ __ _ _| |_ ___
| '__/ _ \ / __| '_ \| '__/ _ \| |_ _____ / __/ _ \| '_ ` _ \| '_ \| | | | __/ _ \
| | | (_) | (__| |_) | | | (_) | _|_____| (_| (_) | | | | | | |_) | |_| | || __/
|_| \___/ \___| .__/|_| \___/|_| \___\___/|_| |_| |_| .__/ \__,_|\__\___|
|_| |_|
"""
print(ascii_art)

Expand Down Expand Up @@ -163,12 +163,12 @@ def load_soc_specs(self, sysinfo: dict = None):

def parse_args(self):
parser = argparse.ArgumentParser(
description="Command line interface for AMD's GPU profiler, Omniperf",
description="Command line interface for AMD's GPU profiler, rocprof-compute",
prog="tool",
formatter_class=lambda prog: argparse.RawTextHelpFormatter(
prog, max_help_position=30
),
usage="omniperf [mode] [options]",
usage="rocprof-compute [mode] [options]",
)
omniarg_parser(
parser, config.omniperf_home, self.__supported_archs, self.__version
Expand All @@ -180,7 +180,9 @@ def parse_args(self):
print(generate_machine_specs(self.__args))
sys.exit(0)
parser.print_help(sys.stderr)
console_error("Omniperf requires you pass a valid mode. Detected None.")
console_error(
"rocprof-compute requires you pass a valid mode. Detected None."
)
return

@demarcate
Expand Down
2 changes: 1 addition & 1 deletion src/omniperf_profile/profiler_base.py
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,7 @@ def pre_processing(self):
self.__args.remaining = " ".join(self.__args.remaining)
else:
console_error(
"Profiling command required. Pass application executable after -- at the end of options.\n\t\ti.e. omniperf profile -n vcopy -- ./vcopy -n 1048576 -b 256"
"Profiling command required. Pass application executable after -- at the end of options.\n\t\ti.e. rocprof-compute profile -n vcopy -- ./vcopy -n 1048576 -b 256"
)

# verify name meets MongoDB length requirements and no illegal chars
Expand Down
6 changes: 3 additions & 3 deletions src/omniperf_soc/soc_base.py
Original file line number Diff line number Diff line change
Expand Up @@ -101,8 +101,8 @@ def get_profiler_options(self):
return []

def check_arch_override(self):
if "OMNIPERF_ARCH_OVERRIDE" in os.environ.keys():
return os.environ["OMNIPERF_ARCH_OVERRIDE"]
if "ROCPROFCOMPUTE_ARCH_OVERRIDE" in os.environ.keys():
return os.environ["ROCPROFCOMPUTE_ARCH_OVERRIDE"]
return ""

@demarcate
Expand Down Expand Up @@ -201,7 +201,7 @@ def populate_mspec(self):
else:
console_error(
"Cannot parse MI300 details from rocminfo. Please verify output or set the arch using (e.g.,) "
'export OMNIPERF_ARCH_OVERRIDE="MI300A"'
'export ROCPROFCOMPUTE_ARCH_OVERRIDE="MI300A"'
)

self._mspec.num_xcd = str(
Expand Down
4 changes: 2 additions & 2 deletions src/omniperf → src/rocprof-compute
100755 → 100644
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ def verify_deps():
localVersion, desiredVersion, operator
):
print(
"[ERROR] the '%s' distribution does not meet version requirements to use omniperf."
"[ERROR] the '%s' distribution does not meet version requirements to use rocprof-compute."
% dependency
)
print(" --> version installed :", localVersion)
Expand All @@ -106,7 +106,7 @@ def verify_deps():
print(
"Please verify all of the python dependencies called out in the requirements file"
)
print("are installed locally prior to running omniperf.")
print("are installed locally prior to running rocprof-compute.")
print("")
print("See: %s" % checkFile)
sys.exit(1)
Expand Down
2 changes: 1 addition & 1 deletion src/roofline.py
Original file line number Diff line number Diff line change
Expand Up @@ -418,7 +418,7 @@ def profile(self):
if not self.__args.remaining:
console_error(
"profiling"
"An <app_cmd> is required to run.\nomniperf profile -n test -- <app_cmd>"
"An <app_cmd> is required to run.\nrocprof-compute profile -n test -- <app_cmd>"
)
# TODO: Add an equivelent of characterize_app() to run profiling directly out of this module

Expand Down
4 changes: 2 additions & 2 deletions src/utils/db_connector.py
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ def prep_import(self):
)

self.connection_info["db"] = (
"omniperf_" + str(self.args.team) + "_" + str(name) + "_" + str(soc)
"rocprof-compute_" + str(self.args.team) + "_" + str(name) + "_" + str(soc)
)

@demarcate
Expand Down Expand Up @@ -157,7 +157,7 @@ def pre_processing(self):
is_full_workload_name = self.args.workload.count("_") >= 3
if not is_full_workload_name:
console_error(
"-w/--workload is not valid. Please use full workload name as seen in GUI when removing (i.e. omniperf_asw_vcopy_mi200)"
"-w/--workload is not valid. Please use full workload name as seen in GUI when removing (i.e. rocprof-compute_asw_vcopy_mi200)"
)
if (
self.connection_info["host"] == None
Expand Down
2 changes: 1 addition & 1 deletion src/utils/gui_components/header.py
Original file line number Diff line number Diff line change
Expand Up @@ -299,7 +299,7 @@ def get_header(raw_pmc, input_filters, kernel_names):
children=[
# Report bug button
html.A(
href="https://github.com/ROCm/omniperf/issues",
href="https://github.com/ROCm/rocprofiler-compute/issues",
children=[
html.Button(
className="report",
Expand Down
12 changes: 6 additions & 6 deletions src/utils/logger.py
Original file line number Diff line number Diff line change
Expand Up @@ -83,8 +83,8 @@ def setup_console_handler():
setattr(logging, "trace", trace_logger)

color_setting = 1
if "OMNIPERF_COLOR" in os.environ.keys():
color_setting = int(os.environ["OMNIPERF_COLOR"])
if "ROCPROFCOMPUTE_COLOR" in os.environ.keys():
color_setting = int(os.environ["ROCPROFCOMPUTE_COLOR"])

if color_setting == 0:
# non-colored
Expand All @@ -99,7 +99,7 @@ def setup_console_handler():
# no color or levelname for INFO, other log messages entirely in color
formatter = ColoredFormatterAll()
else:
print("Unsupported setting for OMNIPERF_COLOR - set to 0, 1, 2 or 3.")
print("Unsupported setting for ROCPROFCOMPUTE_COLOR - set to 0, 1, 2 or 3.")
sys.exit(1)

console_handler = logging.StreamHandler(sys.stdout)
Expand Down Expand Up @@ -130,8 +130,8 @@ def setup_logging_priority(verbosity, quietmode, appmode):
loglevel = levels[min(verbosity, len(levels) - 1)] # cap to last level index

# optional: override of default loglevel via env variable which takes precedence
if "OMNIPERF_LOGLEVEL" in os.environ.keys():
loglevel = os.environ["OMNIPERF_LOGLEVEL"]
if "ROCPROFCOMPUTE_LOGLEVEL" in os.environ.keys():
loglevel = os.environ["ROCPROFCOMPUTE_LOGLEVEL"]
if loglevel in {"DEBUG", "debug"}:
loglevel = logging.DEBUG
elif loglevel in {"TRACE", "trace"}:
Expand All @@ -141,7 +141,7 @@ def setup_logging_priority(verbosity, quietmode, appmode):
elif loglevel in {"ERROR", "error"}:
loglevel = logging.ERROR
else:
print("Ignoring unsupported OMNIPERF_LOGLEVEL setting (%s)" % loglevel)
print("Ignoring unsupported ROCPROFCOMPUTE_LOGLEVEL setting (%s)" % loglevel)
sys.exit(1)

# update console loglevel based on command-line args/env settings
Expand Down
2 changes: 1 addition & 1 deletion src/utils/specs.py
Original file line number Diff line number Diff line change
Expand Up @@ -540,7 +540,7 @@ def get_class_members(self):
return pd.DataFrame(data, index=[0])

def __repr__(self):
topstr = "Machine Specifications: describing the state of the machine that Omniperf data was collected on.\n"
topstr = "Machine Specifications: describing the state of the machine that rocprof-compute data was collected on.\n"
data = []
for field in fields(self):
name = field.name
Expand Down
2 changes: 1 addition & 1 deletion src/utils/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ def get_version_display(version, sha, mode):
"""Pretty print versioning info"""
buf = io.StringIO()
print("-" * 40, file=buf)
print("Omniperf version: %s (%s)" % (version, mode), file=buf)
print("rocprof-compute version: %s (%s)" % (version, mode), file=buf)
print("Git revision: %s" % sha, file=buf)
print("-" * 40, file=buf)
return buf.getvalue()
Expand Down
2 changes: 1 addition & 1 deletion tests/generate_test_analyze_workloads.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
+ arch
+ "():"
+ "\n\twith pytest.raises(SystemExit) as e:"
+ "\n\t\twith patch('sys.argv',['omniperf', 'analyze', '--path', '"
+ "\n\t\twith patch('sys.argv',['rocprof-compute', 'analyze', '--path', '"
+ workload
+ "/"
+ arch
Expand Down
Loading

0 comments on commit 86cd141

Please sign in to comment.