We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 99ef76f + bf23104 commit 9d6eeeaCopy full SHA for 9d6eeea
getarch.c
@@ -90,7 +90,9 @@ USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
90
#include <sys/sysinfo.h>
91
#include <unistd.h>
92
#endif
93
-#if defined(AIX)
+#if defined(_AIX)
94
+#include <unistd.h>
95
+#include <sys/systemcfg.h>
96
97
98
@@ -1870,11 +1872,13 @@ static int get_num_cores(void) {
1870
1872
1871
1873
return count;
1874
-#elif defined(AIX)
1875
+#elif defined(_AIX)
1876
//returns the number of processors which are currently online
1877
count = sysconf(_SC_NPROCESSORS_ONLN);
1878
if (count <= 0) count = 2;
-
1879
+
1880
+ return count;
1881
1882
#else
1883
return 2;
1884
0 commit comments