This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

[patch] Warning patrol part 4


Hi,

Some more warning removal:

../../gcc/gcc/unwind-dw2.c: In function `execute_stack_op':
../../gcc/gcc/unwind-dw2.c:300: warning: `result' might be used uninitialized in this function
Clearly, a false positive. Eliminated by initializing result to zero.
Is this ok?

../../gcc/gcc/config/i386/i386.c: In function `output_fix_trunc':
../../gcc/gcc/config/i386/i386.c:4672: warning: unused variable `xops'
A recent patch eliminated all usage of xops in this function, it can be 
deleted.

I have not touched these:
../../gcc/gcc/config/i386/i386.c: In function `ix86_init_builtins':
../../gcc/gcc/config/i386/i386.c:9272: warning: unused variable `int_ftype_v4sf_int'
../../gcc/gcc/config/i386/i386.c:9349: warning: unused variable `di_ftype_di_int'
../../gcc/gcc/config/i386/i386.c:9354: warning: unused variable `v8qi_ftype_v8qi_di'
These warnings have been present in the tree since this patch:

http://gcc.gnu.org/ml/gcc-patches/2000-09/msg00708.html

They are still awaiting to be used?

Tested and bootstrapped on i686-pc-linux-gnu, see this message:

http://gcc.gnu.org/ml/gcc-patches/2001-06/msg01757.htm


Please apply this if ok.

jan

Changelog:
2001-06-28  Jan van Male  <jan.vanmale@fenk.wau.nl>
        * unwind-dw2.c (execute_stack_op): Fix warning.
        * config/i386/i386.c (output_fix_trunc): Likewise.


Index: gcc/gcc/unwind-dw2.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/unwind-dw2.c,v
retrieving revision 1.4
diff -c -3 -p -r1.4 unwind-dw2.c
*** unwind-dw2.c	2001/05/20 00:35:24	1.4
--- unwind-dw2.c	2001/06/28 14:13:43
*************** execute_stack_op (const unsigned char *o
*** 297,303 ****
    while (op_ptr < op_end)
      {
        enum dwarf_location_atom op = *op_ptr++;
!       _Unwind_Word result, reg;
        _Unwind_Sword offset;
        _Unwind_Ptr ptrtmp;
  
--- 297,303 ----
    while (op_ptr < op_end)
      {
        enum dwarf_location_atom op = *op_ptr++;
!       _Unwind_Word result = 0, reg;
        _Unwind_Sword offset;
        _Unwind_Ptr ptrtmp;
  
Index: gcc/gcc/config/i386/i386.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/config/i386/i386.c,v
retrieving revision 1.272
diff -c -3 -p -r1.272 i386.c
*** i386.c	2001/06/28 08:44:16	1.272
--- i386.c	2001/06/28 14:13:47
*************** output_fix_trunc (insn, operands)
*** 4668,4674 ****
  {
    int stack_top_dies = find_regno_note (insn, REG_DEAD, FIRST_STACK_REG) != 0;
    int dimode_p = GET_MODE (operands[0]) == DImode;
-   rtx xops[4];
  
    /* Jump through a hoop or two for DImode, since the hardware has no
       non-popping instruction.  We used to do this a different way, but
--- 4668,4673 ----


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]