Bug 211652

Summary: crash generates floating point assist faults on ia64
Product: Red Hat Enterprise Linux 4 Reporter: Bryn M. Reeves <bmr>
Component: crashAssignee: Dave Anderson <anderson>
Status: CLOSED ERRATA QA Contact:
Severity: low Docs Contact:
Priority: medium    
Version: 4.4CC: jturner, lwang, tao
Target Milestone: ---   
Target Release: ---   
Hardware: ia64   
OS: Linux   
Fixed In Version: RHBA-2007-0188 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2007-05-01 22:45:21 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Description Flags
backtrace from the location triggering the fp assist fault
prctl(PR_SET_FPEMU, 1, 0, 0, 0); none

Description Bryn M. Reeves 2006-10-20 16:52:47 UTC
The gdb module in crash attempts to manipulate floating point values via ldexp
when printing backtraces. If the values in the fp registers contain
denormals/NANs, the kernel logs a floating point software assist fault.

The messages are low in volume and the concern is primarily cosmetic.

Steps to reproduce:

# rpm -ivh kernel-2.6.9-42.EL.ia64.rpm
# crash /usr/lib/debug/lib/modules/2.6.9-42.EL/vmlinux

crash> foreach bt

# dmesg|grep "assist fault"
kernel: crash(12028): floating-point assist fault at ip 20000000000d4382, isr

The ip is always inside ldexp, being called from the gdb value_print function
(see attached backtrace)

Comment 1 Bryn M. Reeves 2006-10-20 16:52:58 UTC
Created attachment 139001 [details]
backtrace from the location triggering the fp assist fault

Comment 2 Dave Anderson 2006-10-20 17:47:26 UTC
Interesting, although I can't reproduce it, at least with 2.4.21-47.EL.

It looks like the messages can be turned off on a per-task basis
with a prctl PR_SET_FPEMU in order to set the IA64_THREAD_FPEMU_NOPRINT
bit in its current->thread.flags.

Comment 3 Dave Anderson 2006-10-20 18:13:39 UTC
Created attachment 139012 [details]
prctl(PR_SET_FPEMU, 1, 0, 0, 0);


If you get the chance, can you apply this patch to the ia64.c file
in the crash utility sources, rebuild, and see if it clears up the
log messages?

The patch is against the 4.0-3.7 version of crash, but will probably
apply to whatever you're using.  But the easiest thing to do would
be to go to http://people.redhat.com/anderson and download the
crash-4.0-3.7.tar.gz file.  Then:

# tar xzf crash-4.0-3.7.tar.gz
# cd crash-4.0-3.7
# patch -p0 < ia64_prctl.patch
# make
# ./crash

and test it out.

Comment 4 Dave Anderson 2006-10-20 19:27:14 UTC
Or, alternatively, this should accomplish the same thing with
the crash utility unmodified:

 # prctl --fpemu=silent crash 

Comment 6 Bryn M. Reeves 2006-10-23 11:07:52 UTC
Have tested both the prctl workaround and the patch (applied to the U4 crash
sources - went in fine with a bit of offset) - both worked like a charm, thanks!

Comment 7 Dave Anderson 2006-10-24 12:35:13 UTC
This should go into the RHEL4-5 crash utility errata.

Comment 8 RHEL Product and Program Management 2006-10-24 12:43:32 UTC
This request was evaluated by Red Hat Product Management for inclusion in a Red
Hat Enterprise Linux maintenance release.  Product Management has requested
further review of this request by Red Hat Engineering, for potential
inclusion in a Red Hat Enterprise Linux Update release for currently deployed
products.  This request is not yet committed for inclusion in an Update

Comment 9 Dave Anderson 2006-11-03 15:26:26 UTC
I am currently filing the RHEL4-U5 crash utility errata, and
for inclusion this Bugzilla needs:

 rhel-4-5 +
 devel.ack + 
 qa_ack +


Comment 11 Dave Anderson 2006-11-03 19:40:31 UTC
crash version 4.0-3.9 checked into RHEL4 CVS.

(still requires devel_ack+, qa_ack+ and rhel-4.5+)

Comment 16 Red Hat Bugzilla 2007-05-01 22:45:21 UTC
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on the solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.