[cfe-dev] Targeting ARM with Clang
anton at korobeynikov.info
Mon Jul 19 14:57:03 PDT 2010
> Ideally what would be needed for a target configuration file to specify?
> Where should these specifications be housed? I would assume maybe relative to the clang driver ../etc/clang/ ?
> What format should they use? I assume some sort of text, but should it be config file, xml etc?
>From my feeling, first of all one needs to unify all the places, where
the configuration data is used.
Currently there are at least two completely different places:
- Preprocessor (which uses paths for includes & similar stuff)
- Driver itself
> Locations of the assembler and the linker for the target (potentially either relative to clang or absolute on the system)
> ^ what other actions would be sane here?
Sometimes extra post-link step is required. E.g. dsymutil on darwin.
> Specifications for a assembly pre-processor (in my case usable for double checking the assembly output and replacing a few incompatible calls)
> Specifications for a linker post-processor (usable to perform build tasks like archival, or ant builds for JNI projects, bundle creation etc)
? This definitely should be done outside of clang driver.
> A flags for default for blocks, integrated assembler, non-fragile-abi, objc legacy dispatch, mixed dispatch, stack protection levels, unwind tables, relocation models, pic models, objc-gc, dwarf, and SjLj exceptions (these would all allow a fully text based implementation of a ToolChain)
All this is already implemented. No need to some additional stuff in most cases.
See http://clang.llvm.org/UniversalDriver.html as well.
With best regards, Anton Korobeynikov
Faculty of Mathematics and Mechanics, Saint Petersburg State University
More information about the cfe-dev