On Thursday, September 15, 2011, Måns Rullgård <[email protected]> wrote: > Sean McGovern <[email protected]> writes: > >> On Thursday, September 15, 2011, Måns Rullgård <[email protected]> wrote: >>> Sean McGovern <[email protected]> writes: >>> >>>> On Wednesday, September 14, 2011, Måns Rullgård <[email protected]> wrote: >>>>> Sean McGovern <[email protected]> writes: >>>>> >>>>>> On Tue, Sep 13, 2011 at 10:38 PM, Diego Biurrun <[email protected]> >> wrote: >>>>>>> On Tue, Sep 06, 2011 at 12:42:09AM -0400, Sean McGovern wrote: >>>>>>>> The Solaris linker will correctly mark an executable with each >>>>>>>> instruction set it encounters when building an >>>>>>>> executable. However, our libraries have their own functionality >>>>>>>> and guards for processor-specific code. >>>>>>>> >>>>>>>> So, instead suppress creation of the hardware capabilities ELF section. >>>>>>>> --- a/configure >>>>>>>> +++ b/configure >>>>>>>> @@ -2369,6 +2369,7 @@ case $target_os in >>>>>>>> enabled x86 && SHFLAGS="-mimpure-text $SHFLAGS" >>>>>>>> network_extralibs="-lsocket -lnsl" >>>>>>>> add_cppflags -D__EXTENSIONS__ >>>>>>>> + echo "hwcap_1 = OVERRIDE;" > mapfile && add_ldflags -Wl,-M,mapfile >>>>>>>> nm_opts='-P -g' >>>>>>>> ;; >>>>>>> >>>>>>> It seems to me this is specific to the Sun Studio compiler/linker. >>>>>>> We have a section for that compiler in configure. Moving this >>>>>>> block there would contain the hack to the only place where it is >>>>>>> really needed. >>>>>> >>>>>> You are correct that this is really a Sun Studio requirement. However, >>>>>> configure does not know $arch until later in the script. >>>>> >>>>> There is a late block of compiler-specific stuff too, probably for >>>>> reasons like this. >>>> >>>> So is it now reasonable to go ahead with the original patch as is? >>> >>> I don't think so. It is needed only on solaris/x86 when using the >>> sunstudio linker. What linker does gcc on solaris use? >> >> Maybe I described it wrong -- both gcc and Solaris Studio use the same >> linker (/usr/ccs/bin/ld) but different assemblers. The Sun assembler >> instruments it's output such that the linker can build and embed the >> instruction set list correctly. GNU gas does not do this on Solaris. > > So what are the exact conditions which require this flag? Is it needed > on sparc as well as x86? > > -- > Måns Rullgård > [email protected] > _______________________________________________ > libav-devel mailing list > [email protected] > https://lists.libav.org/mailman/listinfo/libav-devel >
Any reasonably modern SPARC processor (read: within the past 10 years) hasn't had radical and divergent changes in instruction sets compared it x86. It would be equally instrumented there but would advertize instruction in VIS or VIS2 that even my old sun4u supported. If we need/want to constrain this to 'solaris and suncc and x86', it can only go where it was placed in this original patch (with an added 'enabled x86 &&' at the front).
_______________________________________________ libav-devel mailing list [email protected] https://lists.libav.org/mailman/listinfo/libav-devel
