5
5
/* */
6
6
/* OpenPOWER HostBoot Project */
7
7
/* */
8
- /* Contributors Listed Below - COPYRIGHT 2014,2020 */
8
+ /* Contributors Listed Below - COPYRIGHT 2014,2022 */
9
9
/* [+] International Business Machines Corp. */
10
10
/* */
11
11
/* */
28
28
namespace Util
29
29
{
30
30
31
- bool isSimics () __attribute__((alias ("__isSimicsRunning" )));
32
- extern "C" bool __isSimicsRunning () NEVER_INLINE ;
31
+ bool __isSimicsRunning () NEVER_INLINE ;
33
32
34
33
bool __isSimicsRunning ()
35
34
{
@@ -40,12 +39,11 @@ bool __isSimicsRunning()
40
39
41
40
bool isSimicsRunning ()
42
41
{
43
- static bool simics = isSimics ();
42
+ static bool simics = __isSimicsRunning ();
44
43
return simics ;
45
44
}
46
45
47
46
48
- bool isQmeModelEnabled () __attribute__((alias ("__isQmeEnabled" )));
49
47
extern "C" bool __isQmeEnabled () NEVER_INLINE ;
50
48
51
49
bool __isQmeEnabled ()
@@ -58,7 +56,7 @@ bool __isQmeEnabled()
58
56
bool requiresSecondaryCoreWorkaround ()
59
57
{
60
58
static const auto required =
61
- isSimicsRunning () && !isQmeModelEnabled ();
59
+ isSimicsRunning () && !__isQmeEnabled ();
62
60
return required ;
63
61
}
64
62
@@ -86,10 +84,14 @@ void setIsConsoleStarted()
86
84
g_isConsoleStarted = true;
87
85
}
88
86
89
- bool isMultiprocSupported () __attribute__((alias ("__isMultiprocSupported" )));
90
87
extern "C" bool __isMultiprocSupported () NEVER_INLINE ;
91
88
92
89
bool __isMultiprocSupported ()
90
+ {
91
+ return MAGIC_INST_CHECK_FEATURE (MAGIC_FEATURE__MULTIPROC );
92
+ }
93
+
94
+ bool isMultiprocSupported ()
93
95
{
94
96
bool multiprocSupport = true;
95
97
@@ -98,7 +100,7 @@ bool __isMultiprocSupported()
98
100
#else
99
101
if (isSimicsRunning ())
100
102
{
101
- multiprocSupport = MAGIC_INST_CHECK_FEATURE ( MAGIC_FEATURE__MULTIPROC );
103
+ multiprocSupport = __isMultiprocSupported ( );
102
104
}
103
105
#endif
104
106
0 commit comments