base: Remove unnecessary DEBUG guard

There is no performance improvement on guarding a cprint
before a panic. We should just print as many info as possible
anytime we encounter a failure

Change-Id: I3ee9fb2c3b8a8f23bdf6173bb2a010020f2b2572
Signed-off-by: Giacomo Travaglini <giacomo.travaglini@arm.com>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/69077
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
Reviewed-by: Daniel Carvalho <odanrc@yahoo.com.br>
Tested-by: kokoro <noreply+kokoro@google.com>
This commit is contained in:
Giacomo Travaglini
2023-03-20 12:57:11 +00:00
parent f6ee1f2724
commit 2bbd2b9596

View File

@@ -172,13 +172,11 @@ bool
Info::baseCheck() const
{
if (!(flags & statistics::init)) {
#ifdef DEBUG
cprintf("this is stat number %d\n", id);
#endif
panic("Not all stats have been initialized.\n"
panic("this is stat number %d\n"
"Not all stats have been initialized.\n"
"You may need to add <ParentClass>::regStats() to a"
" new SimObject's regStats() function. Name: %s",
name);
id, name);
return false;
}