Add new toolchain and driver options for the M68k target
Details
Diff Detail
Event Timeline
- Use the canonical CPU name (i.e. names started with upper case 'M')
- Tell the driver to use integrated assembler (i.e. MC) by default
Some very minor nits - the 68060 omission is the biggest one (apple might not have used it but commodore did!)
clang/include/clang/Driver/Options.td | ||
---|---|---|
168 | (sorting) put this before mips? | |
clang/lib/Driver/ToolChains/Arch/M68k.cpp | ||
45 | Why no 68060 ? | |
65 | (style) remove unnecessary braces? | |
73 | (clang-format) indentation? | |
95 | remove braces | |
clang/lib/Driver/ToolChains/Arch/M68k.h | ||
36 | (clang-format) indentation? | |
39 | (clang-tidy) end namespace tools | |
clang/lib/Driver/ToolChains/Clang.cpp | ||
383 | (sorting) move before msp430 ? | |
clang/lib/Driver/ToolChains/CommonArgs.cpp | ||
371 | (sorting) move down to before mips ? |
clang/lib/Driver/ToolChains/Arch/M68k.cpp | ||
---|---|---|
52 | Can't we just use StringSwitch here? |
clang/include/clang/Driver/Options.td | ||
---|---|---|
3234 | Unless you are planning to add 100 or more target variations I'd prefer to see these explicitly defined instead of a foreach. If I'm grepping for a specific CPU variation in the code base it's nice to get that information easily. | |
clang/lib/Driver/ToolChains/Arch/M68k.cpp | ||
38 | No need for this else here. | |
52 | +1 | |
65 | and also the unnecessary elses. |
clang/include/clang/Driver/Options.td | ||
---|---|---|
3234 | Update: I've just put the sub-target (skeleton) for M68060. So now you can specific M68060 :-) | |
clang/lib/Driver/ToolChains/Arch/M68k.cpp | ||
45 | @RKSimon Just added 060's support :-) |
clang/include/clang/Driver/Options.td | ||
---|---|---|
164 | Looks like this is missing clang-format? |
clang/include/clang/Driver/Options.td | ||
---|---|---|
164 | I don't think clang-format really understands tablegen files. |
clang/include/clang/Driver/Options.td | ||
---|---|---|
164 | It does not. Don't clang-format table-gen files, the end result is horrendous. :) |
LGTM, it would be great if someone else stamps this too, in case I missed something.
clang/include/clang/Driver/Options.td | ||
---|---|---|
164 | Thanks for pointing out, thinko for "please format" |
clang/lib/Driver/ToolChains/Gnu.cpp | ||
---|---|---|
2103 | Aren't these arrays only used on multiarch systems so irrelevant for BSDs? There aren't FreeBSD triples listed for X86/X86_64 for example. |
clang/lib/Driver/ToolChains/Gnu.cpp | ||
---|---|---|
2103 | Makes sense. |