configs: Add hasattr guard to ensure DerivO3CPU compiled
configs/ruby/Ruby.py fails when `DerivO3CPU` is not compiled into the gem5 binary. The `isinstance` check fails. This fix addds a guard. Change-Id: I1e5503ab18ec94683056c6eb28cebeda6632ae8e
This commit is contained in:
@@ -331,8 +331,9 @@ def send_evicts(options):
|
||||
# 2. The x86 mwait instruction is built on top of coherence invalidations
|
||||
# 3. The local exclusive monitor in ARM systems
|
||||
|
||||
if isinstance(options.cpu_type, DerivO3CPU) or ObjectList.cpu_list.get_isa(
|
||||
options.cpu_type
|
||||
) in [ISA.X86, ISA.ARM]:
|
||||
if (
|
||||
hasattr(m5.objects, "DerivO3CPU")
|
||||
and isinstance(options.cpu_type, DerivO3CPU)
|
||||
) or ObjectList.cpu_list.get_isa(options.cpu_type) in [ISA.X86, ISA.ARM]:
|
||||
return True
|
||||
return False
|
||||
|
||||
Reference in New Issue
Block a user