http://llvm.org/bugs/show_bug.cgi?id=22850

            Bug ID: 22850
           Summary: [MachO] Wrong indirect symbols
           Product: libraries
           Version: 3.6
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: P
         Component: MC
          Assignee: [email protected]
          Reporter: [email protected]
                CC: [email protected]
    Classification: Unclassified

There seems to be a really bad bug with indirect symbols.

$ cat test.c

void bar1(void);
void bar2(void);
void bar3(void);
void bar4(void);

void foo(void) { bar1(); bar2(); bar3(); bar4(); }

// EOF

$ clang-3.6.0 -target powerpc-apple-darwin -fPIC -Wall -W -c test.c

$ otool -Iv test.o

test.o:
Indirect symbols for (__TEXT,__picsymbolstub1) 4 entries
address    index name
0x00000040     1 _bar1
0x00000060     1 _bar1
0x00000080     2 _bar2
0x000000a0     2 _bar2
Indirect symbols for (__DATA,__la_symbol_ptr) 4 entries
address    index name
0x000000c0     1 _bar1
0x000000c4     2 _bar2
0x000000c8     2 _bar2
0x000000cc     3 _bar3

$ otool -lv test.o | grep -i indirect

 reserved1 0 (index into indirect symbol table)
 reserved1 1 (index into indirect symbol table)
 indirectsymoff 876
  nindirectsyms 8

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
LLVMbugs mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/llvmbugs

Reply via email to