[issue20947] -Wstrict-overflow findings

2016-09-27 Thread Serhiy Storchaka

Changes by Serhiy Storchaka :


--
resolution:  -> fixed
stage: patch review -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20947] -Wstrict-overflow findings

2016-09-27 Thread Roundup Robot

Roundup Robot added the comment:

New changeset dad879edefd2 by Serhiy Storchaka in branch '3.5':
Issue #20947: Fixed a gcc warning with -Wstrict-overflow.
https://hg.python.org/cpython/rev/dad879edefd2

New changeset 5ecbe8a55ccd by Serhiy Storchaka in branch '3.6':
Issue #20947: Fixed a gcc warning with -Wstrict-overflow.
https://hg.python.org/cpython/rev/5ecbe8a55ccd

New changeset 675d3f76444d by Serhiy Storchaka in branch 'default':
Issue #20947: Fixed a gcc warning with -Wstrict-overflow.
https://hg.python.org/cpython/rev/675d3f76444d

--
nosy: +python-dev

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20947] -Wstrict-overflow findings

2016-09-25 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

Use following command for reproducing:

make -s CFLAGS=-Wstrict-overflow

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20947] -Wstrict-overflow findings

2016-09-25 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

I can reproduce warnings in Modules/_posixsubprocess.c:

gcc -pthread -fPIC -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O3 
-Wall -Wstrict-prototypes -std=c99 -Wextra -Wno-unused-result 
-Wno-unused-parameter -Wno-missing-field-initializers -Wstrict-overflow 
-I./Include -I. -I/usr/include/i386-linux-gnu -I/usr/local/include 
-I/home/serhiy/py/cpython/Include -I/home/serhiy/py/cpython -c 
/home/serhiy/py/cpython/Modules/_posixsubprocess.c -o 
build/temp.linux-i686-3.7/home/serhiy/py/cpython/Modules/_posixsubprocess.o
/home/serhiy/py/cpython/Modules/_posixsubprocess.c: In function ‘child_exec’:
/home/serhiy/py/cpython/Modules/_posixsubprocess.c:524:33: warning: assuming 
pointer wraparound does not occur when comparing P +- C1 with P +- C2 
[-Wstrict-overflow]
 while (saved_errno != 0 && cur > hex_errno) {
 ^
/home/serhiy/py/cpython/Modules/_posixsubprocess.c: In function 
‘subprocess_fork_exec’:
/home/serhiy/py/cpython/Modules/_posixsubprocess.c:524:33: warning: assuming 
pointer wraparound does not occur when comparing P +- C1 with P +- C2 
[-Wstrict-overflow]
 while (saved_errno != 0 && cur > hex_errno) {
 ^
/home/serhiy/py/cpython/Modules/_posixsubprocess.c:544:1: warning: assuming 
pointer wraparound does not occur when comparing P +- C1 with P +- C2 
[-Wstrict-overflow]
 subprocess_fork_exec(PyObject* self, PyObject *args)
 ^
/home/serhiy/py/cpython/Modules/_posixsubprocess.c:544:1: warning: assuming 
pointer wraparound does not occur when comparing P +- C1 with P +- C2 
[-Wstrict-overflow]
/home/serhiy/py/cpython/Modules/_posixsubprocess.c:524:33: warning: assuming 
pointer wraparound does not occur when comparing P +- C1 with P +- C2 
[-Wstrict-overflow]
 while (saved_errno != 0 && cur > hex_errno) {
 ^
/home/serhiy/py/cpython/Modules/_posixsubprocess.c:524:33: warning: assuming 
pointer wraparound does not occur when comparing P +- C1 with P +- C2 
[-Wstrict-overflow]

Proposed simple patch fixes this.

--
assignee:  -> serhiy.storchaka
keywords: +patch
resolution: wont fix -> 
stage: resolved -> patch review
status: closed -> open
versions: +Python 3.6, Python 3.7
Added file: http://bugs.python.org/file44820/issue20947.patch

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20947] -Wstrict-overflow findings

2016-09-25 Thread Christian Heimes

Christian Heimes added the comment:

I can no longer reproduce the warnings with

$ CFLAGS=-Wstrict-overflow ./configure -C --with-pydebug --silent
$ make --silent

--
nosy: +christian.heimes
stage:  -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20947] -Wstrict-overflow findings

2016-07-28 Thread Mark Lawrence

Changes by Mark Lawrence :


--
nosy:  -BreamoreBoy

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20947] -Wstrict-overflow findings

