build_vm_def.sh broken on macosx?

Magnus Ihse Bursie magnus.ihse.bursie at oracle.com
Thu Jan 21 10:37:36 UTC 2016


Hi,

It seems that build_vm_def.sh is broken on macosx. The script lists all 
from *.o using nm, and filters them using this awk expression:
'{ if ($3 ~ /^_ZTV/ || $3 ~ /^gHotSpotVM/) print "\t" $3 }'

However, the typical output from nm on macosx looks like this:
__ZTV10methodOper
__ZTV11MachNopNode

That is, only a single column, and two leading underscore. The awk 
expression will fail to match anything, and an empty vm.def will be 
produced.

If I modify the script to:
'{ if ($1 ~ /^__ZTV/ || $1 ~ /^_gHotSpotVM/) print "\t" $1 }'
then it will match and print these symbols.

The build_vm_def.sh script has not been modified since 2013, so if this 
ever worked, then most likely the nm output has changed in Xcode at some 
point.

My main concern here is the new hotspot build. Does this mean that the 
vm.def fills no purpose on the macosx build, and that the whole process 
of running nm on all object files can be skipped? Or is this a bug that 
has not been discovered? If so, it should be fixed in the old build.

/Magnus


More information about the hotspot-dev mailing list