(s_lcomm_internal): Use it.
* doc/internals.texi (CPU backend): Document it.
* config/obj-evax.h (TC_IMPLICIT_LCOMM_ALIGNMENT): Set to 2**3
bytes.
+Sat Mar 11 00:01:39 2000 Hans-Peter Nilsson <hp@axis.se>
+
+ * read.c (TC_IMPLICIT_LCOMM_ALIGNMENT): New default-definition.
+ (s_lcomm_internal): Use it.
+ * doc/internals.texi (CPU backend): Document it.
+ * config/obj-evax.h (TC_IMPLICIT_LCOMM_ALIGNMENT): Set to 2**3
+ bytes.
+
2000-03-10 Geoffrey Keating <geoffk@cygnus.com>
* config/tc-mips.c (mips_ip): Don't put stuff in .rodata
/* This file is obj-evax.h
- Copyright (C) 1996 Free Software Foundation, Inc.
+ Copyright (C) 1996, 2000 Free Software Foundation, Inc.
Contributed by Klaus Kämpf (kkaempf@progis.de) of
proGIS Software, Aachen, Germany.
#define LKP_S_K_SIZE 16
+#define TC_IMPLICIT_LCOMM_ALIGNMENT(SIZE, P2VAR) (P2VAR) = 3
+
/*
* Local Variables:
* comment-column: 0
You may define this macro to do special handling for an alignment directive.
GAS will call it at the end of the assembly.
+@item TC_IMPLICIT_LCOMM_ALIGNMENT (@var{size}, @var{p2var})
+@cindex TC_IMPLICIT_LCOMM_ALIGNMENT
+An @code{.lcomm} directive with no explicit alignment parameter will use this
+macro to set @var{p2var} to the alignment that a request for @var{size} bytes
+will have. The alignment is expressed as a power of two. If no alignment
+should take place, the macro definition should do nothing. Some targets define
+a @code{.bss} directive that is also affected by this macro. The default
+definition will set @var{p2var} to the truncated power of two of sizes up to
+eight bytes.
+
@item md_flush_pending_output
@cindex md_flush_pending_output
If you define this macro, GAS will call it each time it skips any space because of a
#define TC_START_LABEL(x,y) (x==':')
#endif
+/* Set by the object-format or the target. */
+#ifndef TC_IMPLICIT_LCOMM_ALIGNMENT
+#define TC_IMPLICIT_LCOMM_ALIGNMENT(SIZE, P2VAR) \
+ do { \
+ if ((SIZE) >= 8) \
+ (P2VAR) = 3; \
+ else if ((SIZE) >= 4) \
+ (P2VAR) = 2; \
+ else if ((SIZE) >= 2) \
+ (P2VAR) = 1; \
+ else \
+ (P2VAR) = 0; \
+ } while (0)
+#endif
+
/* The NOP_OPCODE is for the alignment fill value.
* fill it a nop instruction so that the disassembler does not choke
* on it
}
}
#endif
+
if (!needs_align)
{
- /* FIXME. This needs to be machine independent. */
- if (temp >= 8)
- align = 3;
- else if (temp >= 4)
- align = 2;
- else if (temp >= 2)
- align = 1;
- else
- align = 0;
-
-#ifdef OBJ_EVAX
- /* FIXME: This needs to be done in a more general fashion. */
- align = 3;
-#endif
+ TC_IMPLICIT_LCOMM_ALIGNMENT (temp, align);
- record_alignment(bss_seg, align);
+ /* Still zero unless TC_IMPLICIT_LCOMM_ALIGNMENT set it. */
+ if (align)
+ record_alignment(bss_seg, align);
}
if (needs_align)