<html lang="en">
<head>
<title>HPPA ELF32 - Untitled</title>
<meta http-equiv="Content-Type" content="text/html">
<meta name="description" content="Untitled">
<meta name="generator" content="makeinfo 4.8">
<link title="Top" rel="start" href="index.html#Top">
<link rel="up" href="Machine-Dependent.html#Machine-Dependent" title="Machine Dependent">
<link rel="prev" href="ARM.html#ARM" title="ARM">
<link rel="next" href="MMIX.html#MMIX" title="MMIX">
<link href="http://www.gnu.org/software/texinfo/" rel="generator-home" title="Texinfo Homepage">
<meta http-equiv="Content-Style-Type" content="text/css">
<style type="text/css"><!--
@import url("../raisonance.css");
  pre.display { font-family:inherit }
  pre.format  { font-family:inherit }
  pre.smalldisplay { font-family:inherit; font-size:smaller }
  pre.smallformat  { font-family:inherit; font-size:smaller }
  pre.smallexample { font-size:smaller }
  pre.smalllisp    { font-size:smaller }
  span.sc    { font-variant:small-caps }
  span.roman { font-family:serif; font-weight:normal; } 
  span.sansserif { font-family:sans-serif; font-weight:normal; } 
--></style>
</head>
<body>
<div class="node">
<p>
<a name="HPPA-ELF32"></a>
Next:&nbsp;<a rel="next" accesskey="n" href="MMIX.html#MMIX">MMIX</a>,
Previous:&nbsp;<a rel="previous" accesskey="p" href="ARM.html#ARM">ARM</a>,
Up:&nbsp;<a rel="up" accesskey="u" href="Machine-Dependent.html#Machine-Dependent">Machine Dependent</a>
<hr>
</div>

<h3 class="section">4.4 <samp><span class="command">ld</span></samp> and HPPA 32-bit ELF Support</h3>

<p><a name="index-HPPA-multiple-sub_002dspace-stubs-525"></a><a name="index-g_t_002d_002dmulti_002dsubspace-526"></a>When generating a shared library, <samp><span class="command">ld</span></samp> will by default generate
import stubs suitable for use with a single sub-space application. 
The `<samp><span class="samp">--multi-subspace</span></samp>' switch causes <samp><span class="command">ld</span></samp> to generate export
stubs, and different (larger) import stubs suitable for use with
multiple sub-spaces.

   <p><a name="index-HPPA-stub-grouping-527"></a><a name="index-g_t_002d_002dstub_002dgroup_002dsize_003d_0040var_007bN_007d-528"></a>Long branch stubs and import/export stubs are placed by <samp><span class="command">ld</span></samp> in
stub sections located between groups of input sections. 
`<samp><span class="samp">--stub-group-size</span></samp>' specifies the maximum size of a group of input
sections handled by one stub section.  Since branch offsets are signed,
a stub section may serve two groups of input sections, one group before
the stub section, and one group after it.  However, when using
conditional branches that require stubs, it may be better (for branch
prediction) that stub sections only serve one group of input sections. 
A negative value for `<samp><span class="samp">N</span></samp>' chooses this scheme, ensuring that
branches to stubs always use a negative offset.  Two special values of
`<samp><span class="samp">N</span></samp>' are recognized, `<samp><span class="samp">1</span></samp>' and `<samp><span class="samp">-1</span></samp>'.  These both instruct
<samp><span class="command">ld</span></samp> to automatically size input section groups for the branch types
detected, with the same behaviour regarding stub placement as other
positive or negative values of `<samp><span class="samp">N</span></samp>' respectively.

   <p>Note that `<samp><span class="samp">--stub-group-size</span></samp>' does not split input sections.  A
single input section larger than the group size specified will of course
create a larger group (of one section).  If input sections are too
large, it may not be possible for a branch to reach its stub.

   <p><a name="index-VFP11_005fDENORM_005fFIX-529"></a><a name="index-g_t_002d_002dvfp11_002ddenorm_002dfix-530"></a>The `<samp><span class="samp">--vfp11-denorm-fix</span></samp>' switch enables a link-time workaround for a
bug in certain VFP11 coprocessor hardware, which sometimes allows
instructions with denorm operands (which must be handled by support code)
to have those operands overwritten by subsequent instructions before
the support code can read the intended values.

   <p>The bug may be avoided in scalar mode if you allow at least one
intervening instruction between a VFP11 instruction which uses a register
and another instruction which writes to the same register, or at least two
intervening instructions if vector mode is in use. The bug only affects
full-compliance floating-point mode: you do not need this workaround if
you are using "runfast" mode. Please contact ARM for further details.

   <p>This workaround is enabled for scalar code by default for
pre-ARMv7 architectures, but disabled by default for later
architectures. If you know you are not using buggy VFP11 hardware,
you can disable the workaround by specifying the linker option
`<samp><span class="samp">--vfp-denorm-fix=none</span></samp>'. If you are using VFP vector mode, you
should specify `<samp><span class="samp">--vfp-denorm-fix=vector</span></samp>'.

   <p>If the workaround is enabled, instructions are scanned for
potentially-troublesome sequences, and a veneer is created for each
such sequence which may trigger the erratum. The veneer consists of the
first instruction of the sequence and a branch back to the subsequent
instruction. The original instruction is then replaced with a branch to
the veneer. The extra cycles required to call and return from the veneer
are sufficient to avoid the erratum in both the scalar and vector cases.

   </body></html>

