Giacomo Travaglini has submitted this change. ( https://gem5-review.googlesource.com/c/public/gem5/+/42075 )

Change subject: configs: Remove unused argument from create_mem_intf
......................................................................

configs: Remove unused argument from create_mem_intf

The number of memory controllers is not actually used by the
create_mem_intf function

Change-Id: I8663b38938de9b62b778679c1bc5c7c6e15a60da
Signed-off-by: Giacomo Travaglini <[email protected]>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/42075
Reviewed-by: Jason Lowe-Power <[email protected]>
Maintainer: Jason Lowe-Power <[email protected]>
Tested-by: kokoro <[email protected]>
---
M configs/common/MemConfig.py
M configs/ruby/Ruby.py
2 files changed, 5 insertions(+), 4 deletions(-)

Approvals:
  Jason Lowe-Power: Looks good to me, approved; Looks good to me, approved
  kokoro: Regressions pass

Objections:
  Alex Dutu: I would prefer this is not merged as is



diff --git a/configs/common/MemConfig.py b/configs/common/MemConfig.py
index fa1f084..efd3c1d 100644
--- a/configs/common/MemConfig.py
+++ b/configs/common/MemConfig.py
@@ -37,7 +37,7 @@
 from common import ObjectList
 from common import HMC

-def create_mem_intf(intf, r, i, nbr_mem_ctrls, intlv_bits, intlv_size,
+def create_mem_intf(intf, r, i, intlv_bits, intlv_size,
                     xor_low_bit):
     """
     Helper function for creating a single memoy controller from the given
@@ -199,7 +199,7 @@
         for i in range(nbr_mem_ctrls):
             if opt_mem_type and (not opt_nvm_type or range_iter % 2 != 0):
                 # Create the DRAM interface
-                dram_intf = create_mem_intf(intf, r, i, nbr_mem_ctrls,
+                dram_intf = create_mem_intf(intf, r, i,
                     intlv_bits, intlv_size, opt_xor_low_bit)

                 # Set the number of ranks based on the command-line
@@ -223,8 +223,9 @@
                 mem_ctrls.append(mem_ctrl)

elif opt_nvm_type and (not opt_mem_type or range_iter % 2 == 0):
-                nvm_intf = create_mem_intf(n_intf, r, i, nbr_mem_ctrls,
+                nvm_intf = create_mem_intf(n_intf, r, i,
                     intlv_bits, intlv_size, opt_xor_low_bit)
+
                 # Set the number of ranks based on the command-line
                 # options if it was explicitly set
                 if issubclass(n_intf, m5.objects.NVMInterface) and \
diff --git a/configs/ruby/Ruby.py b/configs/ruby/Ruby.py
index 57a5272..0db9d93 100644
--- a/configs/ruby/Ruby.py
+++ b/configs/ruby/Ruby.py
@@ -136,7 +136,7 @@
         for r in system.mem_ranges:
             mem_type = ObjectList.mem_list.get(options.mem_type)
             dram_intf = MemConfig.create_mem_intf(mem_type, r, index,
-                options.num_dirs, int(math.log(options.num_dirs, 2)),
+                int(math.log(options.num_dirs, 2)),
                 intlv_size, options.xor_low_bit)
             if issubclass(mem_type, DRAMInterface):
                 mem_ctrl = m5.objects.MemCtrl(dram = dram_intf)

--
To view, visit https://gem5-review.googlesource.com/c/public/gem5/+/42075
To unsubscribe, or for help writing mail filters, visit https://gem5-review.googlesource.com/settings

Gerrit-Project: public/gem5
Gerrit-Branch: develop
Gerrit-Change-Id: I8663b38938de9b62b778679c1bc5c7c6e15a60da
Gerrit-Change-Number: 42075
Gerrit-PatchSet: 5
Gerrit-Owner: Giacomo Travaglini <[email protected]>
Gerrit-Reviewer: Alex Dutu <[email protected]>
Gerrit-Reviewer: Daniel Carvalho <[email protected]>
Gerrit-Reviewer: Gabe Black <[email protected]>
Gerrit-Reviewer: Giacomo Travaglini <[email protected]>
Gerrit-Reviewer: Jason Lowe-Power <[email protected]>
Gerrit-Reviewer: Jason Lowe-Power <[email protected]>
Gerrit-Reviewer: kokoro <[email protected]>
Gerrit-MessageType: merged
_______________________________________________
gem5-dev mailing list -- [email protected]
To unsubscribe send an email to [email protected]
%(web_page_url)slistinfo%(cgiext)s/%(_internal_name)s

Reply via email to