libjli, get_cpuid() implementation missing for MacOs, breaks libjli.so build in slowdebug
Thomas Stüfe
thomas.stuefe at gmail.com
Fri Mar 6 12:40:17 UTC 2015
Hi all,
I see a build error when building the libjli on MacOs with slowdebug:
Undefined symbols for architecture x86_64:
"_get_cpuid", referenced from:
_hyperthreading_support in ergo_i586.o
_logical_processors_per_package in ergo_i586.o
ld: symbol(s) not found for architecture x86_64
The reason seems to me that is that in ergo_i586.c, the implementation for
"get_cpuid()" is missing for the MacOS case (one is provided for solaris
and linux).
This only breaks the build in slowdebug, because the function is only used
from static functions which are not exported; so when building with
optimization (e.g. fastdebug), all these functions are thrown away by the
compiler and therefore get_cpuid() is not needed.
I opened a bug:
https://bugs.openjdk.java.net/browse/JDK-8074547
but do not provide a fix because I am not sure which way to fix this:
- one could provide an empty implementation for this function
- or one could provide a fully functional implementation
Also, maybe I overlooked something and my analysis is wrong.
What do you guys think?
Kind Regards, Thomas Stuefe
More information about the macosx-port-dev
mailing list