Bug 158547 - [ia64] Epilog counter (ar.ec) needs to be saved and restored for exceptions
Summary: [ia64] Epilog counter (ar.ec) needs to be saved and restored for exceptions
Status: Closed Overcome By Events
Alias: None
Product: Base System
Classification: Unclassified
Component: ia64 (show other bugs)
Version: Unspecified
Hardware: Any Any
: Normal Affects Only Me
Assignee: Marcel Moolenaar
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-07-01 00:50 UTC by Marcel Moolenaar
Modified: 2014-08-26 03:30 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Marcel Moolenaar freebsd_committer freebsd_triage 2011-07-01 00:50:04 UTC
The epilog counter (ar.ec) is implicitly saved and restored across function calls. The counter is saved in the previous frame register. Consequently, synchronous context switches do not need to save/restore this register.

For asynchronous context switches this is obviously not the case. Currently we do not save ar.ec in "exception_save" and we do not restore ar.ec in "exception_restore". SInce the GCC version in the source tree does not generate modulo-scheduled loops with the default options, ar.ec is typically not used. But as soon as GCC generates these loops are a different compiler is used, programs will misbehave and generally fail unless we save and restore ar.ec.
Comment 1 Marcel Moolenaar freebsd_committer freebsd_triage 2014-08-26 03:30:45 UTC
ia64 has been removed from -current.