New user self-registration is disabled due to spam. For an account please email bugs-admin@lists.llvm.org with your e-mail address and full name.

Bug 32611 - PowerPC - unexpected handler being optimized out
Summary: PowerPC - unexpected handler being optimized out
Status: RESOLVED FIXED
Alias: None
Product: new-bugs
Classification: Unclassified
Component: new bugs (show other bugs)
Version: trunk
Hardware: Other Linux
: P normal
Assignee: Stefan Pintilie
URL:
Keywords:
Depends on:
Blocks: release-7.0.0
  Show dependency tree
 
Reported: 2017-04-10 16:46 PDT by Eric Schweitz
Modified: 2019-03-05 16:09 PST (History)
7 users (show)

See Also:
Fixed By Commit(s): rL340641


Attachments
reproduce the unexpected handler issue (213 bytes, text/plain)
2017-04-10 16:46 PDT, Eric Schweitz
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Eric Schweitz 2017-04-10 16:46:57 PDT
Created attachment 18265 [details]
reproduce the unexpected handler issue

This happens in the release_40 branch.

% clang++ unexpected.cpp -O3
% a.out
terminate called after throwing an instance of 'int'
Aborted
% clang++ unexpected.cpp -O0
% a.out
Unexpected handler was called.
terminate called after throwing an instance of 'int'
Aborted

g++ and the x86 backend generate the latter output as well.
Comment 1 Eric Schweitz 2018-04-11 12:15:08 PDT
This is still reproducible on trunk. clang++ now emits a warning about the code, but the Unexpected handler is still optimized away.
Comment 2 Stefan Pintilie 2018-08-24 08:37:23 PDT
Have a fix in this patch:
https://reviews.llvm.org/D50987
Comment 3 Nemanja Ivanovic 2018-08-24 08:44:11 PDT
It would be good to merge this into 7.0 as well if it can be approved/committed in time.
Comment 4 Nemanja Ivanovic 2018-08-24 08:46:13 PDT
Marking this as a blocker for 7.0 so we don't forget to merge it to the release.
Comment 5 Hans Wennborg 2018-08-27 03:05:59 PDT
Merged to 7.0 in r340731.