Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can clang compile 64-bit code? #122

Open
Tracked by #2838
wjk opened this issue Aug 31, 2015 · 3 comments
Open
Tracked by #2838

Can clang compile 64-bit code? #122

wjk opened this issue Aug 31, 2015 · 3 comments

Comments

@wjk
Copy link

wjk commented Aug 31, 2015

I was trying to manually compile some code as 64-bit, but when I pass the -m64 flag to WinObjC clang, it fails with the following error:

failed to load c2 (file not found)

It seems that the MSVC 64-bit backend is missing. However, the rest of my project is also marked as 64-bit (using the MSBuild $(Platform) variable), and compiles just fine. What is going on here? Is there another flag I need to pass to Clang to get it to compile correctly as 64-bit?

@wjk
Copy link
Author

wjk commented Aug 31, 2015

As it turns out, none of my code is compiled as 64-bit. Even though the MSBuild $(Platform) variable was set to x64, inspecting the resulting object files using dumpbin.exe reveals that they are compiled as x86. It seems that none of the compiler toolchain supports 64-bit executables. @s5msft @jmsaunders-ms is there any way to change this?

@jmsaunders-ms
Copy link
Contributor

jmsaunders-ms commented Aug 31, 2015

You're right, clang/c2 for Objective-C does not presently support codegen for x64. This is something we're aware of. ARM support and optimizations have higher priority than x64 code generation, so I would expect to see support after those.

@DHowett-MSFT
Copy link

Clang can now do this, but the rest of WinObjC can't!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

7 participants