Skip to content

Commit

Permalink
Add broken mclk workaround for all arch #453
Browse files Browse the repository at this point in the history
* Add the missing commit
  • Loading branch information
vedithal-amd committed Feb 7, 2025
1 parent 3396ba3 commit fab64fc
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 6 deletions.
6 changes: 4 additions & 2 deletions src/rocprof_compute_soc/soc_gfx908.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,8 +65,10 @@ def __init__(self, args, mspec):
self._mspec.lds_banks_per_cu = 32
self._mspec.pipes_per_gpu = 4
# --showmclkrange is broken in Mi100, hardcode freq
self._mspec.max_mclk = 1200
self._mspec.cur_mclk = 1200
if self._mspec.gpu_model == "MI100":
if self._mspec.max_mclk == None or self._mspec.cur_mclk == None:
self._mspec.max_mclk = 1200
self._mspec.cur_mclk = 1200

@demarcate
def get_profiler_options(self):
Expand Down
7 changes: 7 additions & 0 deletions src/rocprof_compute_soc/soc_gfx90a.py
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,13 @@ def __init__(self, args, mspec):
)
self.roofline_obj = Roofline(args, self._mspec)

# Workaround for broken --showmclkrange
# MI210/MI250/MI250X have 1600MHz mclk
if self._mspec.gpu_model == "MI200":
if self._mspec.max_mclk == None or self._mspec.cur_mclk == None:
self._mspec.max_mclk = 1600
self._mspec.cur_mclk = 1600

# Set arch specific specs
self._mspec._l2_banks = 32
self._mspec.lds_banks_per_cu = 32
Expand Down
10 changes: 6 additions & 4 deletions src/rocprof_compute_soc/soc_gfx942.py
Original file line number Diff line number Diff line change
Expand Up @@ -75,10 +75,12 @@ def __init__(self, args, mspec):
)
self.roofline_obj = Roofline(args, self._mspec)

# --showmclkrange is broken in MI308X, hardcode freq
if self._mspec.gpu_model == "MI308X":
self._mspec.max_mclk = 1300
self._mspec.cur_mclk = 1300
# Workaround for broken --showmclkrange
# MI300X/MI300A/MI308X have 1300MHz mclk
if self._mspec.gpu_model == "MI300":
if self._mspec.max_mclk == None or self._mspec.cur_mclk == None:
self._mspec.max_mclk = 1300
self._mspec.cur_mclk = 1300

# Set arch specific specs
self._mspec._l2_banks = 16
Expand Down

0 comments on commit fab64fc

Please sign in to comment.