Red Hat axp-list: Linux on Alpha (1995-2022)
 help / color / mirror / Atom feed
* relocation truncated to fit: GPREL16 .sbss
@ 2003-08-14 17:32 Uncle George
  2003-08-14 23:35 ` Kelledin
  0 siblings, 1 reply; 3+ messages in thread
From: Uncle George @ 2003-08-14 17:32 UTC (permalink / raw)
  To: axp-list

Does anyone know what the deal is with the mysterious GPREL16 stuff is!

: relocation truncated to fit: GPREL16 .sbss
../unxlnga.pro/slo/fmgridif.o(.text+0x191f4): In function `__tcf_6':
: relocation truncated to fit: GPREL16 .sbss
../unxlnga.pro/slo/deflt3d.o(.text+0x154): In function 
`E3dDefaultAttributes::Reset()':
: relocation truncated to fit: GPREL16 .sdata
../unxlnga.pro/slo/deflt3d.o(.text+0x15c): In function 
`E3dDefaultAttributes::Reset()':
: relocation truncated to fit: GPREL16 .sdata
../unxlnga.pro/slo/deflt3d.o(.text+0x21c): In function 
`E3dDefaultAttributes::Reset()':
: relocation truncated to fit: GPREL16 .sdata
collect2: ld returned 1 exit status




^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: relocation truncated to fit: GPREL16 .sbss
  2003-08-14 17:32 relocation truncated to fit: GPREL16 .sbss Uncle George
@ 2003-08-14 23:35 ` Kelledin
  2003-08-15 15:30   ` Uncle George
  0 siblings, 1 reply; 3+ messages in thread
From: Kelledin @ 2003-08-14 23:35 UTC (permalink / raw)
  To: axp-list

On Thursday 14 August 2003 12:32 pm, Uncle George wrote:
> Does anyone know what the deal is with the mysterious GPREL16
> stuff is!
>
> : relocation truncated to fit: GPREL16 .sbss
>
> ../unxlnga.pro/slo/fmgridif.o(.text+0x191f4): In function 
`__tcf_6':
> : relocation truncated to fit: GPREL16 .sbss
>
> ../unxlnga.pro/slo/deflt3d.o(.text+0x154): In function
>
> `E3dDefaultAttributes::Reset()':
> : relocation truncated to fit: GPREL16 .sdata
>
> ../unxlnga.pro/slo/deflt3d.o(.text+0x15c): In function
>
> `E3dDefaultAttributes::Reset()':
> : relocation truncated to fit: GPREL16 .sdata
>
> ../unxlnga.pro/slo/deflt3d.o(.text+0x21c): In function
>
> `E3dDefaultAttributes::Reset()':
> : relocation truncated to fit: GPREL16 .sdata
>
> collect2: ld returned 1 exit status

Hmmm.  AFAIK gcc shouldn't be generating GPREL16 symbols unless 
it's run with the -msmall-data option turned on, either 
explicitly or implicitly.  GPREL16 is a 16-bit GP-relative 
relocation, used to address static data (in the .sdata section).  
Using GPREL16 limits your static data area to 64K; using GPREL32 
(32-bit GP-relative relocation) limits your static data area to 
4GB.  The default is GPREL32, for obvious reasons.

Chances are, the source code is built with -msmall-data, or it's 
built with -fpic (which implies -msmall-data) instead of -fPIC 
(which implies -mlarge-data).  Then these errors are caused by 
having too much static data to fit in 64K.  If that's not the 
case, I would suspect it's a toolchain bug.

You can read up on these options in the gcc man page.

-- 
Kelledin
"If a server crashes in a server farm and no one pings it, does 
it still cost four figures to fix?"



^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: relocation truncated to fit: GPREL16 .sbss
  2003-08-14 23:35 ` Kelledin
@ 2003-08-15 15:30   ` Uncle George
  0 siblings, 0 replies; 3+ messages in thread
From: Uncle George @ 2003-08-15 15:30 UTC (permalink / raw)
  To: axp-list

It is using -fpic.  It has always been using -fpic.
Interesting that it now shows this anomaly. Will try -fPIC, and see if 
that resolves it.
/gat

BTW GPRELxx is not mentioned in man pages. Nor is there any man-info as 
to what might be causing ( ie truncated bec -msmall-data or -fpic is set 
) the messages.

 Kelledin wrote:

>On Thursday 14 August 2003 12:32 pm, Uncle George wrote:
>  
>
>>Does anyone know what the deal is with the mysterious GPREL16
>>stuff is!
>>
>>: relocation truncated to fit: GPREL16 .sbss
>>
>>../unxlnga.pro/slo/fmgridif.o(.text+0x191f4): In function 
>>    
>>
>`__tcf_6':
>  
>
>>: relocation truncated to fit: GPREL16 .sbss
>>
>>../unxlnga.pro/slo/deflt3d.o(.text+0x154): In function
>>
>>`E3dDefaultAttributes::Reset()':
>>: relocation truncated to fit: GPREL16 .sdata
>>
>>../unxlnga.pro/slo/deflt3d.o(.text+0x15c): In function
>>
>>`E3dDefaultAttributes::Reset()':
>>: relocation truncated to fit: GPREL16 .sdata
>>
>>../unxlnga.pro/slo/deflt3d.o(.text+0x21c): In function
>>
>>`E3dDefaultAttributes::Reset()':
>>: relocation truncated to fit: GPREL16 .sdata
>>
>>collect2: ld returned 1 exit status
>>    
>>
>
>Hmmm.  AFAIK gcc shouldn't be generating GPREL16 symbols unless 
>it's run with the -msmall-data option turned on, either 
>explicitly or implicitly.  GPREL16 is a 16-bit GP-relative 
>relocation, used to address static data (in the .sdata section).  
>Using GPREL16 limits your static data area to 64K; using GPREL32 
>(32-bit GP-relative relocation) limits your static data area to 
>4GB.  The default is GPREL32, for obvious reasons.
>
>Chances are, the source code is built with -msmall-data, or it's 
>built with -fpic (which implies -msmall-data) instead of -fPIC 
>(which implies -mlarge-data).  Then these errors are caused by 
>having too much static data to fit in 64K.  If that's not the 
>case, I would suspect it's a toolchain bug.
>
>You can read up on these options in the gcc man page.
>
>  
>




^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2003-08-15 15:20 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-08-14 17:32 relocation truncated to fit: GPREL16 .sbss Uncle George
2003-08-14 23:35 ` Kelledin
2003-08-15 15:30   ` Uncle George

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox