public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
* Calling convention for Intel APX extension
@ 2023-07-27  8:38 Thomas Koenig
  2023-07-27 13:10 ` Florian Weimer
  2023-07-27 13:43 ` Michael Matz
  0 siblings, 2 replies; 5+ messages in thread
From: Thomas Koenig @ 2023-07-27  8:38 UTC (permalink / raw)
  To: gcc mailing list

With the upcoming Intel APX extension, Intel processors will
finally gain 32 general-purpose registers and three-operand
arithmetic, see

https://www.intel.com/content/www/us/en/developer/articles/technical/advanced-performance-extensions-apx.html

Intel recommends to have the new registers as caller-saved for
compatibility with current calling conventions.  If I understand this
correctly, this is required for exception unwinding, but not if the
function called is __attribute__((nothrow)).

Since Fortran tends to use a lot of registers for its array descriptors,
and also tends to call nothrow functions (all Fortran functions, and
all Fortran intrinsics, such as sin/cos/etc) a lot, it could profit from
making some of the new registers callee-saved, to save some spills
at function calls.

What are the thoughts on it? Is a modification to the ps-ABI already in
the works, and how would it treat this case?

Best regards

	Thomas



^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2023-07-31 12:43 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-07-27  8:38 Calling convention for Intel APX extension Thomas Koenig
2023-07-27 13:10 ` Florian Weimer
2023-07-27 13:43 ` Michael Matz
2023-07-30 15:33   ` Thomas Koenig
2023-07-31 12:43     ` Michael Matz

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).