[Bug c/21548] [4.0 regression] Wrong warning about uninitialized variable

2005-05-13 Thread schwab at suse dot de
--- Additional Comments From schwab at suse dot de 2005-05-13 15:06 --- That's why it should say "might be used". -- What|Removed |Added Status|RESOLVED

[Bug c/21548] [4.0 regression] Wrong warning about uninitialized variable

2005-05-13 Thread rearnsha at gcc dot gnu dot org
--- Additional Comments From rearnsha at gcc dot gnu dot org 2005-05-13 15:05 --- It's nothing to do with ALWAYS. It's to do with COULD BE. There are values that blocksize COULD take that would lead to bytes being uninitialized. That's all the warning is telling you. The compiler is

[Bug c/21548] [4.0 regression] Wrong warning about uninitialized variable

2005-05-13 Thread pinskia at gcc dot gnu dot org
--- Additional Comments From pinskia at gcc dot gnu dot org 2005-05-13 15:01 --- I also get the warning in 3.4.0 and 3.3.3 with your example, did you reduce it too far? -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21548

[Bug c/21548] [4.0 regression] Wrong warning about uninitialized variable

2005-05-13 Thread schwab at suse dot de
--- Additional Comments From schwab at suse dot de 2005-05-13 15:00 --- It is not _always_ uninitialized. -- What|Removed |Added Status|RESOLVED

[Bug c/21548] [4.0 regression] Wrong warning about uninitialized variable

2005-05-13 Thread schwab at suse dot de
--- Additional Comments From schwab at suse dot de 2005-05-13 14:59 --- To clarify, the problem is the "is used" part. This should be "might be used" instead. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21548

[Bug c/21548] [4.0 regression] Wrong warning about uninitialized variable

2005-05-13 Thread rearnsha at gcc dot gnu dot org
--- Additional Comments From rearnsha at gcc dot gnu dot org 2005-05-13 14:57 --- The compiler can't be expected to follow that logic. If blocksize is set to zero by some magic daemon, then the bytes would be undefined. -- What|Removed |Added ---

[Bug c/21548] [4.0 regression] Wrong warning about uninitialized variable

2005-05-13 Thread schwab at suse dot de
--- Additional Comments From schwab at suse dot de 2005-05-13 14:54 --- The program logic guarantees that blocksize is never zero. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21548

[Bug c/21548] [4.0 regression] Wrong warning about uninitialized variable

2005-05-13 Thread pinskia at gcc dot gnu dot org
--- Additional Comments From pinskia at gcc dot gnu dot org 2005-05-13 14:53 --- hmm, what happens if blocksize is zero when foo is entered. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21548