[cfe-dev] ld linker freezes my computer

Andrew Pennebaker andrew.pennebaker at gmail.com
Mon Oct 15 13:08:26 PDT 2012


Summary:

Attempting to link a clang i386 object file into a Mac executable results
in my computer becoming nonresponsive.

I inquired about assembling code with the GNU assembler (Gas AKA as). As
Xcode contains an old linker, as 1.38, Apple advised using clang instead,
per ticket 12408921 (
https://bugreport.apple.com/cgi-bin/WebObjects/RadarWeb.woa/3/wo/UMrtsuR9aIxsbFCn1P0R4w/5.83.28.0.9
).

Steps to Reproduce:

1. Download the Hello World Gas code (
https://github.com/mcandre/mcandre/tree/master/gas/hello/freebsd).
2. Run "make".

Expected Results:

3. The object code is linked into an executable, and then the executable is
run.

$ make
clang -c -o hello.o -arch i386 hello.s
ld -o hello -macosx_version_min 10.6 hello.o
./hello
Hello World!

Actual Results:

3. The computer freezes up.

$ make
clang -c -o hello.o -arch i386 hello.s
ld -o hello -macosx_version_min 10.6 hello.o
(frozen)

Attempts to stop the linker with Control+C, quitting Terminal.app, Force
Quit Applications, and Activity Monitor fail, as the system becomes too
slow to process user input.

Specs:

* ld64-134.9
* clang 4.1
* as 1.38
* Xcode 4.5
* Mac OS X 10.8.2
* MacBook Pro 2009

-- 
Cheers,

Andrew Pennebaker
www.yellosoft.us
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20121015/0df4b877/attachment.html>


More information about the cfe-dev mailing list