From b3656137984c755671e79da32c66379c0a4d2425 Mon Sep 17 00:00:00 2001 From: "Kaveh R. Ghazi" Date: Sun, 9 Dec 2001 16:31:53 +0000 Subject: [PATCH] 1750a.md: Add default case in switch. * 1750a.md: Add default case in switch. * alpha/vms.h (INITIAL_ELIMINATION_OFFSET): Add abort clause in if-else statement. * dsp16xx.c (print_operand_address): Likewise. * i386/osf1elf.h (FUNCTION_PROFILER): Const-ify. * ia64.md: Add missing braces. * rs6000-protos.h (s8bit_cint_operand): Prototype. * s390.h (INITIAL_ELIMINATION_OFFSET): Add abort clause in if-else statement. * stormy16.h (REG_CLASS_CONTENTS): Add missing braces. * v850.h (OUTPUT_ADDR_CONST_EXTRA): Don't issue a `return'. * dbxout.c (dbxout_source_file): Move a variable into the scope where it is used. * final.c (profile_function): Mark parameter with ATTRIBUTE_UNUSED. * genemit.c (gen_expand): Likewise for generated file. * insn-addr.h (INSN_ADDRESSES_NEW): Avoid undefined behavior. From-SVN: r47812 --- gcc/ChangeLog | 18 ++++++++++++++++++ gcc/config/1750a/1750a.md | 2 ++ gcc/config/alpha/vms.h | 2 ++ gcc/config/dsp16xx/dsp16xx.c | 2 ++ gcc/config/i386/osf1elf.h | 6 +++--- gcc/config/ia64/ia64.md | 20 ++++++++++++-------- gcc/config/rs6000/rs6000-protos.h | 1 + gcc/config/s390/s390.h | 2 ++ gcc/config/stormy16/stormy16.h | 22 +++++++++++----------- gcc/config/v850/v850.h | 2 +- gcc/dbxout.c | 4 ++-- gcc/final.c | 2 +- gcc/genemit.c | 2 +- gcc/insn-addr.h | 2 +- 14 files changed, 59 insertions(+), 28 deletions(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 2dd9176d4a7..311c27137f5 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,5 +1,23 @@ 2001-12-09 Kaveh R. Ghazi + * 1750a.md: Add default case in switch. + * alpha/vms.h (INITIAL_ELIMINATION_OFFSET): Add abort clause in + if-else statement. + * dsp16xx.c (print_operand_address): Likewise. + * i386/osf1elf.h (FUNCTION_PROFILER): Const-ify. + * ia64.md: Add missing braces. + * rs6000-protos.h (s8bit_cint_operand): Prototype. + * s390.h (INITIAL_ELIMINATION_OFFSET): Add abort clause in + if-else statement. + * stormy16.h (REG_CLASS_CONTENTS): Add missing braces. + * v850.h (OUTPUT_ADDR_CONST_EXTRA): Don't issue a `return'. + * dbxout.c (dbxout_source_file): Move a variable into the scope + where it is used. + * final.c (profile_function): Mark parameter with + ATTRIBUTE_UNUSED. + * genemit.c (gen_expand): Likewise for generated file. + * insn-addr.h (INSN_ADDRESSES_NEW): Avoid undefined behavior. + * vmsdbg.h: Delete spurious close-comment. (DST_HEADER): Fix typo in ENUM_BITFIELD parameter. * vmsdbgout.c (write_modbeg): Define return type. diff --git a/gcc/config/1750a/1750a.md b/gcc/config/1750a/1750a.md index 1ebd02e213f..2117e94fab6 100644 --- a/gcc/config/1750a/1750a.md +++ b/gcc/config/1750a/1750a.md @@ -693,6 +693,8 @@ case 4: istr = \"dv \"; break; + default: + abort(); } return mod_regno_adjust (istr, operands); }") diff --git a/gcc/config/alpha/vms.h b/gcc/config/alpha/vms.h index 8a5603ffb1c..f6388bc3d40 100644 --- a/gcc/config/alpha/vms.h +++ b/gcc/config/alpha/vms.h @@ -148,6 +148,8 @@ Boston, MA 02111-1307, USA. */ + get_frame_size () \ + current_function_pretend_args_size) \ - current_function_pretend_args_size); \ + else \ + abort(); \ if ((TO) == STACK_POINTER_REGNUM) \ (OFFSET) += ALPHA_ROUND (current_function_outgoing_args_size); \ } diff --git a/gcc/config/dsp16xx/dsp16xx.c b/gcc/config/dsp16xx/dsp16xx.c index 2d9da2be64b..5e67f710e29 100644 --- a/gcc/config/dsp16xx/dsp16xx.c +++ b/gcc/config/dsp16xx/dsp16xx.c @@ -1941,6 +1941,8 @@ print_operand_address(file, addr) offset = INTVAL(XEXP(addr,0)), base = XEXP(addr,1); else if (GET_CODE (XEXP(addr,1)) == CONST_INT) offset = INTVAL(XEXP(addr,1)), base = XEXP(addr,0); + else + abort(); if (GET_CODE (base) == REG && REGNO(base) == STACK_POINTER_REGNUM) { if (offset >= -31 && offset <= 0) diff --git a/gcc/config/i386/osf1elf.h b/gcc/config/i386/osf1elf.h index fefa8c4a211..812e9914a54 100644 --- a/gcc/config/i386/osf1elf.h +++ b/gcc/config/i386/osf1elf.h @@ -153,9 +153,9 @@ do \ { \ if (!OSF_PROFILE_BEFORE_PROLOGUE) \ { \ - char *prefix = ""; \ - char *lprefix = LPREFIX; \ - int labelno = LABELNO; \ + const char *const prefix = ""; \ + const char *const lprefix = LPREFIX; \ + int labelno = LABELNO; \ \ /* Note that OSF/rose blew it in terms of calling mcount, \ since OSF/rose prepends a leading underscore, but mcount's \ diff --git a/gcc/config/ia64/ia64.md b/gcc/config/ia64/ia64.md index 53fa9f3dfd0..4f45575a55e 100644 --- a/gcc/config/ia64/ia64.md +++ b/gcc/config/ia64/ia64.md @@ -5057,14 +5057,18 @@ "" { static const char * const alt[2][4] = { - "lfetch.nta [%0]", - "lfetch.nt1 [%0]", - "lfetch.nt2 [%0]", - "lfetch [%0]", - "lfetch.excl.nta [%0]", - "lfetch.excl.nt1 [%0]", - "lfetch.excl.nt2 [%0]", - "lfetch.excl [%0]" + { + "lfetch.nta [%0]", + "lfetch.nt1 [%0]", + "lfetch.nt2 [%0]", + "lfetch [%0]" + }, + { + "lfetch.excl.nta [%0]", + "lfetch.excl.nt1 [%0]", + "lfetch.excl.nt2 [%0]", + "lfetch.excl [%0]" + } }; int i = (INTVAL (operands[1])); int j = (INTVAL (operands[2])); diff --git a/gcc/config/rs6000/rs6000-protos.h b/gcc/config/rs6000/rs6000-protos.h index b745a3acc0a..5a86ab07f6e 100644 --- a/gcc/config/rs6000/rs6000-protos.h +++ b/gcc/config/rs6000/rs6000-protos.h @@ -70,6 +70,7 @@ extern int call_operand PARAMS ((rtx, enum machine_mode)); extern int current_file_function_operand PARAMS ((rtx, enum machine_mode)); extern int input_operand PARAMS ((rtx, enum machine_mode)); extern int small_data_operand PARAMS ((rtx, enum machine_mode)); +extern int s8bit_cint_operand PARAMS ((rtx, enum machine_mode)); extern int constant_pool_expr_p PARAMS ((rtx)); extern int toc_relative_expr_p PARAMS ((rtx)); extern int expand_block_move PARAMS ((rtx[])); diff --git a/gcc/config/s390/s390.h b/gcc/config/s390/s390.h index 12ebceb6800..e9fa7e41a14 100644 --- a/gcc/config/s390/s390.h +++ b/gcc/config/s390/s390.h @@ -395,6 +395,8 @@ while (0) { (OFFSET) = s390_arg_frame_offset (); } \ else if ((FROM) == ARG_POINTER_REGNUM && (TO) == STACK_POINTER_REGNUM) \ { (OFFSET) = s390_arg_frame_offset (); } \ + else \ + abort(); \ } #define CAN_DEBUG_WITHOUT_FP diff --git a/gcc/config/stormy16/stormy16.h b/gcc/config/stormy16/stormy16.h index 5d3d90f092a..7ad9c55b63f 100644 --- a/gcc/config/stormy16/stormy16.h +++ b/gcc/config/stormy16/stormy16.h @@ -1234,17 +1234,17 @@ enum reg_class `hard-reg-set.h'. */ #define REG_CLASS_CONTENTS \ { \ - 0x00000, \ - 0x00001, \ - 0x00002, \ - 0x00003, \ - 0x00004, \ - 0x000FF, \ - 0x00100, \ - 0x00300, \ - 0x6FFFF, \ - 0x10000, \ - (1 << FIRST_PSEUDO_REGISTER) - 1 \ + { 0x00000 }, \ + { 0x00001 }, \ + { 0x00002 }, \ + { 0x00003 }, \ + { 0x00004 }, \ + { 0x000FF }, \ + { 0x00100 }, \ + { 0x00300 }, \ + { 0x6FFFF }, \ + { 0x10000 }, \ + { (1 << FIRST_PSEUDO_REGISTER) - 1 } \ } /* A C expression whose value is a register class containing hard register diff --git a/gcc/config/v850/v850.h b/gcc/config/v850/v850.h index fa0ee65816d..834ab52ce0a 100644 --- a/gcc/config/v850/v850.h +++ b/gcc/config/v850/v850.h @@ -1254,7 +1254,7 @@ do { \ #define OUTPUT_ADDR_CONST_EXTRA(FILE, X, FAIL) \ if (GET_CODE (x) == TRUNCATE) \ - return output_addr_const (FILE, XEXP (X, 0)); \ + output_addr_const (FILE, XEXP (X, 0)); \ else \ goto FAIL; diff --git a/gcc/dbxout.c b/gcc/dbxout.c index 718250d4960..2ee877d3fb6 100644 --- a/gcc/dbxout.c +++ b/gcc/dbxout.c @@ -566,13 +566,13 @@ dbxout_source_file (file, filename) FILE *file; const char *filename; { - char ltext_label_name[100]; - if (filename && (lastfile == 0 || strcmp (filename, lastfile))) { #ifdef DBX_OUTPUT_SOURCE_FILENAME DBX_OUTPUT_SOURCE_FILENAME (file, filename); #else + char ltext_label_name[100]; + ASM_GENERATE_INTERNAL_LABEL (ltext_label_name, "Ltext", source_label_number); fprintf (file, "%s", ASM_STABS_OP); diff --git a/gcc/final.c b/gcc/final.c index a17c3ac2c84..fcaaf374f35 100644 --- a/gcc/final.c +++ b/gcc/final.c @@ -1600,7 +1600,7 @@ profile_after_prologue (file) static void profile_function (file) - FILE *file; + FILE *file ATTRIBUTE_UNUSED; { #ifndef NO_PROFILE_COUNTERS int align = MIN (BIGGEST_ALIGNMENT, LONG_TYPE_SIZE); diff --git a/gcc/genemit.c b/gcc/genemit.c index 86c852c2f51..712dd24e38b 100644 --- a/gcc/genemit.c +++ b/gcc/genemit.c @@ -464,7 +464,7 @@ gen_expand (expand) for (i = operands; i <= max_dup_opno; i++) printf (" rtx operand%d;\n", i); for (; i <= max_scratch_opno; i++) - printf (" rtx operand%d;\n", i); + printf (" rtx operand%d ATTRIBUTE_UNUSED;\n", i); printf (" rtx _val = 0;\n"); printf (" start_sequence ();\n"); diff --git a/gcc/insn-addr.h b/gcc/insn-addr.h index c3690aa79bf..214df19d573 100644 --- a/gcc/insn-addr.h +++ b/gcc/insn-addr.h @@ -41,7 +41,7 @@ extern int insn_current_address; if (INSN_ADDRESSES_SET_P ()) \ { \ if (INSN_ADDRESSES_SIZE () <= insn_uid__) \ - insn_addresses_ = VARRAY_GROW (insn_addresses_, insn_uid__ + 1); \ + VARRAY_GROW (insn_addresses_, insn_uid__ + 1); \ INSN_ADDRESSES (insn_uid__) = insn_addr__; \ } \ } \