summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorMatteo Andreozzi <Matteo.Andreozzi@arm.com>2017-04-03 13:38:58 +0100
committerAndreas Sandberg <andreas.sandberg@arm.com>2017-04-03 13:53:17 +0100
commit626a0cc003824c3d6d35e9433dcc6751e105a14a (patch)
tree925fc40bbb83505aa15edfe4c8be448d74b9cd68 /src
parent9f3615d9c996e5ee627d4f470f7a3440a91bc39d (diff)
downloadgem5-626a0cc003824c3d6d35e9433dcc6751e105a14a.tar.xz
arm: fix template instantiation warning in clang
In arch/arm/faults.hh, template the static member vals require explicit specialisation to avoid compiler warnings. Change-Id: Ie404ccaa43269cb1bb819e33153e776abbf3a79b Signed-off-by: Andreas Sandberg <andreas.sandberg@arm.com>
Diffstat (limited to 'src')
-rw-r--r--src/arch/arm/faults.hh27
1 files changed, 26 insertions, 1 deletions
diff --git a/src/arch/arm/faults.hh b/src/arch/arm/faults.hh
index da501a109..ab4c67552 100644
--- a/src/arch/arm/faults.hh
+++ b/src/arch/arm/faults.hh
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2010, 2012-2013, 2016 ARM Limited
+ * Copyright (c) 2010, 2012-2013, 2016-2017 ARM Limited
* All rights reserved
*
* The license below extends only to copyright in the software and shall
@@ -566,6 +566,31 @@ class IllegalInstSetStateFault : public ArmFaultVals<IllegalInstSetStateFault>
IllegalInstSetStateFault();
};
+/*
+ * Explicitly declare template static member variables avoid warnings in some clang versions
+ */
+template<> ArmFault::FaultVals ArmFaultVals<Reset>::vals;
+template<> ArmFault::FaultVals ArmFaultVals<UndefinedInstruction>::vals;
+template<> ArmFault::FaultVals ArmFaultVals<SupervisorCall>::vals;
+template<> ArmFault::FaultVals ArmFaultVals<SecureMonitorCall>::vals;
+template<> ArmFault::FaultVals ArmFaultVals<HypervisorCall>::vals;
+template<> ArmFault::FaultVals ArmFaultVals<PrefetchAbort>::vals;
+template<> ArmFault::FaultVals ArmFaultVals<DataAbort>::vals;
+template<> ArmFault::FaultVals ArmFaultVals<VirtualDataAbort>::vals;
+template<> ArmFault::FaultVals ArmFaultVals<HypervisorTrap>::vals;
+template<> ArmFault::FaultVals ArmFaultVals<Interrupt>::vals;
+template<> ArmFault::FaultVals ArmFaultVals<VirtualInterrupt>::vals;
+template<> ArmFault::FaultVals ArmFaultVals<FastInterrupt>::vals;
+template<> ArmFault::FaultVals ArmFaultVals<VirtualFastInterrupt>::vals;
+template<> ArmFault::FaultVals ArmFaultVals<SupervisorTrap>::vals;
+template<> ArmFault::FaultVals ArmFaultVals<SecureMonitorTrap>::vals;
+template<> ArmFault::FaultVals ArmFaultVals<PCAlignmentFault>::vals;
+template<> ArmFault::FaultVals ArmFaultVals<SPAlignmentFault>::vals;
+template<> ArmFault::FaultVals ArmFaultVals<SystemError>::vals;
+template<> ArmFault::FaultVals ArmFaultVals<FlushPipe>::vals;
+template<> ArmFault::FaultVals ArmFaultVals<ArmSev>::vals;
+
+
} // namespace ArmISA
#endif // __ARM_FAULTS_HH__