[LLVMbugs] [Bug 17633] New: Link error 'text relocs not supported for x86_64' when using -fsanitize=function

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Mon Oct 21 06:47:15 PDT 2013


            Bug ID: 17633
           Summary: Link error 'text relocs not supported for x86_64' when
                    using -fsanitize=function
           Product: clang
           Version: trunk
          Hardware: Macintosh
                OS: MacOS X
            Status: NEW
          Severity: normal
          Priority: P
         Component: -New Bugs
          Assignee: unassignedclangbugs at nondot.org
          Reporter: jonathan.sauer at gmx.de
                CC: llvmbugs at cs.uiuc.edu
    Classification: Unclassified

Created attachment 11398
  --> http://llvm.org/bugs/attachment.cgi?id=11398&action=edit
Complete log of clang run

The following code (adapted from clang's
test/CodeGenCXX/catch-undef-behavior.cpp) results in a link error with clang
r193073 on Mac OS X 10.6.8 x86_64:

void indirect_function_call(void (*p)(int))

int main()

This results in (full log attached):

% ~/LLVM/build/Release+Asserts/bin/clang++ -stdlib=libc++ -fsanitize=function
-v clang.cpp
clang version 3.4 (trunk 193073)
Target: x86_64-apple-darwin10.8.0
ld: text relocs not supported for x86_64 in __Z22indirect_function_callPFviE
from /var/folders/RI/RI4iqAygH0OWeTzP0+rLU++++TI/-Tmp-/clang-655d62.o
clang: error: linker command failed with exit code 1 (use -v to see invocation)

Is the function sanitizer intended to be unavailable on Mac OS X x86_64? (in
which case this should probably be mentioned in the documention, and the
function sanitizer should not be included in -fsanitize=undefined on that

You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20131021/df6ac828/attachment.html>

More information about the llvm-bugs mailing list