mirror of
https://git.postgresql.org/git/postgresql.git
synced 2025-01-12 18:34:36 +08:00
Remove theoretically-unnecessary special case for icc.
Intel's icc is generally able to swallow asm blocks written for gcc. We have a few places that don't seem to know that, though. Experiment with removing the special case for icc in ia64_get_bsp(); if the buildfarm likes this, I'll try more cleanup. This is a good test case because it involves a "stop" notation that seems like it might not be very portable.
This commit is contained in:
parent
a65e086453
commit
2c713d6ea2
@ -2997,33 +2997,27 @@ ProcessInterrupts(void)
|
|||||||
/*
|
/*
|
||||||
* IA64-specific code to fetch the AR.BSP register for stack depth checks.
|
* IA64-specific code to fetch the AR.BSP register for stack depth checks.
|
||||||
*
|
*
|
||||||
* We currently support gcc, icc, and HP-UX inline assembly here.
|
* We currently support gcc, icc, and HP-UX's native compiler here.
|
||||||
*/
|
*/
|
||||||
#if defined(__ia64__) || defined(__ia64)
|
#if defined(__ia64__) || defined(__ia64)
|
||||||
|
|
||||||
#if defined(__hpux) && !defined(__GNUC__) && !defined __INTEL_COMPILER
|
#if defined(__hpux) && !defined(__GNUC__) && !defined(__INTEL_COMPILER)
|
||||||
|
/* Assume it's HP-UX native compiler */
|
||||||
#include <ia64/sys/inline.h>
|
#include <ia64/sys/inline.h>
|
||||||
#define ia64_get_bsp() ((char *) (_Asm_mov_from_ar(_AREG_BSP, _NO_FENCE)))
|
#define ia64_get_bsp() ((char *) (_Asm_mov_from_ar(_AREG_BSP, _NO_FENCE)))
|
||||||
#else
|
#else
|
||||||
|
/* Use inline assembly; works with gcc and icc */
|
||||||
#ifdef __INTEL_COMPILER
|
|
||||||
#include <asm/ia64regs.h>
|
|
||||||
#endif
|
|
||||||
|
|
||||||
static __inline__ char *
|
static __inline__ char *
|
||||||
ia64_get_bsp(void)
|
ia64_get_bsp(void)
|
||||||
{
|
{
|
||||||
char *ret;
|
char *ret;
|
||||||
|
|
||||||
#ifndef __INTEL_COMPILER
|
|
||||||
/* the ;; is a "stop", seems to be required before fetching BSP */
|
/* the ;; is a "stop", seems to be required before fetching BSP */
|
||||||
__asm__ __volatile__(
|
__asm__ __volatile__(
|
||||||
";;\n"
|
";;\n"
|
||||||
" mov %0=ar.bsp \n"
|
" mov %0=ar.bsp \n"
|
||||||
: "=r"(ret));
|
: "=r"(ret));
|
||||||
#else
|
|
||||||
ret = (char *) __getReg(_IA64_REG_AR_BSP);
|
|
||||||
#endif
|
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
Loading…
Reference in New Issue
Block a user