]> granicus.if.org Git - clang/commit
Add AVR target and toolchain to Clang
authorDylan McKay <dylanmckay34@gmail.com>
Thu, 5 Jan 2017 05:20:27 +0000 (05:20 +0000)
committerDylan McKay <dylanmckay34@gmail.com>
Thu, 5 Jan 2017 05:20:27 +0000 (05:20 +0000)
commit86d841363774396eeea1e0a5983a112a62c54447
tree6c2ac938a661f68a9f3de20bf16d175a5530a091
parent0738ab99fd30ec6658d5550a2d50409247a73090
Add AVR target and toolchain to Clang

Summary:
Authored by Senthil Kumar Selvaraj

This patch adds barebones support in Clang for the (experimental) AVR target. It uses the integrated assembler for assembly, and the GNU linker for linking, as lld doesn't know about the target yet.

The DataLayout string is the same as the one in AVRTargetMachine.cpp. The alignment specs look wrong to me, as it's an 8 bit target and all types only need 8 bit alignment. Clang failed with a datalayout mismatch error when I tried to change it, so I left it that way for now.

Reviewers: rsmith, dylanmckay, cfe-commits, rengolin

Subscribers: rengolin, jroelofs, wdng

Differential Revision: https://reviews.llvm.org/D27123

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@291082 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Basic/Targets.cpp
lib/Driver/Driver.cpp
lib/Driver/ToolChains.cpp
lib/Driver/ToolChains.h
lib/Driver/Tools.cpp
lib/Driver/Tools.h
test/Driver/avr-toolchain.c [new file with mode: 0644]
test/Preprocessor/init.c