fix for mode attribute stuff
authorMatthias Braun <matze@braunis.de>
Tue, 12 Aug 2008 13:35:43 +0000 (13:35 +0000)
committerMatthias Braun <matze@braunis.de>
Tue, 12 Aug 2008 13:35:43 +0000 (13:35 +0000)
[r21124]

parser.c

index f1adb8e..47556d6 100644 (file)
--- a/parser.c
+++ b/parser.c
@@ -1293,13 +1293,16 @@ static void parse_gnu_attribute_mode_arg(gnu_attribute_t *attribute)
        /* This isn't really correct, the backend should provide a list of machine
         * specific modes (according to gcc philosophy that is...) */
        const char *symbol_str = token.v.symbol->string;
-       if(strcmp_underscore("QI", symbol_str) == 0) {
+       if (strcmp_underscore("QI",   symbol_str) == 0 ||
+           strcmp_underscore("byte", symbol_str) == 0) {
                attribute->u.akind = ATOMIC_TYPE_CHAR;
        } else if (strcmp_underscore("HI", symbol_str) == 0) {
                attribute->u.akind = ATOMIC_TYPE_SHORT;
-       } else if(strcmp_underscore("SI", symbol_str) == 0) {
+       } else if (strcmp_underscore("SI",      symbol_str) == 0
+               || strcmp_underscore("word",    symbol_str) == 0
+               || strcmp_underscore("pointer", symbol_str) == 0) {
                attribute->u.akind = ATOMIC_TYPE_INT;
-       } else if(strcmp_underscore("DI", symbol_str) == 0) {
+       } else if (strcmp_underscore("DI", symbol_str) == 0) {
                attribute->u.akind = ATOMIC_TYPE_LONGLONG;
        } else {
                warningf(HERE, "ignoring unknown mode '%s'", symbol_str);