Skip to content

Commit

Permalink
Merge pull request #846 from ROCm/default-configs
Browse files Browse the repository at this point in the history
bring back default config
  • Loading branch information
vamovsik authored Dec 5, 2024
2 parents fdb4445 + 256cfb9 commit 60734d2
Show file tree
Hide file tree
Showing 2 changed files with 161 additions and 14 deletions.
140 changes: 140 additions & 0 deletions rvs/conf/rvs.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,140 @@
# ################################################################################
# #
# # Copyright (c) 2018-2022 Advanced Micro Devices, Inc. All rights reserved.
# #
# # MIT LICENSE:
# # Permission is hereby granted, free of charge, to any person obtaining a copy of
# # this software and associated documentation files (the "Software"), to deal in
# # the Software without restriction, including without limitation the rights to
# # use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
# # of the Software, and to permit persons to whom the Software is furnished to do
# # so, subject to the following conditions:
# #
# # The above copyright notice and this permission notice shall be included in all
# # copies or substantial portions of the Software.
# #
# # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
# # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
# # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
# # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
# # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
# # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
# # SOFTWARE.
# #
# ###############################################################################

actions:
- name: action_1
device: all
module: gpup
properties:
all:
io_links-properties:
all:

- name: action_2
module: peqt
device: all
capability:
link_cap_max_speed:
link_cap_max_width:
link_stat_cur_speed:
link_stat_neg_width:
slot_pwr_limit_value:
slot_physical_num:
device_id:
vendor_id:
kernel_driver:
dev_serial_num:
D0_Maximum_Power_12V:
D0_Maximum_Power_3_3V:
D0_Sustained_Power_12V:
D0_Sustained_Power_3_3V:
atomic_op_routing:
atomic_op_32_completer:
atomic_op_64_completer:
atomic_op_128_CAS_completer:

- name: action_3
device: all
module: pebb
log_interval: 800
duration: 2000
device_to_host: false
host_to_device: true
parallel: false
block_size: 10240000

- name: action_4
device: all
module: pbqt
log_interval: 800
duration: 5000
peers: all
test_bandwidth: true
bidirectional: true
block_size: 1000000 2000000 10000000

- name: action_5
device: all
module: iet
parallel: true
count: 1
wait: 100
duration: 50000
ramp_interval: 5000
sample_interval: 700
log_interval: 700
max_violations: 1
target_power: 180
tolerance: 0.06
matrix_size: 8640
ops_type: dgemm

- name: action_6
device: all
module: gst
parallel: false
count: 1
duration: 10000
copy_matrix: false
target_stress: 9000
matrix_size_a: 8640
matrix_size_b: 8640
matrix_size_c: 8640
ops_type: sgemm
lda: 8640
ldb: 8640
ldc: 8640

- name: action_7
device: all
module: babel
parallel: true
count: 1
num_iter: 5000
array_size: 33554432
test_type: 2
mibibytes: false
o/p_csv: false
subtest: 1

- name: action_8
device: all
module: mem
parallel: true
count: 1
wait: 100
mapped_memory: false
mem_blocks: 128
num_passes: 500
thrds_per_blk: 64
stress: true
num_iter: 50000
exclude : 9 10

- name: action_9
device: all
deviceid: 26720
module: pesm
monitor: true
35 changes: 21 additions & 14 deletions rvs/src/rvsexec.cpp
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/********************************************************************************
*
* Copyright (c) 2018-2022 Advanced Micro Devices, Inc. All rights reserved.
* Copyright (c) 2018-2024 Advanced Micro Devices, Inc. All rights reserved.
*
* MIT LICENSE:
* Permission is hereby granted, free of charge, to any person obtaining a copy of
Expand Down Expand Up @@ -127,24 +127,32 @@ int rvs::exec::run() {
logger::to_json(true);
}

// check -c option
string config_file;
if (rvs::options::has_option("-c", &val)) {
config_file = val;

// Check if conf. file exists
std::ifstream file(config_file);
} else {
config_file = "../share/rocm-validation-suite/conf/rvs.conf";
// Check if pConfig file exist if not use old path for backward compatibility
std::ifstream file(path + config_file);
if (!file.good()) {
char buff[1024];
snprintf(buff, sizeof(buff),
"%s file is missing.", config_file.c_str());
rvs::logger::Err(buff, MODULE_NAME_CAPS);
return -1;
} else {
file.close();
config_file = "conf/rvs.conf";
}
file.close();
config_file = path + config_file;
}

// Check if pConfig file exists
std::ifstream file(config_file);
if (!file.good()) {
char buff[1024];
snprintf(buff, sizeof(buff),
"%s file is missing.", config_file.c_str());
rvs::logger::Err(buff, MODULE_NAME_CAPS);
return -1;
} else {
file.close();
}

// construct modules configuration file relative path
val = path + "../share/rocm-validation-suite/conf/.rvsmodules.config";
// Check if config file exists if not check the old file location for backward compatibility
Expand Down Expand Up @@ -422,8 +430,7 @@ void rvs::exec::do_help() {
"overwrite the content\n";
cout << " of the current log. Used in conjuction with "
"-d and -l options.\n";
cout << "-c --config Specify the configuration file to be used.\n";
cout << " supported GPUs.This is Mandatory field\n";
cout << "-c --config Specify the configuration file to be used.\n\n";
cout << "-d --debugLevel Specify the debug level for the output log. "
"The range is\n";
cout << " 0 to 5 with 5 being the highest verbose level.\n";
Expand Down

0 comments on commit 60734d2

Please sign in to comment.