2016-07-28 Thread Martin Panter

Martin Panter added the comment:

Regarding the warning in Modules/_posixsubprocess.c, I don’t see any problem. 
I’m not sure exactly what it is warning about. Maybe if the cur pointer ever 
gets _before_ the start of hex_errno, that could be a problem, but the loop 
should stop when it reaches the start.

The warnings in Modules/sha512module.c refer to the first line of the 
sha512_transform() function. I cannot see any pointer comparisons in that 
function. The closest is pointer and array indexing, but it all seems to be in 
order.

I propose to ignore these warnings.

--
nosy: +martin.panter
resolution:  -> wont fix
type:  -> compile error

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20947] -Wstrict-overflow findings

2015-02-12 Thread Mark Lawrence

Mark Lawrence added the comment:

@Serhiy/Victor I believe that you're both interested in this type of problem.

--
nosy: +BreamoreBoy, haypo, serhiy.storchaka

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20947
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20947] -Wstrict-overflow findings

2014-03-16 Thread Jeffrey Walton

New submission from Jeffrey Walton:

$ hg id
3736bf94535c+ tip

Forgive me if you were aware of these. 

/usr/bin/gcc -pthread -fPIC -Wno-unused-result 
-Werror=declaration-after-statement -DNDEBUG -g -fwrapv -O3 -Wall 
-Wstrict-prototypes -fno-common -Wstrict-overflow -Wformat=2 -Wformat-security 
-Wcast-align -Wtrampolines -fno-common -Wstrict-overflow -Wformat=2 
-Wformat-security -Wcast-align -Wtrampolines -I./Include -I. -IInclude 
-I/usr/include/x86_64-linux-gnu -I/usr/local/include -Icpython/./Include 
-Icpython/. -c cpython/./Modules/_posixsubprocess.c -o 
build/temp.linux-x86_64-3.4cpython/./Modules/_posixsubprocess.o
cpython/./Modules/_posixsubprocess.c: In function ‘child_exec’:
cpython/./Modules/_posixsubprocess.c:491:33: warning: assuming pointer 
wraparound does not occur when comparing P +- C1 with P +- C2 
[-Wstrict-overflow]
cpython/./Modules/_posixsubprocess.c: In function ‘subprocess_fork_exec’:
cpython/./Modules/_posixsubprocess.c:491:33: warning: assuming pointer 
wraparound does not occur when comparing P +- C1 with P +- C2 
[-Wstrict-overflow]
cpython/./Modules/_posixsubprocess.c:491:33: warning: assuming pointer 
wraparound does not occur when comparing P +- C1 with P +- C2 
[-Wstrict-overflow]
cpython/./Modules/_posixsubprocess.c:491:33: warning: assuming pointer 
wraparound does not occur when comparing P +- C1 with P +- C2 
[-Wstrict-overflow]
...

/usr/bin/gcc -pthread -fPIC -Wno-unused-result 
-Werror=declaration-after-statement -DNDEBUG -g -fwrapv -O3 -Wall 
-Wstrict-prototypes -fno-common -Wstrict-overflow -Wformat=2 -Wformat-security 
-Wcast-align -Wtrampolines -fno-common -Wstrict-overflow -Wformat=2 
-Wformat-security -Wcast-align -Wtrampolines -I./Include -I. -IInclude 
-I/usr/include/x86_64-linux-gnu -I/usr/local/include -Icpython/./Include 
-Icpython/. -c cpython/./Modules/sha512module.c -o 
build/temp.linux-x86_64-3.4cpython/./Modules/sha512module.o
cpython/./Modules/sha512module.c: In function ‘sha512_transform’:
cpython/./Modules/sha512module.c:128:1: warning: assuming pointer wraparound 
does not occur when comparing P +- C1 with P +- C2 [-Wstrict-overflow]
cpython/./Modules/sha512module.c:128:1: warning: assuming pointer wraparound 
does not occur when comparing P +- C1 with P +- C2 [-Wstrict-overflow]

--
components: Build
hgrepos: 224
messages: 213742
nosy: Jeffrey.Walton
priority: normal
severity: normal
status: open
title: -Wstrict-overflow findings
versions: Python 3.5

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20947
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com