Commit e5e8a8bf by John Wehle Committed by Jeff Law

i386.h (ALIGN_DFmode): Delete.

        * i386.h (ALIGN_DFmode): Delete.
        (CONSTANT_ALIGNMENT): Define.
        * varasm.c (force_const_mem): Use it.

From-SVN: r19823
parent b771b6b4
Sun May 17 23:59:45 1998 John Wehle (john@feith.com)
* i386.h (ALIGN_DFmode): Delete.
(CONSTANT_ALIGNMENT): Define.
* varasm.c (force_const_mem): Use it.
Sun May 17 19:31:05 1998 Richard Henderson <rth@cygnus.com>
* alpha.c (alpha_emit_conditional_branch): Clear cmp_code after
......
......@@ -419,8 +419,30 @@ extern int ix86_arch;
aligned on 64 bit boundaries. */
#define BIGGEST_ALIGNMENT (TARGET_ALIGN_DOUBLE ? 64 : 32)
/* align DFmode constants and nonaggregates */
#define ALIGN_DFmode (!TARGET_386)
/* If defined, a C expression to compute the alignment given to a
constant that is being placed in memory. CONSTANT is the constant
and ALIGN is the alignment that the object would ordinarily have.
The value of this macro is used instead of that alignment to align
the object.
If this macro is not defined, then ALIGN is used.
The typical use of this macro is to increase alignment for string
constants to be word aligned so that `strcpy' calls that copy
constants can be done inline. */
#define CONSTANT_ALIGNMENT(EXP, ALIGN) \
(TREE_CODE (EXP) == REAL_CST \
? ((TYPE_MODE (TREE_TYPE (EXP)) == DFmode && (ALIGN) < 64) \
? 64 \
: (TYPE_MODE (TREE_TYPE (EXP)) == XFmode && (ALIGN) < 128) \
? 128 \
: (ALIGN)) \
: TREE_CODE (EXP) == STRING_CST \
? ((TREE_STRING_LENGTH (EXP) >= 31 && (ALIGN) < 256) \
? 256 \
: (ALIGN)) \
: (ALIGN))
/* If defined, a C expression to compute the alignment for a static
variable. TYPE is the data type, and ALIGN is the alignment that
......
......@@ -3417,6 +3417,10 @@ force_const_mem (mode, x)
align = (mode == VOIDmode) ? UNITS_PER_WORD : GET_MODE_SIZE (mode);
if (align > BIGGEST_ALIGNMENT / BITS_PER_UNIT)
align = BIGGEST_ALIGNMENT / BITS_PER_UNIT;
#ifdef CONSTANT_ALIGNMENT
align = CONSTANT_ALIGNMENT (make_tree (type_for_mode (mode, 0), x),
align * BITS_PER_UNIT) / BITS_PER_UNIT;
#endif
pool_offset += align - 1;
pool_offset &= ~ (align - 1);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment