Topic
4 replies Latest Post - ‏2013-08-08T04:15:56Z by naveenhnr
naveenhnr
naveenhnr
4 Posts
ACCEPTED ANSWER

Pinned topic Relocation error on 32bit rs6000 binary

‏2012-11-07T06:20:27Z |
Hi there,

Recently we migrated AIX 6.1, with the new update I rebuilt my application. The builds completed successfully, but when I try running the 32bit binary built I get following error. The 64bit binary built on the same OS version is running fine. On AIX 5.3 I was not seeing any issues with both 32 and 64 bit binaries.

I appreciate if anybody could help me in letting me know about how to debug this issue. Note that I have already tried using "dump" command, but neither the entry number nor the address is not matching in the dump output. I have also tried updating to TL7, but it still did not help me.

exec(): 0509-036 Cannot load program xxx because of the following errors:
0509-140 Relocation failed for xxx because:
0509-143 Relocation entry 365919 (at address AC8)
specifies an address outside the .data section.
0509-143 Relocation entry 365920 (at address ACC)
specifies an address outside the .data section.
0509-143 Relocation entry 365921 (at address E3C)
0509-191 Examine .loader section relocation entries with the
'dump -Rv' command.
$ oslevel -s
6100-06-05-1115

Compiler version:
$ xlC -qversion
IBM XL C/C++ for AIX, V11.1 (5724-X13)
Version: 11.01.0000.0000

$ ld -V
ld: LD 1.65.1.14 (9/16/09)
Regards
Naveen
Updated on 2012-11-26T05:47:38Z at 2012-11-26T05:47:38Z by naveenhnr
  • flodstrom
    flodstrom
    112 Posts
    ACCEPTED ANSWER

    Re: Relocation error on 32bit rs6000 binary

    ‏2012-11-08T14:57:32Z  in response to naveenhnr
    Noticed that you are using a "vanilla" 11.1 compiler. You should apply a recent compiler PTF to see if that helps.
    • naveenhnr
      naveenhnr
      4 Posts
      ACCEPTED ANSWER

      Re: Relocation error on 32bit rs6000 binary

      ‏2012-11-09T06:26:41Z  in response to flodstrom
      Hi,

      I with new compiler updates, it still did not help me.

      IBM XL C/C++ for AIX, V11.1 (5724-X13)
      Version: 11.01.0000.0011

      Regards
      Naveen
  • naveenhnr
    naveenhnr
    4 Posts
    ACCEPTED ANSWER

    Re: Relocation error on 32bit rs6000 binary

    ‏2012-11-26T05:47:38Z  in response to naveenhnr
    Thanks for your reply Flodstrom! I got the issue. In one of my C++ file there was a huge array(more than 1MB) declared. When I reduce the size of this array to some kilo bytes I'm not seeing relocation error.

    The same code was perfectly working fine on older versions, don't know why it stared failing on the new compiler and OS(11.1 xlc & AIX 6.1).

    I'm now working on a reproducible test case. Meanwhile if anyone has any idea about this do let me know.

    Regards
    Naveen