Path: utzoo!attcan!uunet!tut.cis.ohio-state.edu!ucbvax!hplabs!hpfcso!mjs From: mjs@hpfcso.HP.COM (Marc Sabatella) Newsgroups: comp.sys.hp Subject: Re: HP-UX 7.0 experience Message-ID: <7370090@hpfcso.HP.COM> Date: 1 Mar 90 16:25:30 GMT References: <1990Mar1.005350.5060@uncecs.edu> Organization: Hewlett-Packard, Fort Collins, CO, USA Lines: 42 >We also get complaints from ld of the form "Possible >floating point incompatibility, recompile with +O1 option." >Anyone know what this is about? We're running plain-jane 360/370's >using the cc -g option. What happened was that the floating point register save/restore conventions changed between 6.2 and 6.5, to satisfy the global optimizer. We put a mark in each object file to say if it uses the old or new conventions; most importantly, we put a mark on those new files which not only support the new conventions, but depend on routines that it calls to support them as well. If the linker sees one of the latter object files, and one that was compiled pre-6.5, it complains, since it is possible a routine in the new object file may call a routine in the old object file (directly or indirectly) and thus be messed up since the old routine didn't save/restore the necessary registers. Since you say you are compiling things "-g", that implies not "-O", so you don't have any of the code that requires other modules to use the new conventions. Similarly, since you are recompiling under 7.0, you don't have any of the code that uses the old conventions. Thus it must be some libraries you are using. The easiest way to tell what is going on is to pass "-v" to the linker (via "-Wl,-v" if you are using the compiler driver to perform the link). It will spit all sorts of information at you. You are looking for a line which says something is "version 0" (meaning old conventions) and another saying something is "version 3" (meaning it requires things it calls to use new conventions). Your modules should all be coming out "version 2", meaning they support the new conventions, but do not depend on things they call to do the same. Once you find the offending 0's and 3's, your workaround is to either recompile the things that were "3" using "+O1" (or no optimization at all), which will turn them back into 2's; or to recompile the things that were 0 using any options you want, so they will become anything but 0. Note that just because you optimize something ("-O"), that doesn't mean it will come out 3; it will still come out 2 unless it actually makes a lot of use of floating point. -------------- Marc Sabatella (marc%hpfcrt@hplabs.hp.com) Disclaimers: 2 + 2 = 3, for suitably small values of 2 Bill and Dave may not always agree with me