Python not compiled with -fexceptions in ppc64le

Bug #1691848 reported by Bruno Rosa
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
python2.7 (Ubuntu)
Fix Released
Undecided
Unassigned
python3.6 (Ubuntu)
Fix Released
Undecided
Unassigned

Bug Description

Pytorch (https://github.com/pytorch/pytorch) is an application that is written in python, C and C++. There's high interoperalibity between code written in these languages therex.

The issue is that there are cases when an exception is thrown by C++ code that subsequentely calls some C code before being caught.

In ppc64le builds, without the -fexceptions gcc flag, such exceptions are not caught when the execution returns to C++ code from C code. This makes some Pytorch tests fail.

Compiling CPython with -fexceptions seems to solve this issue.

This was also reported to Debian: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=862925

ProblemType: Bug
DistroRelease: Ubuntu 17.04
Package: python2.7 2.7.13-2
ProcVersionSignature: Ubuntu 4.10.0-19.21-generic 4.10.8
Uname: Linux 4.10.0-19-generic ppc64le
.var.log.platform: Error: [Errno 13] Permission denied: '/var/log/platform'
ApportVersion: 2.20.4-0ubuntu4
Architecture: ppc64el
Date: Thu May 18 15:35:54 2017
InstallationDate: Installed on 2015-11-05 (560 days ago)
InstallationMedia: Ubuntu-Server 15.04 "Vivid Vervet" - Release ppc64el (20150422)
JournalErrors:
 Error: command ['journalctl', '-b', '--priority=warning', '--lines=1000'] failed with exit code 1: Hint: You are currently not seeing messages from other users and the system.
       Users in the 'systemd-journal' group can see all messages. Pass -q to
       turn off this notice.
 No journal files were opened due to insufficient permissions.
ProcLoadAvg: 0.07 0.33 0.43 1/348 20166
ProcSwaps: Filename Type Size Used Priority
ProcVersion: Linux version 4.10.0-19-generic (buildd@bos01-ppc64el-009) (gcc version 6.3.0 20170321 (Ubuntu 6.3.0-10ubuntu1) ) #21-Ubuntu SMP Thu Apr 6 17:03:05 UTC 2017
SourcePackage: python2.7
UpgradeStatus: Upgraded to zesty on 2017-04-17 (30 days ago)
cpu_cores: Number of cores present = 2
cpu_coreson: Number of cores online = 2
cpu_smt: SMT=8

Revision history for this message
Bruno Rosa (bruno.rosa) wrote :
Bruno Rosa (bruno.rosa)
description: updated
Revision history for this message
Matthias Klose (doko) wrote :

is powerpc64le-linux-gnu the only architecture affected?

Revision history for this message
Bruno Rosa (bruno.rosa) wrote :

The flag is not passed to any archictecture. x64 is not affected. Also tested on a Aarch64 and it seems to be affected, but I don't have access to a Aarch64 machine anymore.

Please see https://gcc.gnu.org/onlinedocs/gcc/Code-Gen-Options.html .

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package python3.6 - 3.6.2~rc1-1

---------------
python3.6 (3.6.2~rc1-1) unstable; urgency=medium

  * Python 3.6.2 release candidate 1.
  * Update symbols files.
  * Build using -fexceptions on ppc64 and ppc64el.
    Addresses: #862925. LP: #1691848.

 -- Matthias Klose <email address hidden> Tue, 20 Jun 2017 14:51:36 +0200

Changed in python3.6 (Ubuntu):
status: New → Fix Released
Revision history for this message
Chris Halse Rogers (raof) wrote : Proposed package upload rejected

An upload of python3.5 to xenial-proposed has been rejected from the upload queue for the following reason: "Bug# 1682934 is missing SRU testcase/impact/regresison potential; all bugs are missing a Zesty upload which is requried before we could release the Xenial update.".

Revision history for this message
Gustavo Serra Scalet (gut) wrote :

What about Python v2.7?

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package python2.7 - 2.7.14~rc1-3ubuntu1

---------------
python2.7 (2.7.14~rc1-3ubuntu1) artful; urgency=medium

  * Regenerate the _PyFPE breaks list for Ubuntu.

 -- Matthias Klose <email address hidden> Tue, 05 Sep 2017 20:19:52 +0200

Changed in python2.7 (Ubuntu):
status: New → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.