[Ubuntu 20.04] GCC generates wrong code for exception handling

Bug #1862342 reported by bugproxy
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Ubuntu on IBM z Systems
Fix Released
High
Canonical Foundations Team
gcc-9 (Ubuntu)
Fix Released
Undecided
Skipper Bug Screeners

Bug Description

---Problem description---
Wrong code might get generated if a local variable is set in the try block and read in the catch block.

---Steps to Reproduce---
Please pick up the patch from the following upstream GCC BZ:
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93272

This fixes a latent register allocator problem present since introduction of LRA.

Userspace tool common name: gcc

Userspace rpm: gcc

The userspace tool has the following bit modes: 64

Correct package level has to be select within LP!

bugproxy (bugproxy)
tags: added: architecture-s39064 bugnameltc-183751 severity-high targetmilestone-inin---
Changed in ubuntu:
assignee: nobody → Skipper Bug Screeners (skipper-screen-team)
affects: ubuntu → linux (Ubuntu)
Revision history for this message
Frank Heimes (fheimes) wrote :

Since the bug name says [20.04] I assume it has an impact on gcc-9, which is the default gcc in 20.04. Is that right ? And does it affect other gcc version, too ?

affects: linux (Ubuntu) → gcc-9 (Ubuntu)
Changed in ubuntu-z-systems:
status: New → Triaged
importance: Undecided → High
assignee: nobody → Canonical Foundations Team (canonical-foundations)
Revision history for this message
Matthias Klose (doko) wrote :

this the kind of patch I'd like to see backported upstream first. Anybody who could help with that?

Changed in gcc-9 (Ubuntu):
status: New → Incomplete
bugproxy (bugproxy)
tags: added: targetmilestone-inin2004
removed: targetmilestone-inin---
Revision history for this message
bugproxy (bugproxy) wrote : Comment bridged from LTC Bugzilla

------- Comment From <email address hidden> 2020-02-12 03:08 EDT-------
The patch applies and works also on older versions. I've debugged the original problem on GCC 4.8 and the patch works there as well. I've requested backports to be applied to GCC 8 and 9 in the GCC upstream bugzilla now. Usually the global reviewers give such changes some time on trunk before doing the backports.

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

This bug was fixed in the package gcc-9 - 9.2.1-30ubuntu1

---------------
gcc-9 (9.2.1-30ubuntu1) focal; urgency=medium

  * Merge with Debian; remaining changes:
    - Build from upstream sources.
    - Disable the LTO build on arm64, armhf for now, takes 24+ hours ...

gcc-9 (9.2.1-30) unstable; urgency=medium

  * Update to git 20200224 from the gcc-9 branch.
    - Fix PR target/93658 (PPC), PR target/93568 (PPC), PR target/93828 (x86),
      PR target/93656 (x86).
  * Don't create doc directories for -dbg packages when not building those.
  * Fix PR rtl-optimization/93272, taken from the trunk. LP: #1862342.

 -- Matthias Klose <email address hidden> Mon, 24 Feb 2020 20:14:24 +0100

Changed in gcc-9 (Ubuntu):
status: Incomplete → Fix Released
Frank Heimes (fheimes)
Changed in ubuntu-z-systems:
status: Triaged → Fix Released
Revision history for this message
bugproxy (bugproxy) wrote :

------- Comment From <email address hidden> 2020-02-26 10:02 EDT-------
IBM Bugzilla status -> closed, Fix Released with focal

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.