[cfe-dev] [PATCH] Add preliminary Alpha support

Matt Turner mattst88 at gmail.com
Fri May 13 05:57:20 PDT 2011


On Wed, May 11, 2011 at 4:48 PM, Andrew Lenharth <andrewl at lenharth.org> wrote:
> On Wed, May 11, 2011 at 3:40 PM, Matt Turner <mattst88 at gmail.com> wrote:
>> Signed-off-by: Matt Turner <mattst88 at gmail.com>
>> ---
>> So LLVM's Alpha backend works, somewhat. It generates code that segfaults at
>> any optimization level except -O0, but this is a start at reviving it.
>
> The patch looks good, but I haven't looked at clang stuff for quite a
> while.  Others can comment more here.
>
>> Things I'm unsure about:
>>        DescriptionString - I think everything is natually aligned, but the MIPS
>>        desc string I looked at specified 32-bit alignment for 8 and 16-bit units.
>>
>>        getDefaultFeatures - This seems to be where ISA additions should be created,
>>        or something, but I see 'FIXME: This should not be here.' in other arch's
>>        code. So, what goes here?
>
> If your assumption is correct, then probably nothing.  I took 21164
> support out a few years ago, so only 21264 features are supported.
>
>>        getTargetDefines - I don't know what this function does. Sets what the
>>        preprocessor is supposed to define? gcc defines __alpha__ and some other
>>        things dependent on features supported. Should these things be defined here?
>>
>>        getTargetBuiltins - No idea what this is.
>
> I would assume things like:
> __builtin_alpha_mskwh
> __builtin_alpha_minub8
>
>>        validateAsmConstraint - I think this is for validating inline assembly inputs
>>        and outputs? If so, this shouldn't be a problem.
>
> Yes.  I think you should only need to check INT/FP ness to validate most asm.
>
>>        getClobbers - Must be for inline assembly. The only relevant comments I see
>>        in other code is '// FIXME: Is this really right?', so not terribly helpful.
>
> There shouldn't be hidden clobbers, so this doesn't seem too bad.

Thanks for the review. Since there don't seem to be any NAKs, can we
commit this and I'll send follow-up patches to fill out things like
validateAsmConstraint?

Thanks,
Matt




More information about the cfe-dev mailing list