Red Hat Bugzilla – Bug 959564
ICC uses ms_abi in its internal library without a thunk causing problems for the unwinder in libgcc
Last modified: 2014-07-01 18:54:24 EDT
Description of problem:
When the unwinder in libgcc comes across a ms_abi call the callee-clobbered registers reference out bounds of the array that stores the callee-clobbered registers causing a segv.
This bz is intended for collaboration between LLNL, RH, Intel, and Roguewave to resolve the problems associated with the unwinder not being able to handle exception frames that include more than 17 callee-clobbered registers.
So far this is not considered a GCC or libgcc bug. We currently believe that the problem is due to ICC using MS's abi code inside of their OpenMP library rather than conforming to the ELF ABI. However, investigation and discussion is continuing.
It would be good to involve some people from the Intel compiler team in this discussion.
Created attachment 748936 [details]
patch to do bounds checking on the array
Once RTH takes this patch or a patch like this on 4.8.N can we please back port this one to our libgcc so that people using the intel compiler don't crash.
The customer is carrying the patch right now and rebuilding gcc but they would very much prefer to have one provided by us. Looking at the way things are working, I don't think that this could be added to DTS.
Created attachment 752301 [details]
updated patch that includes __builtin_expect
It looks like RTH committed this to mainline and it will likely be in 4.8.2. Could we please have that patch backported to go into libgcc for rhel6.5 this is really causing a lot of problems for LLNL and so far we have been unable to get Intel to address the issue.
The patch he posted there is better than the one that I just posted:
"The patch in #8 is better, and indeed has a bug fix relative to this
in that the condition should be <= DWARF_FRAME_REGISTERS. Note that
the array size is DWARF_FRAME_REGISTERS + 1."
Verified for gcc-4.4.7-4.el6.x86_64.
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.
For information on the advisory, and where to find the updated
files, follow the link below.
If the solution does not work for you, open a new bug report.