Re: [PATCH] intc/i8259: avoid (false positive) gcc warning

2021-03-18 Thread BALATON Zoltan
On Thu, 18 Mar 2021, Philippe Mathieu-Daudé wrote: On 3/18/21 5:11 PM, Christian Borntraeger wrote: On 18.03.21 17:03, Paolo Bonzini wrote: On 18/03/21 16:47, Christian Borntraeger wrote: some copiler versions are smart enough to detect a potentially uninitialized variable, but are not smart e

Re: [PATCH] intc/i8259: avoid (false positive) gcc warning

2021-03-18 Thread Philippe Mathieu-Daudé
On 3/18/21 5:11 PM, Christian Borntraeger wrote: > On 18.03.21 17:03, Paolo Bonzini wrote: >> On 18/03/21 16:47, Christian Borntraeger wrote: >>> some copiler versions are smart enough to detect a potentially >>> uninitialized variable, but are not smart enough to detect that this >>> cannot happen

Re: [PATCH] intc/i8259: avoid (false positive) gcc warning

2021-03-18 Thread Paolo Bonzini
On 18/03/21 16:47, Christian Borntraeger wrote: some copiler versions are smart enough to detect a potentially uninitialized variable, but are not smart enough to detect that this cannot happen due to the code flow: ../hw/intc/i8259.c: In function ‘pic_read_irq’: ../hw/intc/i8259.c:203:13: error

Re: [PATCH] intc/i8259: avoid (false positive) gcc warning

2021-03-18 Thread Christian Borntraeger
On 18.03.21 17:03, Paolo Bonzini wrote: On 18/03/21 16:47, Christian Borntraeger wrote: some copiler versions are smart enough to detect a potentially uninitialized variable, but are not smart enough to detect that this cannot happen due to the code flow: ../hw/intc/i8259.c: In function ‘pic

[PATCH] intc/i8259: avoid (false positive) gcc warning

2021-03-18 Thread Christian Borntraeger
some copiler versions are smart enough to detect a potentially uninitialized variable, but are not smart enough to detect that this cannot happen due to the code flow: ../hw/intc/i8259.c: In function ‘pic_read_irq’: ../hw/intc/i8259.c:203:13: error: ‘irq2’ may be used uninitialized in this functi