Makefile
lost+found
update.out
-
+update.sourceware
+2001-10-30 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * Makefile.am (ALL_MACHINES): Add cpu-mmix.lo.
+ (BFD64_BACKENDS): Add elf64-mmix.lo and mmo.lo.
+ (BFD64_BACKENDS_CFILES): Add elf64-mmix.c and mmo.c.
+ Regenerate dependencies.
+ * configure.in (bfd_elf64_mmix_vec, bfd_mmo_vec): New vectors.
+ * config.bfd: [BFD64] (mmix-*-*): New case.
+ * cpu-mmix.c, mmo.c, elf64-mmix.c: New files.
+ * archures.c (enum bfd_architecture): Add bfd_arch_mmix.
+ (bfd_mmix_arch): Declare.
+ (bfd_archures_list): Add bfd_mmix_arch.
+ * targets.c (enum bfd_flavour): Add bfd_target_mmo_flavour.
+ (bfd_elf64_mmix_vec, bfd_mmo_vec): Declare.
+ (bfd_target_vect) [BFD64]: Add bfd_elf64_mmix_vec and
+ bfd_mmo_mmix_vec.
+ * reloc.c: Add MMIX relocations.
+ * bfd.c (struct _bfd, tdata): Add mmo_data.
+ * Makefile.in: Regenerate.
+ * configure: Regenerate.
+ * libbfd.h: Regenerate.
+ * bfd-in2.h: Regenerate.
+ * configure: Rebuild.
+
2001-10-30 Richard Earnshaw (rearnsha@arm.com)
* elf.c (_bfd_elf_make_section_from_shdr): Set the LMA based on the
cpu-m10300.lo \
cpu-mcore.lo \
cpu-mips.lo \
+ cpu-mmix.lo \
cpu-ns32k.lo \
cpu-openrisc.lo \
cpu-pdp11.lo \
cpu-m10300.c \
cpu-mcore.c \
cpu-mips.c \
+ cpu-mmix.c \
cpu-ns32k.c \
cpu-openrisc.c \
cpu-pdp11.c \
elf64-ia64.lo \
elf64-gen.lo \
elf64-mips.lo \
+ elf64-mmix.lo \
elf64-ppc.lo \
elf64-s390.lo \
elf64-sparc.lo \
elf64.lo \
+ mmo.lo \
nlm32-alpha.lo \
nlm64.lo \
pepigen.lo
elf64-hppa.c \
elf64-gen.c \
elf64-mips.c \
+ elf64-mmix.c \
elf64-ppc.c \
elf64-s390.c \
elf64-sparc.c \
elf64.c \
+ mmo.c \
nlm32-alpha.c \
nlm64.c
cpu-m10300.lo: cpu-m10300.c $(INCDIR)/filenames.h
cpu-mcore.lo: cpu-mcore.c $(INCDIR)/filenames.h
cpu-mips.lo: cpu-mips.c $(INCDIR)/filenames.h
+cpu-mmix.lo: cpu-mmix.c $(INCDIR)/filenames.h
cpu-ns32k.lo: cpu-ns32k.c $(INCDIR)/filenames.h ns32k.h
cpu-openrisc.lo: cpu-openrisc.c $(INCDIR)/filenames.h
cpu-pdp11.lo: cpu-pdp11.c $(INCDIR)/filenames.h
$(INCDIR)/elf/reloc-macros.h $(INCDIR)/coff/sym.h $(INCDIR)/coff/symconst.h \
$(INCDIR)/coff/internal.h $(INCDIR)/coff/ecoff.h $(INCDIR)/coff/alpha.h \
ecoffswap.h elf64-target.h
+elf64-mmix.lo: elf64-mmix.c $(INCDIR)/filenames.h elf-bfd.h \
+ $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
+ $(INCDIR)/bfdlink.h $(INCDIR)/elf/mmix.h $(INCDIR)/elf/reloc-macros.h \
+ $(INCDIR)/opcode/mmix.h elf64-target.h
elf64-ppc.lo: elf64-ppc.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/elf/ppc.h $(INCDIR)/elf/reloc-macros.h \
$(INCDIR)/bfdlink.h elf-bfd.h $(INCDIR)/elf/common.h \
$(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h elfcore.h \
elflink.h
+mmo.lo: mmo.c $(INCDIR)/filenames.h $(INCDIR)/libiberty.h \
+ $(INCDIR)/elf/mmix.h $(INCDIR)/elf/reloc-macros.h $(INCDIR)/opcode/mmix.h
nlm32-alpha.lo: nlm32-alpha.c $(INCDIR)/filenames.h \
$(INCDIR)/nlm/alpha-ext.h libnlm.h $(INCDIR)/nlm/common.h \
$(INCDIR)/nlm/internal.h $(INCDIR)/nlm/external.h nlmswap.h \
-# Makefile.in generated automatically by automake 1.4 from Makefile.am
+# Makefile.in generated automatically by automake 1.4-p5 from Makefile.am
-# Copyright (C) 1994, 1995-8, 1999 Free Software Foundation, Inc.
+# Copyright (C) 1994, 1995-8, 1999, 2001 Free Software Foundation, Inc.
# This Makefile.in is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
# with or without modifications, as long as this notice is preserved.
cpu-m10300.lo \
cpu-mcore.lo \
cpu-mips.lo \
+ cpu-mmix.lo \
cpu-ns32k.lo \
cpu-openrisc.lo \
cpu-pdp11.lo \
cpu-m10300.c \
cpu-mcore.c \
cpu-mips.c \
+ cpu-mmix.c \
cpu-ns32k.c \
cpu-openrisc.c \
cpu-pdp11.c \
elf64-ia64.lo \
elf64-gen.lo \
elf64-mips.lo \
+ elf64-mmix.lo \
elf64-ppc.lo \
elf64-s390.lo \
elf64-sparc.lo \
elf64.lo \
+ mmo.lo \
nlm32-alpha.lo \
nlm64.lo \
pepigen.lo
elf64-hppa.c \
elf64-gen.c \
elf64-mips.c \
+ elf64-mmix.c \
elf64-ppc.c \
elf64-s390.c \
elf64-sparc.c \
elf64.c \
+ mmo.c \
nlm32-alpha.c \
nlm64.c
DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) $(TEXINFOS) $(EXTRA_DIST)
-TAR = tar
+TAR = gtar
GZIP_ENV = --best
SOURCES = $(libbfd_a_SOURCES) $(libbfd_la_SOURCES)
OBJECTS = $(libbfd_a_OBJECTS) $(libbfd_la_OBJECTS)
dot_seen=no; \
rev=''; list='$(SUBDIRS)'; for subdir in $$list; do \
rev="$$subdir $$rev"; \
- test "$$subdir" = "." && dot_seen=yes; \
+ test "$$subdir" != "." || dot_seen=yes; \
done; \
test "$$dot_seen" = "no" && rev=". $$rev"; \
target=`echo $@ | sed s/-recursive//`; \
cpu-m10300.lo: cpu-m10300.c $(INCDIR)/filenames.h
cpu-mcore.lo: cpu-mcore.c $(INCDIR)/filenames.h
cpu-mips.lo: cpu-mips.c $(INCDIR)/filenames.h
+cpu-mmix.lo: cpu-mmix.c $(INCDIR)/filenames.h
cpu-ns32k.lo: cpu-ns32k.c $(INCDIR)/filenames.h ns32k.h
cpu-openrisc.lo: cpu-openrisc.c $(INCDIR)/filenames.h
cpu-pdp11.lo: cpu-pdp11.c $(INCDIR)/filenames.h
$(INCDIR)/elf/reloc-macros.h $(INCDIR)/coff/sym.h $(INCDIR)/coff/symconst.h \
$(INCDIR)/coff/internal.h $(INCDIR)/coff/ecoff.h $(INCDIR)/coff/alpha.h \
ecoffswap.h elf64-target.h
+elf64-mmix.lo: elf64-mmix.c $(INCDIR)/filenames.h elf-bfd.h \
+ $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
+ $(INCDIR)/bfdlink.h $(INCDIR)/elf/mmix.h $(INCDIR)/elf/reloc-macros.h \
+ $(INCDIR)/opcode/mmix.h elf64-target.h
elf64-ppc.lo: elf64-ppc.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/elf/ppc.h $(INCDIR)/elf/reloc-macros.h \
$(INCDIR)/bfdlink.h elf-bfd.h $(INCDIR)/elf/common.h \
$(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h elfcore.h \
elflink.h
+mmo.lo: mmo.c $(INCDIR)/filenames.h $(INCDIR)/libiberty.h \
+ $(INCDIR)/elf/mmix.h $(INCDIR)/elf/reloc-macros.h $(INCDIR)/opcode/mmix.h
nlm32-alpha.lo: nlm32-alpha.c $(INCDIR)/filenames.h \
$(INCDIR)/nlm/alpha-ext.h libnlm.h $(INCDIR)/nlm/common.h \
$(INCDIR)/nlm/internal.h $(INCDIR)/nlm/external.h nlmswap.h \
.#define bfd_mach_s390_esa 0
.#define bfd_mach_s390_esame 1
. bfd_arch_openrisc, {* OpenRISC *}
+. bfd_arch_mmix, {* Donald Knuth's educational processor *}
. bfd_arch_last
. };
*/
extern const bfd_arch_info_type bfd_ia64_arch;
extern const bfd_arch_info_type bfd_s390_arch;
extern const bfd_arch_info_type bfd_openrisc_arch;
+extern const bfd_arch_info_type bfd_mmix_arch;
static const bfd_arch_info_type * const bfd_archures_list[] = {
#ifdef SELECT_ARCHITECTURES
&bfd_ia64_arch,
&bfd_s390_arch,
&bfd_openrisc_arch,
+ &bfd_mmix_arch,
#endif
0
};
#define bfd_mach_s390_esa 0
#define bfd_mach_s390_esame 1
bfd_arch_openrisc, /* OpenRISC */
+ bfd_arch_mmix, /* Donald Knuth's educational processor */
bfd_arch_last
};
BFD_RELOC_MCORE_PCREL_JSR_IMM11BY2,
BFD_RELOC_MCORE_RVA,
+/* These are relocations for the GETA instruction. */
+ BFD_RELOC_MMIX_GETA,
+ BFD_RELOC_MMIX_GETA_1,
+ BFD_RELOC_MMIX_GETA_2,
+ BFD_RELOC_MMIX_GETA_3,
+
+/* These are relocations for a conditional branch instruction. */
+ BFD_RELOC_MMIX_CBRANCH,
+ BFD_RELOC_MMIX_CBRANCH_J,
+ BFD_RELOC_MMIX_CBRANCH_1,
+ BFD_RELOC_MMIX_CBRANCH_2,
+ BFD_RELOC_MMIX_CBRANCH_3,
+
+/* These are relocations for the PUSHJ instruction. */
+ BFD_RELOC_MMIX_PUSHJ,
+ BFD_RELOC_MMIX_PUSHJ_1,
+ BFD_RELOC_MMIX_PUSHJ_2,
+ BFD_RELOC_MMIX_PUSHJ_3,
+
+/* These are relocations for the JMP instruction. */
+ BFD_RELOC_MMIX_JMP,
+ BFD_RELOC_MMIX_JMP_1,
+ BFD_RELOC_MMIX_JMP_2,
+ BFD_RELOC_MMIX_JMP_3,
+
+/* This is a relocation for a relative address as in a GETA instruction or
+a branch. */
+ BFD_RELOC_MMIX_ADDR19,
+
+/* This is a relocation for a relative address as in a JMP instruction. */
+ BFD_RELOC_MMIX_ADDR27,
+
+/* This is a relocation for an instruction field that may be a general
+register or a value 0..255. */
+ BFD_RELOC_MMIX_REG_OR_BYTE,
+
+/* This is a relocation for an instruction field that may be a general
+register. */
+ BFD_RELOC_MMIX_REG,
+
+/* This is a relocation for two instruction fields holding a register and
+an offset, the equivalent of the relocation. */
+ BFD_RELOC_MMIX_BASE_PLUS_OFFSET,
+
+/* This relocation is an assertion that the expression is not allocated as
+a global register. It does not modify contents. */
+ BFD_RELOC_MMIX_LOCAL,
+
/* This is a 16 bit reloc for the AVR that stores 8 bit pc relative
short offset into 7 bits. */
BFD_RELOC_AVR_7_PCREL,
struct elf_obj_tdata *elf_obj_data;
struct nlm_obj_tdata *nlm_obj_data;
struct bout_data_struct *bout_data;
+ struct mmo_data_struct *mmo_data;
struct sun_core_struct *sun_core_data;
struct sco5_core_struct *sco5_core_data;
struct trad_core_struct *trad_core_data;
bfd_target_versados_flavour,
bfd_target_msdos_flavour,
bfd_target_ovax_flavour,
- bfd_target_evax_flavour
+ bfd_target_evax_flavour,
+ bfd_target_mmo_flavour
};
enum bfd_endian { BFD_ENDIAN_BIG, BFD_ENDIAN_LITTLE, BFD_ENDIAN_UNKNOWN };
. struct elf_obj_tdata *elf_obj_data;
. struct nlm_obj_tdata *nlm_obj_data;
. struct bout_data_struct *bout_data;
+. struct mmo_data_struct *mmo_data;
. struct sun_core_struct *sun_core_data;
. struct sco5_core_struct *sco5_core_data;
. struct trad_core_struct *trad_core_data;
targ_defvec=bfd_elf32_tradbigmips_vec
targ_selvecs="bfd_elf32_tradlittlemips_vec bfd_elf64_tradbigmips_vec bfd_elf64_tradlittlemips_vec ecoff_big_vec ecoff_little_vec"
;;
+#ifdef BFD64
+ mmix-*-*)
+ targ_defvec=bfd_elf64_mmix_vec
+ targ_selvecs=bfd_mmo_vec
+ ;;
+#endif
mn10200-*-*)
targ_defvec=bfd_elf32_mn10200_vec
;;
fi
-for ac_hdr in unistd.h
+for ac_hdr in stdlib.h unistd.h sys/stat.h sys/types.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
#include <fcntl.h>
#include <sys/mman.h>
+#if HAVE_SYS_TYPES_H
+# include <sys/types.h>
+#endif
+
+#if HAVE_STDLIB_H
+# include <stdlib.h>
+#endif
+
+#if HAVE_SYS_STAT_H
+# include <sys/stat.h>
+#endif
+
+#if HAVE_UNISTD_H
+# include <unistd.h>
+#endif
+
/* This mess was copied from the GNU getpagesize.h. */
#ifndef HAVE_GETPAGESIZE
-# ifdef HAVE_UNISTD_H
-# include <unistd.h>
-# endif
/* Assume that all systems that can run configure have sys/param.h. */
# ifndef HAVE_SYS_PARAM_H
}
EOF
-if { (eval echo configure:3477: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:3490: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_func_mmap_fixed_mapped=yes
else
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:3505: checking for $ac_hdr" >&5
+echo "configure:3518: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3510 "configure"
+#line 3523 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3515: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3528: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
__argz_count __argz_stringify __argz_next
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3545: checking for $ac_func" >&5
+echo "configure:3558: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3550 "configure"
+#line 3563 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:3573: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3586: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
for ac_func in stpcpy
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3602: checking for $ac_func" >&5
+echo "configure:3615: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3607 "configure"
+#line 3620 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:3630: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3643: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
if test $ac_cv_header_locale_h = yes; then
echo $ac_n "checking for LC_MESSAGES""... $ac_c" 1>&6
-echo "configure:3664: checking for LC_MESSAGES" >&5
+echo "configure:3677: checking for LC_MESSAGES" >&5
if eval "test \"`echo '$''{'am_cv_val_LC_MESSAGES'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3669 "configure"
+#line 3682 "configure"
#include "confdefs.h"
#include <locale.h>
int main() {
return LC_MESSAGES
; return 0; }
EOF
-if { (eval echo configure:3676: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3689: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
am_cv_val_LC_MESSAGES=yes
else
fi
fi
echo $ac_n "checking whether NLS is requested""... $ac_c" 1>&6
-echo "configure:3697: checking whether NLS is requested" >&5
+echo "configure:3710: checking whether NLS is requested" >&5
# Check whether --enable-nls or --disable-nls was given.
if test "${enable_nls+set}" = set; then
enableval="$enable_nls"
EOF
echo $ac_n "checking whether included gettext is requested""... $ac_c" 1>&6
-echo "configure:3717: checking whether included gettext is requested" >&5
+echo "configure:3730: checking whether included gettext is requested" >&5
# Check whether --with-included-gettext or --without-included-gettext was given.
if test "${with_included_gettext+set}" = set; then
withval="$with_included_gettext"
ac_safe=`echo "libintl.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for libintl.h""... $ac_c" 1>&6
-echo "configure:3736: checking for libintl.h" >&5
+echo "configure:3749: checking for libintl.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3741 "configure"
+#line 3754 "configure"
#include "confdefs.h"
#include <libintl.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3746: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3759: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
echo "$ac_t""yes" 1>&6
echo $ac_n "checking for gettext in libc""... $ac_c" 1>&6
-echo "configure:3763: checking for gettext in libc" >&5
+echo "configure:3776: checking for gettext in libc" >&5
if eval "test \"`echo '$''{'gt_cv_func_gettext_libc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3768 "configure"
+#line 3781 "configure"
#include "confdefs.h"
#include <libintl.h>
int main() {
return (int) gettext ("")
; return 0; }
EOF
-if { (eval echo configure:3775: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3788: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
gt_cv_func_gettext_libc=yes
else
if test "$gt_cv_func_gettext_libc" != "yes"; then
echo $ac_n "checking for bindtextdomain in -lintl""... $ac_c" 1>&6
-echo "configure:3791: checking for bindtextdomain in -lintl" >&5
+echo "configure:3804: checking for bindtextdomain in -lintl" >&5
ac_lib_var=`echo intl'_'bindtextdomain | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lintl $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 3799 "configure"
+#line 3812 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
bindtextdomain()
; return 0; }
EOF
-if { (eval echo configure:3810: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3823: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
echo "$ac_t""yes" 1>&6
echo $ac_n "checking for gettext in libintl""... $ac_c" 1>&6
-echo "configure:3826: checking for gettext in libintl" >&5
+echo "configure:3839: checking for gettext in libintl" >&5
if eval "test \"`echo '$''{'gt_cv_func_gettext_libintl'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3831 "configure"
+#line 3844 "configure"
#include "confdefs.h"
int main() {
return (int) gettext ("")
; return 0; }
EOF
-if { (eval echo configure:3838: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3851: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
gt_cv_func_gettext_libintl=yes
else
# Extract the first word of "msgfmt", so it can be a program name with args.
set dummy msgfmt; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3866: checking for $ac_word" >&5
+echo "configure:3879: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
for ac_func in dcgettext
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3900: checking for $ac_func" >&5
+echo "configure:3913: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3905 "configure"
+#line 3918 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:3928: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3941: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
# Extract the first word of "gmsgfmt", so it can be a program name with args.
set dummy gmsgfmt; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3955: checking for $ac_word" >&5
+echo "configure:3968: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "xgettext", so it can be a program name with args.
set dummy xgettext; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3991: checking for $ac_word" >&5
+echo "configure:4004: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
fi
cat > conftest.$ac_ext <<EOF
-#line 4023 "configure"
+#line 4036 "configure"
#include "confdefs.h"
int main() {
return _nl_msg_cat_cntr
; return 0; }
EOF
-if { (eval echo configure:4031: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4044: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
CATOBJEXT=.gmo
DATADIRNAME=share
# Extract the first word of "msgfmt", so it can be a program name with args.
set dummy msgfmt; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4063: checking for $ac_word" >&5
+echo "configure:4076: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "gmsgfmt", so it can be a program name with args.
set dummy gmsgfmt; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4097: checking for $ac_word" >&5
+echo "configure:4110: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "xgettext", so it can be a program name with args.
set dummy xgettext; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4133: checking for $ac_word" >&5
+echo "configure:4146: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
LINGUAS=
else
echo $ac_n "checking for catalogs to be installed""... $ac_c" 1>&6
-echo "configure:4223: checking for catalogs to be installed" >&5
+echo "configure:4236: checking for catalogs to be installed" >&5
NEW_LINGUAS=
for lang in ${LINGUAS=$ALL_LINGUAS}; do
case "$ALL_LINGUAS" in
if test "$CATOBJEXT" = ".cat"; then
ac_safe=`echo "linux/version.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for linux/version.h""... $ac_c" 1>&6
-echo "configure:4251: checking for linux/version.h" >&5
+echo "configure:4264: checking for linux/version.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4256 "configure"
+#line 4269 "configure"
#include "confdefs.h"
#include <linux/version.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:4261: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:4274: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
l=
- if test -d $srcdir/po; then
+ if test -f $srcdir/po/POTFILES.in; then
test -d po || mkdir po
if test "x$srcdir" != "x."; then
if test "x`echo $srcdir | sed 's@/.*@@'`" = "x"; then
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:4339: checking for a BSD compatible install" >&5
+echo "configure:4352: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
EXEEXT_FOR_BUILD='$(EXEEXT)'
else
echo $ac_n "checking for build system executable suffix""... $ac_c" 1>&6
-echo "configure:4422: checking for build system executable suffix" >&5
+echo "configure:4435: checking for build system executable suffix" >&5
if eval "test \"`echo '$''{'bfd_cv_build_exeext'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:4450: checking for $ac_hdr" >&5
+echo "configure:4463: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4455 "configure"
+#line 4468 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:4460: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:4473: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:4490: checking for $ac_hdr" >&5
+echo "configure:4503: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4495 "configure"
+#line 4508 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:4500: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:4513: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
done
echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6
-echo "configure:4527: checking whether time.h and sys/time.h may both be included" >&5
+echo "configure:4540: checking whether time.h and sys/time.h may both be included" >&5
if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4532 "configure"
+#line 4545 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <sys/time.h>
struct tm *tp;
; return 0; }
EOF
-if { (eval echo configure:4541: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4554: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_header_time=yes
else
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr that defines DIR""... $ac_c" 1>&6
-echo "configure:4566: checking for $ac_hdr that defines DIR" >&5
+echo "configure:4579: checking for $ac_hdr that defines DIR" >&5
if eval "test \"`echo '$''{'ac_cv_header_dirent_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4571 "configure"
+#line 4584 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <$ac_hdr>
DIR *dirp = 0;
; return 0; }
EOF
-if { (eval echo configure:4579: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4592: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
eval "ac_cv_header_dirent_$ac_safe=yes"
else
# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
if test $ac_header_dirent = dirent.h; then
echo $ac_n "checking for opendir in -ldir""... $ac_c" 1>&6
-echo "configure:4604: checking for opendir in -ldir" >&5
+echo "configure:4617: checking for opendir in -ldir" >&5
ac_lib_var=`echo dir'_'opendir | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-ldir $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 4612 "configure"
+#line 4625 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
opendir()
; return 0; }
EOF
-if { (eval echo configure:4623: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4636: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
else
echo $ac_n "checking for opendir in -lx""... $ac_c" 1>&6
-echo "configure:4645: checking for opendir in -lx" >&5
+echo "configure:4658: checking for opendir in -lx" >&5
ac_lib_var=`echo x'_'opendir | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lx $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 4653 "configure"
+#line 4666 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
opendir()
; return 0; }
EOF
-if { (eval echo configure:4664: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4677: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
for ac_func in fcntl getpagesize setitimer sysconf fdopen getuid getgid
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:4689: checking for $ac_func" >&5
+echo "configure:4702: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4694 "configure"
+#line 4707 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:4717: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4730: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
esac
echo $ac_n "checking whether strstr must be declared""... $ac_c" 1>&6
-echo "configure:4752: checking whether strstr must be declared" >&5
+echo "configure:4765: checking whether strstr must be declared" >&5
if eval "test \"`echo '$''{'bfd_cv_decl_needed_strstr'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4757 "configure"
+#line 4770 "configure"
#include "confdefs.h"
#include <stdio.h>
char *(*pfn) = (char *(*)) strstr
; return 0; }
EOF
-if { (eval echo configure:4778: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4791: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_decl_needed_strstr=no
else
fi
echo $ac_n "checking whether malloc must be declared""... $ac_c" 1>&6
-echo "configure:4799: checking whether malloc must be declared" >&5
+echo "configure:4812: checking whether malloc must be declared" >&5
if eval "test \"`echo '$''{'bfd_cv_decl_needed_malloc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4804 "configure"
+#line 4817 "configure"
#include "confdefs.h"
#include <stdio.h>
char *(*pfn) = (char *(*)) malloc
; return 0; }
EOF
-if { (eval echo configure:4825: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4838: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_decl_needed_malloc=no
else
fi
echo $ac_n "checking whether realloc must be declared""... $ac_c" 1>&6
-echo "configure:4846: checking whether realloc must be declared" >&5
+echo "configure:4859: checking whether realloc must be declared" >&5
if eval "test \"`echo '$''{'bfd_cv_decl_needed_realloc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4851 "configure"
+#line 4864 "configure"
#include "confdefs.h"
#include <stdio.h>
char *(*pfn) = (char *(*)) realloc
; return 0; }
EOF
-if { (eval echo configure:4872: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4885: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_decl_needed_realloc=no
else
fi
echo $ac_n "checking whether free must be declared""... $ac_c" 1>&6
-echo "configure:4893: checking whether free must be declared" >&5
+echo "configure:4906: checking whether free must be declared" >&5
if eval "test \"`echo '$''{'bfd_cv_decl_needed_free'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4898 "configure"
+#line 4911 "configure"
#include "confdefs.h"
#include <stdio.h>
char *(*pfn) = (char *(*)) free
; return 0; }
EOF
-if { (eval echo configure:4919: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4932: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_decl_needed_free=no
else
fi
echo $ac_n "checking whether getenv must be declared""... $ac_c" 1>&6
-echo "configure:4940: checking whether getenv must be declared" >&5
+echo "configure:4953: checking whether getenv must be declared" >&5
if eval "test \"`echo '$''{'bfd_cv_decl_needed_getenv'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4945 "configure"
+#line 4958 "configure"
#include "confdefs.h"
#include <stdio.h>
char *(*pfn) = (char *(*)) getenv
; return 0; }
EOF
-if { (eval echo configure:4966: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4979: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_decl_needed_getenv=no
else
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:5189: checking for $ac_hdr" >&5
+echo "configure:5202: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5194 "configure"
+#line 5207 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:5199: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:5212: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
if test "$ac_cv_header_sys_procfs_h" = yes; then
echo $ac_n "checking for prstatus_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5227: checking for prstatus_t in sys/procfs.h" >&5
+echo "configure:5240: checking for prstatus_t in sys/procfs.h" >&5
if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_prstatus_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5232 "configure"
+#line 5245 "configure"
#include "confdefs.h"
#define _SYSCALL32
prstatus_t avar
; return 0; }
EOF
-if { (eval echo configure:5241: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5254: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_have_sys_procfs_type_prstatus_t=yes
else
echo "$ac_t""$bfd_cv_have_sys_procfs_type_prstatus_t" 1>&6
echo $ac_n "checking for prstatus32_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5263: checking for prstatus32_t in sys/procfs.h" >&5
+echo "configure:5276: checking for prstatus32_t in sys/procfs.h" >&5
if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_prstatus32_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5268 "configure"
+#line 5281 "configure"
#include "confdefs.h"
#define _SYSCALL32
prstatus32_t avar
; return 0; }
EOF
-if { (eval echo configure:5277: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5290: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_have_sys_procfs_type_prstatus32_t=yes
else
echo "$ac_t""$bfd_cv_have_sys_procfs_type_prstatus32_t" 1>&6
echo $ac_n "checking for prstatus_t.pr_who in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5299: checking for prstatus_t.pr_who in sys/procfs.h" >&5
+echo "configure:5312: checking for prstatus_t.pr_who in sys/procfs.h" >&5
if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_member_prstatus_t_pr_who'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5304 "configure"
+#line 5317 "configure"
#include "confdefs.h"
#define _SYSCALL32
prstatus_t avar; void* aref = (void*) &avar.pr_who
; return 0; }
EOF
-if { (eval echo configure:5313: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5326: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_have_sys_procfs_type_member_prstatus_t_pr_who=yes
else
echo "$ac_t""$bfd_cv_have_sys_procfs_type_member_prstatus_t_pr_who" 1>&6
echo $ac_n "checking for prstatus32_t.pr_who in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5335: checking for prstatus32_t.pr_who in sys/procfs.h" >&5
+echo "configure:5348: checking for prstatus32_t.pr_who in sys/procfs.h" >&5
if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_member_prstatus32_t_pr_who'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5340 "configure"
+#line 5353 "configure"
#include "confdefs.h"
#define _SYSCALL32
prstatus32_t avar; void* aref = (void*) &avar.pr_who
; return 0; }
EOF
-if { (eval echo configure:5349: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5362: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_have_sys_procfs_type_member_prstatus32_t_pr_who=yes
else
echo "$ac_t""$bfd_cv_have_sys_procfs_type_member_prstatus32_t_pr_who" 1>&6
echo $ac_n "checking for pstatus_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5371: checking for pstatus_t in sys/procfs.h" >&5
+echo "configure:5384: checking for pstatus_t in sys/procfs.h" >&5
if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_pstatus_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5376 "configure"
+#line 5389 "configure"
#include "confdefs.h"
#define _SYSCALL32
pstatus_t avar
; return 0; }
EOF
-if { (eval echo configure:5385: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5398: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_have_sys_procfs_type_pstatus_t=yes
else
echo "$ac_t""$bfd_cv_have_sys_procfs_type_pstatus_t" 1>&6
echo $ac_n "checking for pxstatus_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5407: checking for pxstatus_t in sys/procfs.h" >&5
+echo "configure:5420: checking for pxstatus_t in sys/procfs.h" >&5
if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_pxstatus_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5412 "configure"
+#line 5425 "configure"
#include "confdefs.h"
#define _SYSCALL32
pxstatus_t avar
; return 0; }
EOF
-if { (eval echo configure:5421: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5434: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_have_sys_procfs_type_pxstatus_t=yes
else
echo "$ac_t""$bfd_cv_have_sys_procfs_type_pxstatus_t" 1>&6
echo $ac_n "checking for pstatus32_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5443: checking for pstatus32_t in sys/procfs.h" >&5
+echo "configure:5456: checking for pstatus32_t in sys/procfs.h" >&5
if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_pstatus32_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5448 "configure"
+#line 5461 "configure"
#include "confdefs.h"
#define _SYSCALL32
pstatus32_t avar
; return 0; }
EOF
-if { (eval echo configure:5457: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5470: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_have_sys_procfs_type_pstatus32_t=yes
else
echo "$ac_t""$bfd_cv_have_sys_procfs_type_pstatus32_t" 1>&6
echo $ac_n "checking for prpsinfo_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5479: checking for prpsinfo_t in sys/procfs.h" >&5
+echo "configure:5492: checking for prpsinfo_t in sys/procfs.h" >&5
if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_prpsinfo_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5484 "configure"
+#line 5497 "configure"
#include "confdefs.h"
#define _SYSCALL32
prpsinfo_t avar
; return 0; }
EOF
-if { (eval echo configure:5493: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5506: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_have_sys_procfs_type_prpsinfo_t=yes
else
echo "$ac_t""$bfd_cv_have_sys_procfs_type_prpsinfo_t" 1>&6
echo $ac_n "checking for prpsinfo32_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5515: checking for prpsinfo32_t in sys/procfs.h" >&5
+echo "configure:5528: checking for prpsinfo32_t in sys/procfs.h" >&5
if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_prpsinfo32_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5520 "configure"
+#line 5533 "configure"
#include "confdefs.h"
#define _SYSCALL32
prpsinfo32_t avar
; return 0; }
EOF
-if { (eval echo configure:5529: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5542: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_have_sys_procfs_type_prpsinfo32_t=yes
else
echo "$ac_t""$bfd_cv_have_sys_procfs_type_prpsinfo32_t" 1>&6
echo $ac_n "checking for psinfo_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5551: checking for psinfo_t in sys/procfs.h" >&5
+echo "configure:5564: checking for psinfo_t in sys/procfs.h" >&5
if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_psinfo_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5556 "configure"
+#line 5569 "configure"
#include "confdefs.h"
#define _SYSCALL32
psinfo_t avar
; return 0; }
EOF
-if { (eval echo configure:5565: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5578: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_have_sys_procfs_type_psinfo_t=yes
else
echo "$ac_t""$bfd_cv_have_sys_procfs_type_psinfo_t" 1>&6
echo $ac_n "checking for psinfo32_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5587: checking for psinfo32_t in sys/procfs.h" >&5
+echo "configure:5600: checking for psinfo32_t in sys/procfs.h" >&5
if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_psinfo32_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5592 "configure"
+#line 5605 "configure"
#include "confdefs.h"
#define _SYSCALL32
psinfo32_t avar
; return 0; }
EOF
-if { (eval echo configure:5601: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5614: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_have_sys_procfs_type_psinfo32_t=yes
else
echo "$ac_t""$bfd_cv_have_sys_procfs_type_psinfo32_t" 1>&6
echo $ac_n "checking for lwpstatus_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5623: checking for lwpstatus_t in sys/procfs.h" >&5
+echo "configure:5636: checking for lwpstatus_t in sys/procfs.h" >&5
if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_lwpstatus_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5628 "configure"
+#line 5641 "configure"
#include "confdefs.h"
#define _SYSCALL32
lwpstatus_t avar
; return 0; }
EOF
-if { (eval echo configure:5637: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5650: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_have_sys_procfs_type_lwpstatus_t=yes
else
echo "$ac_t""$bfd_cv_have_sys_procfs_type_lwpstatus_t" 1>&6
echo $ac_n "checking for lwpxstatus_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5659: checking for lwpxstatus_t in sys/procfs.h" >&5
+echo "configure:5672: checking for lwpxstatus_t in sys/procfs.h" >&5
if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_lwpxstatus_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5664 "configure"
+#line 5677 "configure"
#include "confdefs.h"
#define _SYSCALL32
lwpxstatus_t avar
; return 0; }
EOF
-if { (eval echo configure:5673: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5686: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_have_sys_procfs_type_lwpxstatus_t=yes
else
echo "$ac_t""$bfd_cv_have_sys_procfs_type_lwpxstatus_t" 1>&6
echo $ac_n "checking for lwpstatus_t.pr_context in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5695: checking for lwpstatus_t.pr_context in sys/procfs.h" >&5
+echo "configure:5708: checking for lwpstatus_t.pr_context in sys/procfs.h" >&5
if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_context'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5700 "configure"
+#line 5713 "configure"
#include "confdefs.h"
#define _SYSCALL32
lwpstatus_t avar; void* aref = (void*) &avar.pr_context
; return 0; }
EOF
-if { (eval echo configure:5709: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5722: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_context=yes
else
echo "$ac_t""$bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_context" 1>&6
echo $ac_n "checking for lwpstatus_t.pr_reg in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5731: checking for lwpstatus_t.pr_reg in sys/procfs.h" >&5
+echo "configure:5744: checking for lwpstatus_t.pr_reg in sys/procfs.h" >&5
if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_reg'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5736 "configure"
+#line 5749 "configure"
#include "confdefs.h"
#define _SYSCALL32
lwpstatus_t avar; void* aref = (void*) &avar.pr_reg
; return 0; }
EOF
-if { (eval echo configure:5745: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5758: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_reg=yes
else
echo "$ac_t""$bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_reg" 1>&6
echo $ac_n "checking for win32_pstatus_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5767: checking for win32_pstatus_t in sys/procfs.h" >&5
+echo "configure:5780: checking for win32_pstatus_t in sys/procfs.h" >&5
if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_win32_pstatus_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5772 "configure"
+#line 5785 "configure"
#include "confdefs.h"
#define _SYSCALL32
win32_pstatus_t avar
; return 0; }
EOF
-if { (eval echo configure:5781: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5794: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_have_sys_procfs_type_win32_pstatus_t=yes
else
bfd_elf64_ia64_little_vec) tb="$tb elf64-ia64.lo elf64.lo $elf"; target_size=64 ;;
bfd_elf64_little_generic_vec) tb="$tb elf64-gen.lo elf64.lo $elf"; target_size=64 ;;
bfd_elf64_littlemips_vec) tb="$tb elf64-mips.lo elf64.lo elf32-mips.lo elf32.lo $elf ecofflink.lo"; target_size=64 ;;
+ bfd_elf64_mmix_vec) tb="$tb elf64-mmix.lo elf64.lo $elf" target_size=64 ;;
bfd_elf64_powerpc_vec) tb="$tb elf64-ppc.lo elf64-gen.lo elf64.lo $elf"; target_size=64 ;;
bfd_elf64_powerpcle_vec) tb="$tb elf64-ppc.lo elf64-gen.lo elf64.lo $elf" target_size=64 ;;
bfd_elf64_s390_vec) tb="$tb elf64-s390.lo elf64.lo $elf"; target_size=64 ;;
bfd_elf64_tradbigmips_vec) tb="$tb elf64-mips.lo elf64.lo $elf ecofflink.lo"; target_size=64 ;;
bfd_elf64_tradlittlemips_vec) tb="$tb elf64-mips.lo elf64.lo $elf ecofflink.lo"; target_size=64 ;;
bfd_elf64_x86_64_vec) tb="$tb elf64-x86-64.lo elf64.lo $elf"; target_size=64 ;;
+ bfd_mmo_vec) tb="$tb mmo.lo" target_size=64 ;;
bfd_powerpc_pe_vec) tb="$tb pe-ppc.lo peigen.lo cofflink.lo" ;;
bfd_powerpc_pei_vec) tb="$tb pei-ppc.lo peigen.lo cofflink.lo" ;;
bfd_powerpcle_pe_vec) tb="$tb pe-ppc.lo peigen.lo cofflink.lo" ;;
test -n "${havevecs}" && tdefaults="${tdefaults} ${havevecs}"
-for ac_hdr in unistd.h
+for ac_hdr in stdlib.h unistd.h sys/stat.h sys/types.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:6199: checking for $ac_hdr" >&5
+echo "configure:6214: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 6204 "configure"
+#line 6219 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:6209: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:6224: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
for ac_func in getpagesize
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:6238: checking for $ac_func" >&5
+echo "configure:6253: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 6243 "configure"
+#line 6258 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:6266: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6281: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
done
echo $ac_n "checking for working mmap""... $ac_c" 1>&6
-echo "configure:6291: checking for working mmap" >&5
+echo "configure:6306: checking for working mmap" >&5
if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_cv_func_mmap_fixed_mapped=no
else
cat > conftest.$ac_ext <<EOF
-#line 6299 "configure"
+#line 6314 "configure"
#include "confdefs.h"
/* Thanks to Mike Haertel and Jim Avera for this test.
#include <fcntl.h>
#include <sys/mman.h>
+#if HAVE_SYS_TYPES_H
+# include <sys/types.h>
+#endif
+
+#if HAVE_STDLIB_H
+# include <stdlib.h>
+#endif
+
+#if HAVE_SYS_STAT_H
+# include <sys/stat.h>
+#endif
+
+#if HAVE_UNISTD_H
+# include <unistd.h>
+#endif
+
/* This mess was copied from the GNU getpagesize.h. */
#ifndef HAVE_GETPAGESIZE
-# ifdef HAVE_UNISTD_H
-# include <unistd.h>
-# endif
/* Assume that all systems that can run configure have sys/param.h. */
# ifndef HAVE_SYS_PARAM_H
}
EOF
-if { (eval echo configure:6439: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:6467: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_func_mmap_fixed_mapped=yes
else
for ac_func in madvise mprotect
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:6464: checking for $ac_func" >&5
+echo "configure:6492: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 6469 "configure"
+#line 6497 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:6492: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6520: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
bfd_elf64_ia64_little_vec) tb="$tb elf64-ia64.lo elf64.lo $elf"; target_size=64 ;;
bfd_elf64_little_generic_vec) tb="$tb elf64-gen.lo elf64.lo $elf"; target_size=64 ;;
bfd_elf64_littlemips_vec) tb="$tb elf64-mips.lo elf64.lo elf32-mips.lo elf32.lo $elf ecofflink.lo"; target_size=64 ;;
+ bfd_elf64_mmix_vec) tb="$tb elf64-mmix.lo elf64.lo $elf" target_size=64 ;;
bfd_elf64_powerpc_vec) tb="$tb elf64-ppc.lo elf64-gen.lo elf64.lo $elf"; target_size=64 ;;
bfd_elf64_powerpcle_vec) tb="$tb elf64-ppc.lo elf64-gen.lo elf64.lo $elf" target_size=64 ;;
bfd_elf64_s390_vec) tb="$tb elf64-s390.lo elf64.lo $elf"; target_size=64 ;;
bfd_elf64_tradbigmips_vec) tb="$tb elf64-mips.lo elf64.lo $elf ecofflink.lo"; target_size=64 ;;
bfd_elf64_tradlittlemips_vec) tb="$tb elf64-mips.lo elf64.lo $elf ecofflink.lo"; target_size=64 ;;
bfd_elf64_x86_64_vec) tb="$tb elf64-x86-64.lo elf64.lo $elf"; target_size=64 ;;
+ bfd_mmo_vec) tb="$tb mmo.lo" target_size=64 ;;
bfd_powerpc_pe_vec) tb="$tb pe-ppc.lo peigen.lo cofflink.lo" ;;
bfd_powerpc_pei_vec) tb="$tb pei-ppc.lo peigen.lo cofflink.lo" ;;
bfd_powerpcle_pe_vec) tb="$tb pe-ppc.lo peigen.lo cofflink.lo" ;;
--- /dev/null
+/* BFD library support routines for MMIX.
+ Copyright (C) 2001 Free Software Foundation, Inc.
+ Contributed by Hans-Peter Nilsson (hp@bitrange.com)
+
+This file is part of BFD, the Binary File Descriptor library.
+
+This program is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2 of the License, or
+(at your option) any later version.
+
+This program is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with this program; if not, write to the Free Software
+Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+
+#include "bfd.h"
+#include "sysdep.h"
+#include "libbfd.h"
+
+const bfd_arch_info_type
+bfd_mmix_arch =
+ {
+ 64, /* 64 bits in a word. */
+ 64, /* 64 bits in an address. */
+ 8, /* 8 bits in a byte. */
+ bfd_arch_mmix, /* Architecture. */
+ 0, /* Machine number - 0 for now. */
+ /* Sorry, these are by custom and creeping assumption lower-case. */
+ "mmix", /* Architecture name. */
+ "mmix", /* Printable name. */
+ 3, /* Section align power. */
+ true, /* This is the default architecture. */
+ bfd_default_compatible, /* Architecture comparison function. */
+ bfd_default_scan, /* String to architecture conversion. */
+ NULL /* Next in list. */
+};
+2001-10-30 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * doc/bfdint.texi (BFD target vector miscellaneous): Add
+ bfd_target_mmo_flavour.
+ * doc/bfd.texinfo (BFD back ends): Add entry for mmo.
+ * doc/Makefile.am (DOCFILES): Add mmo.texi.
+ (SRCDOC): Add mmo.c.
+ (s-mmo, mmo.texi): New rules.
+
2001-10-29 Kazu Hirata <kazu@hxi.com>
* bfdsumm.texi: Fix a typo.
bfdt.texi cache.texi coffcode.texi \
core.texi elf.texi elfcode.texi format.texi libbfd.texi \
opncls.texi reloc.texi section.texi \
- syms.texi targets.texi init.texi hash.texi linker.texi
+ syms.texi targets.texi init.texi hash.texi linker.texi \
+ mmo.texi
PROTOS = archive.p archures.p bfd.p \
core.p format.p \
$(srcdir)/../libbfd.c $(srcdir)/../opncls.c \
$(srcdir)/../reloc.c $(srcdir)/../section.c \
$(srcdir)/../syms.c $(srcdir)/../targets.c \
- $(srcdir)/../hash.c $(srcdir)/../linker.c
+ $(srcdir)/../hash.c $(srcdir)/../linker.c \
+ $(srcdir)/../mmo.c
SRCPROT = $(srcdir)/../archive.c $(srcdir)/../archures.c \
$(srcdir)/../bfd.c $(srcdir)/../coffcode.h $(srcdir)/../corefile.c \
touch s-elfcode
elfcode.texi: s-elfcode
+s-mmo: $(MKDOC) $(srcdir)/../mmo.c $(srcdir)/doc.str
+ ./$(MKDOC) -f $(srcdir)/doc.str <$(srcdir)/../mmo.c >mmo.tmp
+ $(srcdir)/../../move-if-change mmo.tmp mmo.texi
+ touch s-mmo
+mmo.texi: s-mmo
+
s-format: $(MKDOC) $(srcdir)/../format.c $(srcdir)/doc.str
./$(MKDOC) -f $(srcdir)/doc.str <$(srcdir)/../format.c >format.tmp
$(srcdir)/../../move-if-change format.tmp format.texi
-# Makefile.in generated automatically by automake 1.4 from Makefile.am
+# Makefile.in generated automatically by automake 1.4-p5 from Makefile.am
-# Copyright (C) 1994, 1995-8, 1999 Free Software Foundation, Inc.
+# Copyright (C) 1994, 1995-8, 1999, 2001 Free Software Foundation, Inc.
# This Makefile.in is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
# with or without modifications, as long as this notice is preserved.
bfdt.texi cache.texi coffcode.texi \
core.texi elf.texi elfcode.texi format.texi libbfd.texi \
opncls.texi reloc.texi section.texi \
- syms.texi targets.texi init.texi hash.texi linker.texi
+ syms.texi targets.texi init.texi hash.texi linker.texi \
+ mmo.texi
PROTOS = archive.p archures.p bfd.p \
$(srcdir)/../libbfd.c $(srcdir)/../opncls.c \
$(srcdir)/../reloc.c $(srcdir)/../section.c \
$(srcdir)/../syms.c $(srcdir)/../targets.c \
- $(srcdir)/../hash.c $(srcdir)/../linker.c
+ $(srcdir)/../hash.c $(srcdir)/../linker.c \
+ $(srcdir)/../mmo.c
SRCPROT = $(srcdir)/../archive.c $(srcdir)/../archures.c \
DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) $(TEXINFOS) $(EXTRA_DIST)
-TAR = tar
+TAR = gtar
GZIP_ENV = --best
all: all-redirect
.SUFFIXES:
else ii=; fi; \
list='$(INFO_DEPS)'; \
for file in $$list; do \
- test -z "$ii" \
+ test -z "$$ii" \
|| install-info --info-dir=$(DESTDIR)$(infodir) --remove $$file; \
done
@$(NORMAL_UNINSTALL)
touch s-elfcode
elfcode.texi: s-elfcode
+s-mmo: $(MKDOC) $(srcdir)/../mmo.c $(srcdir)/doc.str
+ ./$(MKDOC) -f $(srcdir)/doc.str <$(srcdir)/../mmo.c >mmo.tmp
+ $(srcdir)/../../move-if-change mmo.tmp mmo.texi
+ touch s-mmo
+mmo.texi: s-mmo
+
s-format: $(MKDOC) $(srcdir)/../format.c $(srcdir)/doc.str
./$(MKDOC) -f $(srcdir)/doc.str <$(srcdir)/../format.c >format.tmp
$(srcdir)/../../move-if-change format.tmp format.texi
* aout :: a.out backends
* coff :: coff backends
* elf :: elf backends
+* mmo :: mmo backend
@ignore
* oasys :: oasys backends
* ieee :: ieee backend
@node coff, elf, aout, BFD back ends
@include coffcode.texi
-@node elf, , coff, BFD back ends
+@node elf, mmo, coff, BFD back ends
@include elf.texi
@c Leave this out until the file has some actual contents...
@c @include elfcode.texi
+@node mmo, , elf, BFD back ends
+@include mmo.texi
+
@node GNU Free Documentation License, Index, BFD back ends, Top
@chapter GNU Free Documentation License
@cindex GNU Free Documentation License
MS-DOS.
@item bfd_target_evax_flavour
openVMS.
+@item bfd_target_mmo_flavour
+Donald Knuth's MMIXware object format.
@end table
@item byteorder
--- /dev/null
+/* MMIX-specific support for 64-bit ELF.
+ Copyright (C) 2001 Free Software Foundation, Inc.
+ Contributed by Hans-Peter Nilsson <hp@bitrange.com>
+
+This file is part of BFD, the Binary File Descriptor library.
+
+This program is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2 of the License, or
+(at your option) any later version.
+
+This program is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with this program; if not, write to the Free Software
+Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+
+/* No specific ABI or "processor-specific supplement" defined. */
+
+/* TODO:
+ - Linker relaxation.
+ - On-demand register allocation (from R_MMIX_BASE_PLUS_OFFSET). */
+
+#include "bfd.h"
+#include "sysdep.h"
+#include "libbfd.h"
+#include "elf-bfd.h"
+#include "elf/mmix.h"
+#include "opcode/mmix.h"
+
+#define MINUS_ONE (((bfd_vma) 0) - 1)
+
+/* Put these everywhere in new code. */
+#define FATAL_DEBUG \
+ _bfd_abort (__FILE__, __LINE__, \
+ "Internal: Non-debugged code (test-case missing)")
+
+#define BAD_CASE(x) \
+ _bfd_abort (__FILE__, __LINE__, \
+ "bad case for " #x)
+
+static boolean mmix_elf_link_output_symbol_hook
+ PARAMS ((bfd *, struct bfd_link_info *, const char *,
+ Elf_Internal_Sym *, asection *));
+
+static bfd_reloc_status_type mmix_elf_reloc
+ PARAMS ((bfd *, arelent *, asymbol *, PTR, asection *, bfd *, char **));
+
+static reloc_howto_type *bfd_elf64_bfd_reloc_type_lookup
+ PARAMS ((bfd *, bfd_reloc_code_real_type));
+
+static void mmix_info_to_howto_rela
+ PARAMS ((bfd *, arelent *, Elf64_Internal_Rela *));
+
+static int mmix_elf_sort_relocs PARAMS ((const PTR, const PTR));
+
+static boolean mmix_elf_check_relocs
+ PARAMS ((bfd *, struct bfd_link_info *, asection *,
+ const Elf_Internal_Rela *));
+
+static boolean mmix_elf_relocate_section
+ PARAMS ((bfd *, struct bfd_link_info *, bfd *, asection *, bfd_byte *,
+ Elf_Internal_Rela *, Elf_Internal_Sym *, asection **));
+
+static asection * mmix_elf_gc_mark_hook
+ PARAMS ((bfd *, struct bfd_link_info *, Elf_Internal_Rela *,
+ struct elf_link_hash_entry *, Elf_Internal_Sym *));
+
+static bfd_reloc_status_type mmix_final_link_relocate
+ PARAMS ((reloc_howto_type *, asection *, bfd_byte *,
+ bfd_vma, bfd_signed_vma, bfd_vma, const char *, asection *));
+
+static bfd_reloc_status_type mmix_elf_perform_relocation
+ PARAMS ((asection *, reloc_howto_type *, PTR, bfd_vma, bfd_vma));
+
+static boolean mmix_elf_section_from_bfd_section
+ PARAMS ((bfd *, Elf64_Internal_Shdr *, asection *, int *));
+
+static boolean mmix_elf_add_symbol_hook
+ PARAMS ((bfd *, struct bfd_link_info *, const Elf_Internal_Sym *,
+ const char **, flagword *, asection **, bfd_vma *));
+
+static boolean mmix_elf_is_local_label_name
+ PARAMS ((bfd *, const char *));
+
+extern boolean mmix_elf_final_link PARAMS ((bfd *, struct bfd_link_info *));
+
+extern void mmix_elf_symbol_processing PARAMS ((bfd *, asymbol *));
+
+/* Watch out: this currently needs to have elements with the same index as
+ their R_MMIX_ number. */
+static reloc_howto_type elf_mmix_howto_table[] =
+ {
+ /* This reloc does nothing. */
+ HOWTO (R_MMIX_NONE, /* type */
+ 0, /* rightshift */
+ 2, /* size (0 = byte, 1 = short, 2 = long) */
+ 32, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_bitfield, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ "R_MMIX_NONE", /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* An 8 bit absolute relocation. */
+ HOWTO (R_MMIX_8, /* type */
+ 0, /* rightshift */
+ 0, /* size (0 = byte, 1 = short, 2 = long) */
+ 8, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_bitfield, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ "R_MMIX_8", /* name */
+ false, /* partial_inplace */
+ 0xff, /* src_mask */
+ 0xff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* An 16 bit absolute relocation. */
+ HOWTO (R_MMIX_16, /* type */
+ 0, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_bitfield, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ "R_MMIX_16", /* name */
+ false, /* partial_inplace */
+ 0xffff, /* src_mask */
+ 0xffff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* An 24 bit absolute relocation. */
+ HOWTO (R_MMIX_24, /* type */
+ 0, /* rightshift */
+ 2, /* size (0 = byte, 1 = short, 2 = long) */
+ 24, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_bitfield, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ "R_MMIX_24", /* name */
+ false, /* partial_inplace */
+ 0xffffff, /* src_mask */
+ 0xffffff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* A 32 bit absolute relocation. */
+ HOWTO (R_MMIX_32, /* type */
+ 0, /* rightshift */
+ 2, /* size (0 = byte, 1 = short, 2 = long) */
+ 32, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_bitfield, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ "R_MMIX_32", /* name */
+ false, /* partial_inplace */
+ 0xffffffff, /* src_mask */
+ 0xffffffff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* 64 bit relocation. */
+ HOWTO (R_MMIX_64, /* type */
+ 0, /* rightshift */
+ 4, /* size (0 = byte, 1 = short, 2 = long) */
+ 64, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_bitfield, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ "R_MMIX_64", /* name */
+ false, /* partial_inplace */
+ MINUS_ONE, /* src_mask */
+ MINUS_ONE, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* An 8 bit PC-relative relocation. */
+ HOWTO (R_MMIX_PC_8, /* type */
+ 0, /* rightshift */
+ 0, /* size (0 = byte, 1 = short, 2 = long) */
+ 8, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_bitfield, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ "R_MMIX_PC_8", /* name */
+ false, /* partial_inplace */
+ 0xff, /* src_mask */
+ 0xff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ /* An 16 bit PC-relative relocation. */
+ HOWTO (R_MMIX_PC_16, /* type */
+ 0, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_bitfield, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ "R_MMIX_PC_16", /* name */
+ false, /* partial_inplace */
+ 0xffff, /* src_mask */
+ 0xffff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ /* An 24 bit PC-relative relocation. */
+ HOWTO (R_MMIX_PC_24, /* type */
+ 0, /* rightshift */
+ 2, /* size (0 = byte, 1 = short, 2 = long) */
+ 24, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_bitfield, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ "R_MMIX_PC_24", /* name */
+ false, /* partial_inplace */
+ 0xffffff, /* src_mask */
+ 0xffffff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ /* A 32 bit absolute PC-relative relocation. */
+ HOWTO (R_MMIX_PC_32, /* type */
+ 0, /* rightshift */
+ 2, /* size (0 = byte, 1 = short, 2 = long) */
+ 32, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_bitfield, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ "R_MMIX_PC_32", /* name */
+ false, /* partial_inplace */
+ 0xffffffff, /* src_mask */
+ 0xffffffff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ /* 64 bit PC-relative relocation. */
+ HOWTO (R_MMIX_PC_64, /* type */
+ 0, /* rightshift */
+ 4, /* size (0 = byte, 1 = short, 2 = long) */
+ 64, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_bitfield, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ "R_MMIX_PC_64", /* name */
+ false, /* partial_inplace */
+ MINUS_ONE, /* src_mask */
+ MINUS_ONE, /* dst_mask */
+ true), /* pcrel_offset */
+
+ /* GNU extension to record C++ vtable hierarchy. */
+ HOWTO (R_MMIX_GNU_VTINHERIT, /* type */
+ 0, /* rightshift */
+ 0, /* size (0 = byte, 1 = short, 2 = long) */
+ 0, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ NULL, /* special_function */
+ "R_MMIX_GNU_VTINHERIT", /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0, /* dst_mask */
+ true), /* pcrel_offset */
+
+ /* GNU extension to record C++ vtable member usage. */
+ HOWTO (R_MMIX_GNU_VTENTRY, /* type */
+ 0, /* rightshift */
+ 0, /* size (0 = byte, 1 = short, 2 = long) */
+ 0, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ _bfd_elf_rel_vtable_reloc_fn, /* special_function */
+ "R_MMIX_GNU_VTENTRY", /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* The GETA relocation is supposed to get any address that could
+ possibly be reached by the GETA instruction. It can silently expand
+ to get a 64-bit operand, but will complain if any of the two least
+ significant bits are set. The howto members reflect a simple GETA. */
+ HOWTO (R_MMIX_GETA, /* type */
+ 2, /* rightshift */
+ 2, /* size (0 = byte, 1 = short, 2 = long) */
+ 19, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ mmix_elf_reloc, /* special_function */
+ "R_MMIX_GETA", /* name */
+ false, /* partial_inplace */
+ 0x0100ffff, /* src_mask */
+ 0x0100ffff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ HOWTO (R_MMIX_GETA_1, /* type */
+ 2, /* rightshift */
+ 2, /* size (0 = byte, 1 = short, 2 = long) */
+ 19, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ mmix_elf_reloc, /* special_function */
+ "R_MMIX_GETA_1", /* name */
+ false, /* partial_inplace */
+ 0x0100ffff, /* src_mask */
+ 0x0100ffff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ HOWTO (R_MMIX_GETA_2, /* type */
+ 2, /* rightshift */
+ 2, /* size (0 = byte, 1 = short, 2 = long) */
+ 19, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ mmix_elf_reloc, /* special_function */
+ "R_MMIX_GETA_2", /* name */
+ false, /* partial_inplace */
+ 0x0100ffff, /* src_mask */
+ 0x0100ffff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ HOWTO (R_MMIX_GETA_3, /* type */
+ 2, /* rightshift */
+ 2, /* size (0 = byte, 1 = short, 2 = long) */
+ 19, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ mmix_elf_reloc, /* special_function */
+ "R_MMIX_GETA_3", /* name */
+ false, /* partial_inplace */
+ 0x0100ffff, /* src_mask */
+ 0x0100ffff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ /* The conditional branches are supposed to reach any (code) address.
+ It can silently expand to a 64-bit operand, but will emit an error if
+ any of the two least significant bits are set. The howto members
+ reflect a simple branch. */
+ HOWTO (R_MMIX_CBRANCH, /* type */
+ 2, /* rightshift */
+ 2, /* size (0 = byte, 1 = short, 2 = long) */
+ 19, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ mmix_elf_reloc, /* special_function */
+ "R_MMIX_CBRANCH", /* name */
+ false, /* partial_inplace */
+ 0x0100ffff, /* src_mask */
+ 0x0100ffff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ HOWTO (R_MMIX_CBRANCH_J, /* type */
+ 2, /* rightshift */
+ 2, /* size (0 = byte, 1 = short, 2 = long) */
+ 19, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ mmix_elf_reloc, /* special_function */
+ "R_MMIX_CBRANCH_J", /* name */
+ false, /* partial_inplace */
+ 0x0100ffff, /* src_mask */
+ 0x0100ffff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ HOWTO (R_MMIX_CBRANCH_1, /* type */
+ 2, /* rightshift */
+ 2, /* size (0 = byte, 1 = short, 2 = long) */
+ 19, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ mmix_elf_reloc, /* special_function */
+ "R_MMIX_CBRANCH_1", /* name */
+ false, /* partial_inplace */
+ 0x0100ffff, /* src_mask */
+ 0x0100ffff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ HOWTO (R_MMIX_CBRANCH_2, /* type */
+ 2, /* rightshift */
+ 2, /* size (0 = byte, 1 = short, 2 = long) */
+ 19, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ mmix_elf_reloc, /* special_function */
+ "R_MMIX_CBRANCH_2", /* name */
+ false, /* partial_inplace */
+ 0x0100ffff, /* src_mask */
+ 0x0100ffff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ HOWTO (R_MMIX_CBRANCH_3, /* type */
+ 2, /* rightshift */
+ 2, /* size (0 = byte, 1 = short, 2 = long) */
+ 19, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ mmix_elf_reloc, /* special_function */
+ "R_MMIX_CBRANCH_3", /* name */
+ false, /* partial_inplace */
+ 0x0100ffff, /* src_mask */
+ 0x0100ffff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ /* The PUSHJ instruction can reach any (code) address, as long as it's
+ the beginning of a function (no usable restriction). It can silently
+ expand to a 64-bit operand, but will emit an error if any of the two
+ least significant bits are set. The howto members reflect a simple
+ PUSHJ. */
+ HOWTO (R_MMIX_PUSHJ, /* type */
+ 2, /* rightshift */
+ 2, /* size (0 = byte, 1 = short, 2 = long) */
+ 19, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ mmix_elf_reloc, /* special_function */
+ "R_MMIX_PUSHJ", /* name */
+ false, /* partial_inplace */
+ 0x0100ffff, /* src_mask */
+ 0x0100ffff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ HOWTO (R_MMIX_PUSHJ_1, /* type */
+ 2, /* rightshift */
+ 2, /* size (0 = byte, 1 = short, 2 = long) */
+ 19, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ mmix_elf_reloc, /* special_function */
+ "R_MMIX_PUSHJ_1", /* name */
+ false, /* partial_inplace */
+ 0x0100ffff, /* src_mask */
+ 0x0100ffff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ HOWTO (R_MMIX_PUSHJ_2, /* type */
+ 2, /* rightshift */
+ 2, /* size (0 = byte, 1 = short, 2 = long) */
+ 19, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ mmix_elf_reloc, /* special_function */
+ "R_MMIX_PUSHJ_2", /* name */
+ false, /* partial_inplace */
+ 0x0100ffff, /* src_mask */
+ 0x0100ffff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ HOWTO (R_MMIX_PUSHJ_3, /* type */
+ 2, /* rightshift */
+ 2, /* size (0 = byte, 1 = short, 2 = long) */
+ 19, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ mmix_elf_reloc, /* special_function */
+ "R_MMIX_PUSHJ_3", /* name */
+ false, /* partial_inplace */
+ 0x0100ffff, /* src_mask */
+ 0x0100ffff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ /* A JMP is supposed to reach any (code) address. By itself, it can
+ reach +-64M; the expansion can reach all 64 bits. Note that the 64M
+ limit is soon reached if you link the program in wildly different
+ memory segments. The howto members reflect a trivial JMP. */
+ HOWTO (R_MMIX_JMP, /* type */
+ 2, /* rightshift */
+ 2, /* size (0 = byte, 1 = short, 2 = long) */
+ 27, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ mmix_elf_reloc, /* special_function */
+ "R_MMIX_JMP", /* name */
+ false, /* partial_inplace */
+ 0x1ffffff, /* src_mask */
+ 0x1ffffff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ HOWTO (R_MMIX_JMP_1, /* type */
+ 2, /* rightshift */
+ 2, /* size (0 = byte, 1 = short, 2 = long) */
+ 27, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ mmix_elf_reloc, /* special_function */
+ "R_MMIX_JMP_1", /* name */
+ false, /* partial_inplace */
+ 0x1ffffff, /* src_mask */
+ 0x1ffffff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ HOWTO (R_MMIX_JMP_2, /* type */
+ 2, /* rightshift */
+ 2, /* size (0 = byte, 1 = short, 2 = long) */
+ 27, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ mmix_elf_reloc, /* special_function */
+ "R_MMIX_JMP_2", /* name */
+ false, /* partial_inplace */
+ 0x1ffffff, /* src_mask */
+ 0x1ffffff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ HOWTO (R_MMIX_JMP_3, /* type */
+ 2, /* rightshift */
+ 2, /* size (0 = byte, 1 = short, 2 = long) */
+ 27, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ mmix_elf_reloc, /* special_function */
+ "R_MMIX_JMP_3", /* name */
+ false, /* partial_inplace */
+ 0x1ffffff, /* src_mask */
+ 0x1ffffff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ /* When we don't emit link-time-relaxable code from the assembler, or
+ when relaxation has done all it can do, these relocs are used. For
+ GETA/PUSHJ/branches. */
+ HOWTO (R_MMIX_ADDR19, /* type */
+ 2, /* rightshift */
+ 2, /* size (0 = byte, 1 = short, 2 = long) */
+ 19, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ mmix_elf_reloc, /* special_function */
+ "R_MMIX_ADDR19", /* name */
+ false, /* partial_inplace */
+ 0x0100ffff, /* src_mask */
+ 0x0100ffff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ /* For JMP. */
+ HOWTO (R_MMIX_ADDR27, /* type */
+ 2, /* rightshift */
+ 2, /* size (0 = byte, 1 = short, 2 = long) */
+ 27, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ mmix_elf_reloc, /* special_function */
+ "R_MMIX_ADDR27", /* name */
+ false, /* partial_inplace */
+ 0x1ffffff, /* src_mask */
+ 0x1ffffff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ /* A general register or the value 0..255. If a value, then the
+ instruction (offset -3) needs adjusting. */
+ HOWTO (R_MMIX_REG_OR_BYTE, /* type */
+ 0, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 8, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_bitfield, /* complain_on_overflow */
+ mmix_elf_reloc, /* special_function */
+ "R_MMIX_REG_OR_BYTE", /* name */
+ false, /* partial_inplace */
+ 0xff, /* src_mask */
+ 0xff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* A general register. */
+ HOWTO (R_MMIX_REG, /* type */
+ 0, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 8, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_bitfield, /* complain_on_overflow */
+ mmix_elf_reloc, /* special_function */
+ "R_MMIX_REG", /* name */
+ false, /* partial_inplace */
+ 0xff, /* src_mask */
+ 0xff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* A register plus an index, corresponding to the relocation expression.
+ The sizes must correspond to the valid range of the expression, while
+ the bitmasks correspond to what we store in the image. */
+ HOWTO (R_MMIX_BASE_PLUS_OFFSET, /* type */
+ 0, /* rightshift */
+ 4, /* size (0 = byte, 1 = short, 2 = long) */
+ 64, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_bitfield, /* complain_on_overflow */
+ mmix_elf_reloc, /* special_function */
+ "R_MMIX_BASE_PLUS_OFFSET", /* name */
+ false, /* partial_inplace */
+ 0xffff, /* src_mask */
+ 0xffff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* A "magic" relocation for a LOCAL expression, asserting that the
+ expression is less than the number of global registers. No actual
+ modification of the contents is done. Implementing this as a
+ relocation was less intrusive than e.g. putting such expressions in a
+ section to discard *after* relocation. */
+ HOWTO (R_MMIX_LOCAL, /* type */
+ 0, /* rightshift */
+ 0, /* size (0 = byte, 1 = short, 2 = long) */
+ 0, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ mmix_elf_reloc, /* special_function */
+ "R_MMIX_LOCAL", /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0, /* dst_mask */
+ false), /* pcrel_offset */
+ };
+
+
+/* Map BFD reloc types to MMIX ELF reloc types. */
+
+struct mmix_reloc_map
+ {
+ bfd_reloc_code_real_type bfd_reloc_val;
+ enum elf_mmix_reloc_type elf_reloc_val;
+ };
+
+
+static const struct mmix_reloc_map mmix_reloc_map[] =
+ {
+ {BFD_RELOC_NONE, R_MMIX_NONE},
+ {BFD_RELOC_8, R_MMIX_8},
+ {BFD_RELOC_16, R_MMIX_16},
+ {BFD_RELOC_24, R_MMIX_24},
+ {BFD_RELOC_32, R_MMIX_32},
+ {BFD_RELOC_64, R_MMIX_64},
+ {BFD_RELOC_8_PCREL, R_MMIX_PC_8},
+ {BFD_RELOC_16_PCREL, R_MMIX_PC_16},
+ {BFD_RELOC_24_PCREL, R_MMIX_PC_24},
+ {BFD_RELOC_32_PCREL, R_MMIX_PC_32},
+ {BFD_RELOC_64_PCREL, R_MMIX_PC_64},
+ {BFD_RELOC_VTABLE_INHERIT, R_MMIX_GNU_VTINHERIT},
+ {BFD_RELOC_VTABLE_ENTRY, R_MMIX_GNU_VTENTRY},
+ {BFD_RELOC_MMIX_GETA, R_MMIX_GETA},
+ {BFD_RELOC_MMIX_CBRANCH, R_MMIX_CBRANCH},
+ {BFD_RELOC_MMIX_PUSHJ, R_MMIX_PUSHJ},
+ {BFD_RELOC_MMIX_JMP, R_MMIX_JMP},
+ {BFD_RELOC_MMIX_ADDR19, R_MMIX_ADDR19},
+ {BFD_RELOC_MMIX_ADDR27, R_MMIX_ADDR27},
+ {BFD_RELOC_MMIX_REG_OR_BYTE, R_MMIX_REG_OR_BYTE},
+ {BFD_RELOC_MMIX_REG, R_MMIX_REG},
+ {BFD_RELOC_MMIX_BASE_PLUS_OFFSET, R_MMIX_BASE_PLUS_OFFSET},
+ {BFD_RELOC_MMIX_LOCAL, R_MMIX_LOCAL}
+ };
+
+static reloc_howto_type *
+bfd_elf64_bfd_reloc_type_lookup (abfd, code)
+ bfd *abfd ATTRIBUTE_UNUSED;
+ bfd_reloc_code_real_type code;
+{
+ unsigned int i;
+
+ for (i = 0;
+ i < sizeof (mmix_reloc_map) / sizeof (mmix_reloc_map[0]);
+ i++)
+ {
+ if (mmix_reloc_map[i].bfd_reloc_val == code)
+ return &elf_mmix_howto_table[mmix_reloc_map[i].elf_reloc_val];
+ }
+
+ return NULL;
+}
+
+
+/* This function performs the actual bitfiddling and sanity check for a
+ final relocation. Each relocation gets its *worst*-case expansion
+ in size when it arrives here; any reduction in size should have been
+ caught in linker relaxation earlier. When we get here, the relocation
+ looks like the smallest instruction with SWYM:s (nop:s) appended to the
+ max size. We fill in those nop:s.
+
+ R_MMIX_GETA: (FIXME: Relaxation should break this up in 1, 2, 3 tetra)
+ GETA $N,foo
+ ->
+ SETL $N,foo & 0xffff
+ INCML $N,(foo >> 16) & 0xffff
+ INCMH $N,(foo >> 32) & 0xffff
+ INCH $N,(foo >> 48) & 0xffff
+
+ R_MMIX_CBRANCH: (FIXME: Relaxation should break this up, but
+ condbranches needing relaxation might be rare enough to not be
+ worthwhile.)
+ [P]Bcc $N,foo
+ ->
+ [~P]B~cc $N,.+20
+ SETL $255,foo & ...
+ INCML ...
+ INCMH ...
+ INCH ...
+ GO $255,$255,0
+
+ R_MMIX_PUSHJ: (FIXME: Relaxation...)
+ PUSHJ $N,foo
+ ->
+ SETL $255,foo & ...
+ INCML ...
+ INCMH ...
+ INCH ...
+ PUSHGO $N,$255,0
+
+ R_MMIX_JMP: (FIXME: Relaxation...)
+ JMP foo
+ ->
+ SETL $255,foo & ...
+ INCML ...
+ INCMH ...
+ INCH ...
+ GO $255,$255,0
+
+ R_MMIX_ADDR19 and R_MMIX_ADDR27 are just filled in. */
+
+static bfd_reloc_status_type
+mmix_elf_perform_relocation (isec, howto, datap, addr, value)
+ asection *isec;
+ reloc_howto_type *howto;
+ PTR datap;
+ bfd_vma addr ATTRIBUTE_UNUSED;
+ bfd_vma value;
+{
+ bfd *abfd = isec->owner;
+ bfd_reloc_status_type flag = bfd_reloc_ok;
+ bfd_reloc_status_type r;
+ int offs = 0;
+ int reg = 255;
+
+ /* The worst case bits are all similar SETL/INCML/INCMH/INCH sequences.
+ We handle the differences here and the common sequence later. */
+ switch (howto->type)
+ {
+ case R_MMIX_GETA:
+ offs = 0;
+ reg = bfd_get_8 (abfd, (bfd_byte *) datap + 1);
+
+ /* We change to an absolute value. */
+ value += addr;
+ break;
+
+ case R_MMIX_CBRANCH:
+ {
+ int in1 = bfd_get_16 (abfd, (bfd_byte *) datap) << 16;
+
+ /* Invert the condition and prediction bit, and set the offset
+ to five instructions ahead.
+
+ We *can* do better if we want to. If the branch is found to be
+ within limits, we could leave the branch as is; there'll just
+ be a bunch of NOP:s after it. But we shouldn't see this
+ sequence often enough that it's worth doing it. */
+
+ bfd_put_32 (abfd,
+ (((in1 ^ ((PRED_INV_BIT | COND_INV_BIT) << 24)) & ~0xffff)
+ | (24/4)),
+ (bfd_byte *) datap);
+
+ /* Put a "GO $255,$255,0" after the common sequence. */
+ bfd_put_32 (abfd,
+ ((GO_INSN_BYTE | IMM_OFFSET_BIT) << 24) | 0xffff00,
+ (bfd_byte *) datap + 20);
+
+ /* Common sequence starts at offset 4. */
+ offs = 4;
+
+ /* We change to an absolute value. */
+ value += addr;
+ }
+ break;
+
+ case R_MMIX_PUSHJ:
+ {
+ int inreg = bfd_get_8 (abfd, (bfd_byte *) datap + 1);
+
+ /* Put a "PUSHGO $N,$255,0" after the common sequence. */
+ bfd_put_32 (abfd,
+ ((PUSHGO_INSN_BYTE | IMM_OFFSET_BIT) << 24)
+ | (inreg << 16)
+ | 0xff00,
+ (bfd_byte *) datap + 16);
+
+ /* We change to an absolute value. */
+ value += addr;
+ }
+ break;
+
+ case R_MMIX_JMP:
+ /* This one is a little special. If we get here on a non-relaxing
+ link, and the destination is actually in range, we don't need to
+ execute the nops.
+ If so, we fall through to the bit-fiddling relocs.
+
+ FIXME: bfd_check_overflow seems broken; the relocation is
+ rightshifted before testing, so supply a zero rightshift. */
+
+ if (! ((value & 3) == 0
+ && (r = bfd_check_overflow (complain_overflow_signed,
+ howto->bitsize,
+ 0,
+ bfd_arch_bits_per_address (abfd),
+ value)) == bfd_reloc_ok))
+ {
+ /* If the relocation doesn't fit in a JMP, we let the NOP:s be
+ modified below, and put a "GO $255,$255,0" after the
+ address-loading sequence. */
+ bfd_put_32 (abfd,
+ ((GO_INSN_BYTE | IMM_OFFSET_BIT) << 24)
+ | 0xffff00,
+ (bfd_byte *) datap + 16);
+
+ /* We change to an absolute value. */
+ value += addr;
+ break;
+ }
+ /* FALLTHROUGH. */
+ case R_MMIX_ADDR19:
+ case R_MMIX_ADDR27:
+ /* These must be in range, or else we emit an error. */
+ if ((value & 3) == 0
+ /* Note rightshift 0; see above. */
+ && (r = bfd_check_overflow (complain_overflow_signed,
+ howto->bitsize,
+ 0,
+ bfd_arch_bits_per_address (abfd),
+ value)) == bfd_reloc_ok)
+ {
+ bfd_vma in1
+ = bfd_get_32 (abfd, (bfd_byte *) datap);
+ bfd_vma highbit;
+
+ if ((bfd_signed_vma) value < 0)
+ {
+ highbit = (1 << 24);
+ value += (1 << (howto->bitsize - 1));
+ }
+ else
+ highbit = 0;
+
+ value >>= 2;
+
+ bfd_put_32 (abfd,
+ (in1 & ~howto->src_mask)
+ | highbit
+ | (value & howto->dst_mask),
+ (bfd_byte *) datap);
+
+ return bfd_reloc_ok;
+ }
+ else
+ return bfd_reloc_overflow;
+
+ case R_MMIX_REG_OR_BYTE:
+ case R_MMIX_REG:
+ if (value > 255)
+ return bfd_reloc_overflow;
+ bfd_put_8 (abfd, value, datap);
+ return bfd_reloc_ok;
+
+ default:
+ BAD_CASE (howto->type);
+ }
+
+ /* This code adds the common SETL/INCML/INCMH/INCH worst-case
+ sequence. */
+
+ /* Lowest two bits must be 0. We return bfd_reloc_overflow for
+ everything that looks strange. */
+ if (value & 3)
+ flag = bfd_reloc_overflow;
+
+ bfd_put_32 (abfd,
+ (SETL_INSN_BYTE << 24) | (value & 0xffff) | (reg << 16),
+ (bfd_byte *) datap + offs);
+ bfd_put_32 (abfd,
+ (INCML_INSN_BYTE << 24) | ((value >> 16) & 0xffff) | (reg << 16),
+ (bfd_byte *) datap + offs + 4);
+ bfd_put_32 (abfd,
+ (INCMH_INSN_BYTE << 24) | ((value >> 32) & 0xffff) | (reg << 16),
+ (bfd_byte *) datap + offs + 8);
+ bfd_put_32 (abfd,
+ (INCH_INSN_BYTE << 24) | ((value >> 48) & 0xffff) | (reg << 16),
+ (bfd_byte *) datap + offs + 12);
+
+ return flag;
+}
+
+/* Set the howto pointer for an MMIX ELF reloc (type RELA). */
+
+static void
+mmix_info_to_howto_rela (abfd, cache_ptr, dst)
+ bfd *abfd ATTRIBUTE_UNUSED;
+ arelent *cache_ptr;
+ Elf64_Internal_Rela *dst;
+{
+ unsigned int r_type;
+
+ r_type = ELF64_R_TYPE (dst->r_info);
+ BFD_ASSERT (r_type < (unsigned int) R_MMIX_max);
+ cache_ptr->howto = &elf_mmix_howto_table[r_type];
+}
+
+/* Any MMIX-specific relocation gets here at assembly time or when linking
+ to other formats (such as mmo); this is the relocation function from
+ the reloc_table. We don't get here for final pure ELF linking. */
+
+static bfd_reloc_status_type
+mmix_elf_reloc (abfd, reloc_entry, symbol, data, input_section,
+ output_bfd, error_message)
+ bfd *abfd;
+ arelent *reloc_entry;
+ asymbol *symbol;
+ PTR data;
+ asection *input_section;
+ bfd *output_bfd;
+ char **error_message ATTRIBUTE_UNUSED;
+{
+ bfd_vma relocation;
+ bfd_reloc_status_type r;
+ asection *reloc_target_output_section;
+ bfd_reloc_status_type flag = bfd_reloc_ok;
+ bfd_vma output_base = 0;
+ bfd_vma addr;
+
+ r = bfd_elf_generic_reloc (abfd, reloc_entry, symbol, data,
+ input_section, output_bfd, error_message);
+
+ /* If that was all that was needed (i.e. this isn't a final link, only
+ some segment adjustments), we're done. */
+ if (r != bfd_reloc_continue)
+ return r;
+
+ if (bfd_is_und_section (symbol->section)
+ && (symbol->flags & BSF_WEAK) == 0
+ && output_bfd == (bfd *) NULL)
+ return bfd_reloc_undefined;
+
+ /* Is the address of the relocation really within the section? */
+ if (reloc_entry->address > input_section->_cooked_size)
+ return bfd_reloc_outofrange;
+
+ /* Work out which section the relocation is targetted at and the
+ initial relocation command value. */
+
+ /* Get symbol value. (Common symbols are special.) */
+ if (bfd_is_com_section (symbol->section))
+ relocation = 0;
+ else
+ relocation = symbol->value;
+
+ reloc_target_output_section = bfd_get_output_section (symbol);
+
+ /* Here the variable relocation holds the final address of the symbol we
+ are relocating against, plus any addend. */
+ if (output_bfd)
+ output_base = 0;
+ else
+ output_base = reloc_target_output_section->vma;
+
+ relocation += output_base + symbol->section->output_offset;
+
+ /* Get position of relocation. */
+ addr = (reloc_entry->address + input_section->output_section->vma
+ + input_section->output_offset);
+ if (output_bfd != (bfd *) NULL)
+ {
+ /* Add in supplied addend. */
+ relocation += reloc_entry->addend;
+
+ /* This is a partial relocation, and we want to apply the
+ relocation to the reloc entry rather than the raw data.
+ Modify the reloc inplace to reflect what we now know. */
+ reloc_entry->addend = relocation;
+ reloc_entry->address += input_section->output_offset;
+ return flag;
+ }
+
+ return mmix_final_link_relocate (reloc_entry->howto, input_section,
+ data, reloc_entry->address,
+ reloc_entry->addend, relocation,
+ bfd_asymbol_name (symbol),
+ reloc_target_output_section);
+}
+
+/* Relocate an MMIX ELF section. Modified from elf32-fr30.c; look to it
+ for guidance if you're thinking of copying this. */
+
+static boolean
+mmix_elf_relocate_section (output_bfd, info, input_bfd, input_section,
+ contents, relocs, local_syms, local_sections)
+ bfd *output_bfd ATTRIBUTE_UNUSED;
+ struct bfd_link_info *info;
+ bfd *input_bfd;
+ asection *input_section;
+ bfd_byte *contents;
+ Elf_Internal_Rela *relocs;
+ Elf_Internal_Sym *local_syms;
+ asection **local_sections;
+{
+ Elf_Internal_Shdr *symtab_hdr;
+ struct elf_link_hash_entry **sym_hashes;
+ Elf_Internal_Rela *rel;
+ Elf_Internal_Rela *relend;
+
+ symtab_hdr = &elf_tdata (input_bfd)->symtab_hdr;
+ sym_hashes = elf_sym_hashes (input_bfd);
+ relend = relocs + input_section->reloc_count;
+
+ for (rel = relocs; rel < relend; rel ++)
+ {
+ reloc_howto_type *howto;
+ unsigned long r_symndx;
+ Elf_Internal_Sym *sym;
+ asection *sec;
+ struct elf_link_hash_entry *h;
+ bfd_vma relocation;
+ bfd_reloc_status_type r;
+ const char *name = NULL;
+ int r_type;
+ boolean undefined_signalled = false;
+
+ r_type = ELF64_R_TYPE (rel->r_info);
+
+ if (r_type == R_MMIX_GNU_VTINHERIT
+ || r_type == R_MMIX_GNU_VTENTRY)
+ continue;
+
+ r_symndx = ELF64_R_SYM (rel->r_info);
+
+ if (info->relocateable)
+ {
+ /* This is a relocateable link. We don't have to change
+ anything, unless the reloc is against a section symbol,
+ in which case we have to adjust according to where the
+ section symbol winds up in the output section. */
+ if (r_symndx < symtab_hdr->sh_info)
+ {
+ sym = local_syms + r_symndx;
+
+ if (ELF_ST_TYPE (sym->st_info) == STT_SECTION)
+ {
+ sec = local_sections [r_symndx];
+ rel->r_addend += sec->output_offset + sym->st_value;
+ }
+ }
+
+ continue;
+ }
+
+ /* This is a final link. */
+ howto = elf_mmix_howto_table + ELF64_R_TYPE (rel->r_info);
+ h = NULL;
+ sym = NULL;
+ sec = NULL;
+
+ if (r_symndx < symtab_hdr->sh_info)
+ {
+ sym = local_syms + r_symndx;
+ sec = local_sections [r_symndx];
+ relocation = (sec->output_section->vma
+ + sec->output_offset
+ + sym->st_value);
+
+ name = bfd_elf_string_from_elf_section
+ (input_bfd, symtab_hdr->sh_link, sym->st_name);
+ name = (name == NULL) ? bfd_section_name (input_bfd, sec) : name;
+ }
+ else
+ {
+ h = sym_hashes [r_symndx - symtab_hdr->sh_info];
+
+ while (h->root.type == bfd_link_hash_indirect
+ || h->root.type == bfd_link_hash_warning)
+ h = (struct elf_link_hash_entry *) h->root.u.i.link;
+
+ name = h->root.root.string;
+
+ if (h->root.type == bfd_link_hash_defined
+ || h->root.type == bfd_link_hash_defweak)
+ {
+ sec = h->root.u.def.section;
+ relocation = (h->root.u.def.value
+ + sec->output_section->vma
+ + sec->output_offset);
+ }
+ else if (h->root.type == bfd_link_hash_undefweak)
+ relocation = 0;
+ else if (info->shared
+ && ELF_ST_VISIBILITY (h->other) == STV_DEFAULT)
+ relocation = 0;
+ else
+ {
+ /* The test on undefined_signalled is redundant at the
+ moment, but kept for symmetry. */
+ if (! undefined_signalled
+ && ! ((*info->callbacks->undefined_symbol)
+ (info, h->root.root.string, input_bfd,
+ input_section, rel->r_offset, true)))
+ return false;
+ undefined_signalled = true;
+ relocation = 0;
+ }
+ }
+
+ r = mmix_final_link_relocate (howto, input_section,
+ contents, rel->r_offset,
+ rel->r_addend, relocation, name, sec);
+
+ if (r != bfd_reloc_ok)
+ {
+ boolean check_ok = true;
+ const char * msg = (const char *) NULL;
+
+ switch (r)
+ {
+ case bfd_reloc_overflow:
+ check_ok = info->callbacks->reloc_overflow
+ (info, name, howto->name, (bfd_vma) 0,
+ input_bfd, input_section, rel->r_offset);
+ break;
+
+ case bfd_reloc_undefined:
+ /* We may have sent this message above. */
+ if (! undefined_signalled)
+ check_ok = info->callbacks->undefined_symbol
+ (info, name, input_bfd, input_section, rel->r_offset,
+ true);
+ undefined_signalled = true;
+ break;
+
+ case bfd_reloc_outofrange:
+ msg = _("internal error: out of range error");
+ break;
+
+ case bfd_reloc_notsupported:
+ msg = _("internal error: unsupported relocation error");
+ break;
+
+ case bfd_reloc_dangerous:
+ msg = _("internal error: dangerous relocation");
+ break;
+
+ default:
+ msg = _("internal error: unknown error");
+ break;
+ }
+
+ if (msg)
+ check_ok = info->callbacks->warning
+ (info, msg, name, input_bfd, input_section, rel->r_offset);
+
+ if (! check_ok)
+ return false;
+ }
+ }
+
+ return true;
+}
+
+/* Perform a single relocation. By default we use the standard BFD
+ routines. A few relocs we have to do ourselves. */
+
+static bfd_reloc_status_type
+mmix_final_link_relocate (howto, input_section, contents,
+ r_offset, r_addend, relocation, symname, symsec)
+ reloc_howto_type *howto;
+ asection *input_section;
+ bfd_byte *contents;
+ bfd_vma r_offset;
+ bfd_signed_vma r_addend;
+ bfd_vma relocation;
+ const char *symname;
+ asection *symsec;
+{
+ bfd_reloc_status_type r = bfd_reloc_ok;
+ bfd_vma addr
+ = (input_section->output_section->vma
+ + input_section->output_offset
+ + r_offset);
+ bfd_signed_vma srel
+ = (bfd_signed_vma) relocation + r_addend;
+
+ switch (howto->type)
+ {
+ /* All these are PC-relative. */
+ case R_MMIX_PUSHJ:
+ case R_MMIX_CBRANCH:
+ case R_MMIX_ADDR19:
+ case R_MMIX_GETA:
+ case R_MMIX_ADDR27:
+ case R_MMIX_JMP:
+ contents += r_offset;
+
+ srel -= (input_section->output_section->vma
+ + input_section->output_offset
+ + r_offset);
+
+ r = mmix_elf_perform_relocation (input_section, howto, contents,
+ addr, srel);
+ break;
+
+ case R_MMIX_REG_OR_BYTE:
+ case R_MMIX_REG:
+ /* For now, we handle these alike. They must refer to an register
+ symbol, which is either relative to the register section and in
+ the range 0..255, or is in the register contents section with vma
+ regno * 8. */
+
+ /* FIXME: A better way to check for reg contents section?
+ FIXME: Postpone section->scaling to mmix_elf_perform_relocation? */
+ if (symsec == NULL)
+ return bfd_reloc_undefined;
+
+ if (strcmp (bfd_get_section_name (symsec->owner, symsec),
+ MMIX_REG_CONTENTS_SECTION_NAME) == 0)
+ {
+ if ((srel & 7) != 0 || srel < 32*8 || srel > 255*8)
+ {
+ /* The bfd_reloc_outofrange return value, though intuitively
+ a better value, will not get us an error. */
+ return bfd_reloc_overflow;
+ }
+ srel /= 8;
+ }
+ else if (strcmp (bfd_get_section_name (symsec->owner, symsec),
+ MMIX_REG_SECTION_NAME) == 0)
+ {
+ if (srel < 0 || srel > 255)
+ /* The bfd_reloc_outofrange return value, though intuitively a
+ better value, will not get us an error. */
+ return bfd_reloc_overflow;
+ }
+ else
+ {
+ (*_bfd_error_handler)
+ (_("%s: register relocation against non-register symbol: %s in %s"),
+ bfd_get_filename (input_section->owner),
+ symname == NULL || *symname == 0 ? _("(unknown)") : symname,
+ bfd_get_section_name (symsec->owner, symsec));
+
+ /* The bfd_reloc_outofrange return value, though intuitively a
+ better value, will not get us an error. */
+ return bfd_reloc_overflow;
+ }
+ contents += r_offset;
+ r = mmix_elf_perform_relocation (input_section, howto, contents,
+ addr, srel);
+ break;
+
+ case R_MMIX_LOCAL:
+ /* This isn't a real relocation, it's just an assertion that the
+ final relocation value corresponds to a local register. We
+ ignore the actual relocation; nothing is changed. */
+ {
+ asection *regsec
+ = bfd_get_section_by_name (input_section->output_section->owner,
+ MMIX_REG_CONTENTS_SECTION_NAME);
+ bfd_vma first_global;
+
+ /* Check that this is an absolute value, or a reference to the
+ register contents section or the register (symbol) section.
+ Absolute numbers can get here as undefined section. Undefined
+ symbols are signalled elsewhere, so there's no conflict in us
+ accidentally handling it. */
+ if (!bfd_is_abs_section (symsec)
+ && !bfd_is_und_section (symsec)
+ && strcmp (bfd_get_section_name (symsec->owner, symsec),
+ MMIX_REG_CONTENTS_SECTION_NAME) != 0
+ && strcmp (bfd_get_section_name (symsec->owner, symsec),
+ MMIX_REG_SECTION_NAME) != 0)
+ {
+ (*_bfd_error_handler)
+ (_("%s: directive LOCAL valid only with a register or absolute value"),
+ bfd_get_filename (input_section->owner));
+
+ return bfd_reloc_overflow;
+ }
+
+ /* If we don't have a register contents section, then $255 is the
+ first global register. */
+ if (regsec == NULL)
+ first_global = 255;
+ else
+ {
+ first_global = bfd_get_section_vma (abfd, regsec) / 8;
+ if (strcmp (bfd_get_section_name (symsec->owner, symsec),
+ MMIX_REG_CONTENTS_SECTION_NAME) == 0)
+ {
+ if ((srel & 7) != 0 || srel < 32*8 || srel > 255*8)
+ /* The bfd_reloc_outofrange return value, though
+ intuitively a better value, will not get us an error. */
+ return bfd_reloc_overflow;
+ srel /= 8;
+ }
+ }
+
+ if ((bfd_vma) srel >= first_global)
+ {
+ /* FIXME: Better error message. */
+ (*_bfd_error_handler)
+ (_("%s: LOCAL directive: Register $%ld is not a local register. First global register is $%ld."),
+ bfd_get_filename (input_section->owner), (long) srel, (long) first_global);
+
+ return bfd_reloc_overflow;
+ }
+ }
+ r = bfd_reloc_ok;
+ break;
+
+ default:
+ r = _bfd_final_link_relocate (howto, input_section->owner, input_section,
+ contents, r_offset,
+ relocation, r_addend);
+ }
+
+ return r;
+}
+
+/* Return the section that should be marked against GC for a given
+ relocation. */
+
+static asection *
+mmix_elf_gc_mark_hook (abfd, info, rel, h, sym)
+ bfd *abfd;
+ struct bfd_link_info *info ATTRIBUTE_UNUSED;
+ Elf_Internal_Rela *rel;
+ struct elf_link_hash_entry *h;
+ Elf_Internal_Sym *sym;
+{
+ if (h != NULL)
+ {
+ switch (ELF64_R_TYPE (rel->r_info))
+ {
+ case R_MMIX_GNU_VTINHERIT:
+ case R_MMIX_GNU_VTENTRY:
+ break;
+
+ default:
+ switch (h->root.type)
+ {
+ case bfd_link_hash_defined:
+ case bfd_link_hash_defweak:
+ return h->root.u.def.section;
+
+ case bfd_link_hash_common:
+ return h->root.u.c.p->section;
+
+ default:
+ break;
+ }
+ }
+ }
+ else
+ {
+ if (!(elf_bad_symtab (abfd)
+ && ELF_ST_BIND (sym->st_info) != STB_LOCAL)
+ && ! ((sym->st_shndx <= 0 || sym->st_shndx >= SHN_LORESERVE)
+ && sym->st_shndx != SHN_COMMON))
+ {
+ return bfd_section_from_elf_index (abfd, sym->st_shndx);
+ }
+ }
+
+ return NULL;
+}
+
+/* Sort register relocs to come before expanding relocs. */
+
+static int
+mmix_elf_sort_relocs (p1, p2)
+ const PTR p1;
+ const PTR p2;
+{
+ const Elf_Internal_Rela *r1 = (const Elf_Internal_Rela *) p1;
+ const Elf_Internal_Rela *r2 = (const Elf_Internal_Rela *) p2;
+ int r1_is_reg, r2_is_reg;
+
+ /* Sort primarily on r_offset & ~3, so relocs are done to consecutive
+ insns. */
+ if ((r1->r_offset & ~(bfd_vma) 3) > (r2->r_offset & ~(bfd_vma) 3))
+ return 1;
+ else if ((r1->r_offset & ~(bfd_vma) 3) < (r2->r_offset & ~(bfd_vma) 3))
+ return -1;
+
+ r1_is_reg
+ = (ELF64_R_TYPE (r1->r_info) == R_MMIX_REG_OR_BYTE
+ || ELF64_R_TYPE (r1->r_info) == R_MMIX_REG);
+ r2_is_reg
+ = (ELF64_R_TYPE (r2->r_info) == R_MMIX_REG_OR_BYTE
+ || ELF64_R_TYPE (r2->r_info) == R_MMIX_REG);
+ if (r1_is_reg != r2_is_reg)
+ return r2_is_reg - r1_is_reg;
+
+ /* Neither or both are register relocs. Then sort on full offset. */
+ if (r1->r_offset > r2->r_offset)
+ return 1;
+ else if (r1->r_offset < r2->r_offset)
+ return -1;
+ return 0;
+}
+
+/* Look through the relocs for a section during the first phase. */
+
+static boolean
+mmix_elf_check_relocs (abfd, info, sec, relocs)
+ bfd *abfd;
+ struct bfd_link_info *info;
+ asection *sec;
+ const Elf_Internal_Rela *relocs;
+{
+ Elf_Internal_Shdr *symtab_hdr;
+ struct elf_link_hash_entry **sym_hashes, **sym_hashes_end;
+ const Elf_Internal_Rela *rel;
+ const Elf_Internal_Rela *rel_end;
+
+ if (info->relocateable)
+ return true;
+
+ symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
+ sym_hashes = elf_sym_hashes (abfd);
+ sym_hashes_end = sym_hashes + symtab_hdr->sh_size/sizeof(Elf64_External_Sym);
+ if (!elf_bad_symtab (abfd))
+ sym_hashes_end -= symtab_hdr->sh_info;
+
+ /* First we sort the relocs so that any register relocs come before
+ expansion-relocs to the same insn. FIXME: Not done for mmo. */
+ qsort ((PTR) relocs, sec->reloc_count, sizeof (Elf_Internal_Rela),
+ mmix_elf_sort_relocs);
+
+ rel_end = relocs + sec->reloc_count;
+ for (rel = relocs; rel < rel_end; rel++)
+ {
+ struct elf_link_hash_entry *h;
+ unsigned long r_symndx;
+
+ r_symndx = ELF64_R_SYM (rel->r_info);
+ if (r_symndx < symtab_hdr->sh_info)
+ h = NULL;
+ else
+ h = sym_hashes[r_symndx - symtab_hdr->sh_info];
+
+ switch (ELF64_R_TYPE (rel->r_info))
+ {
+ /* This relocation describes the C++ object vtable hierarchy.
+ Reconstruct it for later use during GC. */
+ case R_MMIX_GNU_VTINHERIT:
+ if (!_bfd_elf64_gc_record_vtinherit (abfd, sec, h, rel->r_offset))
+ return false;
+ break;
+
+ /* This relocation describes which C++ vtable entries are actually
+ used. Record for later use during GC. */
+ case R_MMIX_GNU_VTENTRY:
+ if (!_bfd_elf64_gc_record_vtentry (abfd, sec, h, rel->r_addend))
+ return false;
+ break;
+ }
+ }
+
+ return true;
+}
+
+/* Change symbols relative to the reg contents section to instead be to
+ the register section, and scale them down to correspond to the register
+ number. */
+
+static boolean
+mmix_elf_link_output_symbol_hook (abfd, info, name, sym, input_sec)
+ bfd *abfd ATTRIBUTE_UNUSED;
+ struct bfd_link_info *info ATTRIBUTE_UNUSED;
+ const char *name ATTRIBUTE_UNUSED;
+ Elf_Internal_Sym *sym;
+ asection *input_sec;
+{
+ if (input_sec != NULL
+ && input_sec->name != NULL
+ && ELF_ST_TYPE (sym->st_info) != STT_SECTION
+ && strcmp (input_sec->name, MMIX_REG_CONTENTS_SECTION_NAME) == 0)
+ {
+ sym->st_value /= 8;
+ sym->st_shndx = SHN_REGISTER;
+ }
+
+ return true;
+}
+
+/* We fake a register section that holds values that are register numbers.
+ Having a SHN_REGISTER and register section translates better to other
+ formats (e.g. mmo) than for example a STT_REGISTER attribute.
+ This section faking is based on a construct in elf32-mips.c. */
+static asection mmix_elf_reg_section;
+static asymbol mmix_elf_reg_section_symbol;
+static asymbol *mmix_elf_reg_section_symbol_ptr;
+
+/* Handle the special MIPS section numbers that a symbol may use.
+ This is used for both the 32-bit and the 64-bit ABI. */
+
+void
+mmix_elf_symbol_processing (abfd, asym)
+ bfd *abfd ATTRIBUTE_UNUSED;
+ asymbol *asym;
+{
+ elf_symbol_type *elfsym;
+
+ elfsym = (elf_symbol_type *) asym;
+ switch (elfsym->internal_elf_sym.st_shndx)
+ {
+ case SHN_REGISTER:
+ if (mmix_elf_reg_section.name == NULL)
+ {
+ /* Initialize the register section. */
+ mmix_elf_reg_section.name = MMIX_REG_SECTION_NAME;
+ mmix_elf_reg_section.flags = SEC_NO_FLAGS;
+ mmix_elf_reg_section.output_section = &mmix_elf_reg_section;
+ mmix_elf_reg_section.symbol = &mmix_elf_reg_section_symbol;
+ mmix_elf_reg_section.symbol_ptr_ptr = &mmix_elf_reg_section_symbol_ptr;
+ mmix_elf_reg_section_symbol.name = MMIX_REG_SECTION_NAME;
+ mmix_elf_reg_section_symbol.flags = BSF_SECTION_SYM;
+ mmix_elf_reg_section_symbol.section = &mmix_elf_reg_section;
+ mmix_elf_reg_section_symbol_ptr = &mmix_elf_reg_section_symbol;
+ }
+ asym->section = &mmix_elf_reg_section;
+ break;
+
+ default:
+ break;
+ }
+}
+
+/* Given a BFD section, try to locate the corresponding ELF section
+ index. */
+
+static boolean
+mmix_elf_section_from_bfd_section (abfd, hdr, sec, retval)
+ bfd * abfd ATTRIBUTE_UNUSED;
+ Elf64_Internal_Shdr * hdr ATTRIBUTE_UNUSED;
+ asection * sec;
+ int * retval;
+{
+ if (strcmp (bfd_get_section_name (abfd, sec), MMIX_REG_SECTION_NAME) == 0)
+ *retval = SHN_REGISTER;
+ else
+ return false;
+
+ return true;
+}
+
+/* Hook called by the linker routine which adds symbols from an object
+ file. We must handle the special SHN_REGISTER section number here.
+
+ We also check that we only have *one* each of the section-start
+ symbols, since otherwise having two with the same value would cause
+ them to be "merged", but with the contents serialized. */
+
+boolean
+mmix_elf_add_symbol_hook (abfd, info, sym, namep, flagsp, secp, valp)
+ bfd *abfd;
+ struct bfd_link_info *info ATTRIBUTE_UNUSED;
+ const Elf_Internal_Sym *sym;
+ const char **namep ATTRIBUTE_UNUSED;
+ flagword *flagsp ATTRIBUTE_UNUSED;
+ asection **secp;
+ bfd_vma *valp ATTRIBUTE_UNUSED;
+{
+ if (sym->st_shndx == SHN_REGISTER)
+ *secp = bfd_make_section_old_way (abfd, MMIX_REG_SECTION_NAME);
+ else if ((*namep)[0] == '_' && (*namep)[1] == '_' && (*namep)[2] == '.'
+ && strncmp (*namep, MMIX_LOC_SECTION_START_SYMBOL_PREFIX,
+ strlen (MMIX_LOC_SECTION_START_SYMBOL_PREFIX)) == 0)
+ {
+ /* See if we have another one. */
+ struct elf_link_hash_entry *h
+ = (struct elf_link_hash_entry *) bfd_link_hash_lookup (info->hash,
+ *namep,
+ false,
+ false, false);
+
+ if (h != NULL && h->root.type != bfd_link_hash_undefined)
+ {
+ /* How do we get the asymbol (or really: the filename) from h?
+ h->root.u.def.section->owner is NULL. */
+ ((*_bfd_error_handler)
+ (_("%s: Error: multiple definition of `%s'; start of %s is set in a earlier linked file\n"),
+ bfd_get_filename (abfd), *namep,
+ *namep + strlen (MMIX_LOC_SECTION_START_SYMBOL_PREFIX)));
+ bfd_set_error (bfd_error_bad_value);
+ return false;
+ }
+ }
+
+ return true;
+}
+
+/* We consider symbols matching "L.*:[0-9]+" to be local symbols. */
+
+boolean
+mmix_elf_is_local_label_name (abfd, name)
+ bfd *abfd;
+ const char *name;
+{
+ const char *colpos;
+ int digits;
+
+ /* Also include the default local-label definition. */
+ if (_bfd_elf_is_local_label_name (abfd, name))
+ return true;
+
+ if (*name != 'L')
+ return false;
+
+ /* If there's no ":", or more than one, it's not a local symbol. */
+ colpos = strchr (name, ':');
+ if (colpos == NULL || strchr (colpos + 1, ':') != NULL)
+ return false;
+
+ /* Check that there are remaining characters and that they are digits. */
+ if (colpos[1] == 0)
+ return false;
+
+ digits = strspn (colpos + 1, "0123456789");
+ return digits != 0 && colpos[1 + digits] == 0;
+}
+
+/* We get rid of the register section here. */
+
+boolean
+mmix_elf_final_link (abfd, info)
+ bfd *abfd;
+ struct bfd_link_info *info;
+{
+ /* We never output a register section, though we create one for
+ temporary measures. Check that nobody entered contents into it. */
+ asection *reg_section;
+ asection **secpp;
+
+ reg_section = bfd_get_section_by_name (abfd, MMIX_REG_SECTION_NAME);
+
+ if (reg_section != NULL)
+ {
+ /* FIXME: Pass error state gracefully. */
+ if (bfd_get_section_flags (abfd, reg_section) & SEC_HAS_CONTENTS)
+ _bfd_abort (__FILE__, __LINE__, _("Register section has contents\n"));
+
+ /* FIXME: This does not seem like the proper way to kill a section,
+ but it's the way it's done elsewhere, like elf64-alpha.c. */
+ /* Really remove the section. */
+ for (secpp = &abfd->sections;
+ *secpp != reg_section;
+ secpp = &(*secpp)->next)
+ ;
+ *secpp = (*secpp)->next;
+ --abfd->section_count;
+ }
+
+ if (! bfd_elf64_bfd_final_link (abfd, info))
+ return false;
+
+ return true;
+}
+
+#define ELF_ARCH bfd_arch_mmix
+#define ELF_MACHINE_CODE EM_MMIX
+
+/* According to mmix-doc page 36 (paragraph 45), this should be (1LL << 48LL).
+ However, that's too much for something somewhere in the linker part of
+ BFD; perhaps the start-address has to be a non-zero multiple of this
+ number, or larger than this number. The symptom is that the linker
+ complains: "warning: allocated section `.text' not in segment". We
+ settle for 64k; the page-size used in examples is 8k.
+ #define ELF_MAXPAGESIZE 0x10000
+
+ Unfortunately, this causes excessive padding in the supposedly small
+ for-education programs that are the expected usage (where people would
+ inspect output). We stick to 256 bytes just to have *some* default
+ alignment. */
+#define ELF_MAXPAGESIZE 0x100
+
+#define TARGET_BIG_SYM bfd_elf64_mmix_vec
+#define TARGET_BIG_NAME "elf64-mmix"
+
+#define elf_info_to_howto_rel NULL
+#define elf_info_to_howto mmix_info_to_howto_rela
+#define elf_backend_relocate_section mmix_elf_relocate_section
+#define elf_backend_gc_mark_hook mmix_elf_gc_mark_hook
+#define elf_backend_link_output_symbol_hook \
+ mmix_elf_link_output_symbol_hook
+#define elf_backend_add_symbol_hook mmix_elf_add_symbol_hook
+
+#define elf_backend_check_relocs mmix_elf_check_relocs
+#define elf_backend_symbol_processing mmix_elf_symbol_processing
+
+#define bfd_elf64_bfd_is_local_label_name \
+ mmix_elf_is_local_label_name
+
+#define elf_backend_may_use_rel_p 0
+#define elf_backend_may_use_rela_p 1
+#define elf_backend_default_use_rela_p 1
+
+#define elf_backend_can_gc_sections 1
+#define elf_backend_section_from_bfd_section \
+ mmix_elf_section_from_bfd_section
+
+#define bfd_elf64_bfd_final_link mmix_elf_final_link
+
+#include "elf64-target.h"
#ifndef elf_backend_got_symbol_offset
#define elf_backend_got_symbol_offset (bfd_vma) 0
#endif
+#ifndef elf_backend_can_refcount
+#define elf_backend_can_refcount 0
+#endif
#ifndef elf_backend_want_got_plt
#define elf_backend_want_got_plt 0
#endif
"BFD_RELOC_MCORE_PCREL_32",
"BFD_RELOC_MCORE_PCREL_JSR_IMM11BY2",
"BFD_RELOC_MCORE_RVA",
+ "BFD_RELOC_MMIX_GETA",
+ "BFD_RELOC_MMIX_GETA_1",
+ "BFD_RELOC_MMIX_GETA_2",
+ "BFD_RELOC_MMIX_GETA_3",
+ "BFD_RELOC_MMIX_CBRANCH",
+ "BFD_RELOC_MMIX_CBRANCH_J",
+ "BFD_RELOC_MMIX_CBRANCH_1",
+ "BFD_RELOC_MMIX_CBRANCH_2",
+ "BFD_RELOC_MMIX_CBRANCH_3",
+ "BFD_RELOC_MMIX_PUSHJ",
+ "BFD_RELOC_MMIX_PUSHJ_1",
+ "BFD_RELOC_MMIX_PUSHJ_2",
+ "BFD_RELOC_MMIX_PUSHJ_3",
+ "BFD_RELOC_MMIX_JMP",
+ "BFD_RELOC_MMIX_JMP_1",
+ "BFD_RELOC_MMIX_JMP_2",
+ "BFD_RELOC_MMIX_JMP_3",
+ "BFD_RELOC_MMIX_ADDR19",
+ "BFD_RELOC_MMIX_ADDR27",
+ "BFD_RELOC_MMIX_REG_OR_BYTE",
+ "BFD_RELOC_MMIX_REG",
+ "BFD_RELOC_MMIX_BASE_PLUS_OFFSET",
+ "BFD_RELOC_MMIX_LOCAL",
"BFD_RELOC_AVR_7_PCREL",
"BFD_RELOC_AVR_13_PCREL",
"BFD_RELOC_AVR_16_PM",
--- /dev/null
+/* BFD back-end for mmo objects (MMIX-specific object-format).
+ Copyright 2001
+ Free Software Foundation, Inc.
+ Written by Hans-Peter Nilsson (hp@bitrange.com).
+ Infrastructure and other bits originally copied from srec.c and
+ binary.c.
+
+This file is part of BFD, the Binary File Descriptor library.
+
+This program is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2 of the License, or
+(at your option) any later version.
+
+This program is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with this program; if not, write to the Free Software
+Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+
+/*
+SECTION
+ mmo backend
+
+ The mmo object format is used exclusively together with Professor
+ Donald E.@: Knuth's educational 64-bit processor MMIX. The simulator
+ @emph{mmix} which is available at
+ @emph{http://www-cs-faculty.stanford.edu/~knuth/programs/mmix.tar.gz}
+ understands this format. That package also includes a combined
+ assembler and linker called @emph{mmixal}. The mmo format has
+ no advantages feature-wise compared to e.g. ELF. It is a simple
+ non-relocatable object format with no support for archives or
+ debugging information, except for symbol value information and
+ line numbers (which is not yet implemented in BFD). See
+ @emph{http://www-cs-faculty.stanford.edu/~knuth/mmix.html} for more
+ information about MMIX. The ELF format is used for intermediate
+ object files in the BFD implementation.
+
+@c We want to xref the symbol table node. A feature in "chew"
+@c requires that "commands" do not contain spaces in the
+@c arguments. Hence the hyphen in "Symbol-table".
+@menu
+@* File layout::
+@* Symbol-table::
+@* mmo section mapping::
+@end menu
+
+INODE
+File layout, Symbol-table, mmo, mmo
+SUBSECTION
+ File layout
+
+ The mmo file contents is not partitioned into named sections as
+ with e.g.@: ELF. Memory areas is formed by specifying the
+ location of the data that follows. Only the memory area
+ @samp{0x0000@dots{}00} to @samp{0x01ff@dots{}ff} is executable, so
+ it is used for code (and constants) and the area
+ @samp{0x2000@dots{}00} to @samp{0x20ff@dots{}ff} is used for
+ writable data. @xref{mmo section mapping}.
+
+ Contents is entered as 32-bit words, xor:ed over previous
+ contents, always zero-initialized. A word that starts with the
+ byte @samp{0x98} forms a command called a @samp{lopcode}, where
+ the next byte distinguished between the thirteen lopcodes. The
+ two remaining bytes, called the @samp{Y} and @samp{Z} fields, or
+ the @samp{YZ} field (a 16-bit big-endian number), are used for
+ various purposes different for each lopcode. As documented in
+ @emph{http://www-cs-faculty.stanford.edu/~knuth/mmixal-intro.ps.gz},
+ the lopcodes are:
+
+ There is provision for specifying ``special data'' of 65536
+ different types. We use type 80 (decimal), arbitrarily chosen the
+ same as the ELF <<e_machine>> number for MMIX, filling it with
+ section information normally found in ELF objects. @xref{mmo
+ section mapping}.
+
+ @table @code
+ @item lop_quote
+ 0x98000001. The next word is contents, regardless of whether it
+ starts with 0x98 or not.
+
+ @item lop_loc
+ 0x9801YYZZ, where @samp{Z} is 1 or 2. This is a location
+ directive, setting the location for the next data to the next
+ 32-bit word (for @math{Z = 1}) or 64-bit word (for @math{Z = 2}),
+ plus @math{Y * 2^56}. Normally @samp{Y} is 0 for the text segment
+ and 2 for the data segment.
+
+ @item lop_skip
+ 0x9802YYZZ. Increase the current location by @samp{YZ} bytes.
+
+ @item lop_fixo
+ 0x9803YYZZ, where @samp{Z} is 1 or 2. Store the current location
+ as 64 bits into the location pointed to by the next 32-bit
+ (@math{Z = 1}) or 64-bit (@math{Z = 2}) word, plus @math{Y *
+ 2^56}.
+
+ @item lop_fixr
+ 0x9804YYZZ. @samp{YZ} is stored into the current location plus
+ @math{2 - 4 * YZ}.
+
+ @item lop_fixrx
+ 0x980500ZZ. @samp{Z} is 16 or 24. A value @samp{L} derived from
+ the following 32-bit word are used in a manner similar to
+ @samp{YZ} in lop_fixr: it is xor:ed into the current location
+ minus @math{4 * L}. The first byte of the word is 0 or 1. If it
+ is 1, then @math{L = (@var{lowest 24 bits of word}) - 2^Z}, if 0,
+ then @math{L = (@var{lowest 24 bits of word})}.
+
+ @item lop_file
+ 0x9806YYZZ. @samp{Y} is the file number, @samp{Z} is count of
+ 32-bit words. Set the file number to @samp{Y} and the line
+ counter to 0. The next @math{Z * 4} bytes contain the file name,
+ padded with zeros if the count is not a multiple of four. The
+ same @samp{Y} may occur multiple times, but @samp{Z} must be 0 for
+ all but the first occurrence.
+
+ @item lop_line
+ 0x9807YYZZ. @samp{YZ} is the line number. Together with
+ lop_file, it forms the source location for the next 32-bit word.
+ Note that for each non-lopcode 32-bit word, line numbers are
+ assumed incremented by one.
+
+ @item lop_spec
+ 0x9808YYZZ. @samp{YZ} is the type number. Data until the next
+ lopcode other than lop_quote forms special data of type @samp{YZ}.
+ @xref{mmo section mapping}.
+
+ Other types than 80, (or type 80 with a content that does not
+ parse) is stored in sections named <<.MMIX.spec_data.@var{n}>>
+ where @var{n} is the @samp{YZ}-type. The flags for such a
+ sections say not to allocate or load the data. The vma is 0.
+ Contents of multiple occurrences of special data @var{n} is
+ concatenated to the data of the previous lop_spec @var{n}s. The
+ location in data or code at which the lop_spec occurred is lost.
+
+ @item lop_pre
+ 0x980901ZZ. The first lopcode in a file. The @samp{Z} field forms the
+ length of header information in 32-bit words, where the first word
+ tells the time in seconds since @samp{00:00:00 GMT Jan 1 1970}.
+
+ @item lop_post
+ 0x980a00ZZ. @math{Z > 32}. This lopcode follows after all
+ content-generating lopcodes in a program. The @samp{Z} field
+ denotes the value of @samp{rG} at the beginning of the program.
+ The following @math{256 - Z} big-endian 64-bit words are loaded
+ into global registers @samp{$G} @dots{} @samp{$255}.
+
+ @item lop_stab
+ 0x980b0000. The next-to-last lopcode in a program. Must follow
+ immediately after the lop_post lopcode and its data. After this
+ lopcode follows all symbols in a compressed format
+ (@pxref{Symbol-table}).
+
+ @item lop_end
+ 0x980cYYZZ. The last lopcode in a program. It must follow the
+ lop_stab lopcode and its data. The @samp{YZ} field contains the
+ number of 32-bit words of symbol table information after the
+ preceding lop_stab lopcode.
+ @end table
+
+ Note that the lopcode "fixups"; <<lop_fixr>>, <<lop_fixrx>> and
+ <<lop_fixo>> are not generated by BFD, but are handled. They are
+ generated by <<mmixal>>.
+
+EXAMPLE
+ This trivial one-label, one-instruction file:
+
+| :Main TRAP 1,2,3
+
+ can be represented this way in mmo:
+
+| 0x98090101 - lop_pre, one 32-bit word with timestamp.
+| <timestamp>
+| 0x98010002 - lop_loc, text segment, using a 64-bit address.
+| Note that mmixal does not emit this for the file above.
+| 0x00000000 - Address, high 32 bits.
+| 0x00000000 - Address, low 32 bits.
+| 0x98060002 - lop_file, 2 32-bit words for file-name.
+| 0x74657374 - "test"
+| 0x2e730000 - ".s\0\0"
+| 0x98070001 - lop_line, line 1.
+| 0x00010203 - TRAP 1,2,3
+| 0x980a00ff - lop_post, setting $255 to 0.
+| 0x00000000
+| 0x00000000
+| 0x980b0000 - lop_stab for ":Main" = 0, serial 1.
+| 0x203a4040 @xref{Symbol-table}.
+| 0x10404020
+| 0x4d206120
+| 0x69016e00
+| 0x81000000
+| 0x980c0005 - lop_end; symbol table contained five 32-bit words. */
+
+#include "bfd.h"
+#include "sysdep.h"
+#include "libbfd.h"
+#include "libiberty.h"
+#include "elf/mmix.h"
+#include "opcode/mmix.h"
+#include <ctype.h>
+
+#define LOP 0x98
+#define LOP_QUOTE 0
+#define LOP_LOC 1
+#define LOP_SKIP 2
+#define LOP_FIXO 3
+#define LOP_FIXR 4
+#define LOP_FIXRX 5
+#define LOP_FILE 6
+#define LOP_LINE 7
+#define LOP_SPEC 8
+#define LOP_PRE 9
+#define LOP_POST 10
+#define LOP_STAB 11
+#define LOP_END 12
+
+#define LOP_QUOTE_NEXT ((LOP << 24) | (LOP_QUOTE << 16) | 1)
+#define SPEC_DATA_SECTION 80
+#define LOP_SPEC_SECTION \
+ ((LOP << 24) | (LOP_SPEC << 16) | SPEC_DATA_SECTION)
+
+/* Must be a power of two. If you change this to be >= 64k, you need a
+ new test-case; the ld test b-loc64k.d touches chunk-size problem areas. */
+#define MMO_SEC_CONTENTS_CHUNK_SIZE (1 << 15)
+
+/* An arbitrary number for the maximum length section name size. */
+#define MAX_SECTION_NAME_SIZE (1024 * 1024)
+
+/* A quite arbitrary number for the maximum length section size. */
+#define MAX_ARTIFICIAL_SECTION_SIZE (1024 * 1024 * 1024)
+
+#define MMO3_WCHAR 0x80
+#define MMO3_LEFT 0x40
+#define MMO3_MIDDLE 0x20
+#define MMO3_RIGHT 0x10
+#define MMO3_TYPEBITS 0xf
+#define MMO3_REGQUAL_BITS 0xf
+#define MMO3_UNDEF 2
+#define MMO3_DATA 8
+#define MMO3_SYMBITS 0x2f
+
+/* Put these everywhere in new code. */
+#define FATAL_DEBUG \
+ _bfd_abort (__FILE__, __LINE__, \
+ "Internal: Non-debugged code (test-case missing)")
+
+#define BAD_CASE(x) \
+ _bfd_abort (__FILE__, __LINE__, \
+ "bad case for " #x)
+
+enum mmo_sym_type { mmo_reg_sym, mmo_undef_sym, mmo_data_sym, mmo_abs_sym};
+
+/* When scanning the mmo file, a linked list of mmo_symbol
+ structures is built to represent the symbol table (if there is
+ one). */
+
+struct mmo_symbol
+ {
+ struct mmo_symbol *next;
+ CONST char *name;
+ bfd_vma value;
+ enum mmo_sym_type sym_type;
+ unsigned int serno;
+ };
+
+struct mmo_data_list_struct
+ {
+ struct mmo_data_list_struct *next;
+ bfd_vma where;
+ bfd_size_type size;
+ bfd_size_type allocated_size;
+ bfd_byte data[1];
+ };
+
+typedef struct mmo_data_list_struct mmo_data_list_type;
+
+struct mmo_symbol_trie
+ {
+ struct mmo_symbol_trie *left;
+ struct mmo_symbol_trie *right;
+ struct mmo_symbol_trie *middle;
+
+ bfd_byte symchar;
+
+ /* A zero name means there's nothing here. */
+ struct mmo_symbol sym;
+ };
+
+/* The mmo tdata information. */
+
+struct mmo_data_struct
+ {
+ struct mmo_symbol *symbols;
+ struct mmo_symbol *symtail;
+ asymbol *csymbols;
+
+ /* File representation of time (NULL) when this file was created. */
+ bfd_byte created[4];
+
+ /* When we're reading bytes recursively, check this occasionally.
+ Also holds write errors. */
+ boolean have_error;
+
+ /* Max symbol length that may appear in the lop_stab table. Note that
+ this table might just hold a subset of symbols for not-really large
+ programs, as it can only be 65536 * 4 bytes large. */
+ int max_symbol_length;
+
+ /* Here's the symbol we build in lop_stab. */
+ char *lop_stab_symbol;
+
+ /* Index into lop_stab_symbol for the next character when parsing the
+ symbol information. */
+ int symbol_position;
+
+ /* When creating arbitrary sections, we need to count section numbers. */
+ int sec_no;
+
+ /* When writing or reading byte-wise, we need to count the bytes
+ within a 32-bit word. */
+ int byte_no;
+
+ /* We also need a buffer to hold the bytes we count reading or writing. */
+ bfd_byte buf[4];
+ };
+
+typedef struct mmo_data_struct tdata_type;
+
+struct mmo_section_data_struct
+ {
+ mmo_data_list_type *head;
+ mmo_data_list_type *tail;
+ };
+
+/* These structures are used in bfd_map_over_sections constructs. */
+
+/* Used when writing out sections; all but the register contents section
+ which is stored in reg_section. */
+struct mmo_write_sec_info
+ {
+ asection *reg_section;
+ boolean retval;
+ };
+
+/* Used when trying to find a section corresponding to addr. */
+struct mmo_find_sec_info
+ {
+ asection *sec;
+ bfd_vma addr;
+ };
+
+static boolean mmo_bfd_copy_private_bfd_data PARAMS ((bfd *, bfd *));
+static void mmo_write_section_unless_reg_contents
+ PARAMS ((bfd *, asection *, PTR));
+static void mmo_find_sec_w_addr PARAMS ((bfd *, asection *, PTR));
+static void mmo_find_sec_w_addr_grow PARAMS ((bfd *, asection *, PTR));
+static asection *mmo_make_section PARAMS ((bfd *, CONST char *));
+static void mmo_get_symbol_info PARAMS ((bfd *, asymbol *, symbol_info *));
+static void mmo_print_symbol
+ PARAMS ((bfd *, PTR, asymbol *, bfd_print_symbol_type));
+static void mmo_init PARAMS ((void));
+static boolean mmo_mkobject PARAMS ((bfd *));
+static boolean mmo_scan PARAMS ((bfd *));
+static asection *mmo_decide_section PARAMS ((bfd *, bfd_vma));
+static asection *mmo_get_generic_spec_data_section PARAMS ((bfd *, int));
+static asection *mmo_get_spec_section PARAMS ((bfd *, int));
+static INLINE bfd_byte *mmo_get_loc PARAMS ((asection *, bfd_vma, int));
+static void mmo_xore_64 PARAMS ((asection *, bfd_vma vma, bfd_vma value));
+static void mmo_xore_32 PARAMS ((asection *, bfd_vma vma, unsigned int));
+static void mmo_xore_16 PARAMS ((asection *, bfd_vma vma, unsigned int));
+static CONST bfd_target *mmo_object_p PARAMS ((bfd *));
+static void mmo_map_set_sizes PARAMS ((bfd *, asection *, PTR));
+static boolean mmo_get_symbols PARAMS ((bfd *));
+static boolean mmo_create_symbol PARAMS ((bfd *, CONST char *, bfd_vma,
+ enum mmo_sym_type, unsigned int));
+static boolean mmo_get_section_contents
+ PARAMS ((bfd *, asection *, PTR, file_ptr, bfd_size_type));
+static long mmo_get_symtab_upper_bound PARAMS ((bfd *));
+static long mmo_get_symtab PARAMS ((bfd *, asymbol **));
+static asymbol *mmo_make_empty_symbol PARAMS ((bfd *));
+static void mmo_get_symbol_info PARAMS ((bfd *, asymbol *, symbol_info *));
+static void mmo_print_symbol PARAMS ((bfd *, PTR, asymbol *,
+ bfd_print_symbol_type));
+static boolean mmo_set_section_contents
+ PARAMS ((bfd *, sec_ptr, PTR, file_ptr, bfd_size_type));
+static int mmo_sizeof_headers PARAMS ((bfd *, boolean));
+static long mmo_get_reloc_upper_bound PARAMS ((bfd *, asection *));
+
+static boolean mmo_internal_write_header PARAMS ((bfd *));
+static boolean mmo_internal_write_post PARAMS ((bfd *, int, asection *));
+static boolean mmo_internal_add_3_sym
+ PARAMS ((bfd *, struct mmo_symbol_trie *, CONST struct mmo_symbol *));
+static unsigned int mmo_internal_3_length
+ PARAMS ((bfd *, struct mmo_symbol_trie *));
+static void mmo_internal_3_dump
+ PARAMS ((bfd *, struct mmo_symbol_trie *));
+static void mmo_beb128_out PARAMS ((bfd *, int, int));
+static boolean mmo_internal_write_section
+ PARAMS ((bfd *, asection *));
+static void mmo_write_tetra PARAMS ((bfd *, unsigned int));
+static void mmo_write_tetra_raw PARAMS ((bfd *, unsigned int));
+static void mmo_write_octa PARAMS ((bfd *, bfd_vma));
+static void mmo_write_octa_raw PARAMS ((bfd *, bfd_vma));
+static boolean mmo_write_chunk
+ PARAMS ((bfd *, CONST bfd_byte *, unsigned int));
+static boolean mmo_write_loc_chunk
+ PARAMS ((bfd *, bfd_vma, CONST bfd_byte *, unsigned int));
+static boolean mmo_write_chunk_list PARAMS ((bfd *, mmo_data_list_type *));
+static boolean mmo_write_loc_chunk_list
+ PARAMS ((bfd *, mmo_data_list_type *));
+static boolean mmo_write_symbols_and_terminator PARAMS ((bfd *));
+static flagword mmo_sec_flags_from_bfd_flags PARAMS ((flagword));
+static flagword bfd_sec_flags_from_mmo_flags PARAMS ((flagword));
+static bfd_byte mmo_get_byte PARAMS ((bfd *));
+static void mmo_write_byte PARAMS ((bfd *, bfd_byte));
+static boolean mmo_new_section_hook PARAMS ((bfd *, asection *));
+static int mmo_sort_mmo_symbols PARAMS ((CONST PTR, CONST PTR));
+static boolean mmo_write_object_contents PARAMS ((bfd *));
+static long mmo_canonicalize_reloc
+ PARAMS ((bfd *, sec_ptr, arelent **, asymbol **));
+
+/* Global "const" variables initialized once. Must not depend on
+ particular input or caller; put such things into the bfd or elsewhere.
+ Look ma, no static per-invocation data! */
+
+static unsigned
+char valid_mmo_symbol_character_set[/* A-Z a-z (we assume consecutive
+ codes; sorry EBCDIC:ers!). */
+ + 'Z' - 'A' + 1 + 'z' - 'a' + 1
+ /* Digits. */
+ + 10
+ /* ':' and '_'. */
+ + 1 + 1
+ /* Codes higher than 126. */
+ + 256 - 126
+ /* Ending zero. */
+ + 1];
+
+
+/* Get section SECNAME or create one if it doesn't exist. When creating
+ one, new memory for the name is allocated. */
+
+static asection *
+mmo_make_section (abfd, secname)
+ bfd *abfd;
+ CONST char *secname;
+{
+ asection *sec = bfd_get_section_by_name (abfd, secname);
+
+ if (sec == NULL)
+ {
+ char *newsecname = strdup (secname);
+
+ if (newsecname == NULL)
+ {
+ (*_bfd_error_handler)
+ (_("%s: No core to allocate section name %s\n"),
+ bfd_get_filename (abfd), secname);
+ bfd_set_error (bfd_error_system_call);
+ return NULL;
+ }
+ sec = bfd_make_section (abfd, newsecname);
+ }
+
+ return sec;
+}
+
+/* Nothing to do, but keep as a placeholder if we need it.
+ Note that state that might differ between bfd:s must not be initialized
+ here, nor must it be static. Add it to tdata information instead. */
+
+static void
+mmo_init ()
+{
+ static boolean inited = false;
+ int i = 0;
+ int j = 0;
+ static const char letters[]
+ = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789:_";
+
+ if (inited == false)
+ {
+ inited = true;
+ }
+
+ /* Fill in the set of valid symbol characters. */
+ strcpy (valid_mmo_symbol_character_set, letters);
+ i = strlen (letters);
+
+ for (j = 126; j < 256; j++)
+ valid_mmo_symbol_character_set[i++] = j;
+}
+
+/* Check whether an existing file is an mmo file. */
+
+static CONST bfd_target *
+mmo_object_p (abfd)
+ bfd *abfd;
+{
+ struct stat statbuf;
+ bfd_byte b[4];
+
+ mmo_init ();
+
+ if (bfd_stat (abfd, &statbuf) < 0
+ || bfd_seek (abfd, (file_ptr) 0, SEEK_SET) != 0
+ || bfd_bread (b, 4, abfd) != 4)
+ goto bad_final;
+
+ /* All mmo files are a multiple of four bytes long.
+ Only recognize version one. */
+ if ((statbuf.st_size % 4) != 0
+ || b[0] != LOP || b[1] != LOP_PRE || b[2] != 1)
+ goto bad_format;
+
+ /* Get the last 32-bit word. */
+ if (bfd_seek (abfd, (file_ptr) statbuf.st_size - 4, SEEK_SET) != 0
+ || bfd_bread (b, 4, abfd) != 4)
+ goto bad_final;
+
+ /* Check if the file ends in a lop_end lopcode. */
+ if (b[0] != LOP || b[1] != LOP_END || ! mmo_mkobject (abfd))
+ goto bad_format;
+
+ /* Compute an upper bound on the max symbol length. Not really
+ important as all of the symbol information can only be 256k. */
+ abfd->tdata.mmo_data->max_symbol_length = (b[2] * 256 + b[3]) * 4;
+ abfd->tdata.mmo_data->lop_stab_symbol
+ = bfd_malloc (abfd->tdata.mmo_data->max_symbol_length + 1);
+
+ if (abfd->tdata.mmo_data->lop_stab_symbol == NULL)
+ {
+ (*_bfd_error_handler)
+ (_("%s: No core to allocate a symbol %d bytes long\n"),
+ bfd_get_filename (abfd), abfd->tdata.mmo_data->max_symbol_length);
+ goto bad_final;
+ }
+
+ /* Read in everything. */
+ if (! mmo_scan (abfd))
+ goto bad_format_free;
+
+ if (abfd->symcount > 0)
+ abfd->flags |= HAS_SYMS;
+
+ /* You'll have to tweak this if you want to use this format for other
+ arches (not recommended due to its small-size limitations). Look at
+ the ELF format for how to make it target-generic. */
+ if (! bfd_default_set_arch_mach (abfd, bfd_arch_mmix, 0))
+ goto bad_format_free;
+
+ return abfd->xvec;
+
+ bad_format_free:
+ free (abfd->tdata.mmo_data->lop_stab_symbol);
+ bad_format:
+ bfd_set_error (bfd_error_wrong_format);
+ bad_final:
+ return NULL;
+}
+
+/* Set up the mmo tdata information. */
+
+static boolean
+mmo_mkobject (abfd)
+ bfd *abfd;
+{
+ mmo_init ();
+
+ if (abfd->tdata.mmo_data == NULL)
+ {
+ time_t created;
+
+ /* All fields are zero-initialized, so we don't have to explicitly
+ initialize most. */
+ tdata_type *tdata = (tdata_type *) bfd_zmalloc (sizeof (tdata_type));
+ if (tdata == NULL)
+ return false;
+
+ created = time (NULL);
+ bfd_put_32 (abfd, created, tdata->created);
+
+ abfd->tdata.mmo_data = tdata;
+ }
+
+ return true;
+}
+
+static boolean
+mmo_bfd_copy_private_bfd_data (ibfd, obfd)
+ bfd *ibfd;
+ bfd *obfd;
+{
+ if (bfd_get_flavour (ibfd) != bfd_target_mmo_flavour
+ || bfd_get_flavour (obfd) != bfd_target_mmo_flavour)
+ return true;
+
+ /* Copy the time the copied-from file was created. If people want the
+ time the file was last *modified*, they have that in the normal file
+ information. */
+ memcpy (obfd->tdata.mmo_data->created, ibfd->tdata.mmo_data->created,
+ sizeof (obfd->tdata.mmo_data->created));
+ return true;
+}
+
+/* Helper functions for mmo_decide_section, used through
+ bfd_map_over_sections. */
+
+static void
+mmo_find_sec_w_addr (abfd, sec, p)
+ bfd *abfd ATTRIBUTE_UNUSED;
+ asection *sec;
+ PTR p;
+{
+ struct mmo_find_sec_info *infop = (struct mmo_find_sec_info *) p;
+ bfd_vma vma = bfd_get_section_vma (abfd, sec);
+
+ /* Ignore sections that aren't loaded. */
+ if ((bfd_get_section_flags (abfd, sec) & (SEC_LOAD | SEC_ALLOC))
+ != (SEC_LOAD | SEC_ALLOC))
+ return;
+
+ if (infop->addr >= vma && infop->addr < vma + sec->_raw_size)
+ infop->sec = sec;
+}
+
+static void
+mmo_find_sec_w_addr_grow (abfd, sec, p)
+ bfd *abfd ATTRIBUTE_UNUSED;
+ asection *sec;
+ PTR p;
+{
+ struct mmo_find_sec_info *infop = (struct mmo_find_sec_info *) p;
+ bfd_vma vma = bfd_get_section_vma (abfd, sec);
+
+ /* Ignore sections that aren't loaded. */
+ if ((bfd_get_section_flags (abfd, sec) & (SEC_LOAD | SEC_ALLOC))
+ != (SEC_LOAD | SEC_ALLOC))
+ return;
+
+ if (infop->addr >= vma && infop->addr < vma + MAX_ARTIFICIAL_SECTION_SIZE)
+ infop->sec = sec;
+}
+
+/* Find a section that corresponds to a VMA. Automatically create .text
+ or .data and set current section to it, depending on what vma. If we
+ can't deduce a section, make one up as ".MMIX.sec.N", where N is an
+ increasing number. */
+
+static asection *
+mmo_decide_section (abfd, vma)
+ bfd *abfd;
+ bfd_vma vma;
+{
+ asection *sec = NULL;
+ char sec_name[sizeof (".MMIX.sec.") + 20];
+ struct mmo_find_sec_info info;
+
+ info.addr = vma;
+ info.sec = NULL;
+
+ /* First see if there's a section that would match exactly. */
+ bfd_map_over_sections (abfd, mmo_find_sec_w_addr, &info);
+
+ if (info.sec != NULL)
+ return info.sec;
+
+ /* If there's no such section, try and expand one of the existing ones,
+ up to a limit. Make sure we have .text and .data before we try that;
+ create them corresponding to expected addresses and set flags to make
+ them match the "loaded and with contents" expectation. */
+ if ((vma >> 56) == 0)
+ {
+ sec = bfd_make_section_old_way (abfd, MMO_TEXT_SECTION_NAME);
+
+ if (sec == NULL)
+ return NULL;
+
+ if (! sec->user_set_vma)
+ bfd_set_section_vma (abfd, sec, vma);
+ if (! bfd_set_section_flags (abfd, sec,
+ bfd_get_section_flags (abfd, sec)
+ | SEC_CODE | SEC_LOAD | SEC_ALLOC))
+ return NULL;
+ }
+ else if ((vma >> 56) == 0x20)
+ {
+ sec = bfd_make_section_old_way (abfd, MMO_DATA_SECTION_NAME);
+
+ if (sec == NULL)
+ return NULL;
+
+ if (! sec->user_set_vma)
+ bfd_set_section_vma (abfd, sec, vma);
+ if (! bfd_set_section_flags (abfd, sec,
+ bfd_get_section_flags (abfd, sec)
+ | SEC_LOAD | SEC_ALLOC))
+ return NULL;
+ }
+
+ bfd_map_over_sections (abfd, mmo_find_sec_w_addr_grow, &info);
+
+ if (info.sec != NULL)
+ return info.sec;
+
+ /* If there's still no suitable section, make a new one. */
+ sprintf (sec_name, ".MMIX.sec.%d", abfd->tdata.mmo_data->sec_no++);
+ sec = mmo_make_section (abfd, sec_name);
+ if (! sec->user_set_vma)
+ bfd_set_section_vma (abfd, sec, vma);
+
+ if (! bfd_set_section_flags (abfd, sec,
+ bfd_get_section_flags (abfd, sec)
+ | SEC_LOAD | SEC_ALLOC))
+ return NULL;
+ return sec;
+}
+
+/* Xor in a 64-bit value VALUE at VMA. */
+
+static INLINE void
+mmo_xore_64 (sec, vma, value)
+ asection *sec;
+ bfd_vma vma;
+ bfd_vma value;
+{
+ bfd_byte *loc = mmo_get_loc (sec, vma, 8);
+ bfd_vma prev = bfd_get_64 (sec->owner, loc);
+
+ value ^= prev;
+ bfd_put_64 (sec->owner, value, loc);
+}
+
+/* Xor in a 32-bit value VALUE at VMA. */
+
+static INLINE void
+mmo_xore_32 (sec, vma, value)
+ asection *sec;
+ bfd_vma vma;
+ unsigned int value;
+{
+ bfd_byte *loc = mmo_get_loc (sec, vma, 4);
+ unsigned int prev = bfd_get_32 (sec->owner, loc);
+
+ value ^= prev;
+ bfd_put_32 (sec->owner, value, loc);
+}
+
+/* Xor in a 16-bit value VALUE at VMA. */
+
+static INLINE void
+mmo_xore_16 (sec, vma, value)
+ asection *sec;
+ bfd_vma vma;
+ unsigned int value;
+{
+ bfd_byte *loc = mmo_get_loc (sec, vma, 2);
+ unsigned int prev = bfd_get_16 (sec->owner, loc);
+
+ value ^= prev;
+ bfd_put_16 (sec->owner, value, loc);
+}
+
+/* Write a 32-bit word to output file, no lop_quote generated. */
+
+static INLINE void
+mmo_write_tetra_raw (abfd, value)
+ bfd *abfd;
+ unsigned int value;
+{
+ bfd_byte buf[4];
+
+ bfd_put_32 (abfd, value, buf);
+
+ if (bfd_bwrite ((PTR) buf, 4, abfd) != 4)
+ abfd->tdata.mmo_data->have_error = true;
+}
+
+/* Write a 32-bit word to output file; lop_quote if necessary. */
+
+static INLINE void
+mmo_write_tetra (abfd, value)
+ bfd *abfd;
+ unsigned int value;
+{
+ if (((value >> 24) & 0xff) == LOP)
+ mmo_write_tetra_raw (abfd, LOP_QUOTE_NEXT);
+
+ mmo_write_tetra_raw (abfd, value);
+}
+
+/* Write a 64-bit word to output file, perhaps with lop_quoting. */
+
+static INLINE void
+mmo_write_octa (abfd, value)
+ bfd *abfd;
+ bfd_vma value;
+{
+ mmo_write_tetra (abfd, (unsigned int) (value >> 32));
+ mmo_write_tetra (abfd, (unsigned int) value);
+}
+
+/* Write a 64-bit word to output file, without lop_quoting. */
+
+static INLINE void
+mmo_write_octa_raw (abfd, value)
+ bfd *abfd;
+ bfd_vma value;
+{
+ mmo_write_tetra_raw (abfd, (unsigned int) (value >> 32));
+ mmo_write_tetra_raw (abfd, (unsigned int) value);
+}
+
+/* Write quoted contents, zero filled. */
+
+static INLINE boolean
+mmo_write_chunk (abfd, loc, len)
+ bfd *abfd;
+ CONST bfd_byte *loc;
+ unsigned int len;
+{
+ boolean retval = true;
+ bfd_byte buf[4] = {0, 0, 0, 0};
+
+ while (len >= 4)
+ {
+ if (loc[0] == LOP)
+ mmo_write_tetra_raw (abfd, LOP_QUOTE_NEXT);
+
+ retval
+ = (retval == true
+ && abfd->tdata.mmo_data->have_error == false
+ && 4 == bfd_bwrite ((PTR) loc, 4, abfd));
+
+ loc += 4;
+ len -= 4;
+ }
+
+ if (len)
+ {
+ memcpy (buf, loc, len);
+ if (buf[0] == LOP)
+ mmo_write_tetra_raw (abfd, LOP_QUOTE_NEXT);
+
+ retval
+ = (retval == true
+ && abfd->tdata.mmo_data->have_error == false
+ && 4 == bfd_bwrite ((PTR) buf, 4, abfd));
+ }
+
+ return retval;
+}
+
+/* Same, but from a list. */
+
+static INLINE boolean
+mmo_write_chunk_list (abfd, datap)
+ bfd *abfd;
+ mmo_data_list_type *datap;
+{
+ for (; datap != NULL; datap = datap->next)
+ if (! mmo_write_chunk (abfd, datap->data, datap->size))
+ return false;
+
+ return true;
+}
+
+/* Write a lop_loc and some contents. */
+
+static boolean
+mmo_write_loc_chunk (abfd, vma, loc, len)
+ bfd *abfd;
+ bfd_vma vma;
+ CONST bfd_byte *loc;
+ unsigned int len;
+{
+ /* We always write the location as 64 bits; no use saving bytes here. */
+ mmo_write_tetra_raw (abfd, (LOP << 24) | (LOP_LOC << 16) | 2);
+
+ /* Find an initial and trailing section of zero tetras; we don't need to
+ write out zeros. FIXME: When we do this, we should emit section size
+ and address specifiers, else objcopy can't perform a unity
+ translation. */
+ while (len >= 4 && bfd_get_32 (abfd, loc) == 0)
+ {
+ vma += 4;
+ len -= 4;
+ loc += 4;
+ }
+
+ while (len >= 4 && bfd_get_32 (abfd, loc + len - 4) == 0)
+ len -= 4;
+
+ mmo_write_octa_raw (abfd, vma);
+ return
+ abfd->tdata.mmo_data->have_error == false
+ && mmo_write_chunk (abfd, loc, len);
+}
+
+/* Same, but from a list. */
+
+static INLINE boolean
+mmo_write_loc_chunk_list (abfd, datap)
+ bfd *abfd;
+ mmo_data_list_type *datap;
+{
+ for (; datap != NULL; datap = datap->next)
+ if (! mmo_write_loc_chunk (abfd, datap->where, datap->data, datap->size))
+ return false;
+
+ return true;
+}
+
+/* Make a .MMIX.spec_data.N section. */
+
+static asection *
+mmo_get_generic_spec_data_section (abfd, spec_data_number)
+ bfd *abfd;
+ int spec_data_number;
+{
+ asection *sec;
+ char secname[sizeof (MMIX_OTHER_SPEC_SECTION_PREFIX) + 20]
+ = MMIX_OTHER_SPEC_SECTION_PREFIX;
+
+ sprintf (secname + strlen (MMIX_OTHER_SPEC_SECTION_PREFIX),
+ "%d", spec_data_number);
+
+ sec = mmo_make_section (abfd, secname);
+
+ return sec;
+}
+
+/* Make a special section for SPEC_DATA_NUMBER. If it is the one we use
+ ourselves, parse some of its data to get at the section name. */
+
+static asection *
+mmo_get_spec_section (abfd, spec_data_number)
+ bfd *abfd;
+ int spec_data_number;
+{
+ bfd_byte *secname;
+ asection *sec;
+ bfd_byte buf[4];
+ unsigned int secname_length;
+ unsigned int i;
+ bfd_vma section_length;
+ bfd_vma section_vma;
+ mmo_data_list_type *loc;
+ flagword flags;
+ long orig_pos;
+
+ /* If this isn't the "special" special data, then make a placeholder
+ section. */
+ if (spec_data_number != SPEC_DATA_SECTION)
+ return mmo_get_generic_spec_data_section (abfd, spec_data_number);
+
+ /* Seek back to this position if there was a format error. */
+ orig_pos = bfd_tell (abfd);
+
+ /* Read the length (in 32-bit words). */
+ if (bfd_bread (buf, 4, abfd) != 4)
+ goto format_error;
+
+ if (buf[0] == LOP)
+ {
+ if (buf[1] != LOP_QUOTE)
+ goto format_error;
+
+ if (bfd_bread (buf, 4, abfd) != 4)
+ goto format_error;
+ }
+
+ /* We don't care to keep the name length accurate. It's
+ zero-terminated. */
+ secname_length = bfd_get_32 (abfd, buf) * 4;
+
+ /* Check section name length for sanity. */
+ if (secname_length > MAX_SECTION_NAME_SIZE)
+ goto format_error;
+
+ /* This should be free'd regardless if a section is created. */
+ secname = bfd_malloc (secname_length + 1);
+ secname[secname_length] = 0;
+
+ for (i = 0; i < secname_length / 4; i++)
+ {
+ if (bfd_bread (secname + i * 4, 4, abfd) != 4)
+ goto format_error_free;
+
+ if (secname[i * 4] == LOP)
+ {
+ /* A bit of overkill, but we handle char 0x98 in a section name,
+ and recognize misparsing. */
+ if (secname[i * 4 + 1] != LOP_QUOTE
+ || bfd_bread (secname + i * 4, 4, abfd) != 4)
+ /* Whoops. We thought this was a name, and now we found a
+ non-lop_quote lopcode before we parsed the whole length of
+ the name. Signal end-of-file in the same manner. */
+ goto format_error_free;
+ }
+ }
+
+ /* Get the section flags. */
+ if (bfd_bread (buf, 4, abfd) != 4
+ || (buf[0] == LOP
+ && (buf[1] != LOP_QUOTE || bfd_bread (buf, 4, abfd) != 4)))
+ goto format_error_free;
+
+ flags = bfd_get_32 (abfd, buf);
+
+ /* Get the section length. */
+ if (bfd_bread (buf, 4, abfd) != 4
+ || (buf[0] == LOP
+ && (buf[1] != LOP_QUOTE || bfd_bread (buf, 4, abfd) != 4)))
+ goto format_error_free;
+
+ section_length = (bfd_vma) bfd_get_32 (abfd, buf) << 32;
+
+ /* That's the first, high-part. Now get the low part. */
+
+ if (bfd_bread (buf, 4, abfd) != 4
+ || (buf[0] == LOP
+ && (buf[1] != LOP_QUOTE || bfd_bread (buf, 4, abfd) != 4)))
+ goto format_error_free;
+
+ section_length |= (bfd_vma) bfd_get_32 (abfd, buf);
+
+ /* Check the section length for sanity. */
+ if (section_length > MAX_ARTIFICIAL_SECTION_SIZE)
+ goto format_error_free;
+
+ /* Get the section VMA. */
+ if (bfd_bread (buf, 4, abfd) != 4
+ || (buf[0] == LOP
+ && (buf[1] != LOP_QUOTE || bfd_bread (buf, 4, abfd) != 4)))
+ goto format_error_free;
+
+ section_vma = (bfd_vma) bfd_get_32 (abfd, buf) << 32;
+
+ /* That's the first, high-part. Now get the low part. */
+ if (bfd_bread (buf, 4, abfd) != 4
+ || (buf[0] == LOP
+ && (buf[1] != LOP_QUOTE || bfd_bread (buf, 4, abfd) != 4)))
+ goto format_error_free;
+
+ section_vma |= (bfd_vma) bfd_get_32 (abfd, buf);
+
+ sec = mmo_make_section (abfd, secname);
+ free (secname);
+ if (sec == NULL)
+ goto format_error;
+
+ /* We allocate a buffer here for the advertised size, with head room for
+ tetrabyte alignment. */
+ loc = bfd_zmalloc (section_length + 3
+ + sizeof (struct mmo_data_list_struct));
+ if (loc == NULL)
+ goto format_error;
+
+ /* Use a TETRA-rounded size for the allocated buffer; we set the
+ "visible" section size below. */
+ loc->size = (section_length + 3) & ~3;
+
+ /* Add in the section flags we found to those bfd entered during this
+ process and set the contents. */
+ if (! bfd_set_section_flags (abfd, sec,
+ bfd_sec_flags_from_mmo_flags (flags)
+ | bfd_get_section_flags (abfd, sec)
+ | (section_length != 0 ? SEC_HAS_CONTENTS : 0))
+ || ! bfd_set_section_size (abfd, sec,
+ sec->_cooked_size + section_length)
+ /* Set VMA only for the first occurrence. */
+ || (! sec->user_set_vma
+ && ! bfd_set_section_vma (abfd, sec, section_vma)))
+ {
+ /* If we get an error for any of the calls above, signal more than
+ just a format error for the spec section. */
+ return NULL;
+ }
+
+ loc->next = NULL;
+ if (((struct mmo_section_data_struct *) (sec->used_by_bfd))->tail != NULL)
+ ((struct mmo_section_data_struct *) (sec->used_by_bfd))->tail->next
+ = loc;
+ else
+ ((struct mmo_section_data_struct *) (sec->used_by_bfd))->head = loc;
+ ((struct mmo_section_data_struct *) (sec->used_by_bfd))->tail = loc;
+ loc->where = section_vma;
+
+ return sec;
+
+ format_error_free:
+ free (secname);
+ format_error:
+ if (bfd_seek (abfd, orig_pos, SEEK_SET) != 0)
+ return NULL;
+
+ return mmo_get_generic_spec_data_section (abfd, spec_data_number);
+}
+
+/* Read a byte, but read from file in multiples of 32-bit words. */
+
+static bfd_byte
+mmo_get_byte (abfd)
+ bfd *abfd;
+{
+ bfd_byte retval;
+
+ if (abfd->tdata.mmo_data->byte_no == 0)
+ {
+ if (abfd->tdata.mmo_data->have_error == false
+ && bfd_bread (abfd->tdata.mmo_data->buf, 4, abfd) != 4)
+ {
+ abfd->tdata.mmo_data->have_error = true;
+
+ /* A value somewhat safe against tripping on some inconsistency
+ when mopping up after this error. */
+ return 128;
+ }
+ }
+
+ retval = abfd->tdata.mmo_data->buf[abfd->tdata.mmo_data->byte_no];
+ abfd->tdata.mmo_data->byte_no = (abfd->tdata.mmo_data->byte_no + 1) % 4;
+
+ return retval;
+}
+
+/* Write a byte, in multiples of 32-bit words. */
+
+static void
+mmo_write_byte (abfd, value)
+ bfd *abfd;
+ bfd_byte value;
+{
+ abfd->tdata.mmo_data->buf[(abfd->tdata.mmo_data->byte_no++ % 4)] = value;
+ if ((abfd->tdata.mmo_data->byte_no % 4) == 0)
+ {
+ if (abfd->tdata.mmo_data->have_error == false
+ && bfd_bwrite (abfd->tdata.mmo_data->buf, 4, abfd) != 4)
+ abfd->tdata.mmo_data->have_error = true;
+ }
+}
+
+/* Create a symbol. */
+
+static boolean
+mmo_create_symbol (abfd, symname, addr, sym_type, serno)
+ bfd *abfd;
+ CONST char *symname;
+ bfd_vma addr;
+ enum mmo_sym_type sym_type;
+ unsigned int serno;
+{
+ struct mmo_symbol *n;
+
+ n = (struct mmo_symbol *) bfd_alloc (abfd, sizeof (struct mmo_symbol));
+ if (n == NULL)
+ return false;
+
+ n->name = bfd_alloc (abfd, strlen (symname) + 1);
+ if (n->name == NULL)
+ return false;
+
+ strcpy ((PTR) n->name, symname);
+
+ n->value = addr;
+ n->sym_type = sym_type;
+ n->serno = serno;
+
+ if (abfd->tdata.mmo_data->symbols == NULL)
+ abfd->tdata.mmo_data->symbols = n;
+ else
+ abfd->tdata.mmo_data->symtail->next = n;
+ abfd->tdata.mmo_data->symtail = n;
+ n->next = NULL;
+
+ ++abfd->symcount;
+
+ /* Check that :Main equals the last octa of the .MMIX.reg_contents
+ section, as it's the one place we're sure to pass when reading a mmo
+ object. For written objects, we do it while setting the symbol
+ table. */
+ if (strcmp (symname, MMIX_START_SYMBOL_NAME) == 0
+ && bfd_get_start_address (abfd) != addr)
+ {
+ (*_bfd_error_handler)
+ (_("%s: invalid mmo file: initialization value for $255 is not `Main'\n"),
+ bfd_get_filename (abfd));
+ bfd_set_error (bfd_error_bad_value);
+ return false;
+ }
+
+ return true;
+}
+
+/* Read in symbols. */
+
+static boolean
+mmo_get_symbols (abfd)
+ bfd *abfd;
+{
+/*
+INODE
+Symbol-table, mmo section mapping, File layout, mmo
+SUBSECTION
+ Symbol table format
+
+ From mmixal.w (or really, the generated mmixal.tex) in
+ @emph{http://www-cs-faculty.stanford.edu/~knuth/programs/mmix.tar.gz}):
+ ``Symbols are stored and retrieved by means of a @samp{ternary
+ search trie}, following ideas of Bentley and Sedgewick. (See
+ ACM--SIAM Symp.@: on Discrete Algorithms @samp{8} (1997), 360--369;
+ R.@:Sedgewick, @samp{Algorithms in C} (Reading, Mass.@:
+ Addison--Wesley, 1998), @samp{15.4}.) Each trie node stores a
+ character, and there are branches to subtries for the cases where
+ a given character is less than, equal to, or greater than the
+ character in the trie. There also is a pointer to a symbol table
+ entry if a symbol ends at the current node.''
+
+ So it's a tree encoded as a stream of bytes. The stream of bytes
+ acts on a single virtual global symbol, adding and removing
+ characters and signalling complete symbol points. Here, we read
+ the stream and create symbols at the completion points.
+
+ First, there's a control byte <<m>>. If any of the listed bits
+ in <<m>> is nonzero, we execute what stands at the right, in
+ the listed order:
+
+| (MMO3_LEFT)
+| 0x40 - Traverse left trie.
+| (Read a new command byte and recurse.)
+|
+| (MMO3_SYMBITS)
+| 0x2f - Read the next byte as a character and store it in the
+| current character position; increment character position.
+| Test the bits of <<m>>:
+|
+| (MMO3_WCHAR)
+| 0x80 - The character is 16-bit (so read another byte,
+| merge into current character.
+|
+| (MMO3_TYPEBITS)
+| 0xf - We have a complete symbol; parse the type, value
+| and serial number and do what should be done
+| with a symbol. The type and length information
+| is in j = (m & 0xf).
+|
+| (MMO3_REGQUAL_BITS)
+| j == 0xf: A register variable. The following
+| byte tells which register.
+| j <= 8: An absolute symbol. Read j bytes as the
+| big-endian number the symbol equals.
+| A j = 2 with two zero bytes denotes an
+| unknown symbol.
+| j > 8: As with j <= 8, but add (0x20 << 56)
+| to the value in the following j - 8
+| bytes.
+|
+| Then comes the serial number, as a variant of
+| uleb128, but better named ubeb128:
+| Read bytes and shift the previous value left 7
+| (multiply by 128). Add in the new byte, repeat
+| until a byte has bit 7 set. The serial number
+| is the computed value minus 128.
+|
+| (MMO3_MIDDLE)
+| 0x20 - Traverse middle trie. (Read a new command byte
+| and recurse.) Decrement character position.
+|
+| (MMO3_RIGHT)
+| 0x10 - Traverse right trie. (Read a new command byte and
+| recurse.)
+
+ Let's look again at the <<lop_stab>> for the trivial file
+ (@pxref{File layout}).
+
+| 0x980b0000 - lop_stab for ":Main" = 0, serial 1.
+| 0x203a4040
+| 0x10404020
+| 0x4d206120
+| 0x69016e00
+| 0x81000000
+
+ This forms the trivial trie (note that the path between ``:'' and
+ ``M'' is redundant):
+
+| 203a ":"
+| 40 /
+| 40 /
+| 10 \
+| 40 /
+| 40 /
+| 204d "M"
+| 2061 "a"
+| 2069 "i"
+| 016e "n" is the last character in a full symbol, and
+| with a value represented in one byte.
+| 00 The value is 0.
+| 81 The serial number is 1. */
+
+ bfd_byte m = mmo_get_byte (abfd);
+
+ /* Check first if we have a bad hair day. */
+ if (abfd->tdata.mmo_data->have_error == true)
+ return false;
+
+ if (m & MMO3_LEFT)
+ /* Traverse left trie. */
+ mmo_get_symbols (abfd);
+
+ if (m & MMO3_SYMBITS)
+ {
+ bfd_byte c = mmo_get_byte (abfd);
+ bfd_byte j = m & MMO3_TYPEBITS;
+ bfd_vma addr = 0;
+ enum mmo_sym_type sym_type;
+ unsigned int serno = 0;
+ bfd_byte k;
+
+ if (m & MMO3_WCHAR)
+ {
+ bfd_byte c2 = mmo_get_byte (abfd);
+
+ /* A two-byte character. We can't grok this, but neither can
+ mmotype, for other cases than the second byte being zero. */
+
+ if (c != 0)
+ {
+ abfd->tdata.mmo_data->lop_stab_symbol
+ [abfd->tdata.mmo_data->symbol_position] = 0;
+
+ (*_bfd_error_handler)
+ (_("%s: unsupported wide character sequence\
+ 0x%02X 0x%02X after symbol name starting with `%s'\n"),
+ bfd_get_filename (abfd), c, c2,
+ abfd->tdata.mmo_data->lop_stab_symbol);
+ bfd_set_error (bfd_error_bad_value);
+ abfd->tdata.mmo_data->have_error = true;
+ return false;
+ }
+ else
+ c = c2;
+ }
+
+ abfd->tdata.mmo_data->lop_stab_symbol[abfd->tdata.mmo_data->symbol_position++] = c;
+ abfd->tdata.mmo_data->lop_stab_symbol[abfd->tdata.mmo_data->symbol_position] = 0;
+
+ if (j & MMO3_REGQUAL_BITS)
+ {
+ if (j == MMO3_REGQUAL_BITS)
+ {
+ sym_type = mmo_reg_sym;
+ addr = mmo_get_byte (abfd);
+ }
+ else if (j <= 8)
+ {
+ unsigned int i;
+
+ for (i = 0; i < j; i++)
+ addr = (addr << 8) + mmo_get_byte (abfd);
+
+ if (addr == 0 && j == MMO3_UNDEF)
+ sym_type = mmo_undef_sym;
+ else
+ sym_type = mmo_abs_sym;
+ }
+ else
+ {
+ unsigned int i;
+
+ for (i = MMO3_DATA; i < j; i++)
+ addr = (addr << 8) + mmo_get_byte (abfd);
+
+ addr += (bfd_vma) 0x20 << 56;
+ sym_type = mmo_data_sym;
+ }
+
+ /* Get the serial number. */
+ do
+ {
+ k = mmo_get_byte (abfd);
+ serno = (serno << 7) + k;
+ }
+ while (k < 128);
+ serno -= 128;
+
+ /* Got it. Now enter it. Skip a leading ":". */
+ if (abfd->tdata.mmo_data->have_error == false
+ && ! mmo_create_symbol (abfd,
+ abfd->tdata.mmo_data->lop_stab_symbol
+ + 1,
+ addr, sym_type, serno))
+ abfd->tdata.mmo_data->have_error = true;
+ }
+
+ if (m & MMO3_MIDDLE)
+ /* Traverse middle trie. */
+ mmo_get_symbols (abfd);
+
+ abfd->tdata.mmo_data->symbol_position--;
+ }
+
+ if (m & MMO3_RIGHT)
+ /* Traverse right trie. */
+ mmo_get_symbols (abfd);
+
+ return abfd->tdata.mmo_data->have_error == false;
+}
+
+/* Get the location of memory area [VMA..VMA + SIZE - 1], which we think
+ is in section SEC. Adjust and reallocate zero-initialized contents.
+ If there's new contents, allocate to the next multiple of
+ MMO_SEC_CONTENTS_CHUNK_SIZE. */
+
+static INLINE bfd_byte *
+mmo_get_loc (sec, vma, size)
+ asection *sec;
+ bfd_vma vma;
+ int size;
+{
+ bfd_size_type allocated_size;
+ struct mmo_section_data_struct *sdatap
+ = (struct mmo_section_data_struct *) sec->used_by_bfd;
+ struct mmo_data_list_struct *datap = sdatap->head;
+ struct mmo_data_list_struct *entry;
+
+ for (; datap != NULL; datap = datap->next)
+ {
+ if (datap->where <= vma
+ && datap->where + datap->size >= vma + size)
+ return datap->data + vma - datap->where;
+ else if (datap->where <= vma
+ && datap->where + datap->allocated_size >= vma + size
+ /* Only munch on the "allocated size" if it does not
+ overlap the next chunk. */
+ && (datap->next == NULL || datap->next->where >= vma + size))
+ {
+ /* There was room allocated, but the size wasn't set to include
+ it. Do that now. */
+ datap->size += (vma + size) - (datap->where + datap->size);
+
+ /* Update the section size. */
+ if (vma + size > sec->vma + sec->_raw_size)
+ sec->_raw_size += (vma + size) - (sec->vma + sec->_raw_size);
+
+ return datap->data + vma - datap->where;
+ }
+ }
+
+ /* Not found; allocate a new block. First check in case we get a
+ request for a size split up over several blocks; we'll have to return
+ NULL for those cases, requesting the caller to split up the request.
+ Requests with an address aligned on MMO_SEC_CONTENTS_CHUNK_SIZE bytes and
+ for no more than MMO_SEC_CONTENTS_CHUNK_SIZE will always get resolved. */
+
+ for (datap = sdatap->head; datap != NULL; datap = datap->next)
+ if ((datap->where <= vma && datap->where + datap->size > vma)
+ || (datap->where < vma + size
+ && datap->where + datap->size >= vma + size))
+ return NULL;
+
+ allocated_size
+ = (size + MMO_SEC_CONTENTS_CHUNK_SIZE - 1) & ~(MMO_SEC_CONTENTS_CHUNK_SIZE - 1);
+ entry = (mmo_data_list_type *)
+ bfd_zalloc (sec->owner, sizeof (mmo_data_list_type) + allocated_size);
+ if (entry == NULL)
+ return false;
+ entry->where = vma;
+ entry->size = size;
+ entry->allocated_size = allocated_size;
+
+ datap = sdatap->head;
+
+ /* Sort the records by address. Optimize for the common case of adding
+ a record to the end of the list. */
+ if (sdatap->tail != NULL && entry->where >= sdatap->tail->where)
+ {
+ sdatap->tail->next = entry;
+ entry->next = NULL;
+ sdatap->tail = entry;
+ }
+ else
+ {
+ mmo_data_list_type **look;
+ for (look = &sdatap->head;
+ *look != NULL && (*look)->where < entry->where;
+ look = &(*look)->next)
+ ;
+ entry->next = *look;
+ *look = entry;
+ if (entry->next == NULL)
+ {
+ sdatap->tail = entry;
+
+ /* We get here for the first time (at other times too) for this
+ section. Say we have contents. */
+ if (! bfd_set_section_flags (sec->owner, sec,
+ bfd_get_section_flags (sec->owner, sec)
+ | SEC_HAS_CONTENTS))
+ return NULL;
+ }
+ }
+
+ /* Update the section size. */
+ if (vma + size > sec->vma + sec->_raw_size)
+ sec->_raw_size += (vma + size) - (sec->vma + sec->_raw_size);
+ return entry->data;
+}
+
+/* Set sizes once we've read in all sections. */
+
+static void
+mmo_map_set_sizes (abfd, sec, ignored)
+ bfd *abfd ATTRIBUTE_UNUSED;
+ asection *sec;
+ PTR ignored ATTRIBUTE_UNUSED;
+{
+ sec->_cooked_size = sec->_raw_size;
+ sec->lma = sec->vma;
+}
+
+/* Read the mmo file and turn it into sections. */
+
+static boolean
+mmo_scan (abfd)
+ bfd *abfd;
+{
+ unsigned int i;
+ unsigned int lineno = 1;
+ boolean error = false;
+ bfd_vma vma = 0;
+ asection *sec = bfd_make_section_old_way (abfd, MMO_TEXT_SECTION_NAME);
+ asection *non_spec_sec = NULL;
+ bfd_vma non_spec_vma = 0;
+ char *current_filename = NULL;
+ bfd_size_type nbytes_read = 0;
+ /* Buffer with room to read a 64-bit value. */
+ bfd_byte buf[8];
+ long stab_loc = -1;
+ char *file_names[256];
+
+ memset (file_names, 0, sizeof (file_names));
+
+ if (bfd_seek (abfd, (file_ptr) 0, SEEK_SET) != 0)
+ goto error_return;
+
+ while ((nbytes_read = bfd_bread (buf, 4, abfd)) == 4)
+ {
+ if (buf[0] == LOP)
+ {
+ unsigned int y = bfd_get_8 (abfd, buf + 2);
+ unsigned int z = bfd_get_8 (abfd, buf + 3);
+
+ /* Change back to the original section for lopcodes other
+ than LOP_QUOTE that comes after a LOP_SPEC. */
+ if ((buf[1] != LOP_QUOTE || y != 0 || z != 1)
+ && non_spec_sec != NULL)
+ {
+ sec = non_spec_sec;
+ vma = non_spec_vma;
+ non_spec_sec = NULL;
+ }
+
+ switch (buf[1])
+ {
+ default:
+ (*_bfd_error_handler)
+ (_("%s: invalid mmo file: unsupported lopcode `%d'\n"),
+ bfd_get_filename (abfd), buf[1]);
+ bfd_set_error (bfd_error_bad_value);
+ goto error_return;
+
+ case LOP_QUOTE:
+ /* Quote the next 32-bit word. */
+ if (y != 0 || z != 1)
+ {
+ (*_bfd_error_handler)
+ (_("%s: invalid mmo file: expected YZ = 1 got YZ = %d for lop_quote\n"),
+ bfd_get_filename (abfd), y*256+z);
+ bfd_set_error (bfd_error_bad_value);
+ goto error_return;
+ }
+ if (bfd_bread (buf, 4, abfd) != 4)
+ goto error_return;
+
+ mmo_xore_32 (sec, vma, bfd_get_32 (abfd, buf));
+ vma += 4;
+ vma &= ~3;
+ lineno++;
+ break;
+
+ case LOP_LOC:
+ /* Set vma (and section). */
+ vma = (bfd_vma) y << 56;
+ if (z == 1)
+ {
+ /* Get a 32-bit value. */
+ if (bfd_bread (buf, 4, abfd) != 4)
+ goto error_return;
+
+ vma += bfd_get_32 (abfd, buf);
+ }
+ else if (z == 2)
+ {
+ /* Get a 64-bit value. */
+ if (bfd_bread (buf, 8, abfd) != 8)
+ goto error_return;
+
+ vma += bfd_get_64 (abfd, buf);
+ }
+ else
+ {
+ (*_bfd_error_handler)
+ (_("%s: invalid mmo file: expected z = 1 or z = 2, got z = %d for lop_loc\n"),
+ bfd_get_filename (abfd), z);
+ bfd_set_error (bfd_error_bad_value);
+ goto error_return;
+ }
+
+ sec = mmo_decide_section (abfd, vma);
+ if (sec == NULL)
+ goto error_return;
+ break;
+
+ case LOP_SKIP:
+ /* Move forward within the same section. */
+ vma += y * 256 + z;
+
+ sec = mmo_decide_section (abfd, vma);
+ if (sec == NULL)
+ goto error_return;
+ break;
+
+ case LOP_FIXO:
+ /* A fixup: Store the current vma somewhere. Position using
+ same format as LOP_LOC. */
+ {
+ bfd_vma p = (bfd_vma) y << 56;
+ asection *fixosec;
+
+ if (z == 1)
+ {
+ /* Get a 32-bit value. */
+ if (bfd_bread (buf, 4, abfd) != 4)
+ goto error_return;
+
+ p += bfd_get_32 (abfd, buf);
+ }
+ else if (z == 2)
+ {
+ /* Get a 64-bit value. */
+ if (bfd_bread (buf, 8, abfd) != 8)
+ goto error_return;
+
+ p += bfd_get_64 (abfd, buf);
+ }
+ else
+ {
+ (*_bfd_error_handler)
+ (_("%s: invalid mmo file: expected z = 1 or z = 2, got z = %d for lop_fixo\n"),
+ bfd_get_filename (abfd), z);
+ bfd_set_error (bfd_error_bad_value);
+ goto error_return;
+ }
+
+ /* The section where we store this address might be a
+ different one than the current section. */
+ fixosec = mmo_decide_section (abfd, p);
+ if (fixosec == NULL)
+ goto error_return;
+ mmo_xore_64 (fixosec, p, vma);
+ }
+ break;
+
+ case LOP_FIXR:
+ /* A fixup: Store YZ of this lopcode into YZ at vma - 4 * yz. */
+ {
+ unsigned int yz = (y * 256 + z);
+ bfd_vma p = vma + 2 - 4 * yz;
+ asection *fixrsec = mmo_decide_section (abfd, p);
+ if (fixrsec == NULL)
+ goto error_return;
+ mmo_xore_16 (fixrsec, p, yz);
+ }
+ break;
+
+ case LOP_FIXRX:
+ /* A fixup, similar to lop_fixr, but taking larger numbers
+ and can change branches into the opposite direction
+ (gasp!). */
+ {
+ bfd_vma delta;
+ bfd_vma p;
+ asection *fixrsec;
+
+ if (y != 0)
+ {
+ (*_bfd_error_handler)
+ (_("%s: invalid mmo file: expected y = 0, got y = %d for lop_fixrx\n"),
+ bfd_get_filename (abfd), y);
+ bfd_set_error (bfd_error_bad_value);
+ goto error_return;
+ }
+
+ if (z != 16 && z != 24)
+ {
+ (*_bfd_error_handler)
+ (_("%s: invalid mmo file: expected z = 16 or z = 24, got z = %d for lop_fixrx\n"),
+ bfd_get_filename (abfd), z);
+ bfd_set_error (bfd_error_bad_value);
+ goto error_return;
+ }
+
+ /* Get the next 32-bit value. */
+ if (bfd_bread (buf, 4, abfd) != 4)
+ goto error_return;
+
+ delta = bfd_get_32 (abfd, buf);
+
+ /* Do an, ehm, involved calculation for the location of
+ the fixup. See mmixal documentation for a verbose
+ explanation. We follow it verbosely here for the
+ readers delight. */
+ if (buf[0] == 0)
+ p = vma - 4 * delta;
+ else if (buf[0] == 1)
+ p = vma - 4 * ((delta & 0xffffff) - (1 << z));
+ else
+ {
+ (*_bfd_error_handler)
+ (_("%s: invalid mmo file: leading byte of operand word must be 0 or 1, got %d for lop_fixrx\n"),
+ bfd_get_filename (abfd), buf[0]);
+ bfd_set_error (bfd_error_bad_value);
+ goto error_return;
+ }
+
+ fixrsec = mmo_decide_section (abfd, vma);
+ if (fixrsec == NULL)
+ goto error_return;
+ mmo_xore_32 (fixrsec, p, delta);
+ }
+ break;
+
+ case LOP_FILE:
+ /* Set current file and perhaps the file name. Reset line
+ number. */
+ if (z != 0)
+ {
+ char *fname = bfd_malloc (z * 4 + 1);
+
+ if (fname == NULL)
+ {
+ (*_bfd_error_handler)
+ (_("%s: cannot allocate file name for file number %d, %d bytes\n"),
+ bfd_get_filename (abfd), y, z * 4 + 1);
+ bfd_set_error (bfd_error_system_call);
+ goto error_return;
+ }
+
+ fname[z * 4] = 0;
+
+ for (i = 0; i < z; i++)
+ {
+ if (bfd_bread (fname + i * 4, 4, abfd) != 4)
+ {
+ free (fname);
+ goto error_return;
+ }
+ }
+
+ if (file_names[y] != NULL)
+ {
+ (*_bfd_error_handler)
+ (_("%s: invalid mmo file: file number %d `%s',\
+ was already entered as `%s'\n"),
+ bfd_get_filename (abfd), y, fname, file_names[y]);
+ bfd_set_error (bfd_error_bad_value);
+ goto error_return;
+ }
+
+ file_names[y] = fname;
+ }
+
+ if (file_names[y] == NULL)
+ {
+ (*_bfd_error_handler)
+ (_("%s: invalid mmo file: file name for number %d\
+ was not specified before use\n"),
+ bfd_get_filename (abfd), y);
+ bfd_set_error (bfd_error_bad_value);
+ goto error_return;
+ }
+
+ current_filename = file_names[y];
+ lineno = 0;
+ break;
+
+ case LOP_LINE:
+ /* Set line number. */
+ lineno = y * 256 + z;
+ /* FIXME: Create a sequence of mmo-specific line number
+ entries for each section, then translate into canonical
+ format. */
+ break;
+
+ case LOP_SPEC:
+ /* Special data follows until the next non-lop_quote
+ lopcode. */
+ non_spec_sec = sec;
+ non_spec_vma = vma;
+ sec = mmo_get_spec_section (abfd, y * 256 + z);
+ if (sec == NULL)
+ goto error_return;
+
+ vma = sec->vma;
+ break;
+
+ case LOP_PRE:
+ {
+ /* We ignore header information, except we read in the
+ creation time from the first 32-bit word with the time
+ in seconds since era. */
+ if (z >= 1
+ && bfd_bread (abfd->tdata.mmo_data->created, 4,
+ abfd) != 4)
+ goto error_return;
+
+ for (i = 1; i < z; i++)
+ if (bfd_bread (buf, 4, abfd) != 4)
+ goto error_return;
+ }
+ break;
+
+ case LOP_POST:
+ /* This tells of the contents of registers $Z..$255 at
+ startup. We make a section out of it, with VMA = Z * 8,
+ but only if Z != 255 or the contents is non-zero. */
+ {
+ asection *rsec;
+ bfd_byte *loc;
+ bfd_vma first_octa;
+ bfd_vma startaddr_octa;
+
+ /* Read first octaword outside loop to simplify logic when
+ excluding the Z == 255, octa == 0 case. */
+ if (bfd_bread (buf, 8, abfd) != 8)
+ goto error_return;
+
+ first_octa = bfd_get_64 (abfd, buf);
+
+ /* Don't emit contents for the trivial case which is
+ always present; $255 pointing to Main. */
+ if (z != 255)
+ {
+ rsec
+ = bfd_make_section_old_way (abfd,
+ MMIX_REG_CONTENTS_SECTION_NAME);
+ rsec->vma = z * 8;
+ loc = mmo_get_loc (rsec, z * 8, (255 - z) * 8);
+ bfd_put_64 (abfd, first_octa, loc);
+
+ for (i = z + 1; i < 255; i++)
+ {
+ if (bfd_bread (loc + (i - z) * 8, 8, abfd) != 8)
+ goto error_return;
+ }
+
+ /* Read out the last octabyte, and use it to set the
+ start address. */
+ if (bfd_bread (buf, 8, abfd) != 8)
+ goto error_return;
+
+ startaddr_octa = bfd_get_64 (abfd, buf);
+ }
+ else
+ startaddr_octa = first_octa;
+
+ if (! bfd_set_start_address (abfd, startaddr_octa))
+ {
+ /* Currently this can't fail, but this should handle
+ future failures. */
+ bfd_set_error (bfd_error_bad_value);
+ goto error_return;
+ }
+ }
+ break;
+
+ case LOP_STAB:
+ /* We read in the symbols now, not later. */
+ if (y != 0 || z != 0)
+ {
+ (*_bfd_error_handler)
+ (_("%s: invalid mmo file: fields y and z of lop_stab\
+ non-zero, y: %d, z: %d\n"),
+ bfd_get_filename (abfd), y, z);
+ bfd_set_error (bfd_error_bad_value);
+ goto error_return;
+ }
+
+ /* Save the location, so we can check that YZ in the LOP_END
+ is correct. */
+ stab_loc = bfd_tell (abfd);
+
+ /* It's not said that an MMO can be without symbols (though
+ mmixal will refuse to assemble files without Main), but
+ it seems it would still be a valid mmo-file, so allow it.
+ We detect the absence of a symbol area in that the upper
+ limit is computed (from the lop_end YZ field) as 0.
+ Don't call mmo_get_symbols; it can only detect the end of
+ a valid symbol trie, not the absence of one. */
+ if (abfd->tdata.mmo_data->max_symbol_length != 0
+ && ! mmo_get_symbols (abfd))
+ goto error_return;
+ break;
+
+ case LOP_END:
+ {
+ /* This must be the last 32-bit word in an mmo file.
+ Let's find out. */
+ struct stat statbuf;
+ long curpos = bfd_tell (abfd);
+
+ if (bfd_stat (abfd, &statbuf) < 0)
+ goto error_return;
+
+ if (statbuf.st_size != curpos)
+ {
+ (*_bfd_error_handler)
+ (_("%s: invalid mmo file: lop_end not last item in\
+ file\n"),
+ bfd_get_filename (abfd));
+ bfd_set_error (bfd_error_bad_value);
+ goto error_return;
+ }
+
+ /* Check that the YZ field is right. Subtract the size of
+ this LOP_END in the calculation; YZ does not include
+ it. */
+ if ((long) (y * 256 + z) * 4 != (curpos - stab_loc) - 4)
+ {
+ (*_bfd_error_handler)
+ (_("%s: invalid mmo file: YZ of lop_end (%ld)\
+ not equal to the number of tetras to the preceding lop_stab (%ld)\n"),
+ bfd_get_filename (abfd), (long) (y * 256 + z),
+ (curpos - stab_loc - 4)/4);
+ bfd_set_error (bfd_error_bad_value);
+ goto error_return;
+ }
+
+ bfd_map_over_sections (abfd, mmo_map_set_sizes, NULL);
+ goto done;
+ }
+ }
+ }
+ else
+ {
+ /* This wasn't a lopcode, so store it in the current section. */
+ mmo_xore_32 (sec, vma & ~3, bfd_get_32 (abfd, buf));
+ vma += 4;
+ vma &= ~3;
+ lineno++;
+ }
+ }
+
+ /* We know this file is a multiple of four bytes (checked in
+ mmo_object_p), so if we got something other than 0, this was a bad
+ file (although it's more likely we'll get 0 in that case too).
+ If we got end-of-file, then there was no lop_stab, so the file has
+ invalid format. */
+
+ if (nbytes_read != 0)
+ bfd_set_error (bfd_error_system_call);
+ else
+ bfd_set_error (bfd_error_bad_value);
+
+ error_return:
+ error = true;
+ done:
+ /* Mark the .text and .data section with their normal attribute if they
+ contain anything. This is not redundant wrt. mmo_decide_section,
+ since that code might never execute, and conversely the alloc+code
+ section flags must be set then. */
+ sec = bfd_get_section_by_name (abfd, MMO_TEXT_SECTION_NAME);
+ if (sec != NULL
+ && (bfd_get_section_flags (abfd, sec) & SEC_HAS_CONTENTS)
+ && ! bfd_set_section_flags (abfd, sec,
+ bfd_get_section_flags (abfd, sec)
+ | SEC_ALLOC | SEC_LOAD | SEC_CODE))
+ error = true;
+
+ sec = bfd_get_section_by_name (abfd, MMO_DATA_SECTION_NAME);
+ if (sec != NULL
+ && (bfd_get_section_flags (abfd, sec) & SEC_HAS_CONTENTS)
+ && ! bfd_set_section_flags (abfd, sec,
+ bfd_get_section_flags (abfd, sec)
+ | SEC_ALLOC | SEC_LOAD))
+ error = true;
+
+ /* Free whatever resources we took. */
+ for (i = 0; i < sizeof (file_names) / sizeof (file_names[0]); i++)
+ if (file_names[i])
+ free (file_names[i]);
+ return error ? false : true;
+}
+
+/* A hook to set up object file dependent section information. For mmo,
+ we point out the shape of allocated section contents. */
+
+static boolean
+mmo_new_section_hook (abfd, newsect)
+ bfd *abfd ATTRIBUTE_UNUSED;
+ asection *newsect;
+{
+ /* We zero-fill all fields and assume NULL is represented by an all
+ zero-bit pattern. */
+ newsect->used_by_bfd =
+ (PTR) bfd_zalloc (abfd, sizeof (struct mmo_section_data_struct));
+
+ if (!newsect->used_by_bfd)
+ return false;
+
+ /* Always align to at least 32-bit words. */
+ newsect->alignment_power = 2;
+ return true;
+}
+
+/* We already have section contents loaded for sections that have
+ contents. */
+
+static boolean
+mmo_get_section_contents (abfd, sec, location, offset, bytes_to_do)
+ bfd *abfd ATTRIBUTE_UNUSED;
+ asection *sec ATTRIBUTE_UNUSED;
+ PTR location ATTRIBUTE_UNUSED;
+ file_ptr offset ATTRIBUTE_UNUSED;
+ bfd_size_type bytes_to_do ATTRIBUTE_UNUSED;
+{
+ /* Iterate over diminishing chunk sizes, copying contents, like
+ mmo_set_section_contents. */
+ while (bytes_to_do)
+ {
+ /* A minor song-and-dance to make sure we're not bitten by the
+ distant possibility of the cast from bfd_vma to int making the
+ chunk zero-sized. */
+ int chunk_size
+ = (int) bytes_to_do != 0 ? bytes_to_do : MMO_SEC_CONTENTS_CHUNK_SIZE;
+ bfd_byte *loc;
+
+ do
+ loc = mmo_get_loc (sec, sec->vma + offset, chunk_size);
+ while (loc == NULL && (chunk_size /= 2) != 0);
+
+ if (chunk_size == 0)
+ return false;
+
+ memcpy (location, loc, chunk_size);
+
+ location += chunk_size;
+ bytes_to_do -= chunk_size;
+ offset += chunk_size;
+ }
+ return true;
+}
+
+/* Return the amount of memory needed to read the symbol table. */
+
+static long
+mmo_get_symtab_upper_bound (abfd)
+ bfd *abfd ATTRIBUTE_UNUSED;
+{
+ return (abfd->symcount + 1) * sizeof (asymbol *);
+}
+
+/* Sort mmo symbols by serial number. */
+
+static int
+mmo_sort_mmo_symbols (arg1, arg2)
+ CONST PTR arg1;
+ CONST PTR arg2;
+{
+ CONST struct mmo_symbol *sym1 = *(CONST struct mmo_symbol **) arg1;
+ CONST struct mmo_symbol *sym2 = *(CONST struct mmo_symbol **) arg2;
+
+ /* Sort by serial number first. */
+ if (sym1->serno < sym2->serno)
+ return -1;
+ else if (sym1->serno > sym2->serno)
+ return 1;
+
+ /* Then sort by address of the table entries. */
+ return ((CONST char *) arg1 - (CONST char *) arg2);
+}
+
+/* Translate the symbol table. */
+
+static long
+mmo_get_symtab (abfd, alocation)
+ bfd *abfd;
+ asymbol **alocation;
+{
+ unsigned int symcount = bfd_get_symcount (abfd);
+ asymbol *csymbols;
+ unsigned int i;
+
+ csymbols = abfd->tdata.mmo_data->csymbols;
+ if (csymbols == NULL)
+ {
+ asymbol *c;
+ struct mmo_symbol *s;
+ struct mmo_symbol **msp;
+
+ /* First we store the symbols into the table we'll return, then we
+ qsort it on the serial number, with secondary on the address of
+ the symbol, to preserve order if there would be non-unique serial
+ numbers. */
+ for (s = abfd->tdata.mmo_data->symbols,
+ msp = (struct mmo_symbol **) alocation;
+ s != NULL;
+ s = s->next, ++msp)
+ *msp = s;
+
+ *msp = NULL;
+
+ qsort (alocation, symcount, sizeof (struct mmo_symbol *),
+ mmo_sort_mmo_symbols);
+
+ csymbols = (asymbol *) bfd_alloc (abfd, symcount * sizeof (asymbol));
+ if (csymbols == NULL && symcount != 0)
+ return false;
+ abfd->tdata.mmo_data->csymbols = csymbols;
+
+ for (msp = (struct mmo_symbol **) alocation, c = csymbols;
+ *msp != NULL;
+ msp++, ++c)
+ {
+ s = *msp;
+ c->the_bfd = abfd;
+ c->name = s->name;
+ c->value = s->value;
+ c->flags = BSF_GLOBAL;
+
+ if (s->sym_type == mmo_data_sym)
+ {
+ c->section
+ = bfd_get_section_by_name (abfd, MMO_DATA_SECTION_NAME);
+
+ if (c->section == NULL)
+ c->section = bfd_abs_section_ptr;
+ else
+ c->value -= c->section->vma;
+ }
+ else if (s->sym_type == mmo_undef_sym)
+ c->section = bfd_und_section_ptr;
+ else if (s->sym_type == mmo_reg_sym)
+ {
+ c->section
+ = bfd_make_section_old_way (abfd, MMIX_REG_SECTION_NAME);
+ }
+ else
+ {
+ asection *textsec
+ = bfd_get_section_by_name (abfd, MMO_TEXT_SECTION_NAME);
+
+ if (textsec != NULL
+ && c->value >= textsec->vma
+ && c->value <= textsec->vma + textsec->_cooked_size)
+ {
+ c->section = textsec;
+ c->value -= c->section->vma;
+ }
+ else
+ c->section = bfd_abs_section_ptr;
+ }
+
+ c->udata.p = NULL;
+ }
+ }
+
+ /* Last, overwrite the incoming table with the right-type entries. */
+ for (i = 0; i < symcount; i++)
+ *alocation++ = csymbols++;
+ *alocation = NULL;
+
+ return symcount;
+}
+
+/* Make an empty symbol. */
+
+static asymbol *
+mmo_make_empty_symbol (abfd)
+ bfd *abfd;
+{
+ asymbol *new = (asymbol *) bfd_zalloc (abfd, sizeof (asymbol));
+
+ if (new)
+ new->the_bfd = abfd;
+ return new;
+}
+
+/* Get information about a symbol. */
+
+static void
+mmo_get_symbol_info (ignore_abfd, symbol, ret)
+ bfd *ignore_abfd ATTRIBUTE_UNUSED;
+ asymbol *symbol;
+ symbol_info *ret;
+{
+ bfd_symbol_info (symbol, ret);
+}
+
+static void
+mmo_print_symbol (abfd, afile, symbol, how)
+ bfd *abfd;
+ PTR afile;
+ asymbol *symbol;
+ bfd_print_symbol_type how;
+{
+ FILE *file = (FILE *) afile;
+
+ switch (how)
+ {
+ case bfd_print_symbol_name:
+ fprintf (file, "%s", symbol->name);
+ break;
+ default:
+ bfd_print_symbol_vandf (abfd, (PTR) file, symbol);
+
+ fprintf (file, " %-5s %s",
+ symbol->section->name,
+ symbol->name);
+ }
+}
+
+/* We can't map a file directly into executable code, so the
+ size of header information is irrelevant. */
+
+static int
+mmo_sizeof_headers (abfd, exec)
+ bfd *abfd ATTRIBUTE_UNUSED;
+ boolean exec ATTRIBUTE_UNUSED;
+{
+ return 0;
+}
+
+/* Write the (section-neutral) file preamble. */
+
+static boolean
+mmo_internal_write_header (abfd)
+ bfd *abfd;
+{
+ CONST char lop_pre_bfd[] = { LOP, LOP_PRE, 1, 1};
+
+ if (bfd_bwrite (lop_pre_bfd, 4, abfd) != 4)
+ return false;
+
+ /* Copy creation time of original file. */
+ if (bfd_bwrite (abfd->tdata.mmo_data->created, 4, abfd) != 4)
+ return false;
+
+ return true;
+}
+
+/* Write the LOP_POST record, with global register initializations.
+ Z is the Z field of the LOP_POST, corresponding to 255 - number of
+ registers at DATA. The Z = 255 field is filled in with the
+ start-address. */
+
+static boolean
+mmo_internal_write_post (abfd, z, sec)
+ bfd *abfd;
+ int z;
+ asection *sec;
+{
+ int i;
+ bfd_byte buf[8];
+ mmo_write_tetra_raw (abfd, (LOP << 24) | (LOP_POST << 16) | z);
+
+ for (i = z; i < 255; i++)
+ {
+ bfd_byte *data = mmo_get_loc (sec, i * 8, 8);
+
+ if (bfd_bwrite (data, 8, abfd) != 8)
+ return false;
+ }
+
+ /* For Z == $255, we always emit the start location; supposedly Main,
+ but we have it handy at bfd_get_start_address. If we're called with
+ Z == 255, don't assume DATA is valid. */
+ bfd_put_64 (abfd, bfd_get_start_address (abfd), buf);
+
+ return
+ abfd->tdata.mmo_data->have_error == false
+ && bfd_bwrite (buf, 8, abfd) == 8;
+}
+
+/* Translate to and from BFD flags. This is to make sure that we don't
+ get bitten by BFD flag number changes. */
+
+static flagword
+mmo_sec_flags_from_bfd_flags (flags)
+ flagword flags;
+{
+ flagword oflags = 0;
+
+ if (flags & SEC_ALLOC)
+ oflags |= MMO_SEC_ALLOC;
+ if (flags & SEC_LOAD)
+ oflags |= MMO_SEC_LOAD;
+ if (flags & SEC_RELOC)
+ oflags |= MMO_SEC_RELOC;
+ if (flags & SEC_READONLY)
+ oflags |= MMO_SEC_READONLY;
+ if (flags & SEC_CODE)
+ oflags |= MMO_SEC_CODE;
+ if (flags & SEC_DATA)
+ oflags |= MMO_SEC_DATA;
+ if (flags & SEC_NEVER_LOAD)
+ oflags |= MMO_SEC_NEVER_LOAD;
+ if (flags & SEC_IS_COMMON)
+ oflags |= MMO_SEC_IS_COMMON;
+ if (flags & SEC_DEBUGGING)
+ oflags |= MMO_SEC_DEBUGGING;
+
+ return oflags;
+}
+
+static flagword
+bfd_sec_flags_from_mmo_flags (flags)
+ flagword flags;
+{
+ flagword oflags = 0;
+
+ if (flags & MMO_SEC_ALLOC)
+ oflags |= SEC_ALLOC;
+ if (flags & MMO_SEC_LOAD)
+ oflags |= SEC_LOAD;
+ if (flags & MMO_SEC_RELOC)
+ oflags |= SEC_RELOC;
+ if (flags & MMO_SEC_READONLY)
+ oflags |= SEC_READONLY;
+ if (flags & MMO_SEC_CODE)
+ oflags |= SEC_CODE;
+ if (flags & MMO_SEC_DATA)
+ oflags |= SEC_DATA;
+ if (flags & MMO_SEC_NEVER_LOAD)
+ oflags |= SEC_NEVER_LOAD;
+ if (flags & MMO_SEC_IS_COMMON)
+ oflags |= SEC_IS_COMMON;
+ if (flags & MMO_SEC_DEBUGGING)
+ oflags |= SEC_DEBUGGING;
+
+ return oflags;
+}
+
+/* Write a section. */
+
+static boolean
+mmo_internal_write_section (abfd, sec)
+ bfd *abfd;
+ asection *sec;
+{
+ /* We do it differently depending on what section this is:
+
+ ".text": Output, prepended by information about the first source file
+ (not yet implemented.)
+
+ ".data": Output.
+
+ (".MMIX.reg_contents": Not handled here.)
+
+ Anything else: Output inside a lop_spec 80, in the format described
+ above. */
+
+ if (strcmp (sec->name, MMO_TEXT_SECTION_NAME) == 0)
+ /* FIXME: Output source file name and line number. */
+ return
+ mmo_write_loc_chunk_list (abfd,
+ ((struct mmo_section_data_struct *)
+ (sec->used_by_bfd))->head);
+ else if (strcmp (sec->name, MMO_DATA_SECTION_NAME) == 0)
+ return
+ mmo_write_loc_chunk_list (abfd,
+ ((struct mmo_section_data_struct *)
+ (sec->used_by_bfd))->head);
+ else if (strcmp (sec->name, MMIX_REG_CONTENTS_SECTION_NAME) == 0)
+ /* Not handled here. */
+ {
+ /* This would normally be an abort call since this can't happen, but
+ we don't do that. */
+ bfd_set_error (bfd_error_bad_value);
+ return false;
+ }
+ else if (strncmp (sec->name, MMIX_OTHER_SPEC_SECTION_PREFIX,
+ strlen (MMIX_OTHER_SPEC_SECTION_PREFIX)) == 0)
+ {
+ int n = atoi (sec->name + strlen (MMIX_OTHER_SPEC_SECTION_PREFIX));
+ mmo_write_tetra_raw (abfd, (LOP << 24) | (LOP_SPEC << 16) | n);
+ return
+ abfd->tdata.mmo_data->have_error == false
+ && mmo_write_chunk_list (abfd,
+ ((struct mmo_section_data_struct *)
+ (sec->used_by_bfd))->head);
+ }
+ /* Ignore sections that are just allocated or empty; we write out
+ _contents_ here. */
+ else if ((bfd_get_section_flags (abfd, sec) & SEC_HAS_CONTENTS) != 0
+ && sec->_raw_size != 0)
+ {
+ /* Keep the document-comment formatted the way it is. */
+/*
+INODE
+mmo section mapping, , Symbol-table, mmo
+SUBSECTION
+ mmo section mapping
+
+ The implementation in BFD uses special data type 80 (decimal) to
+ encapsulate and describe named sections, containing e.g.@: debug
+ information. If needed, any datum in the encapsulation will be
+ quoted using lop_quote. First comes a 32-bit word holding the
+ number of 32-bit words containing the zero-terminated zero-padded
+ segment name. After the name there's a 32-bit word holding flags
+ describing the section type. Then comes a 64-bit big-endian word
+ with the section length (in bytes), then another with the section
+ start address. Depending on the type of section, the contents
+ might follow, zero-padded to 32-bit boundary. For a loadable
+ section (such as data or code), the contents might follow at some
+ later point, not necessarily immediately, as a lop_loc with the
+ same start address as in the section description, followed by the
+ contents. This in effect forms a descriptor that must be emitted
+ before the actual contents. Sections described this way must not
+ overlap.
+
+ For areas that don't have such descriptors, synthetic sections are
+ formed by BFD. Consecutive contents in the two memory areas
+ @samp{0x0000@dots{}00} to @samp{0x01ff@dots{}ff} and
+ @samp{0x2000@dots{}00} to @samp{0x20ff@dots{}ff} are entered in
+ sections named <<.text>> and <<.data>> respectively. If an area
+ is not otherwise described, but would together with a neighboring
+ lower area be less than @samp{0x40000000} bytes long, it is joined
+ with the lower area and the gap is zero-filled. For other cases,
+ a new section is formed, named <<.MMIX.sec.@var{n}>>. Here,
+ @var{n} is a number, a running count through the mmo file,
+ starting at 0.
+
+EXAMPLE
+ A loadable section specified as:
+
+| .section secname,"ax"
+| TETRA 1,2,3,4,-1,-2009
+| BYTE 80
+
+ and linked to address @samp{0x4}, is represented by the sequence:
+
+| 0x98080050 - lop_spec 80
+| 0x00000002 - two 32-bit words for the section name
+| 0x7365636e - "secn"
+| 0x616d6500 - "ame\0"
+| 0x00000033 - flags CODE, READONLY, LOAD, ALLOC
+| 0x00000000 - high 32 bits of section length
+| 0x0000001c - section length is 28 bytes; 6 * 4 + 1 + alignment to 32 bits
+| 0x00000000 - high 32 bits of section address
+| 0x00000004 - section address is 4
+| 0x98010002 - 64 bits with address of following data
+| 0x00000000 - high 64 bits of address
+| 0x00000004 - data starts at address 4
+| 0x00000001 - 1
+| 0x00000002 - 2
+| 0x00000003 - 3
+| 0x00000004 - 4
+| 0xffffffff - -1
+| 0xfffff827 - -2009
+| 0x50000000 - 80 as a byte, padded with zeros.
+
+ Note that the lop_spec wrapping does not include the section
+ contents. Compare this to a non-loaded section specified as:
+
+| .section thirdsec
+| TETRA 200001,100002
+| BYTE 38,40
+
+ This, when linked to address @samp{0x200000000000001c}, is
+ represented by:
+
+| 0x98080050 - lop_spec 80
+| 0x00000002 - two 32-bit words for the section name
+| 0x7365636e - "thir"
+| 0x616d6500 - "dsec"
+| 0x00000010 - flag READONLY
+| 0x00000000 - high 32 bits of section length
+| 0x0000000c - section length is 12 bytes; 2 * 4 + 2 + alignment to 32 bits
+| 0x20000000 - high 64 bits of address
+| 0x0000001c - low 64 bits of address 0x200000000000001c
+| 0x00030d41 - 200001
+| 0x000186a2 - 100002
+| 0x26280000 - 38, 40 as bytes, padded with zeros
+
+ For the latter example, the section contents must not to appear
+ loaded in memory, and is therefore specified as part of the
+ special data. The address is usually unimportant but might
+ provide information for e.g.@: the DWARF 2 debugging format. */
+
+ mmo_write_tetra_raw (abfd, LOP_SPEC_SECTION);
+ mmo_write_tetra (abfd, (strlen (sec->name) + 3) / 4);
+ mmo_write_chunk (abfd, sec->name, strlen (sec->name));
+ /* FIXME: We can get debug sections (.debug_line & Co.) with a
+ section flag still having SEC_RELOC set. Investigate. This
+ might be true for all alien sections; perhaps mmo.em should clear
+ that flag. Might be related to weak references. */
+ mmo_write_tetra (abfd,
+ mmo_sec_flags_from_bfd_flags
+ (bfd_get_section_flags (abfd, sec)));
+ mmo_write_octa (abfd, sec->_raw_size);
+ mmo_write_octa (abfd, bfd_get_section_vma (abfd, sec));
+
+ /* Writing a LOP_LOC ends the LOP_SPEC data, and makes data actually
+ loaded. */
+ if (bfd_get_section_flags (abfd, sec) & SEC_LOAD)
+ return
+ abfd->tdata.mmo_data->have_error == false
+ && mmo_write_loc_chunk_list (abfd,
+ ((struct mmo_section_data_struct *)
+ (sec->used_by_bfd))->head);
+ return
+ abfd->tdata.mmo_data->have_error == false
+ && mmo_write_chunk_list (abfd,
+ ((struct mmo_section_data_struct *)
+ (sec->used_by_bfd))->head);
+ }
+ return true;
+}
+
+/* We save up all data before output. */
+
+static boolean
+mmo_set_section_contents (abfd, sec, location, offset, bytes_to_do)
+ bfd *abfd ATTRIBUTE_UNUSED;
+ sec_ptr sec;
+ PTR location;
+ file_ptr offset;
+ bfd_size_type bytes_to_do;
+{
+ /* Iterate over diminishing chunk sizes, copying contents. */
+ while (bytes_to_do)
+ {
+ /* A minor song-and-dance to make sure we're not bitten by the
+ distant possibility of the cast from bfd_vma to int making the
+ chunk zero-sized. */
+ int chunk_size
+ = (int) bytes_to_do != 0 ? bytes_to_do : MMO_SEC_CONTENTS_CHUNK_SIZE;
+ bfd_byte *loc;
+
+ do
+ loc = mmo_get_loc (sec, sec->vma + offset, chunk_size);
+ while (loc == NULL && (chunk_size /= 2) != 0);
+
+ if (chunk_size == 0)
+ return false;
+
+ memcpy (loc, location, chunk_size);
+
+ location += chunk_size;
+ bytes_to_do -= chunk_size;
+ offset += chunk_size;
+ }
+ return true;
+}
+
+/* Add a symbol to a trie-tree. */
+
+static boolean
+mmo_internal_add_3_sym (abfd, rootp, symp)
+ bfd *abfd;
+ struct mmo_symbol_trie *rootp;
+ CONST struct mmo_symbol *symp;
+{
+ CONST char *name = symp->name;
+ struct mmo_symbol_trie *trie = rootp;
+ struct mmo_symbol_trie **triep = NULL;
+
+ while (*name && trie != NULL)
+ {
+ if (*name < trie->symchar)
+ {
+ triep = &trie->left;
+ trie = trie->left;
+ }
+ else if (*name > trie->symchar)
+ {
+ triep = &trie->right;
+ trie = trie->right;
+ }
+ else if (*name == trie->symchar)
+ {
+ triep = &trie->middle;
+ name++;
+
+ /* Make sure "trie" points to where we should fill in the
+ current symbol whenever we've iterated through "name". We
+ would lose the right position if we encounter "foobar" then
+ "foo". */
+ if (*name)
+ trie = trie->middle;
+ }
+ }
+
+ while (*name != 0)
+ {
+ /* Create middle branches for the rest of the characters. */
+ trie = bfd_zalloc (abfd, sizeof (struct mmo_symbol_trie));
+ *triep = trie;
+ trie->symchar = *name++;
+ triep = &trie->middle;
+ }
+
+ /* We discover a duplicate symbol rather late in the process, but still;
+ we discover it and bail out. */
+ if (trie->sym.name != NULL)
+ {
+ (*_bfd_error_handler)
+ (_("%s: invalid symbol table: duplicate symbol `%s'\n"),
+ bfd_get_filename (abfd), trie->sym.name);
+ bfd_set_error (bfd_error_bad_value);
+ return false;
+ }
+
+ memcpy (&trie->sym, symp, sizeof *symp);
+ return true;
+}
+
+/* Find out the length of the serialized version of a trie in bytes. */
+
+static unsigned int
+mmo_internal_3_length (abfd, trie)
+ bfd *abfd;
+ struct mmo_symbol_trie *trie;
+{
+ /* First, one for the control byte. */
+ unsigned int length = 1;
+
+ if (trie == NULL)
+ return 0;
+
+ /* Add in the recursion to the left. */
+ length += mmo_internal_3_length (abfd, trie->left);
+
+ /* Add in the middle trie and the character. */
+ length += 1 + mmo_internal_3_length (abfd, trie->middle);
+
+ /* Add in the recursion to the right. */
+ length += mmo_internal_3_length (abfd, trie->right);
+
+ /* Add in bytes for the symbol (if this is an endnode). */
+ if (trie->sym.name != NULL)
+ {
+ unsigned int serno = trie->sym.serno;
+
+ /* First what it takes to encode the value. */
+ if (trie->sym.sym_type == mmo_reg_sym)
+ length++;
+ else if (trie->sym.sym_type == mmo_undef_sym)
+ length += 2;
+ else
+ {
+ bfd_vma value = trie->sym.value;
+
+ /* Coded in one to eight following bytes. */
+ if (trie->sym.sym_type == mmo_data_sym)
+ value -= (bfd_vma) 0x20 << 56;
+
+ do
+ {
+ value >>= 8;
+ length++;
+ }
+ while (value != 0);
+ }
+
+ /* Find out what it takes to encode the serial number. */
+ do
+ {
+ serno >>= 7;
+ length++;
+ }
+ while (serno != 0);
+ }
+
+ return length;
+}
+
+/* Helper function for outputting the serial number of a symbol, output as
+ a variant of leb128 (see dwarf2 documentation) which could be called
+ beb128. Using a helper function and recursion simplifies debugging. */
+
+static void
+mmo_beb128_out (abfd, serno, marker)
+ bfd *abfd;
+ int serno;
+ int marker;
+{
+ if (serno & ~0x7f)
+ mmo_beb128_out (abfd, serno >> 7, 0);
+ mmo_write_byte (abfd, marker | (serno & 0x7f));
+}
+
+/* Serialize a trie. */
+
+static void
+mmo_internal_3_dump (abfd, trie)
+ bfd *abfd;
+ struct mmo_symbol_trie *trie;
+{
+ bfd_byte control = 0;
+
+ if (trie == NULL)
+ return;
+
+ if (trie->left)
+ control |= MMO3_LEFT;
+
+ if (trie->middle)
+ control |= MMO3_MIDDLE;
+
+ if (trie->right)
+ control |= MMO3_RIGHT;
+
+ if (trie->sym.name != NULL)
+ {
+ /* Encode the symbol type and length of value bytes. */
+ if (trie->sym.sym_type == mmo_reg_sym)
+ control |= MMO3_REGQUAL_BITS;
+ else if (trie->sym.sym_type == mmo_undef_sym)
+ control |= MMO3_UNDEF;
+ else
+ {
+ bfd_vma value = trie->sym.value;
+
+ /* Coded in 1..8 following bytes. */
+ if (trie->sym.sym_type == mmo_data_sym)
+ {
+ control |= MMO3_DATA;
+ value -= (bfd_vma) 0x20 << 56;
+ }
+
+ do
+ {
+ value >>= 8;
+ control++;
+ }
+ while (value != 0);
+ }
+ }
+
+ /* The control byte is output before recursing. */
+ mmo_write_byte (abfd, control);
+
+ mmo_internal_3_dump (abfd, trie->left);
+
+ if (control & MMO3_SYMBITS)
+ {
+ mmo_write_byte (abfd, trie->symchar);
+
+ if (trie->sym.name != NULL)
+ {
+ if (trie->sym.sym_type == mmo_reg_sym)
+ mmo_write_byte (abfd, trie->sym.value);
+ else if (trie->sym.sym_type == mmo_undef_sym)
+ {
+ mmo_write_byte (abfd, 0);
+ mmo_write_byte (abfd, 0);
+ }
+ else
+ {
+ bfd_vma value = trie->sym.value;
+
+ bfd_byte byte_n = control & 15;
+
+ /* Coded in 1..8 following bytes. Note that the value is
+ shifted out big-endian. */
+ if (trie->sym.sym_type == mmo_data_sym)
+ {
+ value -= (bfd_vma) 0x20 << 56;
+ byte_n -= 8;
+ }
+
+ do
+ {
+ mmo_write_byte (abfd, (value >> ((byte_n - 1) * 8)) & 0xff);
+ byte_n--;
+ }
+ while (byte_n != 0);
+ }
+
+ mmo_beb128_out (abfd, trie->sym.serno, 128);
+ }
+ mmo_internal_3_dump (abfd, trie->middle);
+ }
+ mmo_internal_3_dump (abfd, trie->right);
+}
+
+/* Write symbols, either in mmo format or hidden in a lop_spec 80 section.
+ Write the lop_end terminator also. */
+
+static boolean
+mmo_write_symbols_and_terminator (abfd)
+ bfd *abfd;
+{
+ int count = bfd_get_symcount (abfd);
+ asymbol *fakemain[2];
+ asymbol **table;
+ int serno = 2;
+ struct mmo_symbol_trie root;
+ int trie_len;
+ int i;
+ bfd_byte buf[4];
+
+ /* Create a symbol for "Main". */
+ asymbol *mainsym = bfd_make_empty_symbol (abfd);
+
+ mainsym->flags = BSF_GLOBAL;
+ mainsym->value = bfd_get_start_address (abfd);
+ mainsym->name = MMIX_START_SYMBOL_NAME;
+ mainsym->section = bfd_abs_section_ptr;
+ fakemain[0] = mainsym;
+ fakemain[1] = NULL;
+
+ memset (&root, 0, sizeof (root));
+
+ /* Make all symbols take a left turn. */
+ root.symchar = 0xff;
+
+ /* There must always be a ":Main", so we'll add one
+ if there are no symbols. */
+ if (count == 0)
+ {
+ table = fakemain;
+ count = 1;
+ }
+ else
+ table = bfd_get_outsymbols (abfd);
+
+ for (i = 0; i < count && table[i] != NULL; i++)
+ {
+ asymbol *s = table[i];
+
+ /* It's not enough to consult bfd_is_local_label, since it does not
+ mean "local" in the sense of linkable-and-observable-after-link.
+ Let's just check the BSF_GLOBAL flag.
+
+ Also, don't export symbols with characters not in the allowed set. */
+ if ((s->flags & (BSF_DEBUGGING|BSF_GLOBAL)) == BSF_GLOBAL
+ && strspn (s->name,
+ valid_mmo_symbol_character_set) == strlen (s->name))
+ {
+ struct mmo_symbol sym;
+ memset (&sym, 0, sizeof (sym));
+
+ sym.name = s->name;
+ sym.value =
+ s->value
+ + s->section->output_section->vma
+ + s->section->output_offset;
+
+ if (bfd_is_und_section (s->section))
+ sym.sym_type = mmo_undef_sym;
+ else if (strcmp (s->section->name, MMO_DATA_SECTION_NAME) == 0
+ /* The encoding of data symbols require that the "rest"
+ of the value fits in 6 bytes, so the upper two bytes
+ must be 0x2000. All other symbols get to be the
+ absolute type. */
+ && (sym.value >> 48) == 0x2000)
+ sym.sym_type = mmo_data_sym;
+ else if (strcmp (s->section->name, MMIX_REG_SECTION_NAME) == 0)
+ sym.sym_type = mmo_reg_sym;
+ else if (strcmp (s->section->name,
+ MMIX_REG_CONTENTS_SECTION_NAME) == 0)
+ {
+ sym.sym_type = mmo_reg_sym;
+ sym.value /= 8;
+ }
+ else
+ sym.sym_type = mmo_abs_sym;
+
+ /* FIXME: We assume the order of the received symbols is an
+ ordered mapping of the serial numbers. This is not
+ necessarily true if we e.g. objcopy a mmo file to another and
+ there are gaps in the numbering. Note sure if this can
+ happen. Not sure what to do. */
+ /* Make sure Main has serial number 1; others start at 2. */
+ if (strcmp (s->name, MMIX_START_SYMBOL_NAME) == 0)
+ {
+ sym.serno = 1;
+
+ /* Check that the value assigned to :Main is the same as the
+ entry address. The default linker script asserts this.
+ This is as good a place as any to check this consistency. */
+ if (sym.value != bfd_get_start_address (abfd))
+ {
+ /* Arbitrary buffer to hold the printable representation
+ of a vma. */
+ char vmas_main[40];
+ char vmas_start[40];
+ bfd_vma vma_start = bfd_get_start_address (abfd);
+
+ sprintf_vma (vmas_main, s->value);
+ sprintf_vma (vmas_start, vma_start);
+
+ (*_bfd_error_handler)
+ (_("%s: Bad symbol definition: `Main' set to %s rather\
+ than the start address %s\n"),
+ bfd_get_filename (abfd), vmas_main, vmas_start);
+ bfd_set_error (bfd_error_bad_value);
+ return false;
+ }
+ }
+ else
+ sym.serno = serno++;
+
+ if (! mmo_internal_add_3_sym (abfd, &root, &sym))
+ return false;
+ }
+ }
+
+ /* Change the root node to be a ":"-prefix. */
+ root.symchar = ':';
+ root.middle = root.left;
+ root.right = NULL;
+ root.left = NULL;
+
+ /* We have to find out if we can fit the whole symbol table in the mmo
+ symtab. It would be bad to assume we can always fit it in 262144
+ bytes. If we can't, just leave the Main symbol. */
+ trie_len = (mmo_internal_3_length (abfd, &root) + 3)/4;
+
+ if (trie_len > 0xffff)
+ {
+ /* Test this code by using a lower limit in the test above and check
+ that the single "Main" symbol is emitted and handled properly.
+ There's no specific test-case. */
+ struct mmo_symbol sym;
+
+ (*_bfd_error_handler)
+ (_("%s: warning: symbol table too large for mmo, larger than 65535\
+ 32-bit words: %d. Only `Main' will be emitted.\n"),
+ bfd_get_filename (abfd), trie_len);
+
+ memset (&sym, 0, sizeof (sym));
+ sym.sym_type = mmo_abs_sym;
+ sym.name = MMIX_START_SYMBOL_NAME;
+ sym.serno = 1;
+ sym.value = bfd_get_start_address (abfd);
+
+ /* Then patch up a symbol table to be just the ":Main" symbol. */
+ memset (&root, 0, sizeof (root));
+ root.left = root.middle;
+ root.symchar = 0xff;
+ root.middle = NULL;
+ root.right = NULL;
+
+ if (! mmo_internal_add_3_sym (abfd, &root, &sym))
+ return false;
+
+ root.symchar = ':';
+ root.middle = root.left;
+ root.right = NULL;
+ root.left = NULL;
+
+ trie_len = (mmo_internal_3_length (abfd, &root) + 3)/4;
+ }
+
+ /* Reset the written-bytes counter. */
+ abfd->tdata.mmo_data->byte_no = 0;
+
+ /* Put out the lop_stab mark. */
+ bfd_put_32 (abfd, (LOP << 24) | (LOP_STAB << 16), buf);
+ if (bfd_bwrite (buf, 4, abfd) != 4)
+ return false;
+
+ /* Dump out symbols. */
+ mmo_internal_3_dump (abfd, &root);
+
+ if (trie_len != (abfd->tdata.mmo_data->byte_no + 3)/4)
+ {
+ /* I haven't seen this trig. It seems no use claiming this case
+ isn't debugged and abort if we get here. Instead emit a
+ diagnostic and fail "normally". */
+ (*_bfd_error_handler)
+ (_("%s: internal error, symbol table changed size from %d to %d\
+ words\n"),
+ bfd_get_filename (abfd), trie_len,
+ (abfd->tdata.mmo_data->byte_no + 3)/4);
+ bfd_set_error (bfd_error_bad_value);
+ return false;
+ }
+
+ /* Dump out remaining bytes in the buffer and handle I/O errors by
+ propagating errors. */
+ if ((abfd->tdata.mmo_data->byte_no % 4) != 0
+ || abfd->tdata.mmo_data->have_error)
+ {
+ memset (abfd->tdata.mmo_data->buf + (abfd->tdata.mmo_data->byte_no % 4),
+ 0, 4 - (abfd->tdata.mmo_data->byte_no % 4));
+
+ if (abfd->tdata.mmo_data->have_error
+ || bfd_bwrite (abfd->tdata.mmo_data->buf, 4, abfd) != 4)
+ return false;
+ }
+
+ bfd_put_32 (abfd, (LOP << 24) | (LOP_END << 16) | trie_len, buf);
+ return bfd_bwrite (buf, 4, abfd) == 4;
+}
+
+/* Write section unless it is the register contents section. For that, we
+ instead store the section in the supplied pointer. This function is
+ used through bfd_map_over_sections. */
+
+static void
+mmo_write_section_unless_reg_contents (abfd, sec, p)
+ bfd *abfd;
+ asection *sec;
+ PTR p;
+{
+ struct mmo_write_sec_info *infop = (struct mmo_write_sec_info *) p;
+
+ if (infop->retval == false)
+ return;
+
+ if (strcmp (sec->name, MMIX_REG_CONTENTS_SECTION_NAME) == 0)
+ {
+ infop->reg_section = sec;
+ return;
+ }
+
+ /* Exclude the convenience register section. */
+ if (strcmp (sec->name, MMIX_REG_SECTION_NAME) == 0)
+ {
+ if (bfd_get_section_flags (abfd, sec) & SEC_HAS_CONTENTS)
+ {
+ /* Make sure it hasn't got contents. It seems impossible to
+ make it carry contents, so we don't have a test-case for
+ this. */
+ (*_bfd_error_handler)
+ (_("%s: internal error, internal register section %s had\
+ contents\n"),
+ bfd_get_filename (abfd), sec->name);
+ bfd_set_error (bfd_error_bad_value);
+ infop->retval = false;
+ return;
+ }
+
+ return;
+ }
+
+ infop->retval = mmo_internal_write_section (abfd, sec);
+}
+
+/* Do the actual output of a file. Assumes mmo_set_section_contents is
+ already called. */
+
+static boolean
+mmo_write_object_contents (abfd)
+ bfd *abfd;
+{
+ struct mmo_write_sec_info wsecinfo;
+
+ /* First, there are a few words of preamble. */
+ if (! mmo_internal_write_header (abfd))
+ return false;
+
+ wsecinfo.reg_section = NULL;
+ wsecinfo.retval = true;
+
+ bfd_map_over_sections (abfd, mmo_write_section_unless_reg_contents,
+ (PTR) &wsecinfo);
+
+ if (wsecinfo.retval == false)
+ return false;
+
+ if (wsecinfo.reg_section != NULL)
+ {
+ asection *sec = wsecinfo.reg_section;
+ unsigned int z = (unsigned int) (sec->vma / 8);
+
+ /* Registers 0..31 must not be global. Do sanity check on the "vma"
+ of the register contents section and check that it corresponds to
+ the length of the section. */
+ if (z < 32 || z >= 255 || (sec->vma & 7) != 0
+ || sec->vma != 256 * 8 - sec->_raw_size - 8)
+ {
+ bfd_set_error (bfd_error_bad_value);
+
+ if (sec->_raw_size == 0)
+ /* There must always be at least one such register. */
+ (*_bfd_error_handler)
+ (_("%s: no initialized registers; section length 0\n"),
+ bfd_get_filename (abfd));
+ else if (sec->vma > (256 - 32) * 8)
+ /* Provide better error message for the case of too many
+ global registers. */
+ (*_bfd_error_handler)
+ (_("%s: too many initialized registers; section length %ld\n"),
+ bfd_get_filename (abfd),
+ (long) sec->_raw_size);
+ else
+ (*_bfd_error_handler)
+ (_("%s: invalid start address for initialized registers of\
+ length %ld: 0x%lx%08lx\n"),
+ bfd_get_filename (abfd),
+ (long) sec->_raw_size,
+ (unsigned long) (sec->vma >> 32), (unsigned long) (sec->vma));
+
+ return false;
+ }
+
+ if (! mmo_internal_write_post (abfd, z, sec))
+ return false;
+ }
+ else
+ if (! mmo_internal_write_post (abfd, 255, NULL))
+ return false;
+
+ return mmo_write_symbols_and_terminator (abfd);
+}
+
+/* Return the size of a NULL pointer, so we support linking in an mmo
+ object. */
+
+static long
+mmo_get_reloc_upper_bound (abfd, sec)
+ bfd *abfd ATTRIBUTE_UNUSED;
+ asection *sec ATTRIBUTE_UNUSED;
+{
+ return sizeof (PTR);
+}
+
+/* Similarly canonicalize relocs to empty, filling in the terminating NULL
+ pointer. */
+
+long
+mmo_canonicalize_reloc (abfd, section, relptr, symbols)
+ bfd *abfd ATTRIBUTE_UNUSED;
+ sec_ptr section ATTRIBUTE_UNUSED;
+ arelent **relptr;
+ asymbol **symbols ATTRIBUTE_UNUSED;
+{
+ *relptr = NULL;
+ return 0;
+}
+
+/* If there's anything in particular in a mmo bfd that we want to free,
+ make this a real function. Only do this if you see major memory
+ thrashing; zealous free:ing will cause unwanted behavior, especially if
+ you "free" memory allocated with "bfd_alloc", or even "bfd_release" a
+ block allocated with "bfd_alloc"; they're really allocated from an
+ obstack, and we don't know what was allocated there since this
+ particular allocation. */
+
+#define mmo_close_and_cleanup _bfd_generic_close_and_cleanup
+#define mmo_bfd_free_cached_info _bfd_generic_bfd_free_cached_info
+
+/* Perhaps we need to adjust this one; mmo labels (originally) without a
+ leading ':' might more appropriately be called local. */
+#define mmo_bfd_is_local_label_name bfd_generic_is_local_label_name
+
+/* Is this one really used or defined by anyone? */
+#define mmo_get_lineno _bfd_nosymbols_get_lineno
+
+/* FIXME: We can do better on this one, if we have a dwarf2 .debug_line
+ section or if MMO line numbers are implemented. */
+#define mmo_find_nearest_line _bfd_nosymbols_find_nearest_line
+#define mmo_bfd_make_debug_symbol _bfd_nosymbols_bfd_make_debug_symbol
+#define mmo_read_minisymbols _bfd_generic_read_minisymbols
+#define mmo_minisymbol_to_symbol _bfd_generic_minisymbol_to_symbol
+
+#define mmo_get_section_contents_in_window \
+ _bfd_generic_get_section_contents_in_window
+#define mmo_bfd_get_relocated_section_contents \
+ bfd_generic_get_relocated_section_contents
+#define mmo_bfd_gc_sections bfd_generic_gc_sections
+#define mmo_bfd_link_hash_table_create _bfd_generic_link_hash_table_create
+#define mmo_bfd_link_add_symbols _bfd_generic_link_add_symbols
+#define mmo_bfd_final_link _bfd_generic_final_link
+#define mmo_bfd_link_split_section _bfd_generic_link_split_section
+
+/* Strictly speaking, only MMIX uses this restricted format, but let's not
+ stop anybody from shooting themselves in the foot. */
+#define mmo_set_arch_mach bfd_default_set_arch_mach
+#define mmo_bfd_relax_section bfd_generic_relax_section
+#define mmo_bfd_merge_sections bfd_generic_merge_sections
+
+/* objcopy will be upset if we return -1 from bfd_get_reloc_upper_bound by
+ using BFD_JUMP_TABLE_RELOCS (_bfd_norelocs) rather than 0. FIXME: Most
+ likely a bug in the _bfd_norelocs definition.
+
+ On the other hand, we smuggle in an mmo object (because setting up ELF
+ is too cumbersome) when linking (from other formats, presumably ELF) to
+ represent the g255 entry. We need to link that object, so need to say
+ it has no relocs. Upper bound for the size of the relocation table is
+ the size of a NULL pointer, and we support "canonicalization" for that
+ pointer. */
+#define mmo_bfd_reloc_type_lookup _bfd_norelocs_bfd_reloc_type_lookup
+
+/* We want to copy time of creation, otherwise we'd use
+ BFD_JUMP_TABLE_COPY (_bfd_generic). */
+#define mmo_bfd_merge_private_bfd_data _bfd_generic_bfd_merge_private_bfd_data
+#define mmo_bfd_copy_private_section_data _bfd_generic_bfd_copy_private_section_data
+#define mmo_bfd_copy_private_symbol_data _bfd_generic_bfd_copy_private_symbol_data
+#define mmo_bfd_set_private_flags _bfd_generic_bfd_set_private_flags
+#define mmo_bfd_print_private_bfd_data _bfd_generic_bfd_print_private_bfd_data
+
+CONST bfd_target bfd_mmo_vec =
+{
+ "mmo", /* name */
+ bfd_target_mmo_flavour,
+ BFD_ENDIAN_BIG, /* target byte order */
+ BFD_ENDIAN_BIG, /* target headers byte order */
+
+ /* FIXME: Might need adjustments. */
+ (HAS_RELOC | EXEC_P | /* object flags */
+ HAS_LINENO | HAS_DEBUG |
+ HAS_SYMS | HAS_LOCALS | WP_TEXT),
+
+ /* FIXME: Might need adjustments. */
+ (SEC_CODE | SEC_DATA | SEC_HAS_CONTENTS | SEC_ALLOC | SEC_LOAD
+ | SEC_READONLY | SEC_EXCLUDE | SEC_DEBUGGING | SEC_IN_MEMORY),
+ /* section flags */
+ 0, /* leading underscore */
+ ' ', /* ar_pad_char */
+ 16, /* ar_max_namelen */
+ bfd_getb64, bfd_getb_signed_64, bfd_putb64,
+ bfd_getb32, bfd_getb_signed_32, bfd_putb32,
+ bfd_getb16, bfd_getb_signed_16, bfd_putb16, /* data */
+ bfd_getb64, bfd_getb_signed_64, bfd_putb64,
+ bfd_getb32, bfd_getb_signed_32, bfd_putb32,
+ bfd_getb16, bfd_getb_signed_16, bfd_putb16, /* hdrs */
+
+ {
+ _bfd_dummy_target,
+ mmo_object_p, /* bfd_check_format */
+ _bfd_dummy_target,
+ _bfd_dummy_target,
+ },
+ {
+ bfd_false,
+ mmo_mkobject,
+ bfd_false,
+ bfd_false,
+ },
+ { /* bfd_write_contents */
+ bfd_false,
+ mmo_write_object_contents,
+ bfd_false,
+ bfd_false,
+ },
+
+ BFD_JUMP_TABLE_GENERIC (mmo),
+ BFD_JUMP_TABLE_COPY (mmo),
+ BFD_JUMP_TABLE_CORE (_bfd_nocore),
+ BFD_JUMP_TABLE_ARCHIVE (_bfd_noarchive),
+ BFD_JUMP_TABLE_SYMBOLS (mmo),
+ /* We have to provide a valid method for getting relocs, returning zero,
+ so we can't say BFD_JUMP_TABLE_RELOCS (_bfd_norelocs). */
+ BFD_JUMP_TABLE_RELOCS (mmo),
+ BFD_JUMP_TABLE_WRITE (mmo),
+ BFD_JUMP_TABLE_LINK (mmo),
+ BFD_JUMP_TABLE_DYNAMIC (_bfd_nodynamic),
+
+ NULL,
+
+ NULL
+};
aix386-core.c
+aout0.c
+aout32.c
+aout64.c
aout-adobe.c
aout-arm.c
aout-cris.c
+aoutf1.h
aout-ns32k.c
aout-sparcle.c
aout-target.h
aout-tic30.c
-aout0.c
-aout32.c
-aout64.c
-aoutf1.h
aoutx.h
archive.c
archures.c
cf-m68klynx.c
cf-sparclynx.c
cisco-core.c
+coff64-rs6000.c
coff-a29k.c
coff-alpha.c
coff-apollo.c
coff-arm.c
coff-aux.c
+coffcode.h
+coffgen.c
coff-go32.c
coff-h8300.c
coff-h8500.c
coff-i386.c
coff-i860.c
coff-i960.c
+cofflink.c
coff-m68k.c
coff-m88k.c
coff-mips.c
coff-sparc.c
coff-stgo32.c
coff-svm68k.c
+coffswap.h
coff-tic30.c
coff-tic54x.c
coff-tic80.c
coff-w65.c
coff-we32k.c
coff-z8k.c
-coff64-rs6000.c
-coffcode.h
-coffgen.c
-cofflink.c
-coffswap.h
corefile.c
cpu-a29k.c
cpu-alpha.c
ecoffswap.h
efi-app-ia32.c
efi-app-ia64.c
-elf-bfd.h
-elf-hppa.h
-elf-m10200.c
-elf-m10300.c
-elf.c
elf32-arc.c
elf32-arm.h
elf32-avr.c
+elf32.c
elf32-cris.c
elf32-d10v.c
elf32-d30v.c
elf32-pj.c
elf32-ppc.c
elf32-s390.c
-elf32-sh-lin.c
elf32-sh.c
+elf32-sh-lin.c
elf32-sparc.c
elf32-v850.c
-elf32.c
elf64-alpha.c
+elf64.c
elf64-gen.c
elf64-hppa.c
elf64-hppa.h
elf64-s390.c
elf64-sparc.c
elf64-x86-64.c
-elf64.c
elfarm-nabi.c
elfarm-oabi.c
+elf-bfd.h
+elf.c
elfcode.h
elfcore.h
+elf-hppa.h
elflink.c
elflink.h
+elf-m10200.c
+elf-m10300.c
epoc-pe-arm.c
epoc-pei-arm.c
format.c
mipsbsd.c
netbsd.h
newsos3.c
-nlm-target.h
-nlm.c
nlm32-alpha.c
+nlm32.c
nlm32-i386.c
nlm32-ppc.c
nlm32-sparc.c
-nlm32.c
nlm64.c
+nlm.c
nlmcode.h
nlmswap.h
+nlm-target.h
ns32k.h
ns32knetbsd.c
oasys.c
pdp11.c
pe-arm.c
pe-i386.c
-pe-mcore.c
-pe-mips.c
-pe-ppc.c
-pe-sh.c
pei-arm.c
+peicode.h
pei-i386.c
pei-mcore.c
pei-mips.c
pei-ppc.c
pei-sh.c
-peicode.h
+pe-mcore.c
+pe-mips.c
+pe-ppc.c
+pe-sh.c
ppcboot.c
-reloc.c
reloc16.c
+reloc.c
riscix.c
sco5-core.c
section.c
sparclynx.c
sparcnetbsd.c
srec.c
-stab-syms.c
stabs.c
+stab-syms.c
sunos.c
syms.c
targets.c
vaxnetbsd.c
versados.c
version.h
+vms.c
vms-gsd.c
+vms.h
vms-hdr.c
vms-misc.c
vms-tir.c
-vms.c
-vms.h
-xcoff-target.h
xcofflink.c
+xcoff-target.h
msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
-"POT-Creation-Date: 2001-06-13 12:48+0100\n"
+"POT-Creation-Date: 2001-10-12 22:46+0100\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
"Content-Type: text/plain; charset=CHARSET\n"
"Content-Transfer-Encoding: ENCODING\n"
-#: aout-adobe.c:189
+#: aout-adobe.c:196
#, c-format
msgid "%s: Unknown section type in a.out.adobe file: %x\n"
msgstr ""
-#: aout-cris.c:207
+#: aout-cris.c:208
#, c-format
msgid "%s: Invalid relocation type exported: %d"
msgstr ""
-#: aout-cris.c:251
+#: aout-cris.c:252
#, c-format
msgid "%s: Invalid relocation type imported: %d"
msgstr ""
-#: aout-cris.c:262
+#: aout-cris.c:263
#, c-format
msgid "%s: Bad relocation record imported: %d"
msgstr ""
-#: aoutx.h:1265 aoutx.h:1679
+#: aoutx.h:1282 aoutx.h:1699
#, c-format
msgid "%s: can not represent section `%s' in a.out object file format"
msgstr ""
-#: aoutx.h:1649
+#: aoutx.h:1669
#, c-format
msgid ""
"%s: can not represent section for symbol `%s' in a.out object file format"
msgstr ""
-#: aoutx.h:1651
+#: aoutx.h:1671
msgid "*unknown*"
msgstr ""
-#: aoutx.h:3688
+#: aoutx.h:3735
#, c-format
msgid "%s: relocateable link from %s to %s not supported"
msgstr ""
-#: archive.c:1821
+#: archive.c:1839
msgid "Warning: writing archive was slow: rewriting timestamp\n"
msgstr ""
-#: archive.c:2087
+#: archive.c:2106
msgid "Reading archive file mod timestamp"
msgstr ""
#. FIXME: bfd can't call perror.
-#: archive.c:2114
+#: archive.c:2133
msgid "Writing updated armap timestamp"
msgstr ""
-#: bfd.c:273
+#: bfd.c:274
msgid "No error"
msgstr ""
-#: bfd.c:274
+#: bfd.c:275
msgid "System call error"
msgstr ""
-#: bfd.c:275
+#: bfd.c:276
msgid "Invalid bfd target"
msgstr ""
-#: bfd.c:276
+#: bfd.c:277
msgid "File in wrong format"
msgstr ""
-#: bfd.c:277
+#: bfd.c:278
+msgid "Archive object file in wrong format"
+msgstr ""
+
+#: bfd.c:279
msgid "Invalid operation"
msgstr ""
-#: bfd.c:278
+#: bfd.c:280
msgid "Memory exhausted"
msgstr ""
-#: bfd.c:279
+#: bfd.c:281
msgid "No symbols"
msgstr ""
-#: bfd.c:280
+#: bfd.c:282
msgid "Archive has no index; run ranlib to add one"
msgstr ""
-#: bfd.c:281
+#: bfd.c:283
msgid "No more archived files"
msgstr ""
-#: bfd.c:282
+#: bfd.c:284
msgid "Malformed archive"
msgstr ""
-#: bfd.c:283
+#: bfd.c:285
msgid "File format not recognized"
msgstr ""
-#: bfd.c:284
+#: bfd.c:286
msgid "File format is ambiguous"
msgstr ""
-#: bfd.c:285
+#: bfd.c:287
msgid "Section has no contents"
msgstr ""
-#: bfd.c:286
+#: bfd.c:288
msgid "Nonrepresentable section on output"
msgstr ""
-#: bfd.c:287
+#: bfd.c:289
msgid "Symbol needs debug section which does not exist"
msgstr ""
-#: bfd.c:288
+#: bfd.c:290
msgid "Bad value"
msgstr ""
-#: bfd.c:289
+#: bfd.c:291
msgid "File truncated"
msgstr ""
-#: bfd.c:290
+#: bfd.c:292
msgid "File too big"
msgstr ""
-#: bfd.c:291
+#: bfd.c:293
msgid "#<Invalid error code>"
msgstr ""
-#: bfd.c:675
+#: bfd.c:700
#, c-format
-msgid "bfd assertion fail %s:%d"
+msgid "BFD %s assertion fail %s:%d"
msgstr ""
-#: bfd.c:693
+#: bfd.c:719
#, c-format
-msgid "BFD internal error, aborting at %s line %d in %s\n"
+msgid "BFD %s internal error, aborting at %s line %d in %s\n"
msgstr ""
-#: bfd.c:697
+#: bfd.c:723
#, c-format
-msgid "BFD internal error, aborting at %s line %d\n"
+msgid "BFD %sinternal error, aborting at %s line %d\n"
msgstr ""
-#: bfd.c:699
+#: bfd.c:725
msgid "Please report this bug.\n"
msgstr ""
msgid "Warning: Writing section `%s' to huge (ie negative) file offset 0x%lx."
msgstr ""
-#: coff-rs6000.c:2517 coff64-rs6000.c:1074
+#: coff-rs6000.c:2578 coff64-rs6000.c:1161
#, c-format
msgid "%s: unsupported relocation type 0x%02x"
msgstr ""
-#: coff-rs6000.c:2563 coff64-rs6000.c:1120
+#: coff-rs6000.c:2624 coff64-rs6000.c:1207
#, c-format
msgid "%s: TOC reloc at 0x%x to symbol `%s' with no TOC entry"
msgstr ""
-#: coff-rs6000.c:2809 coff64-rs6000.c:1955
+#: coff-rs6000.c:2874 coff64-rs6000.c:2057
#, c-format
msgid "%s: symbol `%s' has unrecognized smclas %d"
msgstr ""
-#: coff-a29k.c:123
+#: coff-a29k.c:119
msgid "Missing IHCONST"
msgstr ""
-#: coff-a29k.c:183
+#: coff-a29k.c:180
msgid "Missing IHIHALF"
msgstr ""
-#: coff-a29k.c:215
+#: coff-a29k.c:212
msgid "Unrecognized reloc"
msgstr ""
-#: coff-a29k.c:427
+#: coff-a29k.c:408
msgid "missing IHCONST reloc"
msgstr ""
-#: coff-a29k.c:518
+#: coff-a29k.c:498
msgid "missing IHIHALF reloc"
msgstr ""
msgid "GP relative relocation used when GP not defined"
msgstr ""
-#: coff-alpha.c:1487 elf64-alpha.c:4045
+#: coff-alpha.c:1485
msgid "using multiple gp values"
msgstr ""
-#: coff-alpha.c:1993 coff-mips.c:1434
+#: coff-alpha.c:1989 coff-mips.c:1433
msgid "GP relative relocation when GP not defined"
msgstr ""
-#: coff-arm.c:1019 elf32-arm.h:246
+#: coff-arm.c:1051 elf32-arm.h:285
#, c-format
msgid "%s: unable to find THUMB glue '%s' for `%s'"
msgstr ""
-#: coff-arm.c:1048 elf32-arm.h:281
+#: coff-arm.c:1080 elf32-arm.h:320
#, c-format
msgid "%s: unable to find ARM glue '%s' for `%s'"
msgstr ""
-#: coff-arm.c:1342 coff-arm.c:1437 elf32-arm.h:841 elf32-arm.h:946
+#: coff-arm.c:1375 coff-arm.c:1470 elf32-arm.h:886 elf32-arm.h:990
#, c-format
msgid "%s(%s): warning: interworking not enabled."
msgstr ""
-#: coff-arm.c:1346 elf32-arm.h:949
+#: coff-arm.c:1379 elf32-arm.h:993
#, c-format
msgid " first occurrence: %s: arm call to thumb"
msgstr ""
-#: coff-arm.c:1441 elf32-arm.h:844
+#: coff-arm.c:1474 elf32-arm.h:889
#, c-format
msgid " first occurrence: %s: thumb call to arm"
msgstr ""
-#: coff-arm.c:1444
+#: coff-arm.c:1477
msgid " consider relinking with --support-old-code enabled"
msgstr ""
-#: coff-arm.c:1732 coff-tic80.c:682 cofflink.c:2992
+#: coff-arm.c:1767 coff-tic80.c:686 cofflink.c:3017
#, c-format
msgid "%s: bad reloc address 0x%lx in section `%s'"
msgstr ""
-#: coff-arm.c:2069
+#: coff-arm.c:2107
#, c-format
msgid "%s: illegal symbol index in reloc: %d"
msgstr ""
-#: coff-arm.c:2197
+#: coff-arm.c:2235
#, c-format
msgid "%s: ERROR: compiled for APCS-%d whereas target %s uses APCS-%d"
msgstr ""
-#: coff-arm.c:2212
+#: coff-arm.c:2250
#, c-format
msgid ""
"%s: ERROR: passes floats in float registers whereas target %s uses integer "
"registers"
msgstr ""
-#: coff-arm.c:2215
+#: coff-arm.c:2253
#, c-format
msgid ""
"%s: ERROR: passes floats in integer registers whereas target %s uses float "
"registers"
msgstr ""
-#: coff-arm.c:2230
+#: coff-arm.c:2268
#, c-format
msgid ""
"%s: ERROR: compiled as position independent code, whereas target %s is "
"absolute position"
msgstr ""
-#: coff-arm.c:2233
+#: coff-arm.c:2271
#, c-format
msgid ""
"%s: ERROR: compiled as absolute position code, whereas target %s is position "
"independent"
msgstr ""
-#: coff-arm.c:2262
+#: coff-arm.c:2300
#, c-format
msgid "Warning: input file %s supports interworking, whereas %s does not."
msgstr ""
-#: coff-arm.c:2265
+#: coff-arm.c:2303
#, c-format
msgid "Warning: input file %s does not support interworking, whereas %s does."
msgstr ""
-#: coff-arm.c:2292
+#: coff-arm.c:2330
#, c-format
msgid "private flags = %x:"
msgstr ""
-#: coff-arm.c:2300 elf32-arm.h:2234
+#: coff-arm.c:2338 elf32-arm.h:2293
msgid " [floats passed in float registers]"
msgstr ""
-#: coff-arm.c:2302
+#: coff-arm.c:2340
msgid " [floats passed in integer registers]"
msgstr ""
-#: coff-arm.c:2305 elf32-arm.h:2237
+#: coff-arm.c:2343 elf32-arm.h:2296
msgid " [position independent]"
msgstr ""
-#: coff-arm.c:2307
+#: coff-arm.c:2345
msgid " [absolute position]"
msgstr ""
-#: coff-arm.c:2311
+#: coff-arm.c:2349
msgid " [interworking flag not initialised]"
msgstr ""
-#: coff-arm.c:2313
+#: coff-arm.c:2351
msgid " [interworking supported]"
msgstr ""
-#: coff-arm.c:2315
+#: coff-arm.c:2353
msgid " [interworking not supported]"
msgstr ""
-#: coff-arm.c:2363
+#: coff-arm.c:2401
#, c-format
msgid ""
"Warning: Not setting interworking flag of %s, since it has already been "
"specified as non-interworking"
msgstr ""
-#: coff-arm.c:2367
+#: coff-arm.c:2405
#, c-format
msgid "Warning: Clearing the interworking flag of %s due to outside request"
msgstr ""
msgid "%s (%s): Section flag %s (0x%x) ignored"
msgstr ""
-#: coffcode.h:2180
+#: coffcode.h:2117
#, c-format
msgid "Unrecognized TI COFF target id '0x%x'"
msgstr ""
-#: coffcode.h:4252
+#: coffcode.h:4199
#, c-format
msgid "%s: warning: illegal symbol index %ld in line numbers"
msgstr ""
-#: coffcode.h:4266
+#: coffcode.h:4213
#, c-format
msgid "%s: warning: duplicate line number information for `%s'"
msgstr ""
-#: coffcode.h:4626
+#: coffcode.h:4572
#, c-format
msgid "%s: Unrecognized storage class %d for %s symbol `%s'"
msgstr ""
-#: coffcode.h:4757
+#: coffcode.h:4703
#, c-format
msgid "warning: %s: local symbol `%s' has no section"
msgstr ""
-#: coff-tic54x.c:376 coffcode.h:4868
+#: coff-tic54x.c:390 coffcode.h:4810
#, c-format
msgid "%s: warning: illegal symbol index %ld in relocs"
msgstr ""
-#: coffcode.h:4906
+#: coffcode.h:4848
#, c-format
msgid "%s: illegal relocation type %d at address 0x%lx"
msgstr ""
-#: coffgen.c:1640
+#: coffgen.c:1648
#, c-format
msgid "%s: bad string table size %lu"
msgstr ""
-#: coffgen.c:2110
+#: coffgen.c:2125
#, c-format
msgid "AUX tagndx %ld ttlsiz 0x%lx lnnos %ld next %ld"
msgstr ""
msgid "uncertain calling convention for non-COFF symbol"
msgstr ""
-#: cofflink.c:527 elflink.h:1651
+#: cofflink.c:536 elflink.h:1670
#, c-format
msgid "Warning: type of symbol `%s' changed from %d to %d in %s"
msgstr ""
-#: cofflink.c:2290
+#: cofflink.c:2317
#, c-format
msgid "%s: relocs in section `%s', but it has no contents"
msgstr ""
-#: cofflink.c:2629 coffswap.h:895
+#: cofflink.c:2653 coffswap.h:889
#, c-format
msgid "%s: %s: reloc overflow: 0x%lx > 0xffff"
msgstr ""
-#: cofflink.c:2638 coffswap.h:881
+#: cofflink.c:2662 coffswap.h:876
#, c-format
msgid "%s: warning: %s: line number overflow: 0x%lx > 0xffff"
msgstr ""
-#: coff-m68k.c:475 coff-mips.c:2432 elf32-m68k.c:2272
+#: coff-m68k.c:481 coff-mips.c:2431 elf32-m68k.c:2238
msgid "unsupported reloc type"
msgstr ""
-#: coff-mips.c:875 elf32-mips.c:1435
+#: coff-mips.c:875 elf32-mips.c:1448
msgid "GP relative relocation when _gp not defined"
msgstr ""
#. No other sections should appear in -membedded-pic
#. code.
-#: coff-mips.c:2469
+#: coff-mips.c:2468
msgid "reloc against unsupported section"
msgstr ""
-#: coff-mips.c:2477
+#: coff-mips.c:2476
msgid "reloc not properly aligned"
msgstr ""
-#: coff-tic54x.c:263 coff-tic80.c:445
+#: coff-tic54x.c:279 coff-tic80.c:449
#, c-format
msgid "Unrecognized reloc type 0x%x"
msgstr ""
-#: coff-w65.c:369
+#: coff-w65.c:363
#, c-format
msgid "ignoring reloc %s\n"
msgstr ""
-#: dwarf2.c:424
+#: dwarf2.c:475
msgid "Dwarf Error: Can't find .debug_abbrev section."
msgstr ""
-#: dwarf2.c:442
+#: dwarf2.c:492
#, c-format
msgid ""
"Dwarf Error: Abbrev offset (%u) greater than or equal to abbrev size (%u)."
msgstr ""
-#: dwarf2.c:625
+#: dwarf2.c:682
#, c-format
msgid "Dwarf Error: Invalid or unhandled FORM value: %d."
msgstr ""
-#: dwarf2.c:698
+#: dwarf2.c:755
msgid "Dwarf Error: mangled line number section (bad file number)."
msgstr ""
-#: dwarf2.c:783
+#: dwarf2.c:841
msgid "Dwarf Error: Can't find .debug_line section."
msgstr ""
-#: dwarf2.c:807
+#: dwarf2.c:864
#, c-format
msgid "Dwarf Error: Line offset (%u) greater than or equal to line size (%u)."
msgstr ""
-#: dwarf2.c:974
+#: dwarf2.c:1030
msgid "Dwarf Error: mangled line number section."
msgstr ""
-#: dwarf2.c:1153 dwarf2.c:1307
+#: dwarf2.c:1209 dwarf2.c:1426
#, c-format
msgid "Dwarf Error: Could not find abbrev number %d."
msgstr ""
-#: dwarf2.c:1268
+#: dwarf2.c:1387
#, c-format
msgid ""
"Dwarf Error: found dwarf version '%hu', this reader only handles version 2 "
"information."
msgstr ""
-#: dwarf2.c:1275
+#: dwarf2.c:1394
#, c-format
msgid ""
"Dwarf Error: found address size '%u', this reader can not handle sizes "
"greater than '%u'."
msgstr ""
-#: dwarf2.c:1298
+#: dwarf2.c:1417
#, c-format
msgid "Dwarf Error: Bad abbrev number: %d."
msgstr ""
-#: ecoff.c:1323
+#: ecoff.c:1328
#, c-format
msgid "Unknown basic type %d"
msgstr ""
-#: ecoff.c:1592
+#: ecoff.c:1597
#, c-format
msgid ""
"\n"
" End+1 symbol: %ld"
msgstr ""
-#: ecoff.c:1599 ecoff.c:1602
+#: ecoff.c:1604 ecoff.c:1607
#, c-format
msgid ""
"\n"
" First symbol: %ld"
msgstr ""
-#: ecoff.c:1614
+#: ecoff.c:1619
#, c-format
msgid ""
"\n"
" End+1 symbol: %-7ld Type: %s"
msgstr ""
-#: ecoff.c:1621
+#: ecoff.c:1626
#, c-format
msgid ""
"\n"
" Local symbol: %ld"
msgstr ""
-#: ecoff.c:1629
+#: ecoff.c:1634
#, c-format
msgid ""
"\n"
" struct; End+1 symbol: %ld"
msgstr ""
-#: ecoff.c:1634
+#: ecoff.c:1639
#, c-format
msgid ""
"\n"
" union; End+1 symbol: %ld"
msgstr ""
-#: ecoff.c:1639
+#: ecoff.c:1644
#, c-format
msgid ""
"\n"
" enum; End+1 symbol: %ld"
msgstr ""
-#: ecoff.c:1645
+#: ecoff.c:1650
#, c-format
msgid ""
"\n"
" Type: %s"
msgstr ""
-#: elf32-arm.h:1191
+#: elf32-arm.h:1234
#, c-format
msgid "%s: Warning: Arm BLX instruction targets Arm function '%s'."
msgstr ""
-#: elf32-arm.h:1387
+#: elf32-arm.h:1430
#, c-format
msgid "%s: Warning: Thumb BLX instruction targets thumb function '%s'."
msgstr ""
-#: elf-hppa.h:1369 elf-hppa.h:1402 elf32-arm.h:1877 elf32-ppc.c:3093
-#: elf32-s390.c:1442 elf32-sh.c:3107 elf64-s390.c:1431 elf64-x86-64.c:1296
+#: elf32-arm.h:1927
#, c-format
msgid ""
-"%s: warning: unresolvable relocation against symbol `%s' from %s section"
+"%s: warning: unresolvable relocation %d against symbol `%s' from %s section"
msgstr ""
-#: elf-m10200.c:451 elf-m10300.c:663 elf32-arm.h:1951 elf32-avr.c:842
-#: elf32-cris.c:1335 elf32-d10v.c:478 elf32-fr30.c:648 elf32-i860.c:1049
-#: elf32-m32r.c:1266 elf32-openrisc.c:449 elf32-v850.c:1681
+#: elf-m10200.c:465 elf-m10300.c:681 elf32-arm.h:2003 elf32-avr.c:842
+#: elf32-cris.c:1333 elf32-d10v.c:490 elf32-fr30.c:655 elf32-h8300.c:549
+#: elf32-i860.c:1050 elf32-m32r.c:1276 elf32-openrisc.c:456 elf32-v850.c:1695
msgid "internal error: out of range error"
msgstr ""
-#: elf-m10200.c:455 elf-m10300.c:667 elf32-arm.h:1955 elf32-avr.c:846
-#: elf32-cris.c:1339 elf32-d10v.c:482 elf32-fr30.c:652 elf32-i860.c:1053
-#: elf32-m32r.c:1270 elf32-mips.c:7049 elf32-openrisc.c:453 elf32-v850.c:1685
+#: elf-m10200.c:469 elf-m10300.c:685 elf32-arm.h:2007 elf32-avr.c:846
+#: elf32-cris.c:1337 elf32-d10v.c:494 elf32-fr30.c:659 elf32-h8300.c:553
+#: elf32-i860.c:1054 elf32-m32r.c:1280 elf32-mips.c:7061 elf32-openrisc.c:460
+#: elf32-v850.c:1699
msgid "internal error: unsupported relocation error"
msgstr ""
-#: elf-m10200.c:459 elf-m10300.c:671 elf32-arm.h:1959 elf32-d10v.c:486
-#: elf32-m32r.c:1274
+#: elf-m10200.c:473 elf-m10300.c:689 elf32-arm.h:2011 elf32-d10v.c:498
+#: elf32-h8300.c:557 elf32-m32r.c:1284
msgid "internal error: dangerous error"
msgstr ""
-#: elf-m10200.c:463 elf-m10300.c:675 elf32-arm.h:1963 elf32-avr.c:854
-#: elf32-cris.c:1347 elf32-d10v.c:490 elf32-fr30.c:660 elf32-i860.c:1061
-#: elf32-m32r.c:1278 elf32-openrisc.c:461 elf32-v850.c:1705
+#: elf-m10200.c:477 elf-m10300.c:693 elf32-arm.h:2015 elf32-avr.c:854
+#: elf32-cris.c:1345 elf32-d10v.c:502 elf32-fr30.c:667 elf32-h8300.c:561
+#: elf32-i860.c:1062 elf32-m32r.c:1288 elf32-openrisc.c:468 elf32-v850.c:1719
msgid "internal error: unknown error"
msgstr ""
-#: elf32-arm.h:1991
+#: elf32-arm.h:2043
#, c-format
msgid ""
"Warning: Not setting interwork flag of %s since it has already been "
"specified as non-interworking"
msgstr ""
-#: elf32-arm.h:1995
+#: elf32-arm.h:2047
#, c-format
msgid "Warning: Clearing the interwork flag of %s due to outside request"
msgstr ""
-#: elf32-arm.h:2043
+#: elf32-arm.h:2095
#, c-format
msgid ""
"Warning: Clearing the interwork flag in %s because non-interworking code in "
"%s has been linked with it"
msgstr ""
-#: elf32-arm.h:2137
+#: elf32-arm.h:2190
#, c-format
msgid ""
"Error: %s compiled for EABI version %d, whereas %s is compiled for version %d"
msgstr ""
-#: elf32-arm.h:2151
+#: elf32-arm.h:2204
#, c-format
msgid "Error: %s compiled for APCS-%d, whereas %s is compiled for APCS-%d"
msgstr ""
-#: elf32-arm.h:2162
-#, c-format
-msgid ""
-"Error: %s passes floats in %s registers, whereas %s passes them in %s "
-"registers"
-msgstr ""
-
-#: elf32-arm.h:2165 elf32-arm.h:2167
+#: elf32-arm.h:2215 elf32-arm.h:2216
msgid "float"
msgstr ""
-#: elf32-arm.h:2165 elf32-arm.h:2167
+#: elf32-arm.h:2215 elf32-arm.h:2216
msgid "integer"
msgstr ""
-#: elf32-arm.h:2174
+#: elf32-arm.h:2218
#, c-format
-msgid "Error: %s uses %s floating point, whereas %s uses %s floating point"
+msgid ""
+"Error: %s passes floats in %s registers, whereas %s passes them in %s "
+"registers"
msgstr ""
-#: elf32-arm.h:2177 elf32-arm.h:2179
+#: elf32-arm.h:2228 elf32-arm.h:2229
msgid "soft"
msgstr ""
-#: elf32-arm.h:2177 elf32-arm.h:2179
+#: elf32-arm.h:2228 elf32-arm.h:2229
msgid "hard"
msgstr ""
-#: elf32-arm.h:2186
+#: elf32-arm.h:2231
#, c-format
-msgid "Warning: %s %s interworking, whereas %s %s"
+msgid "Error: %s uses %s floating point, whereas %s uses %s floating point"
msgstr ""
-#: elf32-arm.h:2189
+#: elf32-arm.h:2243
msgid "supports"
msgstr ""
-#: elf32-arm.h:2189
+#: elf32-arm.h:2243
msgid "does not support"
msgstr ""
-#: elf32-arm.h:2191
+#: elf32-arm.h:2244
msgid "does"
msgstr ""
-#: elf32-arm.h:2191
+#: elf32-arm.h:2244
msgid "does not"
msgstr ""
+#: elf32-arm.h:2246
+#, c-format
+msgid "Warning: %s %s interworking, whereas %s %s"
+msgstr ""
+
#. Ignore init flag - it may not be set, despite the flags field
#. containing valid data.
-#: elf32-arm.h:2217 elf32-cris.c:2968 elf32-m68k.c:430 elf32-mips.c:2721
+#: elf32-arm.h:2276 elf32-cris.c:2917 elf32-m68k.c:432 elf32-mips.c:2714
#, c-format
msgid "private flags = %lx:"
msgstr ""
-#: elf32-arm.h:2226
+#: elf32-arm.h:2285
msgid " [interworking enabled]"
msgstr ""
-#: elf32-arm.h:2229
+#: elf32-arm.h:2288
msgid " [APCS-26]"
msgstr ""
-#: elf32-arm.h:2231
+#: elf32-arm.h:2290
msgid " [APCS-32]"
msgstr ""
-#: elf32-arm.h:2240
+#: elf32-arm.h:2299
msgid " [new ABI]"
msgstr ""
-#: elf32-arm.h:2243
+#: elf32-arm.h:2302
msgid " [old ABI]"
msgstr ""
-#: elf32-arm.h:2246
+#: elf32-arm.h:2305
msgid " [software FP]"
msgstr ""
-#: elf32-arm.h:2253
+#: elf32-arm.h:2312
msgid " [Version1 EABI]"
msgstr ""
-#: elf32-arm.h:2256 elf32-arm.h:2267
+#: elf32-arm.h:2315 elf32-arm.h:2326
msgid " [sorted symbol table]"
msgstr ""
-#: elf32-arm.h:2258 elf32-arm.h:2269
+#: elf32-arm.h:2317 elf32-arm.h:2328
msgid " [unsorted symbol table]"
msgstr ""
-#: elf32-arm.h:2264
+#: elf32-arm.h:2323
msgid " [Version2 EABI]"
msgstr ""
-#: elf32-arm.h:2272
+#: elf32-arm.h:2331
msgid " [dynamic symbols use segment index]"
msgstr ""
-#: elf32-arm.h:2275
+#: elf32-arm.h:2334
msgid " [mapping symbols precede others]"
msgstr ""
-#: elf32-arm.h:2282
+#: elf32-arm.h:2341
msgid " <EABI version unrecognised>"
msgstr ""
-#: elf32-arm.h:2289
+#: elf32-arm.h:2348
msgid " [relocatable executable]"
msgstr ""
-#: elf32-arm.h:2292
+#: elf32-arm.h:2351
msgid " [has entry point]"
msgstr ""
-#: elf32-arm.h:2297
+#: elf32-arm.h:2356
msgid "<Unrecognised flag bits set>"
msgstr ""
-#: elf32-avr.c:850 elf32-cris.c:1343 elf32-fr30.c:656 elf32-i860.c:1057
-#: elf32-openrisc.c:457 elf32-v850.c:1689
+#: elf32-avr.c:850 elf32-cris.c:1341 elf32-fr30.c:663 elf32-i860.c:1058
+#: elf32-openrisc.c:464 elf32-v850.c:1703
msgid "internal error: dangerous relocation"
msgstr ""
-#: elf32-cris.c:874
-#, c-format
-msgid "%s(%s): unresolvable relocation %s against symbol `%s' from %s section"
-msgstr ""
-
-#: elf32-cris.c:882
+#: elf32-cris.c:880
#, c-format
msgid "%s: unresolvable relocation %s against symbol `%s' from %s section"
msgstr ""
-#: elf32-cris.c:945
+#: elf32-cris.c:943
#, c-format
msgid ""
"%s: No PLT nor GOT for relocation %s against symbol `%s' from %s section"
msgstr ""
-#: elf32-cris.c:948 elf32-cris.c:1075
+#: elf32-cris.c:946 elf32-cris.c:1073
msgid "[whose name is lost]"
msgstr ""
-#: elf32-cris.c:1064
+#: elf32-cris.c:1062
#, c-format
msgid ""
"%s: relocation %s with non-zero addend %d against local symbol from %s "
"section"
msgstr ""
-#: elf32-cris.c:1071
+#: elf32-cris.c:1069
#, c-format
msgid ""
"%s: relocation %s with non-zero addend %d against symbol `%s' from %s section"
msgstr ""
-#: elf32-cris.c:1089
+#: elf32-cris.c:1087
#, c-format
msgid ""
"%s: relocation %s is not allowed for global symbol: `%s' from %s section"
msgstr ""
-#: elf32-cris.c:1207
+#: elf32-cris.c:1205
#, c-format
msgid "%s: Internal inconsistency; no relocation section %s"
msgstr ""
-#: elf32-cris.c:2469
-#, c-format
-msgid ""
-"%s(%s), section %s:\n"
-" relocation %s should not be used in a shared object; recompile with -fPIC"
-msgstr ""
-
-#: elf32-cris.c:2476
+#: elf32-cris.c:2455
#, c-format
msgid ""
"%s, section %s:\n"
" relocation %s should not be used in a shared object; recompile with -fPIC"
msgstr ""
-#: elf32-cris.c:2971
+#: elf32-cris.c:2920
msgid " [symbols have a _ prefix]"
msgstr ""
-#: elf32-cris.c:3010
+#: elf32-cris.c:2959
#, c-format
msgid "%s: uses _-prefixed symbols, but writing file with non-prefixed symbols"
msgstr ""
-#: elf32-cris.c:3011
+#: elf32-cris.c:2960
#, c-format
msgid "%s: uses non-prefixed symbols, but writing file with _-prefixed symbols"
msgstr ""
-#: elf32-gen.c:76 elf64-gen.c:76
-#, c-format
-msgid "%s(%s): Relocations in generic ELF (EM: %d)"
-msgstr ""
-
-#: elf32-gen.c:81 elf64-gen.c:81
+#: elf32-gen.c:82 elf64-gen.c:82
#, c-format
msgid "%s: Relocations in generic ELF (EM: %d)"
msgstr ""
-#: elf32-hppa.c:633
+#: elf32-hppa.c:596
#, c-format
msgid "%s(%s+0x%lx): cannot find stub entry %s"
msgstr ""
-#: elf32-hppa.c:694
+#: elf32-hppa.c:657
#, c-format
msgid "%s: cannot create stub entry %s"
msgstr ""
-#: elf32-hppa.c:888
-#, c-format
-msgid "%s(%s+0x%lx): cannot relocate %s, recompile with -ffunction-sections"
-msgstr ""
-
-#: elf32-hppa.c:901 elf32-hppa.c:1615
-#, c-format
-msgid "Could not find relocation section for %s"
-msgstr ""
-
-#: elf32-hppa.c:1046 elf32-hppa.c:3510
+#: elf32-hppa.c:948 elf32-hppa.c:3436
#, c-format
msgid "%s(%s+0x%lx): cannot reach %s, recompile with -ffunction-sections"
msgstr ""
-#: elf32-hppa.c:1386
+#: elf32-hppa.c:1295
#, c-format
msgid ""
"%s: relocation %s can not be used when making a shared object; recompile "
"with -fPIC"
msgstr ""
-#: elf32-hppa.c:1406
+#: elf32-hppa.c:1315
#, c-format
msgid ""
"%s: relocation %s should not be used when making a shared object; recompile "
"with -fPIC"
msgstr ""
-#: elf32-hppa.c:2811
+#: elf32-hppa.c:1505
+#, c-format
+msgid "Could not find relocation section for %s"
+msgstr ""
+
+#: elf32-hppa.c:2759
#, c-format
msgid "%s: duplicate export stub %s"
msgstr ""
-#: elf32-hppa.c:3394
+#: elf32-hppa.c:3320
#, c-format
msgid "%s(%s+0x%lx): fixing %s"
msgstr ""
-#: elf32-hppa.c:4032
+#: elf32-hppa.c:3955
#, c-format
msgid "%s(%s+0x%lx): cannot handle %s for %s"
msgstr ""
-#: elf32-hppa.c:4355
+#: elf32-hppa.c:4295
msgid ".got section not immediately after .plt section"
msgstr ""
-#: elf32-i386.c:280
+#: elf32-i386.c:298
#, c-format
msgid "%s: invalid relocation type %d"
msgstr ""
-#: elf32-i386.c:577
-#, c-format
-msgid "%s(%s): bad symbol index: %d"
-msgstr ""
-
-#: elf32-i386.c:582
+#: elf32-i386.c:688
#, c-format
msgid "%s: bad symbol index: %d"
msgstr ""
-#: elf32-i386.c:735 elf32-i386.c:1759
-#, c-format
-msgid "%s(%s): bad relocation section name `%s'"
-msgstr ""
-
-#: elf32-i386.c:740 elf32-i386.c:1764
+#: elf32-i386.c:830 elf64-ppc.c:2035
#, c-format
msgid "%s: bad relocation section name `%s'"
msgstr ""
-#: elf32-i386.c:1562
+#: elf32-i386.c:2004 elf64-ppc.c:3608
#, c-format
msgid "%s(%s+0x%lx): unresolvable relocation against symbol `%s'"
msgstr ""
-#: elf32-m32r.c:917
+#: elf32-m32r.c:926
msgid "SDA relocation when _SDA_BASE_ not defined"
msgstr ""
-#: elf32-ia64.c:3416 elf32-m32r.c:1001 elf32-ppc.c:2960 elf64-ia64.c:3416
+#: elf32-ia64.c:3445 elf32-m32r.c:1010 elf32-ppc.c:2953 elf64-ia64.c:3445
#, c-format
msgid "%s: unknown relocation type %d"
msgstr ""
-#: elf32-m32r.c:1209
+#: elf32-m32r.c:1219
#, c-format
msgid "%s: The target (%s) of an %s relocation is in the wrong section (%s)"
msgstr ""
-#: elf32-m32r.c:2011
+#: elf32-m32r.c:2021
#, c-format
msgid "%s: Instruction set mismatch with previous modules"
msgstr ""
-#: elf32-m32r.c:2034
+#: elf32-m32r.c:2044
#, c-format
msgid "private flags = %lx"
msgstr ""
-#: elf32-m32r.c:2039
+#: elf32-m32r.c:2049
msgid ": m32r instructions"
msgstr ""
-#: elf32-m32r.c:2040
+#: elf32-m32r.c:2050
msgid ": m32rx instructions"
msgstr ""
-#: elf32-m68k.c:433
+#: elf32-m68k.c:435
msgid " [cpu32]"
msgstr ""
-#: elf32-mcore.c:364 elf32-mcore.c:490
+#: elf32-mcore.c:373 elf32-mcore.c:499
#, c-format
msgid "%s: Relocation %s (%d) is not currently supported.\n"
msgstr ""
-#: elf32-mcore.c:449
+#: elf32-mcore.c:458
#, c-format
msgid "%s: Unknown relocation type %d\n"
msgstr ""
-#: elf32-mips.c:1594
+#: elf32-mips.c:1607
msgid "32bits gp relative relocation occurs for an external symbol"
msgstr ""
-#: elf32-mips.c:1743
+#: elf32-mips.c:1756
#, c-format
msgid "Linking mips16 objects into %s format is not supported"
msgstr ""
-#: elf32-mips.c:2608
+#: elf32-mips.c:2601
#, c-format
msgid "%s: linking PIC files with non-PIC files"
msgstr ""
-#: elf32-mips.c:2618
+#: elf32-mips.c:2611
#, c-format
msgid "%s: linking abicalls files with non-abicalls files"
msgstr ""
-#: elf32-mips.c:2647
+#: elf32-mips.c:2640
#, c-format
msgid "%s: ISA mismatch (-mips%d) with previous modules (-mips%d)"
msgstr ""
-#: elf32-mips.c:2656
+#: elf32-mips.c:2649
#, c-format
msgid "%s: ISA mismatch (%d) with previous modules (%d)"
msgstr ""
-#: elf32-mips.c:2679
+#: elf32-mips.c:2672
#, c-format
msgid "%s: ABI mismatch: linking %s module with previous %s modules"
msgstr ""
-#: elf32-mips.c:2693 elf32-ppc.c:1478 elf64-sparc.c:2997
+#: elf32-mips.c:2686 elf32-ppc.c:1489 elf64-ppc.c:1541 elf64-sparc.c:3030
#, c-format
msgid "%s: uses different e_flags (0x%lx) fields than previous modules (0x%lx)"
msgstr ""
-#: elf32-mips.c:2724
+#: elf32-mips.c:2717
msgid " [abi=O32]"
msgstr ""
-#: elf32-mips.c:2726
+#: elf32-mips.c:2719
msgid " [abi=O64]"
msgstr ""
-#: elf32-mips.c:2728
+#: elf32-mips.c:2721
msgid " [abi=EABI32]"
msgstr ""
-#: elf32-mips.c:2730
+#: elf32-mips.c:2723
msgid " [abi=EABI64]"
msgstr ""
-#: elf32-mips.c:2732
+#: elf32-mips.c:2725
msgid " [abi unknown]"
msgstr ""
-#: elf32-mips.c:2734
+#: elf32-mips.c:2727
msgid " [abi=N32]"
msgstr ""
-#: elf32-mips.c:2736
+#: elf32-mips.c:2729
msgid " [abi=64]"
msgstr ""
-#: elf32-mips.c:2738
+#: elf32-mips.c:2731
msgid " [no abi set]"
msgstr ""
-#: elf32-mips.c:2741
+#: elf32-mips.c:2734
msgid " [mips1]"
msgstr ""
-#: elf32-mips.c:2743
+#: elf32-mips.c:2736
msgid " [mips2]"
msgstr ""
-#: elf32-mips.c:2745
+#: elf32-mips.c:2738
msgid " [mips3]"
msgstr ""
-#: elf32-mips.c:2747
+#: elf32-mips.c:2740
msgid " [mips4]"
msgstr ""
-#: elf32-mips.c:2749
+#: elf32-mips.c:2742
msgid " [mips5]"
msgstr ""
-#: elf32-mips.c:2751
+#: elf32-mips.c:2744
msgid " [mips32]"
msgstr ""
-#: elf32-mips.c:2753
+#: elf32-mips.c:2746
msgid " [mips64]"
msgstr ""
-#: elf32-mips.c:2755
+#: elf32-mips.c:2748
msgid " [unknown ISA]"
msgstr ""
-#: elf32-mips.c:2758
+#: elf32-mips.c:2751
msgid " [32bitmode]"
msgstr ""
-#: elf32-mips.c:2760
+#: elf32-mips.c:2753
msgid " [not 32bitmode]"
msgstr ""
-#: elf32-mips.c:4428
+#: elf32-mips.c:4429
msgid "static procedure (no name)"
msgstr ""
-#: elf32-mips.c:5045 elf64-alpha.c:4418
+#: elf32-mips.c:5047
#, c-format
msgid "%s: illegal section name `%s'"
msgstr ""
-#: elf32-mips.c:5610
+#: elf32-mips.c:5614
msgid "not enough GOT space for local GOT entries"
msgstr ""
-#: elf32-mips.c:6726
+#: elf32-mips.c:6734
#, c-format
msgid "%s: %s+0x%lx: jump to stub routine which is not jal"
msgstr ""
-#: elf32-mips.c:7715
+#: elf32-mips.c:7733
#, c-format
-msgid "Malformed reloc detected for section %s"
+msgid "%s: Malformed reloc detected for section %s"
msgstr ""
-#: elf32-mips.c:7792
+#: elf32-mips.c:7811
#, c-format
msgid "%s: CALL16 reloc at 0x%lx not against global symbol"
msgstr ""
-#: elf32-ppc.c:1444
+#: elf32-ppc.c:1455 elf64-ppc.c:1506
#, c-format
msgid ""
"%s: compiled with -mrelocatable and linked with modules compiled normally"
msgstr ""
-#: elf32-ppc.c:1452
+#: elf32-ppc.c:1463 elf64-ppc.c:1514
#, c-format
msgid ""
"%s: compiled normally and linked with modules compiled with -mrelocatable"
msgstr ""
-#: elf32-ppc.c:1576
+#: elf32-ppc.c:1587
#, c-format
msgid "%s: Unknown special linker type %d"
msgstr ""
-#: elf32-ppc.c:2242 elf32-ppc.c:2276 elf32-ppc.c:2311
+#: elf32-ppc.c:2235 elf32-ppc.c:2269 elf32-ppc.c:2304
#, c-format
msgid "%s: relocation %s cannot be used when making a shared object"
msgstr ""
-#: elf32-ppc.c:3126
+#: elf-hppa.h:1369 elf-hppa.h:1402 elf32-ppc.c:3086 elf32-s390.c:1424
+#: elf32-sh.c:3134 elf64-s390.c:1411 elf64-x86-64.c:1281
+#, c-format
+msgid ""
+"%s: warning: unresolvable relocation against symbol `%s' from %s section"
+msgstr ""
+
+#: elf32-ppc.c:3121 elf64-ppc.c:3198
#, c-format
msgid "%s: unknown relocation type %d for symbol %s"
msgstr ""
-#: elf32-ppc.c:3490 elf32-ppc.c:3511 elf32-ppc.c:3561
+#: elf32-ppc.c:3485 elf32-ppc.c:3506 elf32-ppc.c:3556
#, c-format
msgid ""
"%s: The target (%s) of a %s relocation is in the wrong output section (%s)"
msgstr ""
-#: elf32-ppc.c:3627
+#: elf32-ppc.c:3622
#, c-format
msgid "%s: Relocation %s is not yet supported for symbol %s."
msgstr ""
-#: elf32-sh.c:1085
+#: elf32-sh.c:1098
#, c-format
msgid "%s: 0x%lx: warning: bad R_SH_USES offset"
msgstr ""
-#: elf32-sh.c:1097
+#: elf32-sh.c:1110
#, c-format
msgid "%s: 0x%lx: warning: R_SH_USES points to unrecognized insn 0x%x"
msgstr ""
-#: elf32-sh.c:1114
+#: elf32-sh.c:1127
#, c-format
msgid "%s: 0x%lx: warning: bad R_SH_USES load offset"
msgstr ""
-#: elf32-sh.c:1129
+#: elf32-sh.c:1142
#, c-format
msgid "%s: 0x%lx: warning: could not find expected reloc"
msgstr ""
-#: elf32-sh.c:1166
+#: elf32-sh.c:1178
#, c-format
msgid "%s: 0x%lx: warning: symbol in unexpected section"
msgstr ""
-#: elf32-sh.c:1288
+#: elf32-sh.c:1300
#, c-format
msgid "%s: 0x%lx: warning: could not find expected COUNT reloc"
msgstr ""
-#: elf32-sh.c:1297
+#: elf32-sh.c:1309
#, c-format
msgid "%s: 0x%lx: warning: bad count"
msgstr ""
-#: elf32-sh.c:1690 elf32-sh.c:2077
+#: elf32-sh.c:1703 elf32-sh.c:2093
#, c-format
msgid "%s: 0x%lx: fatal: reloc overflow while relaxing"
msgstr ""
-#: elf32-sh.c:3171
+#: elf32-sh.c:3200
#, c-format
msgid "%s: 0x%lx: fatal: unaligned branch target for relax-support relocation"
msgstr ""
-#: elf32-sparc.c:1519 elf64-sparc.c:2263
+#: elf32-sparc.c:1537 elf64-sparc.c:2281
#, c-format
msgid "%s: probably compiled without -fPIC?"
msgstr ""
-#: elf32-sparc.c:1976
+#: elf32-sparc.c:1990
#, c-format
msgid "%s: compiled for a 64 bit system and target is 32 bit"
msgstr ""
-#: elf32-sparc.c:1990
+#: elf32-sparc.c:2004
#, c-format
msgid "%s: linking little endian files with big endian files"
msgstr ""
-#: elf32-v850.c:675
+#: elf32-v850.c:684
#, c-format
msgid "Variable `%s' cannot occupy in multiple small data regions"
msgstr ""
-#: elf32-v850.c:678
+#: elf32-v850.c:687
#, c-format
msgid ""
"Variable `%s' can only be in one of the small, zero, and tiny data regions"
msgstr ""
-#: elf32-v850.c:681
+#: elf32-v850.c:690
#, c-format
msgid ""
"Variable `%s' cannot be in both small and zero data regions simultaneously"
msgstr ""
-#: elf32-v850.c:684
+#: elf32-v850.c:693
#, c-format
msgid ""
"Variable `%s' cannot be in both small and tiny data regions simultaneously"
msgstr ""
-#: elf32-v850.c:687
+#: elf32-v850.c:696
#, c-format
msgid ""
"Variable `%s' cannot be in both zero and tiny data regions simultaneously"
msgstr ""
-#: elf32-v850.c:1064
+#: elf32-v850.c:1074
msgid "FAILED to find previous HI16 reloc\n"
msgstr ""
-#: elf32-v850.c:1693
+#: elf32-v850.c:1707
msgid "could not locate special linker symbol __gp"
msgstr ""
-#: elf32-v850.c:1697
+#: elf32-v850.c:1711
msgid "could not locate special linker symbol __ep"
msgstr ""
-#: elf32-v850.c:1701
+#: elf32-v850.c:1715
msgid "could not locate special linker symbol __ctbp"
msgstr ""
-#: elf32-v850.c:1890
+#: elf32-v850.c:1908
#, c-format
msgid "%s: Architecture mismatch with previous modules"
msgstr ""
-#: elf32-v850.c:1909
+#: elf32-v850.c:1928
#, c-format
msgid "private flags = %lx: "
msgstr ""
-#: elf32-v850.c:1914
+#: elf32-v850.c:1933
msgid "v850 architecture"
msgstr ""
-#: elf32-v850.c:1915
+#: elf32-v850.c:1934
msgid "v850e architecture"
msgstr ""
-#: elf32-v850.c:1916
+#: elf32-v850.c:1935
msgid "v850ea architecture"
msgstr ""
-#: elf64-alpha.c:986
+#: elf64-alpha.c:857
msgid "GPDISP relocation did not find ldah and lda instructions"
msgstr ""
-#: elf64-alpha.c:3055
+#: elf64-alpha.c:2909
#, c-format
msgid "%s: .got subsegment exceeds 64K (size %d)"
msgstr ""
-#: elf64-hppa.c:2032
+#: elf64-alpha.c:3463 elf64-alpha.c:3475
+#, c-format
+msgid "%s: gp-relative relocation against dynamic symbol %s"
+msgstr ""
+
+#: elf64-hppa.c:2043
#, c-format
msgid "stub entry for %s cannot load .plt, dp offset = %ld"
msgstr ""
-#: elf64-sparc.c:1249
+#: elf64-ppc.c:1469 libbfd.c:1436
+#, c-format
+msgid "%s: compiled for a big endian system and target is little endian"
+msgstr ""
+
+#: elf64-ppc.c:1471 libbfd.c:1438
+#, c-format
+msgid "%s: compiled for a little endian system and target is big endian"
+msgstr ""
+
+#: elf64-ppc.c:3545
+#, c-format
+msgid "%s: Relocation %s is not supported for symbol %s."
+msgstr ""
+
+#: elf64-ppc.c:3589
+#, c-format
+msgid "%s: error: relocation %s not a multiple of 4"
+msgstr ""
+
+#: elf64-ppc.c:3742
+#, c-format
+msgid "linkage table overflow against `%s'"
+msgstr ""
+
+#: elf64-sparc.c:1272
#, c-format
msgid "%s: check_relocs: unhandled reloc type %d"
msgstr ""
-#: elf64-sparc.c:1286
+#: elf64-sparc.c:1309
msgid "%s: Only registers %%g[2367] can be declared using STT_REGISTER"
msgstr ""
-#: elf64-sparc.c:1306
-msgid ""
-"Register %%g%d used incompatibly: previously declared in %s to %s, in %s "
-"redefined to %s"
+#: elf64-sparc.c:1329
+msgid "Register %%g%d used incompatibly: %s in %s"
msgstr ""
-#: elf64-sparc.c:1329
+#: elf64-sparc.c:1333 elf64-sparc.c:1357 elf64-sparc.c:1406
#, c-format
-msgid "Symbol `%s' has differing types: previously %s, REGISTER in %s"
+msgid " previously %s in %s"
msgstr ""
-#: elf64-sparc.c:1375
+#: elf64-sparc.c:1354 elf64-sparc.c:1403
#, c-format
-msgid "Symbol `%s' has differing types: REGISTER in %s, %s in %s"
+msgid "Symbol `%s' has differing types: %s in %s"
msgstr ""
-#: elf64-sparc.c:2978
+#: elf64-sparc.c:3011
#, c-format
msgid "%s: linking UltraSPARC specific with HAL specific code"
msgstr ""
-#: elf.c:330
+#: elf.c:338
#, c-format
msgid "%s: invalid string offset %u >= %lu for section `%s'"
msgstr ""
-#: elf.c:590
+#: elf.c:443
+#, c-format
+msgid "%s: invalid SHT_GROUP entry"
+msgstr ""
+
+#: elf.c:524
+#, c-format
+msgid "%s: no group info for section %s"
+msgstr ""
+
+#: elf.c:785
msgid ""
"\n"
"Program Header:\n"
msgstr ""
-#: elf.c:638
+#: elf.c:833
msgid ""
"\n"
"Dynamic Section:\n"
msgstr ""
-#: elf.c:767
+#: elf.c:962
msgid ""
"\n"
"Version definitions:\n"
msgstr ""
-#: elf.c:790
+#: elf.c:985
msgid ""
"\n"
"Version References:\n"
msgstr ""
-#: elf.c:795
+#: elf.c:990
#, c-format
msgid " required from %s:\n"
msgstr ""
-#: elf.c:1385
+#: elf.c:1600
#, c-format
msgid "%s: invalid link %lu for reloc section %s (index %u)"
msgstr ""
-#: elf.c:2146
-#, c-format
-msgid ""
-"creating section symbol, name = %s, value = 0x%.8lx, index = %d, section = "
-"0x%.8lx\n"
-msgstr ""
-
-#: elf.c:2749
+#: elf.c:3068
#, c-format
msgid "%s: Not enough room for program headers (allocated %u, need %u)"
msgstr ""
-#: elf.c:2848
+#: elf.c:3167
#, c-format
msgid "%s: Not enough room for program headers, try linking with -N"
msgstr ""
-#: elf.c:2974
+#: elf.c:3293
#, c-format
msgid "Error: First section in segment (%s) starts at 0x%x"
msgstr ""
-#: elf.c:2977
+#: elf.c:3296
#, c-format
msgid " whereas segment starts at 0x%x"
msgstr ""
-#: elf.c:3250
+#: elf.c:3569
#, c-format
msgid "%s: warning: allocated section `%s' not in segment"
msgstr ""
-#: elf.c:3655
+#: elf.c:3887
#, c-format
msgid "%s: symbol `%s' required but not present"
msgstr ""
-#: elf.c:3664
+#: elf.c:3896
#, c-format
msgid ""
"elf_symbol_from_bfd_symbol 0x%.8lx, name = %s, sym num = %d, flags = "
"0x%.8lx%s\n"
msgstr ""
-#: elf.c:3905
+#: elf.c:4137
#, c-format
msgid "%s: warning: Empty loadable segment detected\n"
msgstr ""
-#: elf.c:5290
+#: elf.c:5522
#, c-format
msgid "%s: unsupported relocation type %s"
msgstr ""
-#: elfcode.h:1085
+#: elfcode.h:1096
#, c-format
msgid "%s: version count (%ld) does not match symbol count (%ld)"
msgstr ""
-#: elflink.c:431
+#: elflink.c:434
#, c-format
-msgid "%s: Section %s is already to large to put hole of %ld bytes in"
+msgid "%s: Section %s is too large to add hole of %ld bytes"
msgstr ""
-#: elflink.h:1468
+#: elflink.h:1487
#, c-format
msgid "%s: %s: invalid version %u (max %d)"
msgstr ""
-#: elflink.h:1509
+#: elflink.h:1528
#, c-format
msgid "%s: %s: invalid needed version %d"
msgstr ""
-#: elflink.h:1629
+#: elflink.h:1648
#, c-format
msgid "Warning: size of symbol `%s' changed from %lu to %lu in %s"
msgstr ""
-#: elflink.h:1875
+#: elflink.h:1894
#, c-format
msgid "%s: warning: unexpected redefinition of `%s'"
msgstr ""
-#: elflink.h:3676
+#: elflink.h:3730
#, c-format
msgid "warning: type and size of dynamic symbol `%s' are not defined"
msgstr ""
-#: elflink.h:3948
+#: elflink.h:4037
#, c-format
msgid "%s: undefined versioned symbol name %s"
msgstr ""
-#: elflink.h:4169 elflink.h:4177 elflink.h:5480 elflink.h:6420
+#: elflink.h:4264 elflink.h:4272 elflink.h:5830 elflink.h:6807
msgid "Error: out of memory"
msgstr ""
-#: elflink.h:5258
+#: elflink.h:4434
+msgid "Not enough memory to sort relocations"
+msgstr ""
+
+#: elflink.h:5608
#, c-format
msgid "%s: could not find output section %s for input section %s"
msgstr ""
-#: elflink.h:5661
-#, c-format
-msgid "%s: invalid section symbol index 0x%x (%s) ingored"
+#: elflink.h:6155
+msgid "warning: relocation against removed section; zeroing"
msgstr ""
-#: i386linux.c:450 m68klinux.c:454 sparclinux.c:452
+#: i386linux.c:455 m68klinux.c:459 sparclinux.c:456
#, c-format
msgid "Output file requires shared library `%s'\n"
msgstr ""
-#: i386linux.c:458 m68klinux.c:462 sparclinux.c:460
+#: i386linux.c:463 m68klinux.c:467 sparclinux.c:464
#, c-format
msgid "Output file requires shared library `%s.so.%s'\n"
msgstr ""
-#: i386linux.c:646 i386linux.c:696 m68klinux.c:653 m68klinux.c:701
-#: sparclinux.c:649 sparclinux.c:699
+#: i386linux.c:653 i386linux.c:703 m68klinux.c:660 m68klinux.c:708
+#: sparclinux.c:655 sparclinux.c:705
#, c-format
msgid "Symbol %s not defined for fixups\n"
msgstr ""
-#: i386linux.c:720 m68klinux.c:725 sparclinux.c:723
+#: i386linux.c:727 m68klinux.c:732 sparclinux.c:729
msgid "Warning: fixup count mismatch\n"
msgstr ""
-#: ieee.c:168
+#: ieee.c:235
#, c-format
msgid "%s: string too long (%d chars, max 65535)"
msgstr ""
-#: ieee.c:298
+#: ieee.c:365
#, c-format
msgid "%s: unrecognized symbol `%s' flags 0x%x"
msgstr ""
-#: ieee.c:794
+#: ieee.c:877
#, c-format
msgid "%s: unimplemented ATI record %u for symbol %u"
msgstr ""
-#: ieee.c:819
+#: ieee.c:902
#, c-format
msgid "%s: unexpected ATN type %d in external part"
msgstr ""
-#: ieee.c:841
+#: ieee.c:924
#, c-format
msgid "%s: unexpected type after ATN"
msgstr ""
#: ihex.c:369
#, c-format
-msgid "%s:%d: bad checksum in Intel Hex file (expected %u, found %u)"
+msgid "%s:%u: bad checksum in Intel Hex file (expected %u, found %u)"
msgstr ""
-#: ihex.c:421
+#: ihex.c:423
#, c-format
-msgid "%s:%d: bad extended address record length in Intel Hex file"
+msgid "%s:%u: bad extended address record length in Intel Hex file"
msgstr ""
-#: ihex.c:438
+#: ihex.c:440
#, c-format
-msgid "%s:%d: bad extended start address length in Intel Hex file"
+msgid "%s:%u: bad extended start address length in Intel Hex file"
msgstr ""
-#: ihex.c:455
+#: ihex.c:457
#, c-format
-msgid "%s:%d: bad extended linear address record length in Intel Hex file"
+msgid "%s:%u: bad extended linear address record length in Intel Hex file"
msgstr ""
-#: ihex.c:472
+#: ihex.c:474
#, c-format
-msgid "%s:%d: bad extended linear start address length in Intel Hex file"
+msgid "%s:%u: bad extended linear start address length in Intel Hex file"
msgstr ""
-#: ihex.c:489
+#: ihex.c:491
#, c-format
-msgid "%s:%d: unrecognized ihex type %u in Intel Hex file\n"
+msgid "%s:%u: unrecognized ihex type %u in Intel Hex file\n"
msgstr ""
-#: ihex.c:609
+#: ihex.c:611
#, c-format
msgid "%s: internal error in ihex_read_section"
msgstr ""
-#: ihex.c:644
+#: ihex.c:646
#, c-format
msgid "%s: bad section length in ihex_read_section"
msgstr ""
-#: ihex.c:858
+#: ihex.c:864
#, c-format
msgid "%s: address 0x%s out of range for Intex Hex file"
msgstr ""
-#: libbfd.c:473
+#: libbfd.c:492
#, c-format
msgid "not mapping: data=%lx mapped=%d\n"
msgstr ""
-#: libbfd.c:476
+#: libbfd.c:495
msgid "not mapping: env var not set\n"
msgstr ""
-#: libbfd.c:1371
+#: libbfd.c:1463
#, c-format
-msgid "%s: compiled for a big endian system and target is little endian"
+msgid "Deprecated %s called"
msgstr ""
-#: libbfd.c:1373
+#: libbfd.c:1465
#, c-format
-msgid "%s: compiled for a little endian system and target is big endian"
+msgid " at %s line %d in %s\n"
msgstr ""
-#: linker.c:1808
+#: linker.c:1849
#, c-format
msgid "%s: indirect symbol `%s' to `%s' is a loop"
msgstr ""
-#: linker.c:2693
+#: linker.c:2745
#, c-format
msgid "Attempt to do relocateable link with %s input and %s output"
msgstr ""
-#: merge.c:883
+#: merge.c:892
#, c-format
msgid "%s: access beyond end of merged section (%ld + %ld)"
msgstr ""
-#: oasys.c:1016
+#: oasys.c:1036
#, c-format
msgid "%s: can not represent section `%s' in oasys"
msgstr ""
-#: osf-core.c:146
+#: osf-core.c:152
#, c-format
msgid "Unhandled OSF/1 core file section type %d\n"
msgstr ""
#. XXX code yet to be written.
-#: peicode.h:796
+#: peicode.h:785
#, c-format
msgid "%s: Unhandled import type; %x"
msgstr ""
-#: peicode.h:801
+#: peicode.h:790
#, c-format
msgid "%s: Unrecognised import type; %x"
msgstr ""
-#: peicode.h:815
+#: peicode.h:804
#, c-format
msgid "%s: Unrecognised import name type; %x"
msgstr ""
-#: peicode.h:1172
+#: peicode.h:1162
#, c-format
msgid "%s: Unrecognised machine type (0x%x) in Import Library Format archive"
msgstr ""
-#: peicode.h:1184
+#: peicode.h:1174
#, c-format
msgid ""
"%s: Recognised but unhandled machine type (0x%x) in Import Library Format "
"archive"
msgstr ""
-#: peicode.h:1201
+#: peicode.h:1191
#, c-format
msgid "%s: size field is zero in Import Library Format header"
msgstr ""
-#: peicode.h:1229
+#: peicode.h:1219
#, c-format
msgid "%s: string not null terminated in ILF object file."
msgstr ""
-#: pe-mips.c:654
+#: pe-mips.c:658
#, c-format
msgid "%s: `ld -r' not supported with PE MIPS objects\n"
msgstr ""
-#: pe-mips.c:816
+#: pe-mips.c:820
#, c-format
msgid "%s: jump too far away\n"
msgstr ""
-#: pe-mips.c:843
+#: pe-mips.c:847
#, c-format
msgid "%s: bad pair/reflo after refhi\n"
msgstr ""
-#: ppcboot.c:423
+#: ppcboot.c:427
msgid ""
"\n"
"ppcboot header:\n"
msgstr ""
-#: ppcboot.c:424
+#: ppcboot.c:428
#, c-format
msgid "Entry offset = 0x%.8lx (%ld)\n"
msgstr ""
-#: ppcboot.c:425
+#: ppcboot.c:429
#, c-format
msgid "Length = 0x%.8lx (%ld)\n"
msgstr ""
-#: ppcboot.c:428
+#: ppcboot.c:432
#, c-format
msgid "Flag field = 0x%.2x\n"
msgstr ""
-#: ppcboot.c:434
+#: ppcboot.c:438
#, c-format
msgid "Partition name = \"%s\"\n"
msgstr ""
-#: ppcboot.c:453
+#: ppcboot.c:457
#, c-format
msgid ""
"\n"
"Partition[%d] start = { 0x%.2x, 0x%.2x, 0x%.2x, 0x%.2x }\n"
msgstr ""
-#: ppcboot.c:459
+#: ppcboot.c:463
#, c-format
msgid "Partition[%d] end = { 0x%.2x, 0x%.2x, 0x%.2x, 0x%.2x }\n"
msgstr ""
-#: ppcboot.c:465
+#: ppcboot.c:469
#, c-format
msgid "Partition[%d] sector = 0x%.8lx (%ld)\n"
msgstr ""
-#: ppcboot.c:466
+#: ppcboot.c:470
#, c-format
msgid "Partition[%d] length = 0x%.8lx (%ld)\n"
msgstr ""
-#: som.c:5356
+#: som.c:5401
msgid "som_sizeof_headers unimplemented"
msgstr ""
-#: srec.c:301
+#: srec.c:302
#, c-format
msgid "%s:%d: Unexpected character `%s' in S-record file\n"
msgstr ""
msgid "Unsupported .stab relocation"
msgstr ""
-#: vms-gsd.c:354
+#: vms-gsd.c:355
#, c-format
msgid "bfd_make_section (%s) failed"
msgstr ""
-#: vms-gsd.c:368
+#: vms-gsd.c:370
#, c-format
msgid "bfd_set_section_flags (%s, %x) failed"
msgstr ""
-#: vms-gsd.c:404
+#: vms-gsd.c:406
#, c-format
msgid "Size mismatch section %s=%lx, %s=%lx"
msgstr ""
-#: vms-gsd.c:699
+#: vms-gsd.c:703
#, c-format
msgid "unknown gsd/egsd subtype %d"
msgstr ""
-#: vms-hdr.c:403
+#: vms-hdr.c:406
msgid "Object module NOT error-free !\n"
msgstr ""
-#: vms-misc.c:537
+#: vms-misc.c:543
#, c-format
msgid "Stack overflow (%d) in _bfd_vms_push"
msgstr ""
-#: vms-misc.c:555
+#: vms-misc.c:561
msgid "Stack underflow in _bfd_vms_pop"
msgstr ""
-#: vms-misc.c:911
+#: vms-misc.c:919
msgid "_bfd_vms_output_counted called with zero bytes"
msgstr ""
-#: vms-misc.c:916
+#: vms-misc.c:924
msgid "_bfd_vms_output_counted called with too many bytes"
msgstr ""
-#: vms-misc.c:1047
+#: vms-misc.c:1055
#, c-format
msgid "Symbol %s replaced by %s\n"
msgstr ""
-#: vms-misc.c:1109
+#: vms-misc.c:1117
#, c-format
msgid "failed to enter %s"
msgstr ""
-#: vms-tir.c:68
+#: vms-tir.c:78
msgid "No Mem !"
msgstr ""
-#: vms-tir.c:302
+#: vms-tir.c:313
msgid "Bad section index in ETIR_S_C_STA_PQ"
msgstr ""
-#: vms-tir.c:317
+#: vms-tir.c:328
#, c-format
msgid "Unsupported STA cmd %d"
msgstr ""
-#: vms-tir.c:322 vms-tir.c:1274
+#: vms-tir.c:333 vms-tir.c:1301
#, c-format
msgid "Reserved STA cmd %d"
msgstr ""
-#: vms-tir.c:428
+#: vms-tir.c:443
#, c-format
msgid "ETIR_S_C_STO_GBL: no symbol \"%s\""
msgstr ""
-#: vms-tir.c:449
+#: vms-tir.c:465
#, c-format
msgid "ETIR_S_C_STO_CA: no symbol \"%s\""
msgstr ""
-#: vms-tir.c:462
+#: vms-tir.c:478
msgid "ETIR_S_C_STO_RB/AB: Not supported"
msgstr ""
-#: vms-tir.c:520
+#: vms-tir.c:538
msgid "ETIR_S_C_STO_LP_PSB: Not supported"
msgstr ""
-#: vms-tir.c:526
+#: vms-tir.c:544
msgid "ETIR_S_C_STO_HINT_GBL: not implemented"
msgstr ""
-#: vms-tir.c:532
+#: vms-tir.c:550
msgid "ETIR_S_C_STO_HINT_PS: not implemented"
msgstr ""
-#: vms-tir.c:536 vms-tir.c:1446
+#: vms-tir.c:554 vms-tir.c:1473
#, c-format
msgid "Reserved STO cmd %d"
msgstr ""
-#: vms-tir.c:649
+#: vms-tir.c:667
msgid "ETIR_S_C_OPR_INSV: Not supported"
msgstr ""
-#: vms-tir.c:667
+#: vms-tir.c:685
msgid "ETIR_S_C_OPR_USH: Not supported"
msgstr ""
-#: vms-tir.c:673
+#: vms-tir.c:691
msgid "ETIR_S_C_OPR_ROT: Not supported"
msgstr ""
-#: vms-tir.c:692
+#: vms-tir.c:710
msgid "ETIR_S_C_OPR_REDEF: Not supported"
msgstr ""
-#: vms-tir.c:698
+#: vms-tir.c:716
msgid "ETIR_S_C_OPR_DFLIT: Not supported"
msgstr ""
-#: vms-tir.c:702 vms-tir.c:1641
+#: vms-tir.c:720 vms-tir.c:1668
#, c-format
msgid "Reserved OPR cmd %d"
msgstr ""
-#: vms-tir.c:770 vms-tir.c:1710
+#: vms-tir.c:788 vms-tir.c:1737
#, c-format
msgid "Reserved CTL cmd %d"
msgstr ""
-#: vms-tir.c:798
+#: vms-tir.c:816
msgid "ETIR_S_C_STC_LP: not supported"
msgstr ""
-#: vms-tir.c:816
+#: vms-tir.c:834
msgid "ETIR_S_C_STC_GBL: not supported"
msgstr ""
-#: vms-tir.c:824
+#: vms-tir.c:842
msgid "ETIR_S_C_STC_GCA: not supported"
msgstr ""
-#: vms-tir.c:833
+#: vms-tir.c:851
msgid "ETIR_S_C_STC_PS: not supported"
msgstr ""
#. * arg: -
#. *
#.
-#: vms-tir.c:1174
+#: vms-tir.c:1199
msgid "Stack-from-image not implemented"
msgstr ""
-#: vms-tir.c:1194
+#: vms-tir.c:1219
msgid "Stack-entry-mask not fully implemented"
msgstr ""
#. * compare argument descriptor with symbol argument (ARG$V_PASSMECH)
#. * and stack TRUE (args match) or FALSE (args dont match) value
#.
-#: vms-tir.c:1210
+#: vms-tir.c:1235
msgid "PASSMECH not fully implemented"
msgstr ""
-#: vms-tir.c:1230
+#: vms-tir.c:1256
msgid "Stack-local-symbol not fully implemented"
msgstr ""
-#: vms-tir.c:1245
+#: vms-tir.c:1271
msgid "Stack-literal not fully implemented"
msgstr ""
-#: vms-tir.c:1267
+#: vms-tir.c:1294
msgid "Stack-local-symbol-entry-point-mask not fully implemented"
msgstr ""
-#: vms-tir.c:1442
+#: vms-tir.c:1469
#, c-format
msgid "Unimplemented STO cmd %d"
msgstr ""
-#: vms-tir.c:1581
+#: vms-tir.c:1608
msgid "TIR_S_C_OPR_ASH incomplete"
msgstr ""
-#: vms-tir.c:1595
+#: vms-tir.c:1622
msgid "TIR_S_C_OPR_USH incomplete"
msgstr ""
-#: vms-tir.c:1609
+#: vms-tir.c:1636
msgid "TIR_S_C_OPR_ROT incomplete"
msgstr ""
#.
#. * redefine symbol to current location
#.
-#: vms-tir.c:1630
+#: vms-tir.c:1657
msgid "TIR_S_C_OPR_REDEF not supported"
msgstr ""
#.
#. * define a literal
#.
-#: vms-tir.c:1637
+#: vms-tir.c:1664
msgid "TIR_S_C_OPR_DFLIT not supported"
msgstr ""
-#: vms-tir.c:1691
+#: vms-tir.c:1718
msgid "TIR_S_C_CTL_DFLOC not fully implemented"
msgstr ""
-#: vms-tir.c:1699
+#: vms-tir.c:1726
msgid "TIR_S_C_CTL_STLOC not fully implemented"
msgstr ""
-#: vms-tir.c:1707
+#: vms-tir.c:1734
msgid "TIR_S_C_CTL_STKDL not fully implemented"
msgstr ""
-#: vms-tir.c:1761
+#: vms-tir.c:1791
#, c-format
msgid "Obj code %d not found"
msgstr ""
-#: vms-tir.c:2102
+#: vms-tir.c:2137
#, c-format
msgid "SEC_RELOC with no relocs in section %s"
msgstr ""
-#: vms-tir.c:2376
+#: vms-tir.c:2424
#, c-format
msgid "Unhandled relocation %s"
msgstr ""
-#: xcofflink.c:1220
+#: xcofflink.c:1241
#, c-format
msgid "%s: `%s' has line numbers but no enclosing section"
msgstr ""
-#: xcofflink.c:1267
+#: xcofflink.c:1294
#, c-format
msgid "%s: class %d symbol `%s' has no aux entries"
msgstr ""
-#: xcofflink.c:1290
+#: xcofflink.c:1317
#, c-format
msgid "%s: symbol `%s' has unrecognized csect type %d"
msgstr ""
-#: xcofflink.c:1302
+#: xcofflink.c:1329
#, c-format
msgid "%s: bad XTY_ER symbol `%s': class %d scnum %d scnlen %d"
msgstr ""
-#: xcofflink.c:1340
+#: xcofflink.c:1365
#, c-format
msgid "%s: XMC_TC0 symbol `%s' is class %d scnlen %d"
msgstr ""
-#: xcofflink.c:1493
+#: xcofflink.c:1517
#, c-format
msgid "%s: csect `%s' not in enclosing section"
msgstr ""
-#: xcofflink.c:1598
+#: xcofflink.c:1624
#, c-format
msgid "%s: misplaced XTY_LD `%s'"
msgstr ""
-#: xcofflink.c:1916
+#: xcofflink.c:1948
#, c-format
msgid "%s: reloc %s:%d not in csect"
msgstr ""
-#: xcofflink.c:2051
+#: xcofflink.c:2083
#, c-format
msgid "%s: XCOFF shared object when not producing XCOFF output"
msgstr ""
-#: xcofflink.c:2072
+#: xcofflink.c:2104
#, c-format
msgid "%s: dynamic object with no .loader section"
msgstr ""
-#: xcofflink.c:2715
+#: xcofflink.c:2749
#, c-format
msgid "%s: no such symbol"
msgstr ""
-#: xcofflink.c:2848
+#: xcofflink.c:2890
msgid "error: undefined symbol __rtinit"
msgstr ""
-#: xcofflink.c:3389
+#: xcofflink.c:3423
#, c-format
msgid "warning: attempt to export undefined symbol `%s'"
msgstr ""
-#: xcofflink.c:4358
+#: xcofflink.c:4421
#, c-format
msgid "TOC overflow: 0x%lx > 0x10000; try -mminimal-toc when compiling"
msgstr ""
-#: xcofflink.c:5192 xcofflink.c:5603 xcofflink.c:5665 xcofflink.c:5968
+#: xcofflink.c:5261 xcofflink.c:5723 xcofflink.c:5785 xcofflink.c:6086
#, c-format
msgid "%s: loader reloc in unrecognized section `%s'"
msgstr ""
-#: xcofflink.c:5214 xcofflink.c:5979
+#: xcofflink.c:5283 xcofflink.c:6097
#, c-format
msgid "%s: `%s' in loader reloc but not loader sym"
msgstr ""
-#: xcofflink.c:5229
+#: xcofflink.c:5298
#, c-format
msgid "%s: loader reloc in read-only section %s"
msgstr ""
-#: elf32-ia64.c:2046 elf64-ia64.c:2046
+#: elf32-ia64.c:2083 elf64-ia64.c:2083
msgid "@pltoff reloc against local symbol"
msgstr ""
-#: elf32-ia64.c:2104 elf64-ia64.c:2104
+#: elf32-ia64.c:2141 elf64-ia64.c:2141
msgid "non-zero addend in @fptr reloc"
msgstr ""
-#: elf32-ia64.c:3294 elf64-ia64.c:3294
+#: elf32-ia64.c:3321 elf64-ia64.c:3321
#, c-format
msgid "%s: short data segment overflowed (0x%lx >= 0x400000)"
msgstr ""
-#: elf32-ia64.c:3305 elf64-ia64.c:3305
+#: elf32-ia64.c:3332 elf64-ia64.c:3332
#, c-format
msgid "%s: __gp does not cover short data segment"
msgstr ""
-#: elf32-ia64.c:3575 elf64-ia64.c:3575
+#: elf32-ia64.c:3605 elf64-ia64.c:3605
#, c-format
msgid "%s: linking non-pic code in a shared library"
msgstr ""
-#: elf32-ia64.c:3608 elf64-ia64.c:3608
+#: elf32-ia64.c:3638 elf64-ia64.c:3638
#, c-format
msgid "%s: @gprel relocation against dynamic symbol %s"
msgstr ""
-#: elf32-ia64.c:3744 elf64-ia64.c:3744
+#: elf32-ia64.c:3776 elf64-ia64.c:3776
#, c-format
msgid "%s: dynamic relocation against speculation fixup"
msgstr ""
-#: elf32-ia64.c:3752 elf64-ia64.c:3752
+#: elf32-ia64.c:3784 elf64-ia64.c:3784
#, c-format
msgid "%s: speculation fixup against undefined weak symbol"
msgstr ""
-#: elf32-ia64.c:3935 elf64-ia64.c:3935
+#: elf32-ia64.c:3967 elf64-ia64.c:3967
msgid "unsupported reloc"
msgstr ""
-#: elf32-ia64.c:4232 elf64-ia64.c:4232
+#: elf32-ia64.c:4265 elf64-ia64.c:4265
#, c-format
msgid "%s: linking trap-on-NULL-dereference with non-trapping files"
msgstr ""
-#: elf32-ia64.c:4241 elf64-ia64.c:4241
+#: elf32-ia64.c:4274 elf64-ia64.c:4274
#, c-format
msgid "%s: linking big-endian files with little-endian files"
msgstr ""
-#: elf32-ia64.c:4250 elf64-ia64.c:4250
+#: elf32-ia64.c:4283 elf64-ia64.c:4283
#, c-format
msgid "%s: linking 64-bit files with 32-bit files"
msgstr ""
-#: elf32-ia64.c:4259 elf64-ia64.c:4259
+#: elf32-ia64.c:4292 elf64-ia64.c:4292
#, c-format
msgid "%s: linking constant-gp files with non-constant-gp files"
msgstr ""
-#: elf32-ia64.c:4269 elf64-ia64.c:4269
+#: elf32-ia64.c:4302 elf64-ia64.c:4302
#, c-format
msgid "%s: linking auto-pic files with non-auto-pic files"
msgstr ""
-#: peigen.c:1009 pepigen.c:1009
+#: peigen.c:964 pepigen.c:964
#, c-format
msgid "%s: line number overflow: 0x%lx > 0xffff"
msgstr ""
-#: peigen.c:1027 pepigen.c:1027
+#: peigen.c:981 pepigen.c:981
#, c-format
msgid "%s: reloc overflow 1: 0x%lx > 0xffff"
msgstr ""
-#: peigen.c:1040 pepigen.c:1040
+#: peigen.c:995 pepigen.c:995
msgid "Export Directory [.edata (or where ever we found it)]"
msgstr ""
-#: peigen.c:1041 pepigen.c:1041
+#: peigen.c:996 pepigen.c:996
msgid "Import Directory [parts of .idata]"
msgstr ""
-#: peigen.c:1042 pepigen.c:1042
+#: peigen.c:997 pepigen.c:997
msgid "Resource Directory [.rsrc]"
msgstr ""
-#: peigen.c:1043 pepigen.c:1043
+#: peigen.c:998 pepigen.c:998
msgid "Exception Directory [.pdata]"
msgstr ""
-#: peigen.c:1044 pepigen.c:1044
+#: peigen.c:999 pepigen.c:999
msgid "Security Directory"
msgstr ""
-#: peigen.c:1045 pepigen.c:1045
+#: peigen.c:1000 pepigen.c:1000
msgid "Base Relocation Directory [.reloc]"
msgstr ""
-#: peigen.c:1046 pepigen.c:1046
+#: peigen.c:1001 pepigen.c:1001
msgid "Debug Directory"
msgstr ""
-#: peigen.c:1047 pepigen.c:1047
+#: peigen.c:1002 pepigen.c:1002
msgid "Description Directory"
msgstr ""
-#: peigen.c:1048 pepigen.c:1048
+#: peigen.c:1003 pepigen.c:1003
msgid "Special Directory"
msgstr ""
-#: peigen.c:1049 pepigen.c:1049
+#: peigen.c:1004 pepigen.c:1004
msgid "Thread Storage Directory [.tls]"
msgstr ""
-#: peigen.c:1050 pepigen.c:1050
+#: peigen.c:1005 pepigen.c:1005
msgid "Load Configuration Directory"
msgstr ""
-#: peigen.c:1051 pepigen.c:1051
+#: peigen.c:1006 pepigen.c:1006
msgid "Bound Import Directory"
msgstr ""
-#: peigen.c:1052 pepigen.c:1052
+#: peigen.c:1007 pepigen.c:1007
msgid "Import Address Table Directory"
msgstr ""
-#: peigen.c:1053 pepigen.c:1053
+#: peigen.c:1008 pepigen.c:1008
msgid "Delay Import Directory"
msgstr ""
-#: peigen.c:1054 peigen.c:1055 pepigen.c:1054 pepigen.c:1055
+#: peigen.c:1009 peigen.c:1010 pepigen.c:1009 pepigen.c:1010
msgid "Reserved"
msgstr ""
-#: peigen.c:1119 pepigen.c:1119
+#: peigen.c:1073 pepigen.c:1073
msgid ""
"\n"
"There is an import table, but the section containing it could not be found\n"
msgstr ""
-#: peigen.c:1124 pepigen.c:1124
+#: peigen.c:1078 pepigen.c:1078
#, c-format
msgid ""
"\n"
"There is an import table in %s at 0x%lx\n"
msgstr ""
-#: peigen.c:1163 pepigen.c:1163
+#: peigen.c:1115 pepigen.c:1115
#, c-format
msgid ""
"\n"
"Function descriptor located at the start address: %04lx\n"
msgstr ""
-#: peigen.c:1166 pepigen.c:1166
+#: peigen.c:1118 pepigen.c:1118
#, c-format
msgid "\tcode-base %08lx toc (loadable/actual) %08lx/%08lx\n"
msgstr ""
-#: peigen.c:1172 pepigen.c:1172
+#: peigen.c:1124 pepigen.c:1124
msgid ""
"\n"
"No reldata section! Function descriptor not decoded.\n"
msgstr ""
-#: peigen.c:1177 pepigen.c:1177
+#: peigen.c:1129 pepigen.c:1129
#, c-format
msgid ""
"\n"
"The Import Tables (interpreted %s section contents)\n"
msgstr ""
-#: peigen.c:1180 pepigen.c:1180
+#: peigen.c:1132 pepigen.c:1132
msgid " vma: Hint Time Forward DLL First\n"
msgstr ""
-#: peigen.c:1182 pepigen.c:1182
+#: peigen.c:1134 pepigen.c:1134
msgid " Table Stamp Chain Name Thunk\n"
msgstr ""
-#: peigen.c:1232 pepigen.c:1232
+#: peigen.c:1182 pepigen.c:1182
#, c-format
msgid ""
"\n"
"\tDLL Name: %s\n"
msgstr ""
-#: peigen.c:1236 peigen.c:1299 pepigen.c:1236 pepigen.c:1299
+#: peigen.c:1186 peigen.c:1249 pepigen.c:1186 pepigen.c:1249
msgid "\tvma: Hint/Ord Member-Name\n"
msgstr ""
-#: peigen.c:1298 pepigen.c:1298
+#: peigen.c:1248 pepigen.c:1248
msgid "\tThe Import Address Table (difference found)\n"
msgstr ""
-#: peigen.c:1305 pepigen.c:1305
+#: peigen.c:1255 pepigen.c:1255
msgid "\t>>> Ran out of IAT members!\n"
msgstr ""
-#: peigen.c:1324 pepigen.c:1324
+#: peigen.c:1273 pepigen.c:1273
msgid "\tThe Import Address Table is identical\n"
msgstr ""
-#: peigen.c:1397 pepigen.c:1397
+#: peigen.c:1345 pepigen.c:1345
msgid ""
"\n"
"There is an export table, but the section containing it could not be found\n"
msgstr ""
-#: peigen.c:1402 pepigen.c:1402
+#: peigen.c:1350 pepigen.c:1350
#, c-format
msgid ""
"\n"
"There is an export table in %s at 0x%lx\n"
msgstr ""
-#: peigen.c:1433 pepigen.c:1433
+#: peigen.c:1381 pepigen.c:1381
#, c-format
msgid ""
"\n"
"\n"
msgstr ""
-#: peigen.c:1437 pepigen.c:1437
+#: peigen.c:1385 pepigen.c:1385
#, c-format
msgid "Export Flags \t\t\t%lx\n"
msgstr ""
-#: peigen.c:1440 pepigen.c:1440
+#: peigen.c:1388 pepigen.c:1388
#, c-format
msgid "Time/Date stamp \t\t%lx\n"
msgstr ""
-#: peigen.c:1443 pepigen.c:1443
+#: peigen.c:1391 pepigen.c:1391
#, c-format
msgid "Major/Minor \t\t\t%d/%d\n"
msgstr ""
-#: peigen.c:1446 pepigen.c:1446
+#: peigen.c:1394 pepigen.c:1394
msgid "Name \t\t\t\t"
msgstr ""
-#: peigen.c:1452 pepigen.c:1452
+#: peigen.c:1400 pepigen.c:1400
#, c-format
msgid "Ordinal Base \t\t\t%ld\n"
msgstr ""
-#: peigen.c:1455 pepigen.c:1455
+#: peigen.c:1403 pepigen.c:1403
msgid "Number in:\n"
msgstr ""
-#: peigen.c:1458 pepigen.c:1458
+#: peigen.c:1406 pepigen.c:1406
#, c-format
msgid "\tExport Address Table \t\t%08lx\n"
msgstr ""
-#: peigen.c:1462 pepigen.c:1462
+#: peigen.c:1410 pepigen.c:1410
#, c-format
msgid "\t[Name Pointer/Ordinal] Table\t%08lx\n"
msgstr ""
-#: peigen.c:1465 pepigen.c:1465
+#: peigen.c:1413 pepigen.c:1413
msgid "Table Addresses\n"
msgstr ""
-#: peigen.c:1468 pepigen.c:1468
+#: peigen.c:1416 pepigen.c:1416
msgid "\tExport Address Table \t\t"
msgstr ""
-#: peigen.c:1473 pepigen.c:1473
+#: peigen.c:1421 pepigen.c:1421
msgid "\tName Pointer Table \t\t"
msgstr ""
-#: peigen.c:1478 pepigen.c:1478
+#: peigen.c:1426 pepigen.c:1426
msgid "\tOrdinal Table \t\t\t"
msgstr ""
-#: peigen.c:1492 pepigen.c:1492
+#: peigen.c:1441 pepigen.c:1441
#, c-format
msgid ""
"\n"
"Export Address Table -- Ordinal Base %ld\n"
msgstr ""
-#: peigen.c:1511 pepigen.c:1511
+#: peigen.c:1460 pepigen.c:1460
msgid "Forwarder RVA"
msgstr ""
-#: peigen.c:1522 pepigen.c:1522
+#: peigen.c:1471 pepigen.c:1471
msgid "Export RVA"
msgstr ""
-#: peigen.c:1529 pepigen.c:1529
+#: peigen.c:1478 pepigen.c:1478
msgid ""
"\n"
"[Ordinal/Name Pointer] Table\n"
msgstr ""
-#: peigen.c:1584 pepigen.c:1584
+#: peigen.c:1533 pepigen.c:1533
#, c-format
msgid "Warning, .pdata section size (%ld) is not a multiple of %d\n"
msgstr ""
-#: peigen.c:1588 pepigen.c:1588
+#: peigen.c:1537 pepigen.c:1537
msgid ""
"\n"
"The Function Table (interpreted .pdata section contents)\n"
msgstr ""
-#: peigen.c:1591 pepigen.c:1591
+#: peigen.c:1540 pepigen.c:1540
msgid " vma:\t\t\tBegin Address End Address Unwind Info\n"
msgstr ""
-#: peigen.c:1594 pepigen.c:1594
+#: peigen.c:1543 pepigen.c:1543
msgid " vma:\t\tBegin End EH EH PrologEnd Exception\n"
msgstr ""
-#: peigen.c:1596 pepigen.c:1596
+#: peigen.c:1545 pepigen.c:1545
msgid " \t\tAddress Address Handler Data Address Mask\n"
msgstr ""
-#: peigen.c:1668 pepigen.c:1668
+#: peigen.c:1613 pepigen.c:1613
msgid " Register save millicode"
msgstr ""
-#: peigen.c:1671 pepigen.c:1671
+#: peigen.c:1616 pepigen.c:1616
msgid " Register restore millicode"
msgstr ""
-#: peigen.c:1674 pepigen.c:1674
+#: peigen.c:1619 pepigen.c:1619
msgid " Glue code sequence"
msgstr ""
-#: peigen.c:1725 pepigen.c:1725
+#: peigen.c:1671 pepigen.c:1671
msgid ""
"\n"
"\n"
"PE File Base Relocations (interpreted .reloc section contents)\n"
msgstr ""
-#: peigen.c:1760 pepigen.c:1760
+#: peigen.c:1701 pepigen.c:1701
#, c-format
msgid ""
"\n"
"Virtual Address: %08lx Chunk size %ld (0x%lx) Number of fixups %ld\n"
msgstr ""
-#: peigen.c:1773 pepigen.c:1773
+#: peigen.c:1714 pepigen.c:1714
#, c-format
msgid "\treloc %4d offset %4x [%4lx] %s"
msgstr ""
#. The MS dumpbin program reportedly ands with 0xff0f before
#. printing the characteristics field. Not sure why. No reason to
#. emulate it here.
-#: peigen.c:1812 pepigen.c:1812
+#: peigen.c:1754 pepigen.c:1754
#, c-format
msgid ""
"\n"
ENUMDOC
Motorola Mcore relocations.
+ENUM
+ BFD_RELOC_MMIX_GETA
+ENUMX
+ BFD_RELOC_MMIX_GETA_1
+ENUMX
+ BFD_RELOC_MMIX_GETA_2
+ENUMX
+ BFD_RELOC_MMIX_GETA_3
+ENUMDOC
+ These are relocations for the GETA instruction.
+ENUM
+ BFD_RELOC_MMIX_CBRANCH
+ENUMX
+ BFD_RELOC_MMIX_CBRANCH_J
+ENUMX
+ BFD_RELOC_MMIX_CBRANCH_1
+ENUMX
+ BFD_RELOC_MMIX_CBRANCH_2
+ENUMX
+ BFD_RELOC_MMIX_CBRANCH_3
+ENUMDOC
+ These are relocations for a conditional branch instruction.
+ENUM
+ BFD_RELOC_MMIX_PUSHJ
+ENUMX
+ BFD_RELOC_MMIX_PUSHJ_1
+ENUMX
+ BFD_RELOC_MMIX_PUSHJ_2
+ENUMX
+ BFD_RELOC_MMIX_PUSHJ_3
+ENUMDOC
+ These are relocations for the PUSHJ instruction.
+ENUM
+ BFD_RELOC_MMIX_JMP
+ENUMX
+ BFD_RELOC_MMIX_JMP_1
+ENUMX
+ BFD_RELOC_MMIX_JMP_2
+ENUMX
+ BFD_RELOC_MMIX_JMP_3
+ENUMDOC
+ These are relocations for the JMP instruction.
+ENUM
+ BFD_RELOC_MMIX_ADDR19
+ENUMDOC
+ This is a relocation for a relative address as in a GETA instruction or
+ a branch.
+ENUM
+ BFD_RELOC_MMIX_ADDR27
+ENUMDOC
+ This is a relocation for a relative address as in a JMP instruction.
+ENUM
+ BFD_RELOC_MMIX_REG_OR_BYTE
+ENUMDOC
+ This is a relocation for an instruction field that may be a general
+ register or a value 0..255.
+ENUM
+ BFD_RELOC_MMIX_REG
+ENUMDOC
+ This is a relocation for an instruction field that may be a general
+ register.
+ENUM
+ BFD_RELOC_MMIX_BASE_PLUS_OFFSET
+ENUMDOC
+ This is a relocation for two instruction fields holding a register and
+ an offset, the equivalent of the relocation.
+ENUM
+ BFD_RELOC_MMIX_LOCAL
+ENUMDOC
+ This relocation is an assertion that the expression is not allocated as
+ a global register. It does not modify contents.
+
ENUM
BFD_RELOC_AVR_7_PCREL
ENUMDOC
. bfd_target_versados_flavour,
. bfd_target_msdos_flavour,
. bfd_target_ovax_flavour,
-. bfd_target_evax_flavour
+. bfd_target_evax_flavour,
+. bfd_target_mmo_flavour
.};
.
.enum bfd_endian { BFD_ENDIAN_BIG, BFD_ENDIAN_LITTLE, BFD_ENDIAN_UNKNOWN };
extern const bfd_target bfd_elf64_ia64_little_vec;
extern const bfd_target bfd_elf64_little_generic_vec;
extern const bfd_target bfd_elf64_littlemips_vec;
+extern const bfd_target bfd_elf64_mmix_vec;
extern const bfd_target bfd_elf64_powerpc_vec;
extern const bfd_target bfd_elf64_powerpcle_vec;
extern const bfd_target bfd_elf64_s390_vec;
extern const bfd_target bfd_elf64_tradbigmips_vec;
extern const bfd_target bfd_elf64_tradlittlemips_vec;
extern const bfd_target bfd_elf64_x86_64_vec;
+extern const bfd_target bfd_mmo_vec;
extern const bfd_target bfd_powerpc_pe_vec;
extern const bfd_target bfd_powerpc_pei_vec;
extern const bfd_target bfd_powerpcle_pe_vec;
&bfd_elf64_ia64_little_vec,
&bfd_elf64_little_generic_vec,
&bfd_elf64_littlemips_vec,
+ &bfd_elf64_mmix_vec,
&bfd_elf64_powerpc_vec,
&bfd_elf64_powerpcle_vec,
&bfd_elf64_s390_vec,
&bfd_elf64_tradbigmips_vec,
&bfd_elf64_tradlittlemips_vec,
&bfd_elf64_x86_64_vec,
+#if 0
+ &bfd_mmo_mmix_vec,
+#endif
#endif
&bfd_powerpc_pe_vec,
&bfd_powerpc_pei_vec,
+2001-10-30 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * readelf.c: Include elf/mmix.h.
+ (guess_is_rela): MMIX is RELA.
+ (dump_relocations): Handle MMIX relocations.
+ * Makefile.am: Regenerate dependencies.
+ * Makefile.in: Regenerate.
+
2001-10-13 Nick Clifton <nickc@cambridge.redhat.com>
* readelf.c (parse_args): Handle multiple options to the -w
#include "elf/arc.h"
#include "elf/fr30.h"
#include "elf/mcore.h"
+#include "elf/mmix.h"
#include "elf/i960.h"
#include "elf/pj.h"
#include "elf/avr.h"
case EM_X86_64:
case EM_S390:
case EM_S390_OLD:
+ case EM_MMIX:
return TRUE;
case EM_MMA:
rtype = elf_mcore_reloc_type (type);
break;
+ case EM_MMIX:
+ rtype = elf_mmix_reloc_type (type);
+ break;
+
case EM_PPC:
case EM_PPC64:
rtype = elf_ppc_reloc_type (type);
+2001-10-30 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * configure.in: Update for MMIX port.
+ * Makefile.am: Ditto. Regenerate dependencies.
+ * Makefile.in: Regenerate.
+ * configure: Regenerate.
+ * config/tc-mmix.h, config/tc-mmix.c: New files.
+ * doc/Makefile.am (CPU_DOCS): Add c-mmix.texi
+ * doc/Makefile.in: Regenerate.
+ * doc/all.texi: @set MMIX.
+ * doc/as.texinfo: Ditto. Add MMIX gas manpage option overview.
+ Include c-mmix.texi.
+ * doc/c-mmix.texi: New file.
+
2001-10-24 Chris Demetriou <cgd@broadcom.com>
* config/tc-mips.c (hilo_interlocks, cop_interlocks): Make
m88k \
mcore \
mips \
+ mmix \
mn10200 \
mn10300 \
ns32k \
esac ;; \
coff) valid=yes; \
case $$c in \
- cris | i860) \
+ cris | i860 | mmix) \
valid= ;; \
esac ;; \
ecoff) \
config/tc-m88k.c \
config/tc-mcore.c \
config/tc-mips.c \
+ config/tc-mmix.c \
config/tc-mn10200.c \
config/tc-mn10300.c \
config/tc-ns32k.c \
config/tc-m88k.h \
config/tc-mcore.h \
config/tc-mips.h \
+ config/tc-mmix.h \
config/tc-mn10200.h \
config/tc-mn10300.h \
config/tc-ns32k.h \
$(INCDIR)/opcode/mips.h itbl-ops.h $(INCDIR)/elf/mips.h \
$(INCDIR)/elf/reloc-macros.h ecoff.h $(INCDIR)/coff/sym.h \
$(INCDIR)/coff/ecoff.h
+DEPTC_mmix_elf = $(srcdir)/config/obj-elf.h $(BFDDIR)/elf-bfd.h \
+ $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
+ $(INCDIR)/bfdlink.h $(srcdir)/config/tc-mmix.h subsegs.h \
+ $(INCDIR)/obstack.h $(INCDIR)/elf/mmix.h $(INCDIR)/elf/reloc-macros.h \
+ $(INCDIR)/opcode/mmix.h $(INCDIR)/safe-ctype.h dwarf2dbg.h
DEPTC_mn10200_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-mn10200.h $(INCDIR)/coff/internal.h \
$(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h $(INCDIR)/safe-ctype.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
ecoff.h $(INCDIR)/coff/sym.h $(INCDIR)/coff/ecoff.h \
$(INCDIR)/elf/mips.h $(INCDIR)/elf/reloc-macros.h $(INCDIR)/aout/aout64.h
+DEPOBJ_mmix_elf = $(srcdir)/config/obj-elf.h $(BFDDIR)/elf-bfd.h \
+ $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
+ $(INCDIR)/bfdlink.h $(srcdir)/config/tc-mmix.h $(INCDIR)/safe-ctype.h \
+ subsegs.h $(INCDIR)/obstack.h $(INCDIR)/aout/aout64.h
DEPOBJ_mn10200_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-mn10200.h $(INCDIR)/coff/internal.h \
$(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h $(INCDIR)/obstack.h \
DEP_mips_elf = $(srcdir)/config/obj-elf.h $(INCDIR)/symcat.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-mips.h
+DEP_mmix_elf = $(srcdir)/config/obj-elf.h $(BFDDIR)/elf-bfd.h \
+ $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
+ $(INCDIR)/bfdlink.h $(srcdir)/config/tc-mmix.h
DEP_mn10200_coff = $(srcdir)/config/obj-coff.h $(srcdir)/config/tc-mn10200.h \
$(INCDIR)/symcat.h $(INCDIR)/coff/internal.h $(BFDDIR)/libcoff.h \
$(INCDIR)/bfdlink.h
-# Makefile.in generated automatically by automake 1.4 from Makefile.am
+# Makefile.in generated automatically by automake 1.4-p5 from Makefile.am
-# Copyright (C) 1994, 1995-8, 1999 Free Software Foundation, Inc.
+# Copyright (C) 1994, 1995-8, 1999, 2001 Free Software Foundation, Inc.
# This Makefile.in is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
# with or without modifications, as long as this notice is preserved.
m88k \
mcore \
mips \
+ mmix \
mn10200 \
mn10300 \
ns32k \
esac ;; \
coff) valid=yes; \
case $$c in \
- cris | i860) \
+ cris | i860 | mmix) \
valid= ;; \
esac ;; \
ecoff) \
config/tc-m88k.c \
config/tc-mcore.c \
config/tc-mips.c \
+ config/tc-mmix.c \
config/tc-mn10200.c \
config/tc-mn10300.c \
config/tc-ns32k.c \
config/tc-m88k.h \
config/tc-mcore.h \
config/tc-mips.h \
+ config/tc-mmix.h \
config/tc-mn10200.h \
config/tc-mn10300.h \
config/tc-ns32k.h \
$(INCDIR)/elf/reloc-macros.h ecoff.h $(INCDIR)/coff/sym.h \
$(INCDIR)/coff/ecoff.h
+DEPTC_mmix_elf = $(srcdir)/config/obj-elf.h $(BFDDIR)/elf-bfd.h \
+ $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
+ $(INCDIR)/bfdlink.h $(srcdir)/config/tc-mmix.h subsegs.h \
+ $(INCDIR)/obstack.h $(INCDIR)/elf/mmix.h $(INCDIR)/elf/reloc-macros.h \
+ $(INCDIR)/opcode/mmix.h $(INCDIR)/safe-ctype.h dwarf2dbg.h
+
DEPTC_mn10200_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-mn10200.h $(INCDIR)/coff/internal.h \
$(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h $(INCDIR)/safe-ctype.h \
ecoff.h $(INCDIR)/coff/sym.h $(INCDIR)/coff/ecoff.h \
$(INCDIR)/elf/mips.h $(INCDIR)/elf/reloc-macros.h $(INCDIR)/aout/aout64.h
+DEPOBJ_mmix_elf = $(srcdir)/config/obj-elf.h $(BFDDIR)/elf-bfd.h \
+ $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
+ $(INCDIR)/bfdlink.h $(srcdir)/config/tc-mmix.h $(INCDIR)/safe-ctype.h \
+ subsegs.h $(INCDIR)/obstack.h $(INCDIR)/aout/aout64.h
+
DEPOBJ_mn10200_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-mn10200.h $(INCDIR)/coff/internal.h \
$(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h $(INCDIR)/obstack.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-mips.h
+DEP_mmix_elf = $(srcdir)/config/obj-elf.h $(BFDDIR)/elf-bfd.h \
+ $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
+ $(INCDIR)/bfdlink.h $(srcdir)/config/tc-mmix.h
+
DEP_mn10200_coff = $(srcdir)/config/obj-coff.h $(srcdir)/config/tc-mn10200.h \
$(INCDIR)/symcat.h $(INCDIR)/coff/internal.h $(BFDDIR)/libcoff.h \
$(INCDIR)/bfdlink.h
DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) $(TEXINFOS) $(EXTRA_DIST)
-TAR = tar
+TAR = gtar
GZIP_ENV = --best
SOURCES = $(itbl_test_SOURCES) $(as_new_SOURCES) $(EXTRA_as_new_SOURCES) $(gasp_new_SOURCES)
OBJECTS = $(itbl_test_OBJECTS) $(as_new_OBJECTS) $(gasp_new_OBJECTS)
dot_seen=no; \
rev=''; list='$(SUBDIRS)'; for subdir in $$list; do \
rev="$$subdir $$rev"; \
- test "$$subdir" = "." && dot_seen=yes; \
+ test "$$subdir" != "." || dot_seen=yes; \
done; \
test "$$dot_seen" = "no" && rev=". $$rev"; \
target=`echo $@ | sed s/-recursive//`; \
--- /dev/null
+/* tc-mmix.c -- Assembler for Don Knuth's MMIX.
+ Copyright (C) 2001 Free Software Foundation.
+
+ This file is part of GAS, the GNU Assembler.
+
+ GAS is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2, or (at your option)
+ any later version.
+
+ GAS is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with GAS; see the file COPYING. If not, write to
+ the Free Software Foundation, 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
+
+/* Knuth's assembler mmixal does not provide a relocatable format; mmo is
+ to be considered a final link-format. In the final link, we make mmo,
+ but for relocatable files, we use ELF.
+
+ One goal is to provide a superset of what mmixal does, including
+ compatible syntax, but the main purpose is to serve GCC. */
+
+
+#include <stdio.h>
+#include "as.h"
+#include "subsegs.h"
+#include "bfd.h"
+#include "elf/mmix.h"
+#include "opcode/mmix.h"
+#include "safe-ctype.h"
+#include "dwarf2dbg.h"
+#include "obstack.h"
+
+/* Something to describe what we need to do with a fixup before output,
+ for example assert something of what it became or make a relocation. */
+
+enum mmix_fixup_action
+ {
+ mmix_fixup_byte,
+ mmix_fixup_register,
+ mmix_fixup_register_or_adjust_for_byte
+ };
+
+static int get_spec_regno PARAMS ((char *));
+static int get_operands PARAMS ((int, char *, expressionS[]));
+static int get_putget_operands
+ PARAMS ((struct mmix_opcode *, char *, expressionS[]));
+static void s_prefix PARAMS ((int));
+static void s_greg PARAMS ((int));
+static void s_loc PARAMS ((int));
+static void s_bspec PARAMS ((int));
+static void s_espec PARAMS ((int));
+static void mmix_s_local PARAMS ((int));
+static void mmix_greg_internal PARAMS ((char *));
+static void mmix_set_geta_branch_offset PARAMS ((char *, offsetT value));
+static void mmix_set_jmp_offset PARAMS ((char *, offsetT));
+static void mmix_fill_nops PARAMS ((char *, int));
+static int cmp_greg_symbol_fixes PARAMS ((const PTR, const PTR));
+static int cmp_greg_val_greg_symbol_fixes
+ PARAMS ((const PTR p1, const PTR p2));
+static void mmix_handle_rest_of_empty_line PARAMS ((void));
+static void mmix_discard_rest_of_line PARAMS ((void));
+static void mmix_byte PARAMS ((void));
+static void mmix_cons PARAMS ((int));
+static void mmix_frob_local_reloc PARAMS ((bfd *, asection *, PTR));
+
+/* Continue the tradition of symbols.c; use control characters to enforce
+ magic. These are used when replacing e.g. 8F and 8B so we can handle
+ such labels correctly with the common parser hooks. */
+#define MAGIC_FB_BACKWARD_CHAR '\003'
+#define MAGIC_FB_FORWARD_CHAR '\004'
+
+/* Copy the location of a frag to a fix. */
+#define COPY_FR_WHERE_TO_FX(FRAG, FIX) \
+ do \
+ { \
+ (FIX)->fx_file = (FRAG)->fr_file; \
+ (FIX)->fx_line = (FRAG)->fr_line; \
+ } \
+ while (0)
+
+const char *md_shortopts = "x";
+static int current_fb_label = -1;
+static char *pending_label = NULL;
+
+static bfd_vma lowest_text_loc = (bfd_vma) -1;
+static int text_has_contents = 0;
+
+/* The alignment of the previous instruction, and a boolean for whether we
+ want to avoid aligning the next WYDE, TETRA, OCTA or insn. */
+static int last_alignment = 0;
+static int want_unaligned = 0;
+
+static bfd_vma lowest_data_loc = (bfd_vma) -1;
+static int data_has_contents = 0;
+
+/* The fragS of the instruction being assembled. Only valid from within
+ md_assemble. */
+fragS *mmix_opcode_frag = NULL;
+
+/* Raw GREGs as appearing in input. These may be fewer than the number
+ after relaxing. */
+static int n_of_raw_gregs = 0;
+static struct
+ {
+ char *label;
+ expressionS exp;
+ } mmix_raw_gregs[MAX_GREGS];
+
+/* Fixups for all unique GREG registers. We store the fixups here in
+ md_convert_frag, then we use the array to convert
+ BFD_RELOC_MMIX_BASE_PLUS_OFFSET fixups in tc_gen_reloc. The index is
+ just a running number and is not supposed to be correlated to a
+ register number. */
+static fixS *mmix_gregs[MAX_GREGS];
+static int n_of_cooked_gregs = 0;
+
+/* Pointing to the register section we use for output. */
+static asection *real_reg_section;
+
+/* For each symbol; unknown or section symbol, we keep a list of GREG
+ definitions sorted on increasing offset. It seems no use keeping count
+ to allocate less room than the maximum number of gregs when we've found
+ one for a section or symbol. */
+struct mmix_symbol_gregs
+ {
+ int n_gregs;
+ struct mmix_symbol_greg_fixes
+ {
+ fixS *fix;
+
+ /* A signed type, since we may have GREGs pointing slightly before the
+ contents of a section. */
+ offsetT offs;
+ } greg_fixes[MAX_GREGS];
+ };
+
+/* Should read insert a colon on something that starts in column 0 on
+ this line? */
+static int label_without_colon_this_line = 1;
+
+/* Should we expand operands for external symbols? */
+static int expand_op = 1;
+
+/* Should we warn when expanding operands? FIXME: test-cases for when -x
+ is absent. */
+static int warn_on_expansion = 1;
+
+/* Should we merge non-zero GREG register definitions? */
+static int merge_gregs = 1;
+
+/* Should we emit built-in symbols? */
+static int predefined_syms = 1;
+
+/* Should we anything but the listed special register name (e.g. equated
+ symbols)? */
+static int equated_spec_regs = 1;
+
+/* Do we require standard GNU syntax? */
+int mmix_gnu_syntax = 0;
+
+/* Do we globalize all symbols? */
+int mmix_globalize_symbols = 0;
+
+/* Do we know that the next semicolon is at the end of the operands field
+ (in mmixal mode; constant 1 in GNU mode)? */
+int mmix_next_semicolon_is_eoln = 1;
+
+/* Do we have a BSPEC in progress? */
+static int doing_bspec = 0;
+static char *bspec_file;
+static unsigned int bspec_line;
+
+struct option md_longopts[] =
+ {
+#define OPTION_RELAX (OPTION_MD_BASE)
+#define OPTION_NOEXPAND (OPTION_RELAX + 1)
+#define OPTION_NOMERGEGREG (OPTION_NOEXPAND + 1)
+#define OPTION_NOSYMS (OPTION_NOMERGEGREG + 1)
+#define OPTION_GNU_SYNTAX (OPTION_NOSYMS + 1)
+#define OPTION_GLOBALIZE_SYMBOLS (OPTION_GNU_SYNTAX + 1)
+#define OPTION_FIXED_SPEC_REGS (OPTION_GLOBALIZE_SYMBOLS + 1)
+ {"linkrelax", no_argument, NULL, OPTION_RELAX},
+ {"no-expand", no_argument, NULL, OPTION_NOEXPAND},
+ {"no-merge-gregs", no_argument, NULL, OPTION_NOMERGEGREG},
+ {"no-predefined-syms", no_argument, NULL, OPTION_NOSYMS},
+ {"gnu-syntax", no_argument, NULL, OPTION_GNU_SYNTAX},
+ {"globalize-symbols", no_argument, NULL, OPTION_GLOBALIZE_SYMBOLS},
+ {"fixed-special-register-names", no_argument, NULL,
+ OPTION_FIXED_SPEC_REGS},
+ {NULL, no_argument, NULL, 0}
+ };
+
+size_t md_longopts_size = sizeof (md_longopts);
+
+static struct hash_control *mmix_opcode_hash;
+
+/* We use these when implementing the PREFIX pseudo. */
+char *mmix_current_prefix;
+struct obstack mmix_sym_obstack;
+
+
+/* For MMIX, we encode the relax_substateT:s (in e.g. fr_substate) as one
+ bit length, and the relax-type shifted on top of that. There seems to
+ be no point in making the relaxation more fine-grained; the linker does
+ that better and we might interfere by changing non-optimal relaxations
+ into other insns that cannot be relaxed as easily.
+
+ Groups for MMIX relaxing:
+
+ 1. GETA
+ extra length: zero or three insns.
+
+ 2. Bcc
+ extra length: zero or five insns.
+
+ 3. PUSHJ
+ extra length: zero or four insns.
+
+ 4. JMP
+ extra length: zero or four insns. */
+
+#define STATE_GETA (1)
+#define STATE_BCC (2)
+#define STATE_PUSHJ (3)
+#define STATE_JMP (4)
+#define STATE_GREG (5)
+
+/* No fine-grainedness here. */
+#define STATE_LENGTH_MASK (1)
+
+#define STATE_ZERO (0)
+#define STATE_MAX (1)
+
+/* More descriptive name for convenience. */
+/* FIXME: We should start on something different, not MAX. */
+#define STATE_UNDF STATE_MAX
+
+/* FIXME: For GREG, we must have other definitions; UNDF == MAX isn't
+ appropriate; we need it the other way round. This value together with
+ fragP->tc_frag_data shows what state the frag is in: tc_frag_data
+ non-NULL means 0, NULL means 8 bytes. */
+#define STATE_GREG_UNDF ENCODE_RELAX (STATE_GREG, STATE_ZERO)
+#define STATE_GREG_DEF ENCODE_RELAX (STATE_GREG, STATE_MAX)
+
+/* These displacements are relative to the adress following the opcode
+ word of the instruction. The catch-all states have zero for "reach"
+ and "next" entries. */
+
+#define GETA_0F (65536 * 4 - 8)
+#define GETA_0B (-65536 * 4 - 4)
+
+#define GETA_MAX_LEN 4*4
+#define GETA_3F 0
+#define GETA_3B 0
+
+#define BCC_0F GETA_0F
+#define BCC_0B GETA_0B
+
+#define BCC_MAX_LEN 6*4
+#define BCC_5F GETA_3F
+#define BCC_5B GETA_3B
+
+#define PUSHJ_0F GETA_0F
+#define PUSHJ_0B GETA_0B
+
+#define PUSHJ_MAX_LEN 5*4
+#define PUSHJ_4F GETA_3F
+#define PUSHJ_4B GETA_3B
+
+#define JMP_0F (65536 * 256 * 4 - 8)
+#define JMP_0B (-65536 * 256 * 4 - 4)
+
+#define JMP_MAX_LEN 5*4
+#define JMP_4F 0
+#define JMP_4B 0
+
+#define RELAX_ENCODE_SHIFT 1
+#define ENCODE_RELAX(what, length) (((what) << RELAX_ENCODE_SHIFT) + (length))
+
+const relax_typeS mmix_relax_table[] =
+ {
+ /* Error sentinel (0, 0). */
+ {1, 1, 0, 0},
+
+ /* Unused (0, 1). */
+ {1, 1, 0, 0},
+
+ /* GETA (1, 0). */
+ {GETA_0F, GETA_0B, 0, ENCODE_RELAX (STATE_GETA, STATE_MAX)},
+
+ /* GETA (1, 1). */
+ {GETA_3F, GETA_3B,
+ GETA_MAX_LEN - 4, 0},
+
+ /* BCC (2, 0). */
+ {BCC_0F, BCC_0B, 0, ENCODE_RELAX (STATE_BCC, STATE_MAX)},
+
+ /* BCC (2, 1). */
+ {BCC_5F, BCC_5B,
+ BCC_MAX_LEN - 4, 0},
+
+ /* PUSHJ (3, 0). */
+ {PUSHJ_0F, PUSHJ_0B, 0, ENCODE_RELAX (STATE_PUSHJ, STATE_MAX)},
+
+ /* PUSHJ (3, 1). */
+ {PUSHJ_4F, PUSHJ_4B,
+ PUSHJ_MAX_LEN - 4, 0},
+
+ /* JMP (4, 0). */
+ {JMP_0F, JMP_0B, 0, ENCODE_RELAX (STATE_JMP, STATE_MAX)},
+
+ /* JMP (4, 1). */
+ {JMP_4F, JMP_4B,
+ JMP_MAX_LEN - 4, 0},
+
+ /* GREG (5, 0), (5, 1), though the table entry isn't used. */
+ {0, 0, 0, 0}, {0, 0, 0, 0}
+};
+
+const pseudo_typeS md_pseudo_table[] =
+ {
+ /* Support " .greg sym,expr" syntax. */
+ {"greg", s_greg, 0},
+
+ /* Support " .bspec expr" syntax. */
+ {"bspec", s_bspec, 1},
+
+ /* Support " .espec" syntax. */
+ {"espec", s_espec, 1},
+
+ /* Support " .local $45" syntax. */
+ {"local", mmix_s_local, 1},
+
+ /* Support DWARF2 debugging info. */
+ {"file", dwarf2_directive_file, 0},
+ {"loc", dwarf2_directive_loc, 0},
+
+ {NULL, 0, 0}
+ };
+
+const char mmix_comment_chars[] = "%!";
+
+/* A ':' is a valid symbol character in mmixal. It's the prefix
+ delimiter, but other than that, it works like a symbol character,
+ except that we strip one off at the beginning of symbols. An '@' is a
+ symbol by itself (for the current location); space around it must not
+ be stripped. */
+const char mmix_symbol_chars[] = ":@";
+
+const char line_comment_chars[] = "*#";
+
+const char line_separator_chars[] = ";";
+
+const char mmix_exp_chars[] = "eE";
+
+const char mmix_flt_chars[] = "rf";
+
+
+/* Fill in the offset-related part of GETA or Bcc. */
+
+static void
+mmix_set_geta_branch_offset (opcodep, value)
+ char *opcodep;
+ offsetT value;
+{
+ if (value < 0)
+ {
+ value += 65536 * 4;
+ opcodep[0] |= 1;
+ }
+
+ value /= 4;
+ md_number_to_chars (opcodep + 2, value, 2);
+}
+
+/* Fill in the offset-related part of JMP. */
+
+static void
+mmix_set_jmp_offset (opcodep, value)
+ char *opcodep;
+ offsetT value;
+{
+ if (value < 0)
+ {
+ value += 65536 * 256 * 4;
+ opcodep[0] |= 1;
+ }
+
+ value /= 4;
+ md_number_to_chars (opcodep + 1, value, 3);
+}
+
+/* Fill in NOP:s for the expanded part of GETA/JMP/Bcc/PUSHJ. */
+
+static void
+mmix_fill_nops (opcodep, n)
+ char *opcodep;
+ int n;
+{
+ int i;
+
+ for (i = 0; i < n; i++)
+ md_number_to_chars (opcodep + i*4, SWYM_INSN_BYTE << 24, 4);
+}
+
+/* See macro md_parse_name in tc-mmix.h. */
+
+int
+mmix_current_location (fn, exp)
+ void (*fn) PARAMS ((expressionS *));
+ expressionS *exp;
+{
+ (*fn) (exp);
+
+ return 1;
+}
+
+/* Get up to three operands, filling them into the exp array.
+ General idea and code stolen from the tic80 port. */
+
+static int
+get_operands (max_operands, s, exp)
+ int max_operands;
+ char *s;
+ expressionS exp[];
+{
+ char *p = s;
+ int numexp = 0;
+ int nextchar = ',';
+
+ while (nextchar == ',')
+ {
+ /* Skip leading whitespace */
+ while (*p == ' ' || *p == '\t')
+ p++;
+
+ /* Check to see if we have any operands left to parse */
+ if (*p == 0 || *p == '\n' || *p == '\r')
+ {
+ break;
+ }
+ else if (numexp == max_operands)
+ {
+ /* This seems more sane than saying "too many operands". We'll
+ get here only if the trailing trash starts with a comma. */
+ as_bad (_("invalid operands"));
+ mmix_discard_rest_of_line ();
+ return 0;
+ }
+
+ /* Begin operand parsing at the current scan point. */
+
+ input_line_pointer = p;
+ expression (&exp[numexp]);
+
+ if (exp[numexp].X_op == O_illegal)
+ {
+ as_bad (_("invalid operands"));
+ }
+ else if (exp[numexp].X_op == O_absent)
+ {
+ as_bad (_("missing operand"));
+ }
+
+ numexp++;
+ p = input_line_pointer;
+
+ /* Skip leading whitespace */
+ while (*p == ' ' || *p == '\t')
+ p++;
+ nextchar = *p++;
+ }
+
+ /* If we allow "naked" comments, ignore the rest of the line. */
+ if (nextchar != ',')
+ {
+ mmix_handle_rest_of_empty_line ();
+ input_line_pointer--;
+ }
+
+ /* Mark the end of the valid operands with an illegal expression. */
+ exp[numexp].X_op = O_illegal;
+
+ return (numexp);
+}
+
+/* Get the value of a special register, or -1 if the name does not match
+ one. NAME is a null-terminated string. */
+
+static int
+get_spec_regno (name)
+ char *name;
+{
+ int i;
+
+ if (name == NULL)
+ return -1;
+
+ if (*name == ':')
+ name++;
+
+ /* Well, it's a short array and we'll most often just match the first
+ entry, rJ. */
+ for (i = 0; mmix_spec_regs[i].name != NULL; i++)
+ if (strcmp (name, mmix_spec_regs[i].name) == 0)
+ return mmix_spec_regs[i].number;
+
+ return -1;
+}
+
+/* For GET and PUT, parse the register names "manually", so we don't use
+ user labels. */
+static int
+get_putget_operands (insn, operands, exp)
+ struct mmix_opcode *insn;
+ char *operands;
+ expressionS exp[];
+{
+ expressionS *expp_reg;
+ expressionS *expp_sreg;
+ char *sregp = NULL;
+ char *sregend = operands;
+ char *p = operands;
+ char c = *sregend;
+ int regno;
+
+ /* Skip leading whitespace */
+ while (*p == ' ' || *p == '\t')
+ p++;
+
+ input_line_pointer = p;
+
+ if (insn->operands == mmix_operands_get)
+ {
+ expp_reg = &exp[0];
+ expp_sreg = &exp[1];
+
+ expression (expp_reg);
+
+ p = input_line_pointer;
+
+ /* Skip whitespace */
+ while (*p == ' ' || *p == '\t')
+ p++;
+
+ if (*p == ',')
+ {
+ p++;
+
+ /* Skip whitespace */
+ while (*p == ' ' || *p == '\t')
+ p++;
+ sregp = p;
+ input_line_pointer = sregp;
+ c = get_symbol_end ();
+ sregend = input_line_pointer;
+ }
+ }
+ else
+ {
+ expp_sreg = &exp[0];
+ expp_reg = &exp[1];
+
+ /* Initialize to error state in case we'll never call expression on
+ this operand. */
+ expp_reg->X_op = O_illegal;
+
+ sregp = p;
+ c = get_symbol_end ();
+ sregend = p = input_line_pointer;
+ *p = c;
+
+ /* Skip whitespace */
+ while (*p == ' ' || *p == '\t')
+ p++;
+
+ if (*p == ',')
+ {
+ p++;
+
+ /* Skip whitespace */
+ while (*p == ' ' || *p == '\t')
+ p++;
+
+ input_line_pointer = p;
+ expression (expp_reg);
+ }
+ *sregend = 0;
+ }
+
+ regno = get_spec_regno (sregp);
+ *sregend = c;
+
+ /* Let the caller issue errors; we've made sure the operands are
+ invalid. */
+ if (expp_reg->X_op != O_illegal
+ && expp_reg->X_op != O_absent
+ && regno != -1)
+ {
+ expp_sreg->X_op = O_register;
+ expp_sreg->X_add_number = regno + 256;
+ }
+
+ return 2;
+}
+
+/* Handle MMIX-specific option. */
+
+int
+md_parse_option (c, arg)
+ int c;
+ char *arg ATTRIBUTE_UNUSED;
+{
+ switch (c)
+ {
+ case 'x':
+ warn_on_expansion = 0;
+ break;
+
+ case OPTION_RELAX:
+ linkrelax = 1;
+ break;
+
+ case OPTION_NOEXPAND:
+ expand_op = 0;
+ break;
+
+ case OPTION_NOMERGEGREG:
+ merge_gregs = 0;
+ break;
+
+ case OPTION_NOSYMS:
+ predefined_syms = 0;
+ equated_spec_regs = 0;
+ break;
+
+ case OPTION_GNU_SYNTAX:
+ mmix_gnu_syntax = 1;
+ label_without_colon_this_line = 0;
+ break;
+
+ case OPTION_GLOBALIZE_SYMBOLS:
+ mmix_globalize_symbols = 1;
+ break;
+
+ case OPTION_FIXED_SPEC_REGS:
+ equated_spec_regs = 0;
+ break;
+
+ default:
+ return 0;
+ }
+
+ return 1;
+}
+
+/* Display MMIX-specific help text. */
+
+void
+md_show_usage (stream)
+ FILE * stream;
+{
+ fprintf (stream, _(" MMIX-specific command line options:\n"));
+ fprintf (stream, _("\
+ -fixed-special-register-names\n\
+ Allow only the original special register names.\n"));
+ fprintf (stream, _("\
+ -globalize-symbols Make all symbols global.\n"));
+ fprintf (stream, _("\
+ -gnu-syntax Turn off mmixal syntax compatibility.\n"));
+ fprintf (stream, _("\
+ -relax Create linker relaxable code.\n"));
+ fprintf (stream, _("\
+ -no-predefined-syms Do not provide mmixal built-in constants.\n\
+ Implies -fixed-special-register-names.\n"));
+ fprintf (stream, _("\
+ -no-expand Do not expand GETA, branches, PUSHJ or JUMP\n\
+ into multiple instructions.\n"));
+ fprintf (stream, _("\
+ -no-merge-gregs Do not merge GREG definitions with nearby values.\n"));
+ fprintf (stream, _("\
+ -x Do not warn when an operand to GETA, a branch,\n\
+ PUSHJ or JUMP is not known to be within range.\n\
+ The linker will catch any errors.\n"));
+}
+
+/* Step to end of line, but don't step over the end of the line. */
+
+static void
+mmix_discard_rest_of_line ()
+{
+ while (*input_line_pointer
+ && (! is_end_of_line [(unsigned char) *input_line_pointer]
+ || TC_EOL_IN_INSN (input_line_pointer)))
+ input_line_pointer++;
+}
+
+/* Act as demand_empty_rest_of_line if we're in strict GNU syntax mode,
+ otherwise just ignore the rest of the line (and skip the end-of-line
+ delimiter). */
+
+static void
+mmix_handle_rest_of_empty_line ()
+{
+ if (mmix_gnu_syntax)
+ demand_empty_rest_of_line ();
+ else
+ {
+ mmix_discard_rest_of_line ();
+ input_line_pointer++;
+ }
+}
+
+/* Initialize GAS MMIX specifics. */
+
+void
+mmix_md_begin ()
+{
+ int i;
+ const struct mmix_opcode *opcode;
+
+ /* We assume nobody will use this, so don't allocate any room. */
+ obstack_begin (&mmix_sym_obstack, 0);
+
+ /* This will break the day the "lex" thingy changes. For now, it's the
+ only way to make ':' part of a name, and a name beginner. */
+ lex_type [':'] = (LEX_NAME | LEX_BEGIN_NAME);
+
+ mmix_opcode_hash = hash_new ();
+
+ real_reg_section
+ = bfd_make_section_old_way (stdoutput, MMIX_REG_SECTION_NAME);
+
+ for (opcode = mmix_opcodes; opcode->name; opcode++)
+ hash_insert (mmix_opcode_hash, opcode->name, (char *) opcode);
+
+ /* We always insert the ordinary registers 0..255 as registers. */
+ for (i = 0; i < 256; i++)
+ {
+ char buf[5];
+
+ /* Alternatively, we could diddle with '$' and the following number,
+ but keeping the registers as symbols helps keep parsing simple. */
+ sprintf (buf, "$%d", i);
+ symbol_table_insert (symbol_new (buf, reg_section, i,
+ &zero_address_frag));
+ }
+
+ /* Insert mmixal built-in names if allowed. */
+ if (predefined_syms)
+ {
+ for (i = 0; mmix_spec_regs[i].name != NULL; i++)
+ symbol_table_insert (symbol_new (mmix_spec_regs[i].name,
+ reg_section,
+ mmix_spec_regs[i].number + 256,
+ &zero_address_frag));
+
+ /* FIXME: Perhaps these should be recognized as specials; as field
+ names for those instructions. */
+ symbol_table_insert (symbol_new ("ROUND_CURRENT", reg_section, 512,
+ &zero_address_frag));
+ symbol_table_insert (symbol_new ("ROUND_OFF", reg_section, 512 + 1,
+ &zero_address_frag));
+ symbol_table_insert (symbol_new ("ROUND_UP", reg_section, 512 + 2,
+ &zero_address_frag));
+ symbol_table_insert (symbol_new ("ROUND_DOWN", reg_section, 512 + 3,
+ &zero_address_frag));
+ symbol_table_insert (symbol_new ("ROUND_NEAR", reg_section, 512 + 4,
+ &zero_address_frag));
+ }
+}
+
+/* Assemble one insn in STR. */
+
+void
+md_assemble (str)
+ char *str;
+{
+ char *operands = str;
+ char modified_char = 0;
+ struct mmix_opcode *instruction;
+ fragS *opc_fragP = NULL;
+ int max_operands = 3;
+
+ /* Note that the struct frag member fr_literal in frags.h is char[], so
+ I have to make this a plain char *. */
+ /* unsigned */ char *opcodep = NULL;
+
+ expressionS exp[4];
+ int n_operands = 0;
+
+ /* Move to end of opcode. */
+ for (operands = str;
+ is_part_of_name (*operands);
+ ++operands)
+ ;
+
+ if (ISSPACE (*operands))
+ {
+ modified_char = *operands;
+ *operands++ = '\0';
+ }
+
+ instruction = (struct mmix_opcode *) hash_find (mmix_opcode_hash, str);
+ if (instruction == NULL)
+ {
+ as_bad (_("unknown opcode: `%s'"), str);
+
+ /* Avoid "unhandled label" errors. */
+ pending_label = NULL;
+ return;
+ }
+
+ /* Put back the character after the opcode. */
+ if (modified_char != 0)
+ operands[-1] = modified_char;
+
+ input_line_pointer = operands;
+
+ /* Is this a mmixal pseudodirective? */
+ if (instruction->type == mmix_type_pseudo)
+ {
+ /* For mmixal compatibility, a label for an instruction (and
+ emitting pseudo) refers to the _aligned_ address. We emit the
+ label here for the pseudos that don't handle it themselves. When
+ having an fb-label, emit it here, and increment the counter after
+ the pseudo. */
+ switch (instruction->operands)
+ {
+ case mmix_operands_loc:
+ case mmix_operands_byte:
+ case mmix_operands_prefix:
+ case mmix_operands_local:
+ case mmix_operands_bspec:
+ case mmix_operands_espec:
+ if (current_fb_label >= 0)
+ colon (fb_label_name (current_fb_label, 1));
+ else if (pending_label != NULL)
+ {
+ colon (pending_label);
+ pending_label = NULL;
+ }
+ break;
+
+ default:
+ break;
+ }
+
+ /* Some of the pseudos emit contents, others don't. Set a
+ contents-emitted flag when we emit something into .text */
+ switch (instruction->operands)
+ {
+ case mmix_operands_loc:
+ /* LOC */
+ s_loc (0);
+ break;
+
+ case mmix_operands_byte:
+ /* BYTE */
+ mmix_byte ();
+ break;
+
+ case mmix_operands_wyde:
+ /* WYDE */
+ mmix_cons (2);
+ break;
+
+ case mmix_operands_tetra:
+ /* TETRA */
+ mmix_cons (4);
+ break;
+
+ case mmix_operands_octa:
+ /* OCTA */
+ mmix_cons (8);
+ break;
+
+ case mmix_operands_prefix:
+ /* PREFIX */
+ s_prefix (0);
+ break;
+
+ case mmix_operands_local:
+ /* LOCAL */
+ mmix_s_local (0);
+ break;
+
+ case mmix_operands_bspec:
+ /* BSPEC */
+ s_bspec (0);
+ break;
+
+ case mmix_operands_espec:
+ /* ESPEC */
+ s_espec (0);
+ break;
+
+ default:
+ BAD_CASE (instruction->operands);
+ }
+
+ /* These are all working like the pseudo functions in read.c:s_...,
+ in that they step over the end-of-line marker at the end of the
+ line. We don't want that here. */
+ input_line_pointer--;
+
+ /* Step up the fb-label counter if there was a definition on this
+ line. */
+ if (current_fb_label >= 0)
+ {
+ fb_label_instance_inc (current_fb_label);
+ current_fb_label = -1;
+ }
+
+ /* Reset any don't-align-next-datum request, unless this was a LOC
+ directive. */
+ if (instruction->operands != mmix_operands_loc)
+ want_unaligned = 0;
+
+ return;
+ }
+
+ /* Not a pseudo; we *will* emit contents. */
+ if (now_seg == data_section)
+ {
+ if (lowest_data_loc != (bfd_vma) -1 && (lowest_data_loc & 3) != 0)
+ {
+ if (data_has_contents)
+ as_bad (_("specified location wasn't TETRA-aligned"));
+ else if (want_unaligned)
+ as_bad (_("unaligned data at an absolute location is not supported"));
+
+ lowest_data_loc &= ~(bfd_vma) 3;
+ lowest_data_loc += 4;
+ }
+
+ data_has_contents = 1;
+ }
+ else if (now_seg == text_section)
+ {
+ if (lowest_text_loc != (bfd_vma) -1 && (lowest_text_loc & 3) != 0)
+ {
+ if (text_has_contents)
+ as_bad (_("specified location wasn't TETRA-aligned"));
+ else if (want_unaligned)
+ as_bad (_("unaligned data at an absolute location is not supported"));
+
+ lowest_text_loc &= ~(bfd_vma) 3;
+ lowest_text_loc += 4;
+ }
+
+ text_has_contents = 1;
+ }
+
+ /* After a sequence of BYTEs or WYDEs, we need to get to instruction
+ alignment. For other pseudos, a ".p2align 2" is supposed to be
+ inserted by the user. */
+ if (last_alignment < 2 && ! want_unaligned)
+ {
+ frag_align (2, 0, 0);
+ record_alignment (now_seg, 2);
+ last_alignment = 2;
+ }
+ else
+ /* Reset any don't-align-next-datum request. */
+ want_unaligned = 0;
+
+ /* For mmixal compatibility, a label for an instruction (and emitting
+ pseudo) refers to the _aligned_ address. So we have to emit the
+ label here. */
+ if (pending_label != NULL)
+ {
+ colon (pending_label);
+ pending_label = NULL;
+ }
+
+ /* We assume that mmix_opcodes keeps having unique mnemonics for each
+ opcode, so we don't have to iterate over more than one opcode; if the
+ syntax does not match, then there's a syntax error. */
+
+ /* Operands have little or no context and are all comma-separated; it is
+ easier to parse each expression first. */
+ switch (instruction->operands)
+ {
+ case mmix_operands_reg_yz:
+ case mmix_operands_pop:
+ case mmix_operands_regaddr:
+ case mmix_operands_pushj:
+ case mmix_operands_get:
+ case mmix_operands_put:
+ case mmix_operands_set:
+ case mmix_operands_save:
+ case mmix_operands_unsave:
+ max_operands = 2;
+ break;
+
+ case mmix_operands_sync:
+ case mmix_operands_jmp:
+ case mmix_operands_resume:
+ max_operands = 1;
+ break;
+
+ /* The original 3 is fine for the rest. */
+ default:
+ break;
+ }
+
+ /* If this is GET or PUT, and we don't do allow those names to be
+ equated, we need to parse the names ourselves, so we don't pick up a
+ user label instead of the special register. */
+ if (! equated_spec_regs
+ && (instruction->operands == mmix_operands_get
+ || instruction->operands == mmix_operands_put))
+ n_operands = get_putget_operands (instruction, operands, exp);
+ else
+ n_operands = get_operands (max_operands, operands, exp);
+
+ /* If there's a fb-label on the current line, set that label. This must
+ be done *after* evaluating expressions of operands, since neither a
+ "1B" nor a "1F" refers to "1H" on the same line. */
+ if (current_fb_label >= 0)
+ {
+ fb_label_instance_inc (current_fb_label);
+ colon (fb_label_name (current_fb_label, 0));
+ current_fb_label = -1;
+ }
+
+ /* We also assume that the length of the instruction is determinable
+ from the first format character. Currently *all* the information is
+ in the first character. We need a self-contained frag since we want
+ the relocation to point to the instruction, not the variant part. */
+
+ opcodep = frag_more (4);
+ mmix_opcode_frag = opc_fragP = frag_now;
+ frag_now->fr_opcode = opcodep;
+
+ /* Mark start of insn for DWARF2 debug features. */
+ if (OUTPUT_FLAVOR == bfd_target_elf_flavour)
+ dwarf2_emit_insn (4);
+
+ md_number_to_chars (opcodep, instruction->match, 4);
+
+ switch (instruction->operands)
+ {
+ case mmix_operands_jmp:
+ if (n_operands == 0 && ! mmix_gnu_syntax)
+ /* Zeros are in place - nothing needs to be done when we have no
+ operands. */
+ break;
+
+ /* Add a frag for a JMP relaxation; we need room for max four
+ extra instructions. We don't do any work around here to check if
+ we can determine the offset right away. */
+ if (n_operands != 1 || exp[0].X_op == O_register)
+ {
+ as_bad (_("invalid operand to opcode %s: `%s'"),
+ instruction->name, operands);
+ return;
+ }
+
+ if (expand_op)
+ frag_var (rs_machine_dependent, 4*4, 0,
+ ENCODE_RELAX (STATE_JMP, STATE_UNDF),
+ exp[0].X_add_symbol,
+ exp[0].X_add_number,
+ opcodep);
+ else
+ fix_new_exp (opc_fragP, opcodep - opc_fragP->fr_literal, 4,
+ exp + 0, 1, BFD_RELOC_MMIX_ADDR27);
+ break;
+
+ case mmix_operands_pushj:
+ /* We take care of PUSHJ in full here. */
+ if (n_operands != 2
+ || ((exp[0].X_op == O_constant || exp[0].X_op == O_register)
+ && (exp[0].X_add_number > 255 || exp[0].X_add_number < 0)))
+ {
+ as_bad (_("invalid operands to opcode %s: `%s'"),
+ instruction->name, operands);
+ return;
+ }
+
+ if (exp[0].X_op == O_register || exp[0].X_op == O_constant)
+ opcodep[1] = exp[0].X_add_number;
+ else
+ fix_new_exp (opc_fragP, opcodep - opc_fragP->fr_literal + 1,
+ 1, exp + 0, 0, BFD_RELOC_MMIX_REG_OR_BYTE);
+
+ if (expand_op)
+ frag_var (rs_machine_dependent, PUSHJ_MAX_LEN - 4, 0,
+ ENCODE_RELAX (STATE_PUSHJ, STATE_UNDF),
+ exp[1].X_add_symbol,
+ exp[1].X_add_number,
+ opcodep);
+ else
+ fix_new_exp (opc_fragP, opcodep - opc_fragP->fr_literal, 4,
+ exp + 1, 1, BFD_RELOC_MMIX_ADDR19);
+ break;
+
+ case mmix_operands_regaddr:
+ /* GETA/branch: Add a frag for relaxation. We don't do any work
+ around here to check if we can determine the offset right away. */
+ if (n_operands != 2 || exp[1].X_op == O_register)
+ {
+ as_bad (_("invalid operands to opcode %s: `%s'"),
+ instruction->name, operands);
+ return;
+ }
+
+ if (! expand_op)
+ fix_new_exp (opc_fragP, opcodep - opc_fragP->fr_literal, 4,
+ exp + 1, 1, BFD_RELOC_MMIX_ADDR19);
+ else if (instruction->type == mmix_type_condbranch)
+ frag_var (rs_machine_dependent, BCC_MAX_LEN - 4, 0,
+ ENCODE_RELAX (STATE_BCC, STATE_UNDF),
+ exp[1].X_add_symbol,
+ exp[1].X_add_number,
+ opcodep);
+ else
+ frag_var (rs_machine_dependent, GETA_MAX_LEN - 4, 0,
+ ENCODE_RELAX (STATE_GETA, STATE_UNDF),
+ exp[1].X_add_symbol,
+ exp[1].X_add_number,
+ opcodep);
+ break;
+
+ default:
+ break;
+ }
+
+ switch (instruction->operands)
+ {
+ case mmix_operands_regs:
+ /* We check the number of operands here, since we're in a
+ FALLTHROUGH sequence in the next switch. */
+ if (n_operands != 3 || exp[2].X_op == O_constant)
+ {
+ as_bad (_("invalid operands to opcode %s: `%s'"),
+ instruction->name, operands);
+ return;
+ }
+ /* FALLTHROUGH. */
+ case mmix_operands_regs_z:
+ if (n_operands != 3)
+ {
+ as_bad (_("invalid operands to opcode %s: `%s'"),
+ instruction->name, operands);
+ return;
+ }
+ /* FALLTHROUGH. */
+ case mmix_operands_reg_yz:
+ case mmix_operands_roundregs_z:
+ case mmix_operands_roundregs:
+ case mmix_operands_regs_z_opt:
+ case mmix_operands_neg:
+ case mmix_operands_regaddr:
+ case mmix_operands_get:
+ case mmix_operands_set:
+ case mmix_operands_save:
+ if (n_operands < 1
+ || (exp[0].X_op == O_register && exp[0].X_add_number > 255))
+ {
+ as_bad (_("invalid operands to opcode %s: `%s'"),
+ instruction->name, operands);
+ return;
+ }
+
+ if (exp[0].X_op == O_register)
+ opcodep[1] = exp[0].X_add_number;
+ else
+ fix_new_exp (opc_fragP, opcodep - opc_fragP->fr_literal + 1,
+ 1, exp + 0, 0, BFD_RELOC_MMIX_REG);
+ break;
+
+ default:
+ ;
+ }
+
+ /* A corresponding once-over for those who take an 8-bit constant as
+ their first operand. */
+ switch (instruction->operands)
+ {
+ case mmix_operands_pushgo:
+ /* PUSHGO: X is a constant, but can be expressed as a register.
+ We handle X here and use the common machinery of T,X,3,$ for
+ the rest of the operands. */
+ if (n_operands < 2
+ || ((exp[0].X_op == O_constant || exp[0].X_op == O_register)
+ && (exp[0].X_add_number > 255 || exp[0].X_add_number < 0)))
+ {
+ as_bad (_("invalid operands to opcode %s: `%s'"),
+ instruction->name, operands);
+ return;
+ }
+ else if (exp[0].X_op == O_constant || exp[0].X_op == O_register)
+ opcodep[1] = exp[0].X_add_number;
+ else
+ fix_new_exp (opc_fragP, opcodep - opc_fragP->fr_literal + 1,
+ 1, exp + 0, 0, BFD_RELOC_MMIX_REG_OR_BYTE);
+ break;
+
+ case mmix_operands_pop:
+ if ((n_operands == 0 || n_operands == 1) && ! mmix_gnu_syntax)
+ break;
+ /* FALLTHROUGH. */
+ case mmix_operands_x_regs_z:
+ if (n_operands < 1
+ || (exp[0].X_op == O_constant
+ && (exp[0].X_add_number > 255
+ || exp[0].X_add_number < 0)))
+ {
+ as_bad (_("invalid operands to opcode %s: `%s'"),
+ instruction->name, operands);
+ return;
+ }
+
+ if (exp[0].X_op == O_constant)
+ opcodep[1] = exp[0].X_add_number;
+ else
+ /* FIXME: This doesn't bring us unsignedness checking. */
+ fix_new_exp (opc_fragP, opcodep - opc_fragP->fr_literal + 1,
+ 1, exp + 0, 0, BFD_RELOC_8);
+ default:
+ ;
+ }
+
+ /* Handle the rest. */
+ switch (instruction->operands)
+ {
+ case mmix_operands_set:
+ /* SET: Either two registers, "$X,$Y", with Z field as zero, or
+ "$X,YZ", meaning change the opcode to SETL. */
+ if (n_operands != 2
+ || (exp[1].X_op == O_constant
+ && (exp[1].X_add_number > 0xffff || exp[1].X_add_number < 0)))
+ {
+ as_bad (_("invalid operands to opcode %s: `%s'"),
+ instruction->name, operands);
+ return;
+ }
+
+ if (exp[1].X_op == O_constant)
+ {
+ /* There's an ambiguity with "SET $0,Y" when Y isn't defined
+ yet. To keep things simple, we assume that Y is then a
+ register, and only change the opcode if Y is defined at this
+ point.
+
+ There's no compatibility problem with mmixal, since it emits
+ errors if the field is not defined at this point. */
+ md_number_to_chars (opcodep, SETL_INSN_BYTE, 1);
+
+ opcodep[2] = (exp[1].X_add_number >> 8) & 255;
+ opcodep[3] = exp[1].X_add_number & 255;
+ break;
+ }
+ /* FALLTHROUGH. */
+ case mmix_operands_x_regs_z:
+ /* SYNCD: "X,$Y,$Z|Z". */
+ /* FALLTHROUGH. */
+ case mmix_operands_regs:
+ /* Three registers, $X,$Y,$Z. */
+ /* FALLTHROUGH. */
+ case mmix_operands_regs_z:
+ /* Operands "$X,$Y,$Z|Z", number of arguments checked above. */
+ /* FALLTHROUGH. */
+ case mmix_operands_pushgo:
+ /* Operands "$X|X,$Y,$Z|Z", optional Z. */
+ /* FALLTHROUGH. */
+ case mmix_operands_regs_z_opt:
+ /* Operands "$X,$Y,$Z|Z", with $Z|Z being optional, default 0. Any
+ operands not completely decided yet are postponed to later in
+ assembly (but not until link-time yet). */
+
+ if ((n_operands != 2 && n_operands != 3)
+ || (exp[1].X_op == O_register && exp[1].X_add_number > 255)
+ || (n_operands == 3
+ && ((exp[2].X_op == O_register
+ && exp[2].X_add_number > 255
+ && mmix_gnu_syntax)
+ || (exp[2].X_op == O_constant
+ && (exp[2].X_add_number > 255
+ || exp[2].X_add_number < 0)))))
+ {
+ as_bad (_("invalid operands to opcode %s: `%s'"),
+ instruction->name, operands);
+ return;
+ }
+
+ if (n_operands == 2)
+ {
+ symbolS *sym;
+
+ /* The last operand is immediate whenever we see just two
+ operands. */
+ opcodep[0] |= IMM_OFFSET_BIT;
+
+ /* Now, we could either have an implied "0" as the Z operand, or
+ it could be the constant of a "base address plus offset". It
+ depends on whether it is allowed; only memory operations, as
+ signified by instruction->type and "T" and "X" operand types,
+ and it depends on whether we find a register in the second
+ operand, exp[1]. */
+ if (exp[1].X_op == O_register && exp[1].X_add_number <= 255)
+ {
+ /* A zero then; all done. */
+ opcodep[2] = exp[1].X_add_number;
+ break;
+ }
+
+ /* Not known as a register. Is base address plus offset
+ allowed, or can we assume that it is a register anyway? */
+ if ((instruction->operands != mmix_operands_regs_z_opt
+ && instruction->operands != mmix_operands_x_regs_z
+ && instruction->operands != mmix_operands_pushgo)
+ || (instruction->type != mmix_type_memaccess_octa
+ && instruction->type != mmix_type_memaccess_tetra
+ && instruction->type != mmix_type_memaccess_wyde
+ && instruction->type != mmix_type_memaccess_byte
+ && instruction->type != mmix_type_memaccess_block
+ && instruction->type != mmix_type_jsr
+ && instruction->type != mmix_type_branch))
+ {
+ fix_new_exp (opc_fragP, opcodep - opc_fragP->fr_literal + 2,
+ 1, exp + 1, 0, BFD_RELOC_MMIX_REG);
+ break;
+ }
+
+ /* To avoid getting a NULL add_symbol for constants and then
+ catching a SEGV in write_relocs since it doesn't handle
+ constants well for relocs other than PC-relative, we need to
+ pass expressions as symbols and use fix_new, not fix_new_exp. */
+ sym = make_expr_symbol (exp + 1);
+
+ /* Now we know it can be a "base address plus offset". Add
+ proper fixup types so we can handle this later, when we've
+ parsed everything. */
+ fix_new (opc_fragP, opcodep - opc_fragP->fr_literal + 2,
+ 8, sym, 0, 0, BFD_RELOC_MMIX_BASE_PLUS_OFFSET);
+ break;
+ }
+
+ if (exp[1].X_op == O_register)
+ opcodep[2] = exp[1].X_add_number;
+ else
+ fix_new_exp (opc_fragP, opcodep - opc_fragP->fr_literal + 2,
+ 1, exp + 1, 0, BFD_RELOC_MMIX_REG);
+
+ /* In mmixal compatibility mode, we allow special registers as
+ constants for the Z operand. They have 256 added to their
+ register numbers, so the right thing will happen if we just treat
+ those as constants. */
+ if (exp[2].X_op == O_register && exp[2].X_add_number <= 255)
+ opcodep[3] = exp[2].X_add_number;
+ else if (exp[2].X_op == O_constant
+ || (exp[2].X_op == O_register && exp[2].X_add_number > 255))
+ {
+ opcodep[3] = exp[2].X_add_number;
+ opcodep[0] |= IMM_OFFSET_BIT;
+ }
+ else
+ fix_new_exp (opc_fragP, opcodep - opc_fragP->fr_literal + 3,
+ 1, exp + 2, 0,
+ (instruction->operands == mmix_operands_set
+ || instruction->operands == mmix_operands_regs)
+ ? BFD_RELOC_MMIX_REG : BFD_RELOC_MMIX_REG_OR_BYTE);
+ break;
+
+ case mmix_operands_pop:
+ /* POP, one eight and one 16-bit operand. */
+ if (n_operands == 0 && ! mmix_gnu_syntax)
+ break;
+ if (n_operands == 1 && ! mmix_gnu_syntax)
+ goto a_single_24_bit_number_operand;
+ /* FALLTHROUGH. */
+ case mmix_operands_reg_yz:
+ /* A register and a 16-bit unsigned number. */
+ if (n_operands != 2
+ || exp[1].X_op == O_register
+ || (exp[1].X_op == O_constant
+ && (exp[1].X_add_number > 0xffff || exp[1].X_add_number < 0)))
+ {
+ as_bad (_("invalid operands to opcode %s: `%s'"),
+ instruction->name, operands);
+ return;
+ }
+
+ if (exp[1].X_op == O_constant)
+ {
+ opcodep[2] = (exp[1].X_add_number >> 8) & 255;
+ opcodep[3] = exp[1].X_add_number & 255;
+ }
+ else
+ /* FIXME: This doesn't bring us unsignedness checking. */
+ fix_new_exp (opc_fragP, opcodep - opc_fragP->fr_literal + 2,
+ 2, exp + 1, 0, BFD_RELOC_16);
+ break;
+
+ case mmix_operands_jmp:
+ /* A JMP. Everyhing is already done. */
+ break;
+
+ case mmix_operands_roundregs:
+ /* Two registers with optional rounding mode or constant in between. */
+ if ((n_operands == 3 && exp[2].X_op == O_constant)
+ || (n_operands == 2 && exp[1].X_op == O_constant))
+ {
+ as_bad (_("invalid operands to opcode %s: `%s'"),
+ instruction->name, operands);
+ return;
+ }
+ /* FALLTHROUGH. */
+ case mmix_operands_roundregs_z:
+ /* Like FLOT, "$X,ROUND_MODE,$Z|Z", but the rounding mode is
+ optional and can be the corresponding constant. */
+ {
+ /* Which exp index holds the second operand (not the rounding
+ mode). */
+ int op2no = n_operands - 1;
+
+ if ((n_operands != 2 && n_operands != 3)
+ || ((exp[op2no].X_op == O_register
+ && exp[op2no].X_add_number > 255)
+ || (exp[op2no].X_op == O_constant
+ && (exp[op2no].X_add_number > 255
+ || exp[op2no].X_add_number < 0)))
+ || (n_operands == 3
+ /* We don't allow for the rounding mode to be deferred; it
+ must be determined in the "first pass". It cannot be a
+ symbol equated to a rounding mode, but defined after
+ the first use. */
+ && ((exp[1].X_op == O_register
+ && exp[1].X_add_number < 512)
+ || (exp[1].X_op == O_constant
+ && exp[1].X_add_number < 0
+ && exp[1].X_add_number > 4)
+ || (exp[1].X_op != O_register
+ && exp[1].X_op != O_constant))))
+ {
+ as_bad (_("invalid operands to opcode %s: `%s'"),
+ instruction->name, operands);
+ return;
+ }
+
+ /* Add rounding mode if present. */
+ if (n_operands == 3)
+ opcodep[2] = exp[1].X_add_number & 255;
+
+ if (exp[op2no].X_op == O_register)
+ opcodep[3] = exp[op2no].X_add_number;
+ else if (exp[op2no].X_op == O_constant)
+ {
+ opcodep[3] = exp[op2no].X_add_number;
+ opcodep[0] |= IMM_OFFSET_BIT;
+ }
+ else
+ fix_new_exp (opc_fragP, opcodep - opc_fragP->fr_literal + 3,
+ 1, exp + op2no, 0,
+ instruction->operands == mmix_operands_roundregs
+ ? BFD_RELOC_MMIX_REG
+ : BFD_RELOC_MMIX_REG_OR_BYTE);
+ break;
+ }
+
+ case mmix_operands_sync:
+ a_single_24_bit_number_operand:
+ if (n_operands != 1
+ || exp[0].X_op == O_register
+ || (exp[0].X_op == O_constant
+ && (exp[0].X_add_number > 0xffffff || exp[0].X_add_number < 0)))
+ {
+ as_bad (_("invalid operands to opcode %s: `%s'"),
+ instruction->name, operands);
+ return;
+ }
+
+ if (exp[0].X_op == O_constant)
+ {
+ opcodep[1] = (exp[0].X_add_number >> 16) & 255;
+ opcodep[2] = (exp[0].X_add_number >> 8) & 255;
+ opcodep[3] = exp[0].X_add_number & 255;
+ }
+ else
+ /* FIXME: This doesn't bring us unsignedness checking. */
+ fix_new_exp (opc_fragP, opcodep - opc_fragP->fr_literal + 1,
+ 3, exp + 0, 0, BFD_RELOC_24);
+ break;
+
+ case mmix_operands_neg:
+ /* Operands "$X,Y,$Z|Z"; NEG or NEGU. Y is optional, 0 is default. */
+
+ if ((n_operands != 3 && n_operands != 2)
+ || (n_operands == 3 && exp[1].X_op == O_register)
+ || ((exp[1].X_op == O_constant || exp[1].X_op == O_register)
+ && (exp[1].X_add_number > 255 || exp[1].X_add_number < 0))
+ || (n_operands == 3
+ && ((exp[2].X_op == O_register && exp[2].X_add_number > 255)
+ || (exp[2].X_op == O_constant
+ && (exp[2].X_add_number > 255
+ || exp[2].X_add_number < 0)))))
+ {
+ as_bad (_("invalid operands to opcode %s: `%s'"),
+ instruction->name, operands);
+ return;
+ }
+
+ if (n_operands == 2)
+ {
+ if (exp[1].X_op == O_register)
+ opcodep[3] = exp[1].X_add_number;
+ else if (exp[1].X_op == O_constant)
+ {
+ opcodep[3] = exp[1].X_add_number;
+ opcodep[0] |= IMM_OFFSET_BIT;
+ }
+ else
+ fix_new_exp (opc_fragP, opcodep - opc_fragP->fr_literal + 3,
+ 1, exp + 1, 0, BFD_RELOC_MMIX_REG_OR_BYTE);
+ break;
+ }
+
+ if (exp[1].X_op == O_constant)
+ opcodep[2] = exp[1].X_add_number;
+ else
+ fix_new_exp (opc_fragP, opcodep - opc_fragP->fr_literal + 2,
+ 1, exp + 1, 0, BFD_RELOC_8);
+
+ if (exp[2].X_op == O_register)
+ opcodep[3] = exp[2].X_add_number;
+ else if (exp[2].X_op == O_constant)
+ {
+ opcodep[3] = exp[2].X_add_number;
+ opcodep[0] |= IMM_OFFSET_BIT;
+ }
+ else
+ fix_new_exp (opc_fragP, opcodep - opc_fragP->fr_literal + 3,
+ 1, exp + 2, 0, BFD_RELOC_MMIX_REG_OR_BYTE);
+ break;
+
+ case mmix_operands_regaddr:
+ /* A GETA/branch-type. */
+ break;
+
+ case mmix_operands_get:
+ /* "$X,spec_reg"; GET.
+ Like with rounding modes, we demand that the special register or
+ symbol is already defined when we get here at the point of use. */
+ if (n_operands != 2
+ || (exp[1].X_op == O_register
+ && (exp[1].X_add_number < 256 || exp[1].X_add_number >= 512))
+ || (exp[1].X_op == O_constant
+ && (exp[1].X_add_number < 0 || exp[1].X_add_number > 256))
+ || (exp[1].X_op != O_constant && exp[1].X_op != O_register))
+ {
+ as_bad (_("invalid operands to opcode %s: `%s'"),
+ instruction->name, operands);
+ return;
+ }
+
+ opcodep[3] = exp[1].X_add_number - 256;
+ break;
+
+ case mmix_operands_put:
+ /* "spec_reg,$Z|Z"; PUT. */
+ if (n_operands != 2
+ || (exp[0].X_op == O_register
+ && (exp[0].X_add_number < 256 || exp[0].X_add_number >= 512))
+ || (exp[0].X_op == O_constant
+ && (exp[0].X_add_number < 0 || exp[0].X_add_number > 256))
+ || (exp[0].X_op != O_constant && exp[0].X_op != O_register))
+ {
+ as_bad (_("invalid operands to opcode %s: `%s'"),
+ instruction->name, operands);
+ return;
+ }
+
+ opcodep[1] = exp[0].X_add_number - 256;
+
+ /* Note that the Y field is zero. */
+
+ if (exp[1].X_op == O_register)
+ opcodep[3] = exp[1].X_add_number;
+ else if (exp[1].X_op == O_constant)
+ {
+ opcodep[3] = exp[1].X_add_number;
+ opcodep[0] |= IMM_OFFSET_BIT;
+ }
+ else
+ fix_new_exp (opc_fragP, opcodep - opc_fragP->fr_literal + 3,
+ 1, exp + 1, 0, BFD_RELOC_MMIX_REG_OR_BYTE);
+ break;
+
+ case mmix_operands_save:
+ /* "$X,0"; SAVE. */
+ if (n_operands != 2
+ || exp[1].X_op != O_constant
+ || exp[1].X_add_number != 0)
+ {
+ as_bad (_("invalid operands to opcode %s: `%s'"),
+ instruction->name, operands);
+ return;
+ }
+ break;
+
+ case mmix_operands_unsave:
+ if (n_operands < 2 && ! mmix_gnu_syntax)
+ {
+ if (n_operands == 1)
+ {
+ if (exp[0].X_op == O_register)
+ opcodep[3] = exp[0].X_add_number;
+ else
+ fix_new_exp (opc_fragP, opcodep - opc_fragP->fr_literal + 3,
+ 1, exp, 0, BFD_RELOC_MMIX_REG);
+ }
+ break;
+ }
+
+ /* "0,$Z"; UNSAVE. */
+ if (n_operands != 2
+ || exp[0].X_op != O_constant
+ || exp[0].X_add_number != 0
+ || exp[1].X_op == O_constant
+ || (exp[1].X_op == O_register
+ && exp[1].X_add_number > 255))
+ {
+ as_bad (_("invalid operands to opcode %s: `%s'"),
+ instruction->name, operands);
+ return;
+ }
+
+ if (exp[1].X_op == O_register)
+ opcodep[3] = exp[1].X_add_number;
+ else
+ fix_new_exp (opc_fragP, opcodep - opc_fragP->fr_literal + 3,
+ 1, exp + 1, 0, BFD_RELOC_MMIX_REG);
+ break;
+
+ case mmix_operands_xyz_opt:
+ /* SWYM, TRIP, TRAP: zero, one, two or three operands. */
+ if (n_operands == 0 && ! mmix_gnu_syntax)
+ /* Zeros are in place - nothing needs to be done for zero
+ operands. We don't allow this in GNU syntax mode, because it
+ was believed that the risk of missing to supply an operand is
+ higher than the benefit of not having to specify a zero. */
+ ;
+ else if (n_operands == 1 && exp[0].X_op != O_register)
+ {
+ if (exp[0].X_op == O_constant)
+ {
+ if (exp[0].X_add_number > 255*255*255
+ || exp[0].X_add_number < 0)
+ {
+ as_bad (_("invalid operands to opcode %s: `%s'"),
+ instruction->name, operands);
+ return;
+ }
+ else
+ {
+ opcodep[1] = (exp[0].X_add_number >> 16) & 255;
+ opcodep[2] = (exp[0].X_add_number >> 8) & 255;
+ opcodep[3] = exp[0].X_add_number & 255;
+ }
+ }
+ else
+ fix_new_exp (opc_fragP, opcodep - opc_fragP->fr_literal + 1,
+ 3, exp, 0, BFD_RELOC_24);
+ }
+ else if (n_operands == 2
+ && exp[0].X_op != O_register
+ && exp[1].X_op != O_register)
+ {
+ /* Two operands. */
+
+ if (exp[0].X_op == O_constant)
+ {
+ if (exp[0].X_add_number > 255
+ || exp[0].X_add_number < 0)
+ {
+ as_bad (_("invalid operands to opcode %s: `%s'"),
+ instruction->name, operands);
+ return;
+ }
+ else
+ opcodep[1] = exp[0].X_add_number & 255;
+ }
+ else
+ fix_new_exp (opc_fragP, opcodep - opc_fragP->fr_literal + 1,
+ 1, exp, 0, BFD_RELOC_8);
+
+ if (exp[1].X_op == O_constant)
+ {
+ if (exp[1].X_add_number > 255*255
+ || exp[1].X_add_number < 0)
+ {
+ as_bad (_("invalid operands to opcode %s: `%s'"),
+ instruction->name, operands);
+ return;
+ }
+ else
+ {
+ opcodep[2] = (exp[1].X_add_number >> 8) & 255;
+ opcodep[3] = exp[1].X_add_number & 255;
+ }
+ }
+ else
+ fix_new_exp (opc_fragP, opcodep - opc_fragP->fr_literal + 2,
+ 2, exp + 1, 0, BFD_RELOC_16);
+ }
+ else if (n_operands == 3
+ && exp[0].X_op != O_register
+ && exp[1].X_op != O_register
+ && exp[2].X_op != O_register)
+ {
+ /* Three operands. */
+
+ if (exp[0].X_op == O_constant)
+ {
+ if (exp[0].X_add_number > 255
+ || exp[0].X_add_number < 0)
+ {
+ as_bad (_("invalid operands to opcode %s: `%s'"),
+ instruction->name, operands);
+ return;
+ }
+ else
+ opcodep[1] = exp[0].X_add_number & 255;
+ }
+ else
+ fix_new_exp (opc_fragP, opcodep - opc_fragP->fr_literal + 1,
+ 1, exp, 0, BFD_RELOC_8);
+
+ if (exp[1].X_op == O_constant)
+ {
+ if (exp[1].X_add_number > 255
+ || exp[1].X_add_number < 0)
+ {
+ as_bad (_("invalid operands to opcode %s: `%s'"),
+ instruction->name, operands);
+ return;
+ }
+ else
+ opcodep[2] = exp[1].X_add_number & 255;
+ }
+ else
+ fix_new_exp (opc_fragP, opcodep - opc_fragP->fr_literal + 2,
+ 1, exp + 1, 0, BFD_RELOC_8);
+
+ if (exp[2].X_op == O_constant)
+ {
+ if (exp[2].X_add_number > 255
+ || exp[2].X_add_number < 0)
+ {
+ as_bad (_("invalid operands to opcode %s: `%s'"),
+ instruction->name, operands);
+ return;
+ }
+ else
+ opcodep[3] = exp[2].X_add_number & 255;
+ }
+ else
+ fix_new_exp (opc_fragP, opcodep - opc_fragP->fr_literal + 3,
+ 1, exp + 2, 0, BFD_RELOC_8);
+ }
+ else if (n_operands <= 3
+ && (strcmp (instruction->name, "trip") == 0
+ || strcmp (instruction->name, "trap") == 0))
+ {
+ /* The meaning of operands to TRIP and TRAP are not defined, so
+ we add combinations not handled above here as we find them. */
+ if (n_operands == 3)
+ {
+ /* Don't require non-register operands. Always generate
+ fixups, so we don't have to copy lots of code and create
+ maintanance problems. TRIP is supposed to be a rare
+ instruction, so the overhead should not matter. We
+ aren't allowed to fix_new_exp for an expression which is
+ an O_register at this point, however. */
+ if (exp[0].X_op == O_register)
+ opcodep[1] = exp[0].X_add_number;
+ else
+ fix_new_exp (opc_fragP, opcodep - opc_fragP->fr_literal + 1,
+ 1, exp, 0, BFD_RELOC_MMIX_REG_OR_BYTE);
+ if (exp[1].X_op == O_register)
+ opcodep[2] = exp[1].X_add_number;
+ else
+ fix_new_exp (opc_fragP, opcodep - opc_fragP->fr_literal + 2,
+ 1, exp + 1, 0, BFD_RELOC_MMIX_REG_OR_BYTE);
+ if (exp[2].X_op == O_register)
+ opcodep[3] = exp[2].X_add_number;
+ else
+ fix_new_exp (opc_fragP, opcodep - opc_fragP->fr_literal + 3,
+ 1, exp + 2, 0, BFD_RELOC_MMIX_REG_OR_BYTE);
+ }
+ else if (n_operands == 2)
+ {
+ if (exp[0].X_op == O_register)
+ opcodep[2] = exp[0].X_add_number;
+ else
+ fix_new_exp (opc_fragP, opcodep - opc_fragP->fr_literal + 2,
+ 1, exp, 0, BFD_RELOC_MMIX_REG_OR_BYTE);
+ if (exp[1].X_op == O_register)
+ opcodep[3] = exp[1].X_add_number;
+ else
+ fix_new_exp (opc_fragP, opcodep - opc_fragP->fr_literal + 3,
+ 1, exp + 1, 0, BFD_RELOC_MMIX_REG_OR_BYTE);
+ }
+ else
+ {
+ as_bad (_("unsupported operands to %s: `%s'"),
+ instruction->name, operands);
+ return;
+ }
+ }
+ else
+ {
+ as_bad (_("invalid operands to opcode %s: `%s'"),
+ instruction->name, operands);
+ return;
+ }
+ break;
+
+ case mmix_operands_resume:
+ if (n_operands == 0 && ! mmix_gnu_syntax)
+ break;
+
+ if (n_operands != 1
+ || exp[0].X_op == O_register
+ || (exp[0].X_op == O_constant
+ && (exp[0].X_add_number < 0
+ || exp[0].X_add_number > 255)))
+ {
+ as_bad (_("invalid operands to opcode %s: `%s'"),
+ instruction->name, operands);
+ return;
+ }
+
+ if (exp[0].X_op == O_constant)
+ opcodep[3] = exp[0].X_add_number;
+ else
+ fix_new_exp (opc_fragP, opcodep - opc_fragP->fr_literal + 3,
+ 1, exp + 0, 0, BFD_RELOC_8);
+ break;
+
+ case mmix_operands_pushj:
+ /* All is done for PUSHJ already. */
+ break;
+
+ default:
+ BAD_CASE (instruction->operands);
+ }
+}
+
+/* For the benefit of insns that start with a digit, we assemble by way of
+ tc_unrecognized_line too, through this function. */
+
+int
+mmix_assemble_return_nonzero (str)
+ char *str;
+{
+ int last_error_count = had_errors ();
+ char *s2 = str;
+ char c;
+
+ /* Normal instruction handling downcases, so we must too. */
+ while (ISALNUM (*s2))
+ {
+ if (ISUPPER ((unsigned char) *s2))
+ *s2 = TOLOWER (*s2);
+ s2++;
+ }
+
+ /* Cut the line for sake of the assembly. */
+ for (s2 = str; *s2 && *s2 != '\n'; s2++)
+ ;
+
+ c = *s2;
+ *s2 = 0;
+ md_assemble (str);
+ *s2 = c;
+
+ return had_errors () == last_error_count;
+}
+
+/* The PREFIX pseudo. */
+
+static void
+s_prefix (unused)
+ int unused ATTRIBUTE_UNUSED;
+{
+ char *p;
+ int c;
+
+ SKIP_WHITESPACE ();
+
+ p = input_line_pointer;
+
+ c = get_symbol_end ();
+
+ /* Reseting prefix? */
+ if (*p == ':' && p[1] == 0)
+ mmix_current_prefix = NULL;
+ else
+ {
+ /* Put this prefix on the mmix symbols obstack. We could malloc and
+ free it separately, but then we'd have to worry about that.
+ People using up memory on prefixes have other problems. */
+ obstack_grow (&mmix_sym_obstack, p, strlen (p) + 1);
+ p = obstack_finish (&mmix_sym_obstack);
+
+ /* Accumulate prefixes, and strip a leading ':'. */
+ if (mmix_current_prefix != NULL || *p == ':')
+ p = mmix_prefix_name (p);
+
+ mmix_current_prefix = p;
+ }
+
+ *input_line_pointer = c;
+
+ mmix_handle_rest_of_empty_line ();
+}
+
+/* We implement prefixes by using the tc_canonicalize_symbol_name hook,
+ and store each prefixed name on a (separate) obstack. This means that
+ the name is on the "notes" obstack in non-prefixed form and on the
+ mmix_sym_obstack in prefixed form, but currently it is not worth
+ rewriting the whole GAS symbol handling to improve "hooking" to avoid
+ that. (It might be worth a rewrite for other reasons, though). */
+
+char *
+mmix_prefix_name (shortname)
+ char *shortname;
+{
+ if (*shortname == ':')
+ return shortname + 1;
+
+ if (mmix_current_prefix == NULL)
+ as_fatal (_("internal: mmix_prefix_name but empty prefix"));
+
+ if (*shortname == '$')
+ return shortname;
+
+ obstack_grow (&mmix_sym_obstack, mmix_current_prefix,
+ strlen (mmix_current_prefix));
+ obstack_grow (&mmix_sym_obstack, shortname, strlen (shortname) + 1);
+ return obstack_finish (&mmix_sym_obstack);
+}
+
+/* The GREG pseudo. At LABEL, we have the name of a symbol that we
+ want to make a register symbol, and which should be initialized with
+ the value in the expression at INPUT_LINE_POINTER (defaulting to 0).
+ Either and (perhaps less meaningful) both may be missing. LABEL must
+ be persistent, perhaps allocated on an obstack. */
+
+static void
+mmix_greg_internal (label)
+ char *label;
+{
+ expressionS *expP = &mmix_raw_gregs[n_of_raw_gregs].exp;
+
+ /* Don't set the section to register contents section before the
+ expression has been parsed; it may refer to the current position. */
+ expression (expP);
+
+ /* FIXME: Check that no expression refers to the register contents
+ section. May need to be done in elf64-mmix.c. */
+ if (expP->X_op == O_absent)
+ {
+ /* Default to zero if the expression was absent. */
+ expP->X_op = O_constant;
+ expP->X_add_number = 0;
+ expP->X_unsigned = 0;
+ expP->X_add_symbol = NULL;
+ expP->X_op_symbol = NULL;
+ }
+
+ /* We must handle prefixes here, as we save the labels and expressions
+ to be output later. */
+ mmix_raw_gregs[n_of_raw_gregs].label
+ = mmix_current_prefix == NULL ? label : mmix_prefix_name (label);
+
+ if (n_of_raw_gregs == MAX_GREGS - 1)
+ as_bad (_("too many GREG registers allocated (max %d)"), MAX_GREGS);
+ else
+ n_of_raw_gregs++;
+
+ mmix_handle_rest_of_empty_line ();
+}
+
+/* The ".greg label,expr" worker. */
+
+static void
+s_greg (unused)
+ int unused ATTRIBUTE_UNUSED;
+{
+ char *p;
+ char c;
+ p = input_line_pointer;
+
+ /* This will skip over what can be a symbol and zero out the next
+ character, which we assume is a ',' or other meaningful delimiter.
+ What comes after that is the initializer expression for the
+ register. */
+ c = get_symbol_end ();
+
+ if (! is_end_of_line [(unsigned char) c])
+ input_line_pointer++;
+
+ if (*p)
+ {
+ /* The label must be persistent; it's not used until after all input
+ has been seen. */
+ obstack_grow (&mmix_sym_obstack, p, strlen (p) + 1);
+ mmix_greg_internal (obstack_finish (&mmix_sym_obstack));
+ }
+ else
+ mmix_greg_internal (NULL);
+}
+
+/* The "BSPEC expr" worker. */
+
+static void
+s_bspec (unused)
+ int unused ATTRIBUTE_UNUSED;
+{
+ asection *expsec;
+ asection *sec;
+ char secname[sizeof (MMIX_OTHER_SPEC_SECTION_PREFIX) + 20]
+ = MMIX_OTHER_SPEC_SECTION_PREFIX;
+ expressionS exp;
+ int n;
+
+ /* Get a constant expression which we can evaluate *now*. Supporting
+ more complex (though assembly-time computable) expressions is
+ feasible but Too Much Work for something of unknown usefulness like
+ BSPEC-ESPEC. */
+ expsec = expression (&exp);
+ mmix_handle_rest_of_empty_line ();
+
+ /* Check that we don't have another BSPEC in progress. */
+ if (doing_bspec)
+ {
+ as_bad (_("BSPEC already active. Nesting is not supported."));
+ return;
+ }
+
+ if (exp.X_op != O_constant
+ || expsec != absolute_section
+ || exp.X_add_number < 0
+ || exp.X_add_number > 65535)
+ {
+ as_bad (_("invalid BSPEC expression"));
+ exp.X_add_number = 0;
+ }
+
+ n = (int) exp.X_add_number;
+
+ sprintf (secname + strlen (MMIX_OTHER_SPEC_SECTION_PREFIX), "%d", n);
+ sec = bfd_get_section_by_name (stdoutput, secname);
+ if (sec == NULL)
+ {
+ /* We need a non-volatile name as it will be stored in the section
+ struct. */
+ char *newsecname = xstrdup (secname);
+ sec = bfd_make_section (stdoutput, newsecname);
+
+ if (sec == NULL)
+ as_fatal (_("can't create section %s"), newsecname);
+
+ if (!bfd_set_section_flags (stdoutput, sec,
+ bfd_get_section_flags (stdoutput, sec)
+ | SEC_READONLY))
+ as_fatal (_("can't set section flags for section %s"), newsecname);
+ }
+
+ /* Tell ELF about the pending section change. */
+ obj_elf_section_change_hook ();
+ subseg_set (sec, 0);
+
+ /* Save position for missing ESPEC. */
+ as_where (&bspec_file, &bspec_line);
+
+ doing_bspec = 1;
+}
+
+/* The "ESPEC" worker. */
+
+static void
+s_espec (unused)
+ int unused ATTRIBUTE_UNUSED;
+{
+ /* First, check that we *do* have a BSPEC in progress. */
+ if (! doing_bspec)
+ {
+ as_bad (_("ESPEC without preceding BSPEC"));
+ return;
+ }
+
+ mmix_handle_rest_of_empty_line ();
+ doing_bspec = 0;
+
+ /* When we told ELF about the section change in s_bspec, it stored the
+ previous section for us so we can get at it with the equivalent of a
+ .previous pseudo. */
+ obj_elf_previous (0);
+}
+
+/* The " .local expr" and " local expr" worker. We make a BFD_MMIX_LOCAL
+ relocation against the current position against the expression.
+ Implementing this by means of contents in a section lost. */
+
+static void
+mmix_s_local (unused)
+ int unused ATTRIBUTE_UNUSED;
+{
+ expressionS exp;
+
+ /* Don't set the section to register contents section before the
+ expression has been parsed; it may refer to the current position in
+ some contorted way. */
+ expression (&exp);
+
+ if (exp.X_op == O_absent)
+ {
+ as_bad (_("missing local expression"));
+ return;
+ }
+ else if (exp.X_op == O_register)
+ {
+ /* fix_new_exp doesn't like O_register. Should be configurable.
+ We're fine with a constant here, though. */
+ exp.X_op = O_constant;
+ }
+
+ fix_new_exp (frag_now, 0, 0, &exp, 0, BFD_RELOC_MMIX_LOCAL);
+ mmix_handle_rest_of_empty_line ();
+}
+
+/* Set fragP->fr_var to the initial guess of the size of a relaxable insn
+ and return it. Sizes of other instructions are not known. This
+ function may be called multiple times. */
+
+int
+md_estimate_size_before_relax (fragP, segment)
+ fragS *fragP;
+ segT segment;
+{
+ int length;
+
+#define HANDLE_RELAXABLE(state) \
+ case ENCODE_RELAX (state, STATE_UNDF): \
+ if (fragP->fr_symbol != NULL \
+ && S_GET_SEGMENT (fragP->fr_symbol) == segment) \
+ { \
+ /* The symbol lies in the same segment - a relaxable case. */ \
+ fragP->fr_subtype \
+ = ENCODE_RELAX (state, STATE_ZERO); \
+ } \
+ break;
+
+ switch (fragP->fr_subtype)
+ {
+ HANDLE_RELAXABLE (STATE_GETA);
+ HANDLE_RELAXABLE (STATE_BCC);
+ HANDLE_RELAXABLE (STATE_PUSHJ);
+ HANDLE_RELAXABLE (STATE_JMP);
+
+ case ENCODE_RELAX (STATE_GETA, STATE_ZERO):
+ case ENCODE_RELAX (STATE_BCC, STATE_ZERO):
+ case ENCODE_RELAX (STATE_PUSHJ, STATE_ZERO):
+ case ENCODE_RELAX (STATE_JMP, STATE_ZERO):
+ /* When relaxing a section for the second time, we don't need to do
+ anything except making sure that fr_var is set right. */
+ break;
+
+ case STATE_GREG_DEF:
+ length = fragP->tc_frag_data != NULL ? 0 : 8;
+ fragP->fr_var = length;
+
+ /* Don't consult the relax_table; it isn't valid for this
+ relaxation. */
+ return length;
+ break;
+
+ default:
+ BAD_CASE (fragP->fr_subtype);
+ }
+
+ length = mmix_relax_table[fragP->fr_subtype].rlx_length;
+ fragP->fr_var = length;
+
+ return length;
+}
+
+/* Turn a string in input_line_pointer into a floating point constant of type
+ type, and store the appropriate bytes in *litP. The number of LITTLENUMS
+ emitted is stored in *sizeP . An error message is returned, or NULL on
+ OK. */
+
+char *
+md_atof (type, litP, sizeP)
+ int type;
+ char *litP;
+ int *sizeP;
+{
+ int prec;
+ LITTLENUM_TYPE words[4];
+ char *t;
+ int i;
+
+ switch (type)
+ {
+ /* FIXME: Having 'f' in mmix_flt_chars (and here) makes it
+ problematic to also have a forward reference in an expression.
+ The testsuite wants it, and it's customary.
+ We'll deal with the real problems when they come; we share the
+ problem with most other ports. */
+ case 'f':
+ case 'r':
+ prec = 2;
+ break;
+ case 'd':
+ prec = 4;
+ break;
+ default:
+ *sizeP = 0;
+ return _("bad call to md_atof");
+ }
+
+ t = atof_ieee (input_line_pointer, type, words);
+ if (t)
+ input_line_pointer = t;
+
+ *sizeP = prec * 2;
+
+ for (i = 0; i < prec; i++)
+ {
+ md_number_to_chars (litP, (valueT) words[i], 2);
+ litP += 2;
+ }
+ return NULL;
+}
+
+/* Convert variable-sized frags into one or more fixups. */
+
+void
+md_convert_frag (abfd, sec, fragP)
+ bfd *abfd ATTRIBUTE_UNUSED;
+ segT sec ATTRIBUTE_UNUSED;
+ fragS *fragP;
+{
+ /* Pointer to first byte in variable-sized part of the frag. */
+ char *var_partp;
+
+ /* Pointer to first opcode byte in frag. */
+ char *opcodep;
+
+ /* Size in bytes of variable-sized part of frag. */
+ int var_part_size = 0;
+
+ /* This is part of *fragP. It contains all information about addresses
+ and offsets to varying parts. */
+ symbolS *symbolP;
+ unsigned long var_part_offset;
+
+ /* This is the frag for the opcode. It, rather than fragP, must be used
+ when emitting a frag for the opcode. */
+ fragS *opc_fragP = fragP->tc_frag_data;
+ fixS *tmpfixP;
+
+ /* Where, in file space, does addr point? */
+ bfd_vma target_address;
+ bfd_vma opcode_address;
+
+ know (fragP->fr_type == rs_machine_dependent);
+
+ var_part_offset = fragP->fr_fix;
+ var_partp = fragP->fr_literal + var_part_offset;
+ opcodep = fragP->fr_opcode;
+
+ symbolP = fragP->fr_symbol;
+
+ target_address
+ = ((symbolP ? S_GET_VALUE (symbolP) : 0) + fragP->fr_offset);
+
+ /* The opcode that would be extended is the last four "fixed" bytes. */
+ opcode_address = fragP->fr_address + fragP->fr_fix - 4;
+
+ switch (fragP->fr_subtype)
+ {
+ case ENCODE_RELAX (STATE_GETA, STATE_ZERO):
+ case ENCODE_RELAX (STATE_BCC, STATE_ZERO):
+ case ENCODE_RELAX (STATE_PUSHJ, STATE_ZERO):
+ mmix_set_geta_branch_offset (opcodep, target_address - opcode_address);
+ if (linkrelax)
+ {
+ tmpfixP
+ = fix_new (opc_fragP, opcodep - opc_fragP->fr_literal, 4,
+ fragP->fr_symbol, fragP->fr_offset, 1,
+ BFD_RELOC_MMIX_ADDR19);
+ COPY_FR_WHERE_TO_FX (fragP, tmpfixP);
+ }
+ var_part_size = 0;
+ break;
+
+ case ENCODE_RELAX (STATE_JMP, STATE_ZERO):
+ mmix_set_jmp_offset (opcodep, target_address - opcode_address);
+ if (linkrelax)
+ {
+ tmpfixP
+ = fix_new (opc_fragP, opcodep - opc_fragP->fr_literal, 4,
+ fragP->fr_symbol, fragP->fr_offset, 1,
+ BFD_RELOC_MMIX_ADDR27);
+ COPY_FR_WHERE_TO_FX (fragP, tmpfixP);
+ }
+ var_part_size = 0;
+ break;
+
+ case STATE_GREG_DEF:
+ if (fragP->tc_frag_data == NULL)
+ {
+ tmpfixP
+ = fix_new (fragP, var_partp - fragP->fr_literal, 8,
+ fragP->fr_symbol, fragP->fr_offset, 0, BFD_RELOC_64);
+ COPY_FR_WHERE_TO_FX (fragP, tmpfixP);
+ mmix_gregs[n_of_cooked_gregs++] = tmpfixP;
+ var_part_size = 8;
+ }
+ else
+ var_part_size = 0;
+ break;
+
+#define HANDLE_MAX_RELOC(state, reloc) \
+ case ENCODE_RELAX (state, STATE_MAX): \
+ var_part_size \
+ = mmix_relax_table[ENCODE_RELAX (state, STATE_MAX)].rlx_length; \
+ mmix_fill_nops (var_partp, var_part_size / 4); \
+ if (warn_on_expansion) \
+ as_warn_where (fragP->fr_file, fragP->fr_line, \
+ _("operand out of range, instruction expanded")); \
+ tmpfixP = fix_new (fragP, var_partp - fragP->fr_literal - 4, 8, \
+ fragP->fr_symbol, fragP->fr_offset, 1, reloc); \
+ COPY_FR_WHERE_TO_FX (fragP, tmpfixP); \
+ break
+
+ HANDLE_MAX_RELOC (STATE_GETA, BFD_RELOC_MMIX_GETA);
+ HANDLE_MAX_RELOC (STATE_BCC, BFD_RELOC_MMIX_CBRANCH);
+ HANDLE_MAX_RELOC (STATE_PUSHJ, BFD_RELOC_MMIX_PUSHJ);
+ HANDLE_MAX_RELOC (STATE_JMP, BFD_RELOC_MMIX_JMP);
+
+ default:
+ BAD_CASE (fragP->fr_subtype);
+ break;
+ }
+
+ fragP->fr_fix += var_part_size;
+ fragP->fr_var = 0;
+}
+
+/* Applies the desired value to the specified location.
+ Also sets up addends for RELA type relocations.
+ Stolen from tc-mcore.c.
+
+ Note that this function isn't called when linkrelax != 0. */
+
+int
+md_apply_fix3 (fixP, valp, segment)
+ fixS * fixP;
+ valueT * valp;
+ segT segment;
+{
+ char *buf = fixP->fx_where + fixP->fx_frag->fr_literal;
+ /* Note: use offsetT because it is signed, valueT is unsigned. */
+ offsetT val = (offsetT) * valp;
+ segT symsec
+ = (fixP->fx_addsy == NULL
+ ? absolute_section : S_GET_SEGMENT (fixP->fx_addsy));
+
+ /* If the fix is relative to a symbol which is not defined, or, (if
+ pcrel), not in the same segment as the fix, we cannot resolve it
+ here. */
+ if (fixP->fx_addsy != NULL
+ && (! S_IS_DEFINED (fixP->fx_addsy)
+ || S_IS_WEAK (fixP->fx_addsy)
+ || (fixP->fx_pcrel && symsec != segment)
+ || (! fixP->fx_pcrel
+ && symsec != absolute_section
+ && ((fixP->fx_r_type != BFD_RELOC_MMIX_REG
+ && fixP->fx_r_type != BFD_RELOC_MMIX_REG_OR_BYTE)
+ || (symsec != reg_section
+ && symsec != real_reg_section)))))
+ {
+ fixP->fx_done = 0;
+ return 0;
+ }
+ else if (fixP->fx_r_type == BFD_RELOC_MMIX_LOCAL
+ || fixP->fx_r_type == BFD_RELOC_VTABLE_INHERIT
+ || fixP->fx_r_type == BFD_RELOC_VTABLE_ENTRY)
+ {
+ /* These are never "fixed". */
+ fixP->fx_done = 0;
+ return 0;
+ }
+ else
+ /* We assume every other relocation is "fixed". */
+ fixP->fx_done = 1;
+
+ switch (fixP->fx_r_type)
+ {
+ case BFD_RELOC_64:
+ case BFD_RELOC_32:
+ case BFD_RELOC_24:
+ case BFD_RELOC_16:
+ case BFD_RELOC_8:
+ case BFD_RELOC_64_PCREL:
+ case BFD_RELOC_32_PCREL:
+ case BFD_RELOC_24_PCREL:
+ case BFD_RELOC_16_PCREL:
+ case BFD_RELOC_8_PCREL:
+ md_number_to_chars (buf, val, fixP->fx_size);
+ break;
+
+ case BFD_RELOC_MMIX_ADDR19:
+ if (expand_op)
+ {
+ /* This shouldn't happen. */
+ BAD_CASE (fixP->fx_r_type);
+ break;
+ }
+ /* FALLTHROUGH. */
+ case BFD_RELOC_MMIX_GETA:
+ case BFD_RELOC_MMIX_CBRANCH:
+ case BFD_RELOC_MMIX_PUSHJ:
+ /* If this fixup is out of range, punt to the linker to emit an
+ error. This should only happen with -no-expand. */
+ if (val < -(((offsetT) 1 << 19)/2)
+ || val >= ((offsetT) 1 << 19)/2 - 1
+ || (val & 3) != 0)
+ {
+ if (warn_on_expansion)
+ as_warn_where (fixP->fx_file, fixP->fx_line,
+ _("operand out of range"));
+ fixP->fx_done = 0;
+ val = 0;
+ }
+ mmix_set_geta_branch_offset (buf, val);
+ break;
+
+ case BFD_RELOC_MMIX_ADDR27:
+ if (expand_op)
+ {
+ /* This shouldn't happen. */
+ BAD_CASE (fixP->fx_r_type);
+ break;
+ }
+ /* FALLTHROUGH. */
+ case BFD_RELOC_MMIX_JMP:
+ /* If this fixup is out of range, punt to the linker to emit an
+ error. This should only happen with -no-expand. */
+ if (val < -(((offsetT) 1 << 27)/2)
+ || val >= ((offsetT) 1 << 27)/2 - 1
+ || (val & 3) != 0)
+ {
+ if (warn_on_expansion)
+ as_warn_where (fixP->fx_file, fixP->fx_line,
+ _("operand out of range"));
+ fixP->fx_done = 0;
+ val = 0;
+ }
+ mmix_set_jmp_offset (buf, val);
+ break;
+
+ case BFD_RELOC_MMIX_REG_OR_BYTE:
+ if (fixP->fx_addsy != NULL
+ && (S_GET_SEGMENT (fixP->fx_addsy) != real_reg_section
+ || S_GET_VALUE (fixP->fx_addsy) > 255)
+ && S_GET_SEGMENT (fixP->fx_addsy) != absolute_section)
+ as_bad_where (fixP->fx_file, fixP->fx_line,
+ _("invalid operands"));
+ buf[0] = val;
+
+ /* If this reloc is for a Z field, we need to adjust
+ the opcode if we got a constant here.
+ FIXME: Can we make this more robust? */
+
+ if ((fixP->fx_where & 3) == 3
+ && (fixP->fx_addsy == NULL
+ || S_GET_SEGMENT (fixP->fx_addsy) == absolute_section))
+ buf[-3] |= IMM_OFFSET_BIT;
+
+ /* We don't want this "symbol" appearing in output, because that
+ will fail. */
+ if (fixP->fx_addsy
+ && S_GET_SEGMENT (fixP->fx_addsy) == real_reg_section)
+ symbol_clear_used_in_reloc (fixP->fx_addsy);
+ break;
+
+ case BFD_RELOC_MMIX_REG:
+ if (fixP->fx_addsy == NULL
+ || S_GET_SEGMENT (fixP->fx_addsy) != real_reg_section
+ || S_GET_VALUE (fixP->fx_addsy) > 255)
+ as_bad_where (fixP->fx_file, fixP->fx_line,
+ _("invalid operands"));
+ *buf = val;
+
+ if (fixP->fx_addsy
+ && S_GET_SEGMENT (fixP->fx_addsy) == real_reg_section)
+ symbol_clear_used_in_reloc (fixP->fx_addsy);
+ break;
+
+ case BFD_RELOC_MMIX_BASE_PLUS_OFFSET:
+ /* These are never "fixed". */
+ fixP->fx_done = 0;
+ return 0;
+
+ case BFD_RELOC_MMIX_PUSHJ_1:
+ case BFD_RELOC_MMIX_PUSHJ_2:
+ case BFD_RELOC_MMIX_PUSHJ_3:
+ case BFD_RELOC_MMIX_CBRANCH_J:
+ case BFD_RELOC_MMIX_CBRANCH_1:
+ case BFD_RELOC_MMIX_CBRANCH_2:
+ case BFD_RELOC_MMIX_CBRANCH_3:
+ case BFD_RELOC_MMIX_GETA_1:
+ case BFD_RELOC_MMIX_GETA_2:
+ case BFD_RELOC_MMIX_GETA_3:
+ case BFD_RELOC_MMIX_JMP_1:
+ case BFD_RELOC_MMIX_JMP_2:
+ case BFD_RELOC_MMIX_JMP_3:
+ default:
+ BAD_CASE (fixP->fx_r_type);
+ break;
+ }
+
+ if (fixP->fx_done)
+ /* Make sure that for completed fixups we have the value around for
+ use by e.g. mmix_frob_file. */
+ fixP->fx_offset = val;
+
+ return 0; /* Return value is ignored. */
+}
+
+/* A bsearch function for looking up a value against offsets for GREG
+ definitions. */
+
+static int
+cmp_greg_val_greg_symbol_fixes (p1, p2)
+ const PTR p1;
+ const PTR p2;
+{
+ offsetT val1 = *(offsetT *) p1;
+ offsetT val2 = ((struct mmix_symbol_greg_fixes *) p2)->offs;
+
+ if (val1 >= val2 && val1 < val2 + 255)
+ return 0;
+
+ if (val1 > val2)
+ return 1;
+
+ return -1;
+}
+
+/* Generate a machine-dependent relocation. */
+
+arelent *
+tc_gen_reloc (section, fixP)
+ asection *section ATTRIBUTE_UNUSED;
+ fixS *fixP;
+{
+ bfd_signed_vma val
+ = fixP->fx_offset + (fixP->fx_addsy ? S_GET_VALUE (fixP->fx_addsy) : 0);
+ arelent *relP;
+ bfd_reloc_code_real_type code = BFD_RELOC_NONE;
+ char *buf = fixP->fx_where + fixP->fx_frag->fr_literal;
+ symbolS *addsy = fixP->fx_addsy;
+ asection *addsec = addsy == NULL ? NULL : S_GET_SEGMENT (addsy);
+ bfd_vma addend = fixP->fx_offset;
+ asymbol *baddsy = addsy != NULL ? symbol_get_bfdsym (addsy) : NULL;
+
+ /* A single " LOCAL expression" in the wrong section will not work when
+ linking to MMO; relocations for zero-content sections are then
+ ignored. Normally, relocations would modify section contents, and
+ you'd never think or be able to do something like that. The
+ relocation resulting from a LOCAL directive doesn't have an obvious
+ and mandatory location. I can't figure out a way to do this better
+ than just helping the user around this limitation here; hopefully the
+ code using the local expression is around. Putting the LOCAL
+ semantics in a relocation still seems right; a section didn't do. */
+ if (bfd_section_size (section->owner, section) == 0)
+ as_bad_where
+ (fixP->fx_file, fixP->fx_line,
+ fixP->fx_r_type == BFD_RELOC_MMIX_LOCAL
+ /* The BFD_RELOC_MMIX_LOCAL-specific message is supposed to be
+ user-friendly, though a little bit non-substantial. */
+ ? _("directive LOCAL must be placed in code or data")
+ : _("internal confusion: relocation in a section without contents"));
+
+ /* FIXME: Range tests for all these. */
+ switch (fixP->fx_r_type)
+ {
+ case BFD_RELOC_64:
+ case BFD_RELOC_32:
+ case BFD_RELOC_24:
+ case BFD_RELOC_16:
+ case BFD_RELOC_8:
+ code = fixP->fx_r_type;
+
+ if (addsy == NULL
+ || bfd_is_abs_section (S_GET_SEGMENT (addsy)))
+ {
+ /* Resolve this reloc now, as md_apply_fix3 would have done (not
+ called if -linkrelax). There is no point in keeping a reloc
+ to an absolute symbol. No reloc that is subject to
+ relaxation must be to an absolute symbol; difference
+ involving symbols in a specific section must be signalled as
+ an error if the relaxing cannot be expressed; having a reloc
+ to the resolved (now absolute) value does not help. */
+ md_number_to_chars (buf, val, fixP->fx_size);
+ return NULL;
+ }
+ break;
+
+ case BFD_RELOC_64_PCREL:
+ case BFD_RELOC_32_PCREL:
+ case BFD_RELOC_24_PCREL:
+ case BFD_RELOC_16_PCREL:
+ case BFD_RELOC_8_PCREL:
+ case BFD_RELOC_MMIX_LOCAL:
+ case BFD_RELOC_VTABLE_INHERIT:
+ case BFD_RELOC_VTABLE_ENTRY:
+ case BFD_RELOC_MMIX_GETA:
+ case BFD_RELOC_MMIX_GETA_1:
+ case BFD_RELOC_MMIX_GETA_2:
+ case BFD_RELOC_MMIX_GETA_3:
+ case BFD_RELOC_MMIX_CBRANCH:
+ case BFD_RELOC_MMIX_CBRANCH_J:
+ case BFD_RELOC_MMIX_CBRANCH_1:
+ case BFD_RELOC_MMIX_CBRANCH_2:
+ case BFD_RELOC_MMIX_CBRANCH_3:
+ case BFD_RELOC_MMIX_PUSHJ:
+ case BFD_RELOC_MMIX_PUSHJ_1:
+ case BFD_RELOC_MMIX_PUSHJ_2:
+ case BFD_RELOC_MMIX_PUSHJ_3:
+ case BFD_RELOC_MMIX_JMP:
+ case BFD_RELOC_MMIX_JMP_1:
+ case BFD_RELOC_MMIX_JMP_2:
+ case BFD_RELOC_MMIX_JMP_3:
+ case BFD_RELOC_MMIX_ADDR19:
+ case BFD_RELOC_MMIX_ADDR27:
+ code = fixP->fx_r_type;
+ break;
+
+ case BFD_RELOC_MMIX_REG_OR_BYTE:
+ /* If we have this kind of relocation to an unknown symbol or to the
+ register contents section (that is, to a register), then we can't
+ resolve the relocation here. */
+ if (addsy != NULL
+ && (bfd_is_und_section (S_GET_SEGMENT (addsy))
+ || strcmp (bfd_get_section_name (addsec->owner, addsec),
+ MMIX_REG_CONTENTS_SECTION_NAME) == 0))
+ {
+ code = fixP->fx_r_type;
+ break;
+ }
+
+ /* If the relocation is not to the register section or to the
+ absolute section (a numeric value), then we have an error. */
+ if (addsy != NULL
+ && (S_GET_SEGMENT (addsy) != real_reg_section
+ || val > 255
+ || val < 0)
+ && ! bfd_is_abs_section (S_GET_SEGMENT (addsy)))
+ goto badop;
+
+ /* Set the "immediate" bit of the insn if this relocation is to Z
+ field when the value is a numeric value, i.e. not a register. */
+ if ((fixP->fx_where & 3) == 3
+ && (addsy == NULL
+ || S_GET_SEGMENT (addsy) == absolute_section))
+ buf[-3] |= IMM_OFFSET_BIT;
+
+ buf[0] = val;
+ return NULL;
+
+ case BFD_RELOC_MMIX_BASE_PLUS_OFFSET:
+ if (addsy != NULL
+ && strcmp (bfd_get_section_name (addsec->owner, addsec),
+ MMIX_REG_CONTENTS_SECTION_NAME) == 0)
+ {
+ /* This changed into a register; the relocation is for the
+ register-contents section. The constant part remains zero. */
+ code = BFD_RELOC_MMIX_REG;
+ break;
+ }
+
+ /* If we've found out that this was indeed a register, then replace
+ with the register number. The constant part is already zero.
+
+ If we encounter any other defined symbol, then we must find a
+ suitable register and emit a reloc. */
+ if (addsy == NULL
+ || S_GET_SEGMENT (addsy) != real_reg_section)
+ {
+ struct mmix_symbol_gregs *gregs;
+ struct mmix_symbol_greg_fixes *fix;
+
+ if (S_IS_DEFINED (addsy))
+ {
+ if (! symbol_section_p (addsy)
+ && ! bfd_is_abs_section (S_GET_SEGMENT (addsy)))
+ as_fatal (_("internal: BFD_RELOC_MMIX_BASE_PLUS_OFFSET not resolved to section"));
+
+ /* If this is an absolute symbol sufficiently near
+ lowest_data_loc, then we canonicalize on the data
+ section. Note that val is signed here; we may subtract
+ lowest_data_loc which is unsigned. Careful with those
+ comparisons. */
+ if (lowest_data_loc != (bfd_vma) -1
+ && (bfd_vma) val + 256 > lowest_data_loc
+ && bfd_is_abs_section (S_GET_SEGMENT (addsy)))
+ {
+ val -= (offsetT) lowest_data_loc;
+ addsy = section_symbol (data_section);
+ }
+ /* Likewise text section. */
+ else if (lowest_text_loc != (bfd_vma) -1
+ && (bfd_vma) val + 256 > lowest_text_loc
+ && bfd_is_abs_section (S_GET_SEGMENT (addsy)))
+ {
+ val -= (offsetT) lowest_text_loc;
+ addsy = section_symbol (text_section);
+ }
+ }
+
+ gregs = *symbol_get_tc (addsy);
+
+ /* If that symbol does not have any associated GREG definitions,
+ we can't do anything. FIXME: implement allocate-on-demand in
+ the linker. */
+ if (gregs == NULL
+ || (fix = bsearch (&val, gregs->greg_fixes, gregs->n_gregs,
+ sizeof (gregs->greg_fixes[0]),
+ cmp_greg_val_greg_symbol_fixes)) == NULL
+ /* The register must not point *after* the address we want. */
+ || fix->offs > val
+ /* Neither must the register point more than 255 bytes
+ before the address we want. */
+ || fix->offs + 255 < val)
+ {
+ as_bad_where (fixP->fx_file, fixP->fx_line,
+ _("no suitable GREG definition for operands"));
+ return NULL;
+ }
+ else
+ {
+ /* Transform the base-plus-offset reloc for the actual area
+ to a reloc for the register with the address of the area.
+ Put addend for register in Z operand. */
+ buf[1] = val - fix->offs;
+ code = BFD_RELOC_MMIX_REG;
+ baddsy
+ = (bfd_get_section_by_name (stdoutput,
+ MMIX_REG_CONTENTS_SECTION_NAME)
+ ->symbol);
+
+ addend = fix->fix->fx_frag->fr_address + fix->fix->fx_where;
+ }
+ }
+ else if (S_GET_VALUE (addsy) > 255)
+ as_bad_where (fixP->fx_file, fixP->fx_line,
+ _("invalid operands"));
+ else
+ {
+ *buf = val;
+ return NULL;
+ }
+ break;
+
+ case BFD_RELOC_MMIX_REG:
+ if (addsy != NULL
+ && (bfd_is_und_section (S_GET_SEGMENT (addsy))
+ || strcmp (bfd_get_section_name (addsec->owner, addsec),
+ MMIX_REG_CONTENTS_SECTION_NAME) == 0))
+ {
+ code = fixP->fx_r_type;
+ break;
+ }
+
+ if (addsy != NULL
+ && (S_GET_SEGMENT (addsy) != real_reg_section
+ || val > 255
+ || val < 0)
+ && ! bfd_is_und_section (S_GET_SEGMENT (addsy)))
+ /* Drop through to error message. */
+ ;
+ else
+ {
+ buf[0] = val;
+ return NULL;
+ }
+ /* FALLTHROUGH. */
+
+ /* The others are supposed to be handled by md_apply_fix3.
+ FIXME: ... which isn't called when -linkrelax. Move over
+ md_apply_fix3 code here for everything reasonable. */
+ badop:
+ default:
+ as_bad_where
+ (fixP->fx_file, fixP->fx_line,
+ _("operands were not reducible at assembly-time"));
+
+ /* Unmark this symbol as used in a reloc, so we don't bump into a BFD
+ assert when trying to output reg_section. FIXME: A gas bug. */
+ if (addsy)
+ symbol_clear_used_in_reloc (addsy);
+ return NULL;
+ }
+
+ relP = (arelent *) xmalloc (sizeof (arelent));
+ assert (relP != 0);
+ relP->sym_ptr_ptr = (asymbol **) xmalloc (sizeof (asymbol *));
+ *relP->sym_ptr_ptr = baddsy;
+ relP->address = fixP->fx_frag->fr_address + fixP->fx_where;
+
+ relP->addend = addend;
+
+ /* If this had been a.out, we would have had a kludge for weak symbols
+ here. */
+
+ relP->howto = bfd_reloc_type_lookup (stdoutput, code);
+ if (! relP->howto)
+ {
+ const char *name;
+
+ name = S_GET_NAME (addsy);
+ if (name == NULL)
+ name = _("<unknown>");
+ as_fatal (_("cannot generate relocation type for symbol %s, code %s"),
+ name, bfd_get_reloc_code_name (code));
+ }
+
+ return relP;
+}
+
+/* Do some reformatting of a line. FIXME: We could transform a mmixal
+ line into traditional (GNU?) format, unless #NO_APP, and get rid of all
+ ugly labels_without_colons etc. */
+
+void
+mmix_handle_mmixal ()
+{
+ char *s0 = input_line_pointer;
+ char *s;
+ char *label = NULL;
+ char c;
+
+ if (pending_label != NULL)
+ as_fatal (_("internal: unhandled label %s"), pending_label);
+
+ if (mmix_gnu_syntax)
+ return;
+
+ /* If the first character is a '.', then it's a pseudodirective, not a
+ label. Make GAS not handle label-without-colon on this line. We
+ also don't do mmixal-specific stuff on this line. */
+ if (input_line_pointer[0] == '.')
+ {
+ label_without_colon_this_line = 0;
+ return;
+ }
+
+ /* Don't handle empty lines here. */
+ while (1)
+ {
+ if (*s0 == 0 || is_end_of_line [(unsigned int) *s0])
+ return;
+
+ if (! ISSPACE (*s0))
+ break;
+
+ s0++;
+ }
+
+ /* If we're on a line with a label, check if it's a mmixal fb-label.
+ Save an indicator and skip the label; it must be set only after all
+ fb-labels of expressions are evaluated. */
+ if (ISDIGIT (input_line_pointer[0])
+ && input_line_pointer[1] == 'H'
+ && ISSPACE (input_line_pointer[2]))
+ {
+ char *s;
+ current_fb_label = input_line_pointer[0] - '0';
+
+ /* We have to skip the label, but also preserve the newlineness of
+ the previous character, since the caller checks that. It's a
+ mess we blame on the caller. */
+ input_line_pointer[1] = input_line_pointer[-1];
+ input_line_pointer += 2;
+
+ s = input_line_pointer;
+ while (*s && ISSPACE (*s) && ! is_end_of_line[(unsigned int) *s])
+ s++;
+
+ /* For errors emitted here, the book-keeping is off by one; the
+ caller is about to bump the counters. Adjust the error messages. */
+ if (is_end_of_line [(unsigned int) *s])
+ {
+ char *name;
+ unsigned int line;
+ as_where (&name, &line);
+ as_bad_where (name, line + 1,
+ _("[0-9]H labels may not appear alone on a line"));
+ current_fb_label = -1;
+ }
+ if (*s == '.')
+ {
+ char *name;
+ unsigned int line;
+ as_where (&name, &line);
+ as_bad_where (name, line + 1,
+ _("[0-9]H labels do not mix with dot-pseudos"));
+ current_fb_label = -1;
+ }
+ }
+ else
+ {
+ current_fb_label = -1;
+ if (is_name_beginner (input_line_pointer[0]))
+ label = input_line_pointer;
+ }
+
+ s0 = input_line_pointer;
+ /* Skip over label. */
+ while (*s0 && is_part_of_name (*s0))
+ s0++;
+
+ /* Remove trailing ":" off labels, as they'd otherwise be considered
+ part of the name. But don't do it for local labels. */
+ if (s0 != input_line_pointer && s0[-1] == ':'
+ && (s0 - 2 != input_line_pointer
+ || ! ISDIGIT (s0[-2])))
+ s0[-1] = ' ';
+ else if (label != NULL)
+ {
+ /* For labels that don't end in ":", we save it so we can later give
+ it the same alignment and address as the associated instruction. */
+
+ /* Make room for the label including the ending nul. */
+ int len_0 = s0 - label + 1;
+
+ /* Save this label on the MMIX symbol obstack. Saving it on an
+ obstack is needless for "IS"-pseudos, but it's harmless and we
+ avoid a little code-cluttering. */
+ obstack_grow (&mmix_sym_obstack, label, len_0);
+ pending_label = obstack_finish (&mmix_sym_obstack);
+ pending_label[len_0 - 1] = 0;
+ }
+
+ while (*s0 && ISSPACE (*s0) && ! is_end_of_line [(unsigned int) *s0])
+ s0++;
+
+ if (pending_label != NULL && is_end_of_line [(unsigned int) *s0])
+ /* Whoops, this was actually a lone label on a line. Like :-ended
+ labels, we don't attach such labels to the next instruction or
+ pseudo. */
+ pending_label = NULL;
+
+ /* Find local labels of operands. Look for "[0-9][FB]" where the
+ characters before and after are not part of words. Break if a single
+ or double quote is seen anywhere. It means we can't have local
+ labels as part of list with mixed quoted and unquoted members for
+ mmixal compatibility but we can't have it all. For the moment.
+ Replace the '<N>B' or '<N>F' with MAGIC_FB_BACKWARD_CHAR<N> and
+ MAGIC_FB_FORWARD_CHAR<N> respectively. */
+
+ /* First make sure we don't have any of the magic characters on the line
+ appearing as input. */
+ s = s0;
+ while (*s)
+ {
+ c = *s++;
+ if (is_end_of_line [(unsigned int) c])
+ break;
+ if (c == MAGIC_FB_BACKWARD_CHAR || c == MAGIC_FB_FORWARD_CHAR)
+ as_bad (_("invalid characters in input"));
+ }
+
+ /* Scan again, this time looking for ';' after operands. */
+ s = s0;
+
+ /* Skip the insn. */
+ while (*s
+ && ! ISSPACE (*s)
+ && *s != ';'
+ && ! is_end_of_line[(unsigned int) *s])
+ s++;
+
+ /* Skip the spaces after the insn. */
+ while (*s
+ && ISSPACE (*s)
+ && *s != ';'
+ && ! is_end_of_line[(unsigned int) *s])
+ s++;
+
+ /* Skip the operands. While doing this, replace [0-9][BF] with
+ (MAGIC_FB_BACKWARD_CHAR|MAGIC_FB_FORWARD_CHAR)[0-9]. */
+ while ((c = *s) != 0
+ && ! ISSPACE (c)
+ && c != ';'
+ && ! is_end_of_line[(unsigned int) c])
+ {
+ if (c == '"')
+ {
+ s++;
+
+ /* FIXME: Test-case for semi-colon in string. */
+ while (*s
+ && *s != '"'
+ && (! is_end_of_line [(unsigned int) *s] || *s == ';'))
+ s++;
+
+ if (*s == '"')
+ s++;
+ }
+ else if (ISDIGIT (c))
+ {
+ if ((s[1] != 'B' && s[1] != 'F')
+ || is_part_of_name (s[-1])
+ || is_part_of_name (s[2]))
+ s++;
+ else
+ {
+ s[0] = (s[1] == 'B'
+ ? MAGIC_FB_BACKWARD_CHAR : MAGIC_FB_FORWARD_CHAR);
+ s[1] = c;
+ }
+ }
+ else
+ s++;
+ }
+
+ /* Skip any spaces after the operands. */
+ while (*s
+ && ISSPACE (*s)
+ && *s != ';'
+ && !is_end_of_line[(unsigned int) *s])
+ s++;
+
+ /* If we're now looking at a semi-colon, then it's an end-of-line
+ delimiter. */
+ mmix_next_semicolon_is_eoln = (*s == ';');
+
+ /* Make IS into an EQU by replacing it with "= ". Only match upper-case
+ though; let lower-case be a syntax error. */
+ s = s0;
+ if (s[0] == 'I' && s[1] == 'S' && ISSPACE (s[2]))
+ {
+ *s = '=';
+ s[1] = ' ';
+
+ /* Since labels can start without ":", we have to handle "X IS 42"
+ in full here, or "X" will be parsed as a label to be set at ".". */
+ input_line_pointer = s;
+
+ /* Right after this function ends, line numbers will be bumped if
+ input_line_pointer[-1] = '\n'. We want accurate line numbers for
+ the equals call, so we bump them before the call, and make sure
+ they aren't bumped afterwards. */
+ bump_line_counters ();
+
+ /* A fb-label is valid as an IS-label. */
+ if (current_fb_label >= 0)
+ {
+ char *fb_name;
+
+ /* We need to save this name on our symbol obstack, since the
+ string we got in fb_label_name is volatile and will change
+ with every call to fb_label_name, like those resulting from
+ parsing the IS-operand. */
+ fb_name = fb_label_name (current_fb_label, 1);
+ obstack_grow (&mmix_sym_obstack, fb_name, strlen (fb_name) + 1);
+ equals (obstack_finish (&mmix_sym_obstack), 0);
+ fb_label_instance_inc (current_fb_label);
+ current_fb_label = -1;
+ }
+ else
+ {
+ if (pending_label == NULL)
+ as_bad (_("empty label field for IS"));
+ else
+ equals (pending_label, 0);
+ pending_label = NULL;
+ }
+
+ /* For mmixal, we can have comments without a comment-start
+ character. */
+ mmix_handle_rest_of_empty_line ();
+ input_line_pointer--;
+
+ input_line_pointer[-1] = ' ';
+ }
+ else if (s[0] == 'G'
+ && s[1] == 'R'
+ && strncmp (s, "GREG", 4) == 0
+ && (ISSPACE (s[4]) || is_end_of_line[(unsigned char) s[4]]))
+ {
+ input_line_pointer = s + 4;
+
+ /* Right after this function ends, line numbers will be bumped if
+ input_line_pointer[-1] = '\n'. We want accurate line numbers for
+ the s_greg call, so we bump them before the call, and make sure
+ they aren't bumped afterwards. */
+ bump_line_counters ();
+
+ /* A fb-label is valid as a GREG-label. */
+ if (current_fb_label >= 0)
+ {
+ char *fb_name;
+
+ /* We need to save this name on our symbol obstack, since the
+ string we got in fb_label_name is volatile and will change
+ with every call to fb_label_name, like those resulting from
+ parsing the IS-operand. */
+ fb_name = fb_label_name (current_fb_label, 1);
+
+ /* Make sure we save the canonical name and don't get bitten by
+ prefixes. */
+ obstack_1grow (&mmix_sym_obstack, ':');
+ obstack_grow (&mmix_sym_obstack, fb_name, strlen (fb_name) + 1);
+ mmix_greg_internal (obstack_finish (&mmix_sym_obstack));
+ fb_label_instance_inc (current_fb_label);
+ current_fb_label = -1;
+ }
+ else
+ mmix_greg_internal (pending_label);
+
+ /* Back up before the end-of-line marker that was skipped in
+ mmix_greg_internal. */
+ input_line_pointer--;
+ input_line_pointer[-1] = ' ';
+
+ pending_label = NULL;
+ }
+ else if (pending_label != NULL)
+ {
+ input_line_pointer += strlen (pending_label);
+
+ /* See comment above about getting line numbers bumped. */
+ input_line_pointer[-1] = '\n';
+ }
+}
+
+/* Give the value of an fb-label rewritten as in mmix_handle_mmixal, when
+ parsing an expression.
+
+ On valid calls, input_line_pointer points at a MAGIC_FB_BACKWARD_CHAR
+ or MAGIC_FB_BACKWARD_CHAR, followed by an ascii digit for the label.
+ We fill in the label as an expression. */
+
+void
+mmix_fb_label (expP)
+ expressionS *expP;
+{
+ symbolS *sym;
+ char *fb_internal_name;
+
+ /* This doesn't happen when not using mmixal syntax. */
+ if (mmix_gnu_syntax
+ || (input_line_pointer[0] != MAGIC_FB_BACKWARD_CHAR
+ && input_line_pointer[0] != MAGIC_FB_FORWARD_CHAR))
+ return;
+
+ /* The current backward reference has augmentation 0. A forward
+ reference has augmentation 1, unless it's the same as a fb-label on
+ _this_ line, in which case we add one more so we don't refer to it.
+ This is the semantics of mmixal; it differs to that of common
+ fb-labels which refer to a here-label on the current line as a
+ backward reference. */
+ fb_internal_name
+ = fb_label_name (input_line_pointer[1] - '0',
+ (input_line_pointer[0] == MAGIC_FB_FORWARD_CHAR ? 1 : 0)
+ + ((input_line_pointer[1] - '0' == current_fb_label
+ && input_line_pointer[0] == MAGIC_FB_FORWARD_CHAR)
+ ? 1 : 0));
+
+ input_line_pointer += 2;
+ sym = symbol_find_or_make (fb_internal_name);
+
+ /* We don't have to clean up unrelated fields here; we just do what the
+ expr machinery does, but *not* just what it does for [0-9][fb], since
+ we need to treat those as ordinary symbols sometimes; see testcases
+ err-byte2.s and fb-2.s. */
+ if (S_GET_SEGMENT (sym) == absolute_section)
+ {
+ expP->X_op = O_constant;
+ expP->X_add_number = S_GET_VALUE (sym);
+ }
+ else
+ {
+ expP->X_op = O_symbol;
+ expP->X_add_symbol = sym;
+ expP->X_add_number = 0;
+ }
+}
+
+/* See whether we need to force a relocation into the output file.
+ This is used to force out switch and PC relative relocations when
+ relaxing. */
+
+int
+mmix_force_relocation (fixP)
+ fixS * fixP;
+{
+ if (fixP->fx_r_type == BFD_RELOC_MMIX_LOCAL
+ || fixP->fx_r_type == BFD_RELOC_VTABLE_INHERIT
+ || fixP->fx_r_type == BFD_RELOC_VTABLE_ENTRY
+ || fixP->fx_r_type == BFD_RELOC_MMIX_BASE_PLUS_OFFSET)
+ return 1;
+
+ /* FIXME: This is dubious. Handling of weak symbols should have been
+ caught before we get here. */
+ if ((fixP->fx_addsy && S_IS_WEAK (fixP->fx_addsy)))
+ return 1;
+
+ if (linkrelax)
+ return 1;
+
+ /* All our pcrel relocations are must-keep. Note that md_apply_fix3 is
+ called *after* this, and will handle getting rid of the presumed
+ reloc; a relocation isn't *forced* other than to be handled by
+ md_apply_fix3 (or tc_gen_reloc if linkrelax). */
+ if (fixP->fx_pcrel)
+ return 1;
+
+ return 0;
+}
+
+/* The location from which a PC relative jump should be calculated,
+ given a PC relative reloc. */
+
+long
+md_pcrel_from_section (fixP, sec)
+ fixS * fixP;
+ segT sec;
+{
+ if (fixP->fx_addsy != (symbolS *) NULL
+ && (! S_IS_DEFINED (fixP->fx_addsy)
+ || S_GET_SEGMENT (fixP->fx_addsy) != sec))
+ {
+ /* The symbol is undefined (or is defined but not in this section).
+ Let the linker figure it out. */
+ return 0;
+ }
+
+ return (fixP->fx_frag->fr_address + fixP->fx_where);
+}
+
+/* Adjust the symbol table. We make reg_section relative to the real
+ register section.
+
+ FIXME: There's a gas bug; should be fixed when the reg_section symbol
+ is "accidentally" saved for relocs which are really fixups that will be
+ fixed up. */
+
+void
+mmix_adjust_symtab ()
+{
+ symbolS *sym;
+ symbolS *prevsym;
+ symbolS *regsec = section_symbol (reg_section);
+ segT realregsec = NULL;
+
+ for (prevsym = sym = symbol_rootP;
+ sym != NULL;
+ prevsym = sym, sym = symbol_next (sym))
+ if (S_GET_SEGMENT (sym) == reg_section)
+ {
+ if (sym == regsec
+ || (!S_IS_EXTERN (sym) && !symbol_used_in_reloc_p (sym)))
+ {
+ symbol_remove (sym, &symbol_rootP, &symbol_lastP);
+
+ /* We make one extra turn, or we'll lose the next symbol. We
+ assume that the symbol we remove is not the symbol root
+ (.text normally is). */
+ sym = prevsym;
+ }
+ else
+ {
+ /* Change section to the *real* register section, so it gets
+ proper treatment when writing it out. Only do this for
+ global symbols. This also means we don't have to check for
+ $0..$255. */
+ if (realregsec == NULL)
+ realregsec
+ = bfd_make_section_old_way (stdoutput, MMIX_REG_SECTION_NAME);
+
+ S_SET_SEGMENT (sym, realregsec);
+ }
+ }
+}
+
+/* This is the expansion of LABELS_WITHOUT_COLONS.
+ We let md_start_line_hook tweak label_without_colon_this_line, and then
+ this function returns the tweaked value, and sets it to 1 for the next
+ line. FIXME: Very, very brittle. Not sure it works the way I
+ thought at the time I first wrote this. */
+
+int
+mmix_label_without_colon_this_line ()
+{
+ int retval = label_without_colon_this_line;
+
+ if (! mmix_gnu_syntax)
+ label_without_colon_this_line = 1;
+
+ return retval;
+}
+
+/* This is the expansion of md_relax_frag. We go through the ordinary
+ relax table function except when the frag is for a GREG. Then we have
+ to check whether there's another GREG by the same value that we can
+ join with. */
+
+long
+mmix_md_relax_frag (seg, fragP, stretch)
+ segT seg;
+ fragS *fragP;
+ long stretch;
+{
+ if (fragP->fr_subtype != STATE_GREG_DEF
+ && fragP->fr_subtype != STATE_GREG_UNDF)
+ return relax_frag (seg, fragP, stretch);
+
+ /* If we're defined, we don't grow. */
+ if (fragP->fr_subtype == STATE_GREG_DEF)
+ return 0;
+
+ as_fatal (_("internal: unexpected relax type %d:%d"),
+ fragP->fr_type, fragP->fr_subtype);
+ return 0;
+}
+
+/* Various things we punt until all input is seen. */
+
+void
+mmix_md_end ()
+{
+ fragS *fragP;
+ symbolS *mainsym;
+ int i;
+
+ /* The first frag of GREG:s going into the register contents section. */
+ fragS *mmix_reg_contents_frags = NULL;
+
+ /* Reset prefix. All labels reachable at this point must be
+ canonicalized. */
+ mmix_current_prefix = NULL;
+
+ if (doing_bspec)
+ as_bad_where (bspec_file, bspec_line, _("BSPEC without ESPEC."));
+
+ /* Emit the low LOC setting of .text. */
+ if (text_has_contents && lowest_text_loc != (bfd_vma) -1)
+ {
+ symbolS *symbolP;
+ char locsymbol[sizeof (":") - 1
+ + sizeof (MMIX_LOC_SECTION_START_SYMBOL_PREFIX) - 1
+ + sizeof (".text")];
+
+ /* An exercise in non-ISO-C-ness, this one. */
+ sprintf (locsymbol, ":%s%s", MMIX_LOC_SECTION_START_SYMBOL_PREFIX,
+ ".text");
+ symbolP
+ = symbol_new (locsymbol, absolute_section, lowest_text_loc,
+ &zero_address_frag);
+ S_SET_EXTERNAL (symbolP);
+ }
+
+ /* Ditto .data. */
+ if (data_has_contents && lowest_data_loc != (bfd_vma) -1)
+ {
+ symbolS *symbolP;
+ char locsymbol[sizeof (":") - 1
+ + sizeof (MMIX_LOC_SECTION_START_SYMBOL_PREFIX) - 1
+ + sizeof (".data")];
+
+ sprintf (locsymbol, ":%s%s", MMIX_LOC_SECTION_START_SYMBOL_PREFIX,
+ ".data");
+ symbolP
+ = symbol_new (locsymbol, absolute_section, lowest_data_loc,
+ &zero_address_frag);
+ S_SET_EXTERNAL (symbolP);
+ }
+
+ /* Unless GNU syntax mode, set "Main" to be a function, so the
+ disassembler doesn't get confused when we write truly
+ mmixal-compatible code (and don't use .type). Similarly set it
+ global (regardless of -globalize-symbols), so the linker sees it as
+ the start symbol in ELF mode. */
+ mainsym = symbol_find (MMIX_START_SYMBOL_NAME);
+ if (mainsym != NULL && ! mmix_gnu_syntax)
+ {
+ symbol_get_bfdsym (mainsym)->flags |= BSF_FUNCTION;
+ S_SET_EXTERNAL (mainsym);
+ }
+
+ if (n_of_raw_gregs != 0)
+ {
+ /* Emit GREGs. They are collected in order of appearance, but must
+ be emitted in opposite order to both have section address regno*8
+ and the same allocation order (within a file) as mmixal. */
+ segT this_segment = now_seg;
+ subsegT this_subsegment = now_subseg;
+ asection *regsec
+ = bfd_make_section_old_way (stdoutput,
+ MMIX_REG_CONTENTS_SECTION_NAME);
+ subseg_set (regsec, 0);
+
+ /* Finally emit the initialization-value. Emit a variable frag, which
+ we'll fix in md_estimate_size_before_relax. We set the initializer
+ for the tc_frag_data field to NULL, so we can use that field for
+ relaxation purposes. */
+ mmix_opcode_frag = NULL;
+
+ frag_grow (0);
+ mmix_reg_contents_frags = frag_now;
+
+ for (i = n_of_raw_gregs - 1; i >= 0; i--)
+ {
+ if (mmix_raw_gregs[i].label != NULL)
+ /* There's a symbol. Let it refer to this location in the
+ register contents section. The symbol must be globalized
+ separately. */
+ colon (mmix_raw_gregs[i].label);
+
+ frag_var (rs_machine_dependent, 8, 0, STATE_GREG_UNDF,
+ make_expr_symbol (&mmix_raw_gregs[i].exp), 0, NULL);
+ }
+
+ subseg_set (this_segment, this_subsegment);
+ }
+
+ /* Iterate over frags resulting from GREGs and move those that evidently
+ have the same value together and point one to another.
+
+ This works in time O(N^2) but since the upper bound for non-error use
+ is 223, it's best to keep this simpler algorithm. */
+ for (fragP = mmix_reg_contents_frags; fragP != NULL; fragP = fragP->fr_next)
+ {
+ fragS **fpp;
+ fragS *fp = NULL;
+ fragS *osymfrag;
+ offsetT osymval;
+ expressionS *oexpP;
+ symbolS *symbolP = fragP->fr_symbol;
+
+ if (fragP->fr_type != rs_machine_dependent
+ || fragP->fr_subtype != STATE_GREG_UNDF)
+ continue;
+
+ /* Whatever the outcome, we will have this GREG judged merged or
+ non-merged. Since the tc_frag_data is NULL at this point, we
+ default to non-merged. */
+ fragP->fr_subtype = STATE_GREG_DEF;
+
+ /* If we're not supposed to merge GREG definitions, then just don't
+ look for equivalents. */
+ if (! merge_gregs)
+ continue;
+
+ osymval = (offsetT) S_GET_VALUE (symbolP);
+ osymfrag = symbol_get_frag (symbolP);
+
+ /* If the symbol isn't defined, we can't say that another symbol
+ equals this frag, then. FIXME: We can look at the "deepest"
+ defined name; if a = c and b = c then obviously a == b. */
+ if (! S_IS_DEFINED (symbolP))
+ continue;
+
+ oexpP = symbol_get_value_expression (fragP->fr_symbol);
+
+ /* If the initialization value is zero, then we must not merge them. */
+ if (oexpP->X_op == O_constant && osymval == 0)
+ continue;
+
+ /* Iterate through the frags downward this one. If we find one that
+ has the same non-zero value, move it to after this one and point
+ to it as the equivalent. */
+ for (fpp = &fragP->fr_next; *fpp != NULL; fpp = &fpp[0]->fr_next)
+ {
+ fp = *fpp;
+
+ if (fp->fr_type != rs_machine_dependent
+ || fp->fr_subtype != STATE_GREG_UNDF)
+ continue;
+
+ /* Calling S_GET_VALUE may simplify the symbol, changing from
+ expr_section etc. so call it first. */
+ if ((offsetT) S_GET_VALUE (fp->fr_symbol) == osymval
+ && symbol_get_frag (fp->fr_symbol) == osymfrag)
+ {
+ /* Move the frag links so the one we found equivalent comes
+ after the current one, carefully considering that
+ sometimes fpp == &fragP->fr_next and the moves must be a
+ NOP then. */
+ *fpp = fp->fr_next;
+ fp->fr_next = fragP->fr_next;
+ fragP->fr_next = fp;
+ break;
+ }
+ }
+
+ if (*fpp != NULL)
+ fragP->tc_frag_data = fp;
+ }
+}
+
+/* qsort function for mmix_symbol_gregs. */
+
+static int
+cmp_greg_symbol_fixes (parg, qarg)
+ const PTR parg;
+ const PTR qarg;
+{
+ const struct mmix_symbol_greg_fixes *p
+ = (const struct mmix_symbol_greg_fixes *) parg;
+ const struct mmix_symbol_greg_fixes *q
+ = (const struct mmix_symbol_greg_fixes *) qarg;
+
+ return p->offs > q->offs ? 1 : p->offs < q->offs ? -1 : 0;
+}
+
+/* Collect GREG definitions from mmix_gregs and hang them as lists sorted
+ on increasing offsets onto each section symbol or undefined symbol.
+
+ Also, remove the register convenience section so it doesn't get output
+ as an ELF section. */
+
+void
+mmix_frob_file ()
+{
+ int i;
+ struct mmix_symbol_gregs *all_greg_symbols[MAX_GREGS];
+ int n_greg_symbols = 0;
+
+ /* Collect all greg fixups and decorate each corresponding symbol with
+ the greg fixups for it. */
+ for (i = 0; i < n_of_cooked_gregs; i++)
+ {
+ offsetT offs;
+ symbolS *sym;
+ struct mmix_symbol_gregs *gregs;
+ fixS *fixP;
+
+ fixP = mmix_gregs[i];
+ know (fixP->fx_r_type == BFD_RELOC_64);
+
+ /* This case isn't doable in general anyway, methinks. */
+ if (fixP->fx_subsy != NULL)
+ {
+ as_bad_where (fixP->fx_file, fixP->fx_line,
+ _("GREG expression too complicated"));
+ continue;
+ }
+
+ sym = fixP->fx_addsy;
+ offs = (offsetT) fixP->fx_offset;
+
+ /* If the symbol is defined, then it must be resolved to a section
+ symbol at this time, or else we don't know how to handle it. */
+ if (S_IS_DEFINED (sym))
+ {
+ if (! symbol_section_p (sym)
+ && ! bfd_is_abs_section (S_GET_SEGMENT (sym)))
+ as_fatal (_("internal: GREG expression not resolved to section"));
+
+ offs += S_GET_VALUE (sym);
+ }
+
+ /* If this is an absolute symbol sufficiently near lowest_data_loc,
+ then we canonicalize on the data section. Note that offs is
+ signed here; we may subtract lowest_data_loc which is unsigned.
+ Careful with those comparisons. */
+ if (lowest_data_loc != (bfd_vma) -1
+ && (bfd_vma) offs + 256 > lowest_data_loc
+ && bfd_is_abs_section (S_GET_SEGMENT (sym)))
+ {
+ offs -= (offsetT) lowest_data_loc;
+ sym = section_symbol (data_section);
+ }
+ /* Likewise text section. */
+ else if (lowest_text_loc != (bfd_vma) -1
+ && (bfd_vma) offs + 256 > lowest_text_loc
+ && bfd_is_abs_section (S_GET_SEGMENT (sym)))
+ {
+ offs -= (offsetT) lowest_text_loc;
+ sym = section_symbol (text_section);
+ }
+
+ gregs = *symbol_get_tc (sym);
+
+ if (gregs == NULL)
+ {
+ gregs = xmalloc (sizeof (*gregs));
+ gregs->n_gregs = 0;
+ symbol_set_tc (sym, &gregs);
+ all_greg_symbols[n_greg_symbols++] = gregs;
+ }
+
+ gregs->greg_fixes[gregs->n_gregs].fix = fixP;
+ gregs->greg_fixes[gregs->n_gregs++].offs = offs;
+ }
+
+ /* For each symbol having a GREG definition, sort those definitions on
+ offset. */
+ for (i = 0; i < n_greg_symbols; i++)
+ qsort (all_greg_symbols[i]->greg_fixes, all_greg_symbols[i]->n_gregs,
+ sizeof (all_greg_symbols[i]->greg_fixes[0]), cmp_greg_symbol_fixes);
+
+ if (real_reg_section != NULL)
+ {
+ asection **secpp;
+
+ /* FIXME: Pass error state gracefully. */
+ if (bfd_get_section_flags (stdoutput, real_reg_section) & SEC_HAS_CONTENTS)
+ as_fatal (_("register section has contents\n"));
+
+ /* FIXME: This does not seem like the proper way to kill a section,
+ but it's the way it's done elsewhere, like elf64-alpha.c. */
+ /* Really remove the section. */
+ for (secpp = &stdoutput->sections;
+ *secpp != real_reg_section;
+ secpp = &(*secpp)->next)
+ ;
+ *secpp = (*secpp)->next;
+ --stdoutput->section_count;
+ }
+
+}
+
+/* Provide an expression for a built-in name provided when-used.
+ Either a symbol that is a handler; living in 0x10*[1..8] and having
+ name [DVWIOUZX]_Handler, or a mmixal built-in symbol.
+
+ If the name isn't a built-in name and parsed into *EXPP, return zero. */
+
+int
+mmix_parse_predefined_name (name, expP)
+ char *name;
+ expressionS *expP;
+{
+ char *canon_name;
+ char *handler_charp;
+ const char handler_chars[] = "DVWIOUZX";
+ symbolS *symp;
+
+ if (! predefined_syms)
+ return 0;
+
+ canon_name = tc_canonicalize_symbol_name (name);
+
+ if (canon_name[1] == '_'
+ && strcmp (canon_name + 2, "Handler") == 0
+ && (handler_charp = strchr (handler_chars, *canon_name)) != NULL)
+ {
+ /* If the symbol doesn't exist, provide one relative to the .text
+ section.
+
+ FIXME: We should provide separate sections, mapped in the linker
+ script. */
+ symp = symbol_find (name);
+ if (symp == NULL)
+ symp = symbol_new (name, text_section,
+ 0x10 * (handler_charp + 1 - handler_chars),
+ &zero_address_frag);
+ }
+ else
+ {
+ /* These symbols appear when referenced; needed for
+ mmixal-compatible programs. */
+ unsigned int i;
+
+ static const struct
+ {
+ const char *name;
+ valueT val;
+ } predefined_abs_syms[] =
+ {
+ {"Data_Segment", (valueT) 0x20 << 56},
+ {"Pool_Segment", (valueT) 0x40 << 56},
+ {"Stack_Segment", (valueT) 0x60 << 56},
+ {"StdIn", 0},
+ {"StdOut", 1},
+ {"StdErr", 2},
+ {"TextRead", 0},
+ {"TextWrite", 1},
+ {"BinaryRead", 2},
+ {"BinaryWrite", 3},
+ {"BinaryReadWrite", 4},
+ {"Halt", 0},
+ {"Fopen", 1},
+ {"Fclose", 2},
+ {"Fread", 3},
+ {"Fgets", 4},
+ {"Fgetws", 5},
+ {"Fwrite", 6},
+ {"Fputs", 7},
+ {"Fputws", 8},
+ {"Fseek", 9},
+ {"Ftell", 10},
+ {"D_BIT", 0x80},
+ {"V_BIT", 0x40},
+ {"W_BIT", 0x20},
+ {"I_BIT", 0x10},
+ {"O_BIT", 0x08},
+ {"U_BIT", 0x04},
+ {"Z_BIT", 0x02},
+ {"X_BIT", 0x01},
+ {"Inf", 0x7ff00000}
+ };
+
+ /* If it's already in the symbol table, we shouldn't do anything. */
+ symp = symbol_find (name);
+ if (symp != NULL)
+ return 0;
+
+ for (i = 0;
+ i < sizeof (predefined_abs_syms)/sizeof (predefined_abs_syms[0]);
+ i++)
+ if (strcmp (canon_name, predefined_abs_syms[i].name) == 0)
+ {
+ symbol_table_insert (symbol_new (predefined_abs_syms[i].name,
+ absolute_section,
+ predefined_abs_syms[i].val,
+ &zero_address_frag));
+
+ /* Let gas find the symbol we just created, through its
+ ordinary lookup. */
+ return 0;
+ }
+
+ /* Not one of those symbols. Let gas handle it. */
+ return 0;
+ }
+
+ expP->X_op = O_symbol;
+ expP->X_add_number = 0;
+ expP->X_add_symbol = symp;
+ expP->X_op_symbol = NULL;
+
+ return 1;
+}
+
+/* Worker for mmix_frob_file_before_adjust. */
+
+static void
+mmix_frob_local_reloc (abfd, sec, xxx)
+ bfd *abfd ATTRIBUTE_UNUSED;
+ asection *sec;
+ PTR xxx ATTRIBUTE_UNUSED;
+{
+ segment_info_type *seginfo = seg_info (sec);
+ fixS *fixp;
+
+ if (seginfo == NULL)
+ return;
+
+ for (fixp = seginfo->fix_root; fixp; fixp = fixp->fx_next)
+ if (! fixp->fx_done && fixp->fx_addsy != NULL)
+ {
+ symbolS *sym = fixp->fx_addsy;
+ asection *section = S_GET_SEGMENT (sym);
+
+ if (section == reg_section
+ && fixp->fx_r_type == BFD_RELOC_MMIX_LOCAL)
+ {
+ /* If the register is marked global, we don't need to replace
+ with the *real* register section since that will be done
+ when the symbol is changed. */
+ if (! S_IS_EXTERNAL (sym))
+ /* If it's a local symbol, we replace it with an anonymous
+ one with the same constant value. */
+ fixp->fx_addsy = expr_build_uconstant (S_GET_VALUE (sym));
+ }
+ }
+}
+
+/* Change fixups for register symbols for BFD_MMIX_LOCAL to be for an
+ absolute symbol. */
+
+void
+mmix_frob_file_before_adjust ()
+{
+ return;
+ bfd_map_over_sections (stdoutput, mmix_frob_local_reloc, (char *) 0);
+}
+
+/* Just check that we don't have a BSPEC/ESPEC pair active when changing
+ sections "normally", and get knowledge about alignment from the new
+ section. */
+
+void
+mmix_md_elf_section_change_hook ()
+{
+ if (doing_bspec)
+ as_bad (_("section change from within a BSPEC/ESPEC pair is not supported"));
+
+ last_alignment = bfd_get_section_alignment (now_seg->owner, now_seg);
+ want_unaligned = 0;
+}
+
+/* The LOC worker. This is like s_org, but we have to support changing
+ section too. */
+
+static void
+s_loc (ignore)
+ int ignore ATTRIBUTE_UNUSED;
+{
+ segT section;
+ expressionS exp;
+ char *p;
+ symbolS *sym;
+ offsetT off;
+
+ /* Must not have a BSPEC in progress. */
+ if (doing_bspec)
+ {
+ as_bad (_("directive LOC from within a BSPEC/ESPEC pair is not supported"));
+ return;
+ }
+
+ section = expression (&exp);
+
+ if (exp.X_op == O_illegal
+ || exp.X_op == O_absent
+ || exp.X_op == O_big
+ || section == undefined_section)
+ {
+ as_bad (_("invalid LOC expression"));
+ return;
+ }
+
+ if (section == absolute_section)
+ {
+ /* Translate a constant into a suitable section. */
+
+ if (exp.X_add_number < ((offsetT) 0x20 << 56))
+ {
+ /* Lower than Data_Segment - assume it's .text. */
+ section = text_section;
+
+ /* Save the lowest seen location, so we can pass on this
+ information to the linker. We don't actually org to this
+ location here, we just pass on information to the linker so
+ it can put the code there for us. */
+
+ /* If there was already a loc (that has to be set lower than
+ this one), we org at (this - lower). There's an implicit
+ "LOC 0" before any entered code. FIXME: handled by spurious
+ settings of text_has_contents. */
+ if (exp.X_add_number < 0
+ || exp.X_add_number < (offsetT) lowest_text_loc)
+ {
+ as_bad (_("LOC expression stepping backwards is not supported"));
+ exp.X_op = O_absent;
+ }
+ else
+ {
+ if (text_has_contents && lowest_text_loc == (bfd_vma) -1)
+ lowest_text_loc = 0;
+
+ if (lowest_text_loc == (bfd_vma) -1)
+ {
+ lowest_text_loc = exp.X_add_number;
+
+ /* We want only to change the section, not set an offset. */
+ exp.X_op = O_absent;
+ }
+ else
+ exp.X_add_number -= lowest_text_loc;
+ }
+ }
+ else
+ {
+ /* Do the same for the .data section. */
+ section = data_section;
+
+ if (exp.X_add_number < (offsetT) lowest_data_loc)
+ {
+ as_bad (_("LOC expression stepping backwards is not supported"));
+ exp.X_op = O_absent;
+ }
+ else
+ {
+ if (data_has_contents && lowest_data_loc == (bfd_vma) -1)
+ lowest_data_loc = (bfd_vma) 0x20 << 56;
+
+ if (lowest_data_loc == (bfd_vma) -1)
+ {
+ lowest_data_loc = exp.X_add_number;
+
+ /* We want only to change the section, not set an offset. */
+ exp.X_op = O_absent;
+ }
+ else
+ exp.X_add_number -= lowest_data_loc;
+ }
+ }
+ }
+
+ if (section != now_seg)
+ {
+ obj_elf_section_change_hook ();
+ subseg_set (section, 0);
+
+ /* Call our section change hooks using the official hook. */
+ md_elf_section_change_hook ();
+ }
+
+ if (exp.X_op != O_absent)
+ {
+ if (exp.X_op != O_constant && exp.X_op != O_symbol)
+ {
+ /* Handle complex expressions. */
+ sym = make_expr_symbol (&exp);
+ off = 0;
+ }
+ else
+ {
+ sym = exp.X_add_symbol;
+ off = exp.X_add_number;
+ }
+
+ p = frag_var (rs_org, 1, 1, (relax_substateT) 0, sym, off, (char *) 0);
+ *p = 0;
+ }
+
+ mmix_handle_rest_of_empty_line ();
+}
+
+/* The BYTE worker. We have to support sequences of mixed "strings",
+ numbers and other constant "first-pass" reducible expressions separated
+ by comma. */
+
+static void
+mmix_byte ()
+{
+ unsigned int c;
+ char *start;
+
+ if (now_seg == text_section)
+ text_has_contents = 1;
+ else if (now_seg == data_section)
+ data_has_contents = 1;
+
+ do
+ {
+ SKIP_WHITESPACE ();
+ switch (*input_line_pointer)
+ {
+ case '\"':
+ ++input_line_pointer;
+ start = input_line_pointer;
+ while (is_a_char (c = next_char_of_string ()))
+ {
+ FRAG_APPEND_1_CHAR (c);
+ }
+
+ if (input_line_pointer[-1] != '\"')
+ {
+ /* We will only get here in rare cases involving #NO_APP,
+ where the unterminated string is not recognized by the
+ preformatting pass. */
+ as_bad (_("unterminated string"));
+ mmix_discard_rest_of_line ();
+ return;
+ }
+ break;
+
+ default:
+ {
+ expressionS exp;
+ segT expseg = expression (&exp);
+
+ /* We have to allow special register names as constant numbers. */
+ if ((expseg != absolute_section && expseg != reg_section)
+ || (exp.X_op != O_constant
+ && (exp.X_op != O_register
+ || exp.X_add_number <= 255)))
+ {
+ as_bad (_("BYTE expression not a pure number"));
+ mmix_discard_rest_of_line ();
+ return;
+ }
+ else if ((exp.X_add_number > 255 && exp.X_op != O_register)
+ || exp.X_add_number < 0)
+ {
+ /* Note that mmixal does not allow negative numbers in
+ BYTE sequences, so neither should we. */
+ as_bad (_("BYTE expression not in the range 0..255"));
+ mmix_discard_rest_of_line ();
+ return;
+ }
+
+ FRAG_APPEND_1_CHAR (exp.X_add_number);
+ }
+ break;
+ }
+
+ SKIP_WHITESPACE ();
+ c = *input_line_pointer++;
+ }
+ while (c == ',');
+
+ input_line_pointer--;
+
+ if (mmix_gnu_syntax)
+ demand_empty_rest_of_line ();
+ else
+ {
+ mmix_discard_rest_of_line ();
+ /* Do like demand_empty_rest_of_line and step over the end-of-line
+ boundary. */
+ input_line_pointer++;
+ }
+
+ /* Make sure we align for the next instruction. */
+ last_alignment = 0;
+}
+
+/* Like cons_worker, but we have to ignore "naked comments", not barf on
+ them. Implements WYDE, TETRA and OCTA. We're a little bit more
+ lenient than mmix_byte but FIXME: they should eventually merge. */
+
+static void
+mmix_cons (nbytes)
+ int nbytes;
+{
+ expressionS exp;
+ char *start;
+
+ /* If we don't have any contents, then it's ok to have a specified start
+ address that is not a multiple of the max data size. We will then
+ align it as necessary when we get here. Otherwise, it's a fatal sin. */
+ if (now_seg == text_section)
+ {
+ if (lowest_text_loc != (bfd_vma) -1
+ && (lowest_text_loc & (nbytes - 1)) != 0)
+ {
+ if (text_has_contents)
+ as_bad (_("data item with alignment larger than location"));
+ else if (want_unaligned)
+ as_bad (_("unaligned data at an absolute location is not supported"));
+
+ lowest_text_loc &= ~((bfd_vma) nbytes - 1);
+ lowest_text_loc += (bfd_vma) nbytes;
+ }
+
+ text_has_contents = 1;
+ }
+ else if (now_seg == data_section)
+ {
+ if (lowest_data_loc != (bfd_vma) -1
+ && (lowest_data_loc & (nbytes - 1)) != 0)
+ {
+ if (data_has_contents)
+ as_bad (_("data item with alignment larger than location"));
+ else if (want_unaligned)
+ as_bad (_("unaligned data at an absolute location is not supported"));
+
+ lowest_data_loc &= ~((bfd_vma) nbytes - 1);
+ lowest_data_loc += (bfd_vma) nbytes;
+ }
+
+ data_has_contents = 1;
+ }
+
+ /* Always align these unless asked not to (valid for the current pseudo). */
+ if (! want_unaligned)
+ {
+ last_alignment = nbytes == 2 ? 1 : (nbytes == 4 ? 2 : 3);
+ frag_align (last_alignment, 0, 0);
+ record_alignment (now_seg, last_alignment);
+ }
+
+ /* For mmixal compatibility, a label for an instruction (and emitting
+ pseudo) refers to the _aligned_ address. So we have to emit the
+ label here. */
+ if (current_fb_label >= 0)
+ colon (fb_label_name (current_fb_label, 1));
+ else if (pending_label != NULL)
+ {
+ colon (pending_label);
+ pending_label = NULL;
+ }
+
+ SKIP_WHITESPACE ();
+
+ if (is_end_of_line [(unsigned int) *input_line_pointer])
+ {
+ /* Default to zero if the expression was absent. */
+
+ exp.X_op = O_constant;
+ exp.X_add_number = 0;
+ exp.X_unsigned = 0;
+ exp.X_add_symbol = NULL;
+ exp.X_op_symbol = NULL;
+ emit_expr (&exp, (unsigned int) nbytes);
+ }
+ else
+ do
+ {
+ unsigned int c;
+
+ switch (*input_line_pointer)
+ {
+ /* We support strings here too; each character takes up nbytes
+ bytes. */
+ case '\"':
+ ++input_line_pointer;
+ start = input_line_pointer;
+ while (is_a_char (c = next_char_of_string ()))
+ {
+ exp.X_op = O_constant;
+ exp.X_add_number = c;
+ exp.X_unsigned = 1;
+ emit_expr (&exp, (unsigned int) nbytes);
+ }
+
+ if (input_line_pointer[-1] != '\"')
+ {
+ /* We will only get here in rare cases involving #NO_APP,
+ where the unterminated string is not recognized by the
+ preformatting pass. */
+ as_bad (_("unterminated string"));
+ mmix_discard_rest_of_line ();
+ return;
+ }
+ break;
+
+ default:
+ {
+ expression (&exp);
+ emit_expr (&exp, (unsigned int) nbytes);
+ SKIP_WHITESPACE ();
+ }
+ break;
+ }
+ }
+ while (*input_line_pointer++ == ',');
+
+ input_line_pointer--; /* Put terminator back into stream. */
+
+ mmix_handle_rest_of_empty_line ();
+
+ /* We don't need to step up the counter for the current_fb_label here;
+ that's handled by the caller. */
+}
+
+/* The md_do_align worker. At present, we just record an alignment to
+ nullify the automatic alignment we do for WYDE, TETRA and OCTA, as gcc
+ does not use the unaligned macros when attribute packed is used.
+ Arguably this is a GCC bug. */
+
+void
+mmix_md_do_align (n, fill, len, max)
+ int n;
+ char *fill ATTRIBUTE_UNUSED;
+ int len ATTRIBUTE_UNUSED;
+ int max ATTRIBUTE_UNUSED;
+{
+ last_alignment = n;
+ want_unaligned = n == 0;
+}
--- /dev/null
+/* tc-mmix.h -- Header file for tc-mmix.c.
+ Copyright (C) 2001 Free Software Foundation, Inc.
+ Written by Hans-Peter Nilsson (hp@bitrange.com).
+
+ This file is part of GAS, the GNU Assembler.
+
+ GAS is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2, or (at your option)
+ any later version.
+
+ GAS is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with GAS; see the file COPYING. If not, write to the Free
+ Software Foundation, 59 Temple Place - Suite 330, Boston, MA
+ 02111-1307, USA. */
+
+#define TC_MMIX
+
+/* See gas/doc/internals.texi for explanation of these macros. */
+#define TARGET_FORMAT "elf64-mmix"
+#define TARGET_ARCH bfd_arch_mmix
+#define TARGET_BYTES_BIG_ENDIAN 1
+
+extern const char mmix_comment_chars[];
+#define tc_comment_chars mmix_comment_chars
+
+extern const char mmix_symbol_chars[];
+#define tc_symbol_chars mmix_symbol_chars
+
+extern const char mmix_exp_chars[];
+#define EXP_CHARS mmix_exp_chars
+
+extern const char mmix_flt_chars[];
+#define FLT_CHARS mmix_flt_chars
+
+/* "@" is a synonym for ".". */
+#define LEX_AT (LEX_BEGIN_NAME)
+
+extern int mmix_label_without_colon_this_line PARAMS ((void));
+#define LABELS_WITHOUT_COLONS mmix_label_without_colon_this_line ()
+
+extern int mmix_next_semicolon_is_eoln;
+#define TC_EOL_IN_INSN(p) (*(p) == ';' && ! mmix_next_semicolon_is_eoln)
+
+/* This is one direction we can get mmixal compatibility. */
+extern void mmix_handle_mmixal PARAMS ((void));
+#define md_start_line_hook mmix_handle_mmixal
+
+extern void mmix_md_begin PARAMS ((void));
+#define md_begin mmix_md_begin
+
+extern void mmix_md_end PARAMS ((void));
+#define md_end mmix_md_end
+
+extern int mmix_current_location \
+ PARAMS ((void (*fn) (expressionS *), expressionS *));
+extern int mmix_parse_predefined_name PARAMS ((char *, expressionS *));
+
+extern char *mmix_current_prefix;
+
+/* A bit ugly, since we "know" that there's a static function
+ current_location that does what we want. We also strip off a leading
+ ':' in another ugly way.
+
+ The [DVWIOUZX]_Handler symbols are provided when-used. */
+
+extern int mmix_gnu_syntax;
+#define md_parse_name(name, exp, cpos) \
+ (! mmix_gnu_syntax \
+ && (name[0] == '@' \
+ ? (! is_part_of_name (name[1]) \
+ && mmix_current_location (current_location, exp)) \
+ : ((name[0] == ':' || isupper (name[0])) \
+ && mmix_parse_predefined_name (name, exp))))
+
+extern char *mmix_prefix_name PARAMS ((char *));
+
+/* We implement when *creating* a symbol, we also need to strip a ':' or
+ prepend a prefix. */
+#define tc_canonicalize_symbol_name(x) \
+ (mmix_current_prefix == NULL && (x)[0] != ':' ? (x) : mmix_prefix_name (x))
+
+#define md_undefined_symbol(x) NULL
+
+extern void mmix_fb_label PARAMS ((expressionS *));
+
+/* Since integer_constant is local to expr.c, we have to make this a
+ macro. FIXME: Do it cleaner. */
+#define md_operand(exp) \
+ do { \
+ if (input_line_pointer[0] == '#') \
+ { \
+ input_line_pointer++; \
+ integer_constant (16, (exp)); \
+ } \
+ else if (input_line_pointer[0] == '&' \
+ && input_line_pointer[1] != '&') \
+ as_bad (_("`&' serial number operator is not supported")); \
+ else \
+ mmix_fb_label (exp); \
+ } while (0)
+
+
+/* Gas dislikes the 2ADD, 8ADD etc. insns, so we have to assemble them in
+ the error-recovery loop. Hopefully there are no significant
+ differences. Also, space on a line isn't gracefully handled. */
+extern int mmix_assemble_return_nonzero PARAMS ((char *));
+#define tc_unrecognized_line(c) \
+ ((c) == ' ' \
+ || (((c) == '1' || (c) == '2' || (c) == '4' || (c) == '8') \
+ && mmix_assemble_return_nonzero (input_line_pointer - 1)))
+
+#define md_number_to_chars number_to_chars_bigendian
+
+#define WORKING_DOT_WORD
+
+extern const struct relax_type mmix_relax_table[];
+#define TC_GENERIC_RELAX_TABLE mmix_relax_table
+
+/* We use the relax table for everything except the GREG frags. */
+extern long mmix_md_relax_frag PARAMS ((segT, fragS *, long));
+#define md_relax_frag mmix_md_relax_frag
+
+#define tc_fix_adjustable(X) \
+ ((! (X)->fx_addsy \
+ || (! S_IS_WEAK ((X)->fx_addsy) \
+ && S_GET_SEGMENT ((X)->fx_addsy) != reg_section)) \
+ && (X)->fx_r_type != BFD_RELOC_VTABLE_INHERIT \
+ && (X)->fx_r_type != BFD_RELOC_VTABLE_ENTRY)
+
+/* Adjust symbols which are registers. */
+#define tc_adjust_symtab() mmix_adjust_symtab ()
+extern void mmix_adjust_symtab PARAMS ((void));
+
+/* Avoid outputting GAS register section symbols. This happens when the
+ assembly had errors, and will propagate to an assert in BFD. FIXME:
+ It seems the symbol output when-errors is a bug in GAS. Fix that
+ some time. See also tc_gen_reloc.
+
+ Here's where we make all symbols global, when so requested.
+ We must avoid doing that for expression symbols or section symbols,
+ though. */
+extern int mmix_globalize_symbols;
+#define tc_frob_symbol(sym, punt) \
+ do { \
+ if (S_GET_SEGMENT (sym) == reg_section \
+ || (symp) == section_symbol (absolute_section)) \
+ (punt) = 1; \
+ \
+ if (mmix_globalize_symbols \
+ && ! symbol_section_p (sym) \
+ && symp != section_symbol (absolute_section) \
+ && (! S_IS_LOCAL (sym) \
+ || S_GET_SEGMENT (sym) == reg_section) \
+ && (S_GET_SEGMENT (sym) != reg_section \
+ || (S_GET_NAME (sym)[0] != '$' \
+ && S_GET_VALUE (sym) < 256))) \
+ S_SET_EXTERNAL (sym); \
+ } while (0)
+
+/* When relaxing, we need to emit various relocs we otherwise wouldn't. */
+#define TC_FORCE_RELOCATION(fix) mmix_force_relocation (fix)
+extern int mmix_force_relocation PARAMS ((struct fix *));
+
+/* Call md_pcrel_from_section(), not md_pcrel_from(). */
+#define MD_PCREL_FROM_SECTION(FIXP, SEC) md_pcrel_from_section (FIXP, SEC)
+extern long md_pcrel_from_section PARAMS ((struct fix *, segT));
+
+#define MD_APPLY_FIX3
+
+#define TC_HANDLES_FX_DONE
+
+#define md_section_align(seg, size) (size)
+
+#define LISTING_HEADER "GAS for MMIX"
+
+/* The default of 4 means Bcc expansion looks like it's missing a line. */
+#define LISTING_LHS_CONT_LINES 5
+
+extern fragS *mmix_opcode_frag;
+#define TC_FRAG_TYPE fragS *
+#define TC_FRAG_INIT(frag) (frag)->tc_frag_data = mmix_opcode_frag
+
+/* We need to associate each section symbol with a list of GREGs defined
+ for that section/segment and sorted on offset, between the point where
+ all symbols have been evaluated and all frags mapped, and when the
+ fixups are done and relocs are output. Similarly for each unknown
+ symbol. */
+extern void mmix_frob_file PARAMS ((void));
+#define tc_frob_file mmix_frob_file
+
+/* Used by mmix_frob_file. Hangs on section symbols and unknown symbols. */
+struct mmix_symbol_gregs;
+#define TC_SYMFIELD_TYPE struct mmix_symbol_gregs *
+
+extern void mmix_frob_file_before_adjust PARAMS ((void));
+#define tc_frob_file_before_adjust mmix_frob_file_before_adjust
+
+extern void mmix_md_elf_section_change_hook PARAMS ((void));
+#define md_elf_section_change_hook mmix_md_elf_section_change_hook
+
+extern void mmix_md_do_align PARAMS ((int, char *, int, int));
+#define md_do_align(n, fill, len, max, label) \
+ mmix_md_do_align (n, fill, len, max)
+
+/* Each insn is a tetrabyte (4 bytes) long, but if there are BYTE
+ sequences sprinkled in, we can get unaligned DWARF2 offsets, so let's
+ explicitly say one byte. */
+#define DWARF2_LINE_MIN_INSN_LENGTH 1
program_transform_name=s,x,x,
silent=
site=
-sitefile=
srcdir=
target=NONE
verbose=
--help print this message
--no-create do not create output files
--quiet, --silent do not print \`checking...' messages
- --site-file=FILE use FILE as the site file
--version print the version of autoconf that created configure
Directory and file names:
--prefix=PREFIX install architecture-independent files in PREFIX
-site=* | --site=* | --sit=*)
site="$ac_optarg" ;;
- -site-file | --site-file | --site-fil | --site-fi | --site-f)
- ac_prev=sitefile ;;
- -site-file=* | --site-file=* | --site-fil=* | --site-fi=* | --site-f=*)
- sitefile="$ac_optarg" ;;
-
-srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
ac_prev=srcdir ;;
-srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
# Prefer explicitly selected file to automatically selected ones.
-if test -z "$sitefile"; then
- if test -z "$CONFIG_SITE"; then
- if test "x$prefix" != xNONE; then
- CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
- else
- CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
- fi
+if test -z "$CONFIG_SITE"; then
+ if test "x$prefix" != xNONE; then
+ CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
+ else
+ CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
fi
-else
- CONFIG_SITE="$sitefile"
fi
for ac_site_file in $CONFIG_SITE; do
if test -r "$ac_site_file"; then
fi
echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6
-echo "configure:563: checking for Cygwin environment" >&5
+echo "configure:552: checking for Cygwin environment" >&5
if eval "test \"`echo '$''{'ac_cv_cygwin'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 568 "configure"
+#line 557 "configure"
#include "confdefs.h"
int main() {
return __CYGWIN__;
; return 0; }
EOF
-if { (eval echo configure:579: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:568: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_cygwin=yes
else
CYGWIN=
test "$ac_cv_cygwin" = yes && CYGWIN=yes
echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6
-echo "configure:596: checking for mingw32 environment" >&5
+echo "configure:585: checking for mingw32 environment" >&5
if eval "test \"`echo '$''{'ac_cv_mingw32'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 601 "configure"
+#line 590 "configure"
#include "confdefs.h"
int main() {
return __MINGW32__;
; return 0; }
EOF
-if { (eval echo configure:608: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:597: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_mingw32=yes
else
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:673: checking host system type" >&5
+echo "configure:662: checking host system type" >&5
host_alias=$host
case "$host_alias" in
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:694: checking target system type" >&5
+echo "configure:683: checking target system type" >&5
target_alias=$target
case "$target_alias" in
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:712: checking build system type" >&5
+echo "configure:701: checking build system type" >&5
build_alias=$build
case "$build_alias" in
# Extract the first word of "gcc", so it can be a program name with args.
set dummy gcc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:737: checking for $ac_word" >&5
+echo "configure:726: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "cc", so it can be a program name with args.
set dummy cc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:767: checking for $ac_word" >&5
+echo "configure:756: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "cl", so it can be a program name with args.
set dummy cl; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:818: checking for $ac_word" >&5
+echo "configure:807: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:850: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:839: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
cat > conftest.$ac_ext << EOF
-#line 861 "configure"
+#line 850 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:866: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:855: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:892: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:881: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:897: checking whether we are using GNU C" >&5
+echo "configure:886: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:906: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:895: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:925: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:914: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
fi
echo $ac_n "checking for POSIXized ISC""... $ac_c" 1>&6
-echo "configure:957: checking for POSIXized ISC" >&5
+echo "configure:946: checking for POSIXized ISC" >&5
if test -d /etc/conf/kconfig.d &&
grep _POSIX_VERSION /usr/include/sys/unistd.h >/dev/null 2>&1
then
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:991: checking for a BSD compatible install" >&5
+echo "configure:980: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
-echo "configure:1044: checking whether build environment is sane" >&5
+echo "configure:1033: checking whether build environment is sane" >&5
# Just in case
sleep 1
echo timestamp > conftestfile
test "$program_transform_name" = "" && program_transform_name="s,x,x,"
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:1101: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:1090: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
missing_dir=`cd $ac_aux_dir && pwd`
echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
-echo "configure:1147: checking for working aclocal" >&5
+echo "configure:1136: checking for working aclocal" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
fi
echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
-echo "configure:1160: checking for working autoconf" >&5
+echo "configure:1149: checking for working autoconf" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
fi
echo $ac_n "checking for working automake""... $ac_c" 1>&6
-echo "configure:1173: checking for working automake" >&5
+echo "configure:1162: checking for working automake" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
fi
echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
-echo "configure:1186: checking for working autoheader" >&5
+echo "configure:1175: checking for working autoheader" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
fi
echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
-echo "configure:1199: checking for working makeinfo" >&5
+echo "configure:1188: checking for working makeinfo" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
if test "$GCC" = yes; then
# Check if gcc -print-prog-name=ld gives a path.
echo $ac_n "checking for ld used by GCC""... $ac_c" 1>&6
-echo "configure:1294: checking for ld used by GCC" >&5
+echo "configure:1283: checking for ld used by GCC" >&5
case $host in
*-*-mingw*)
# gcc leaves a trailing carriage return which upsets mingw
esac
elif test "$with_gnu_ld" = yes; then
echo $ac_n "checking for GNU ld""... $ac_c" 1>&6
-echo "configure:1324: checking for GNU ld" >&5
+echo "configure:1313: checking for GNU ld" >&5
else
echo $ac_n "checking for non-GNU ld""... $ac_c" 1>&6
-echo "configure:1327: checking for non-GNU ld" >&5
+echo "configure:1316: checking for non-GNU ld" >&5
fi
if eval "test \"`echo '$''{'lt_cv_path_LD'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
fi
test -z "$LD" && { echo "configure: error: no acceptable ld found in \$PATH" 1>&2; exit 1; }
echo $ac_n "checking if the linker ($LD) is GNU ld""... $ac_c" 1>&6
-echo "configure:1362: checking if the linker ($LD) is GNU ld" >&5
+echo "configure:1351: checking if the linker ($LD) is GNU ld" >&5
if eval "test \"`echo '$''{'lt_cv_prog_gnu_ld'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
echo $ac_n "checking for $LD option to reload object files""... $ac_c" 1>&6
-echo "configure:1379: checking for $LD option to reload object files" >&5
+echo "configure:1368: checking for $LD option to reload object files" >&5
if eval "test \"`echo '$''{'lt_cv_ld_reload_flag'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
test -n "$reload_flag" && reload_flag=" $reload_flag"
echo $ac_n "checking for BSD-compatible nm""... $ac_c" 1>&6
-echo "configure:1391: checking for BSD-compatible nm" >&5
+echo "configure:1380: checking for BSD-compatible nm" >&5
if eval "test \"`echo '$''{'lt_cv_path_NM'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
echo "$ac_t""$NM" 1>&6
echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6
-echo "configure:1429: checking whether ln -s works" >&5
+echo "configure:1418: checking whether ln -s works" >&5
if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
fi
echo $ac_n "checking how to recognise dependant libraries""... $ac_c" 1>&6
-echo "configure:1450: checking how to recognise dependant libraries" >&5
+echo "configure:1439: checking how to recognise dependant libraries" >&5
if eval "test \"`echo '$''{'lt_cv_deplibs_check_method'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
deplibs_check_method=$lt_cv_deplibs_check_method
echo $ac_n "checking for object suffix""... $ac_c" 1>&6
-echo "configure:1614: checking for object suffix" >&5
+echo "configure:1603: checking for object suffix" >&5
if eval "test \"`echo '$''{'ac_cv_objext'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
rm -f conftest*
echo 'int i = 1;' > conftest.$ac_ext
-if { (eval echo configure:1620: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1609: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
for ac_file in conftest.*; do
case $ac_file in
*.c) ;;
echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
-echo "configure:1640: checking for executable suffix" >&5
+echo "configure:1629: checking for executable suffix" >&5
if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
rm -f conftest*
echo 'int main () { return 0; }' > conftest.$ac_ext
ac_cv_exeext=
- if { (eval echo configure:1650: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
+ if { (eval echo configure:1639: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
for file in conftest.*; do
case $file in
- *.c | *.o | *.obj | *.ilk | *.pdb) ;;
+ *.c | *.o | *.obj) ;;
*) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;;
esac
done
file_magic*)
if test "$file_magic_cmd" = '$MAGIC_CMD'; then
echo $ac_n "checking for ${ac_tool_prefix}file""... $ac_c" 1>&6
-echo "configure:1683: checking for ${ac_tool_prefix}file" >&5
+echo "configure:1672: checking for ${ac_tool_prefix}file" >&5
if eval "test \"`echo '$''{'lt_cv_path_MAGIC_CMD'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
if test -z "$lt_cv_path_MAGIC_CMD"; then
if test -n "$ac_tool_prefix"; then
echo $ac_n "checking for file""... $ac_c" 1>&6
-echo "configure:1745: checking for file" >&5
+echo "configure:1734: checking for file" >&5
if eval "test \"`echo '$''{'lt_cv_path_MAGIC_CMD'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
set dummy ${ac_tool_prefix}ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1816: checking for $ac_word" >&5
+echo "configure:1805: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "ranlib", so it can be a program name with args.
set dummy ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1848: checking for $ac_word" >&5
+echo "configure:1837: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
set dummy ${ac_tool_prefix}strip; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1883: checking for $ac_word" >&5
+echo "configure:1872: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_STRIP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "strip", so it can be a program name with args.
set dummy strip; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1915: checking for $ac_word" >&5
+echo "configure:1904: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_STRIP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
case $host in
*-*-irix6*)
# Find out which ABI we are using.
- echo '#line 1982 "configure"' > conftest.$ac_ext
- if { (eval echo configure:1983: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+ echo '#line 1971 "configure"' > conftest.$ac_ext
+ if { (eval echo configure:1972: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
case `/usr/bin/file conftest.$ac_objext` in
*32-bit*)
LD="${LD-ld} -32"
SAVE_CFLAGS="$CFLAGS"
CFLAGS="$CFLAGS -belf"
echo $ac_n "checking whether the C compiler needs -belf""... $ac_c" 1>&6
-echo "configure:2004: checking whether the C compiler needs -belf" >&5
+echo "configure:1993: checking whether the C compiler needs -belf" >&5
if eval "test \"`echo '$''{'lt_cv_cc_needs_belf'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext <<EOF
-#line 2017 "configure"
+#line 2006 "configure"
#include "confdefs.h"
int main() {
; return 0; }
EOF
-if { (eval echo configure:2024: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2013: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
lt_cv_cc_needs_belf=yes
else
mips-*-elf* | mips-*-rtems* | mips-*-openbsd*)
fmt=elf ;;
mips-*-vxworks*) fmt=elf mips_stabs_elf=y ;;
+ mmix-*-*) fmt=elf bfd_gas=yes ;;
mn10200-*-*) fmt=elf bfd_gas=yes ;;
mn10300-*-*) fmt=elf bfd_gas=yes ;;
openrisc-*-*) fmt=elf bfd_gas=yes ;;
# Extract the first word of "gcc", so it can be a program name with args.
set dummy gcc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3097: checking for $ac_word" >&5
+echo "configure:3087: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "cc", so it can be a program name with args.
set dummy cc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3127: checking for $ac_word" >&5
+echo "configure:3117: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "cl", so it can be a program name with args.
set dummy cl; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3178: checking for $ac_word" >&5
+echo "configure:3168: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:3210: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:3200: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
cat > conftest.$ac_ext << EOF
-#line 3221 "configure"
+#line 3211 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:3226: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3216: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:3252: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:3242: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:3257: checking whether we are using GNU C" >&5
+echo "configure:3247: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:3266: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:3256: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:3285: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:3275: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3322: checking for $ac_word" >&5
+echo "configure:3312: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_YACC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
test -n "$YACC" || YACC="yacc"
echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
-echo "configure:3353: checking how to run the C preprocessor" >&5
+echo "configure:3343: checking how to run the C preprocessor" >&5
# On Suns, sometimes $CPP names a directory.
if test -n "$CPP" && test -d "$CPP"; then
CPP=
# On the NeXT, cc -E runs the code through the compiler's parser,
# not just through cpp.
cat > conftest.$ac_ext <<EOF
-#line 3368 "configure"
+#line 3358 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3374: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3364: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
rm -rf conftest*
CPP="${CC-cc} -E -traditional-cpp"
cat > conftest.$ac_ext <<EOF
-#line 3385 "configure"
+#line 3375 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3391: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3381: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
rm -rf conftest*
CPP="${CC-cc} -nologo -E"
cat > conftest.$ac_ext <<EOF
-#line 3402 "configure"
+#line 3392 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3408: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3398: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3438: checking for $ac_word" >&5
+echo "configure:3428: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_LEX'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "flex", so it can be a program name with args.
set dummy flex; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3471: checking for $ac_word" >&5
+echo "configure:3461: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_LEX'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
*) ac_lib=l ;;
esac
echo $ac_n "checking for yywrap in -l$ac_lib""... $ac_c" 1>&6
-echo "configure:3505: checking for yywrap in -l$ac_lib" >&5
+echo "configure:3495: checking for yywrap in -l$ac_lib" >&5
ac_lib_var=`echo $ac_lib'_'yywrap | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-l$ac_lib $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 3513 "configure"
+#line 3503 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
yywrap()
; return 0; }
EOF
-if { (eval echo configure:3524: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3514: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
fi
echo $ac_n "checking lex output file root""... $ac_c" 1>&6
-echo "configure:3547: checking lex output file root" >&5
+echo "configure:3537: checking lex output file root" >&5
if eval "test \"`echo '$''{'ac_cv_prog_lex_root'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
LEX_OUTPUT_ROOT=$ac_cv_prog_lex_root
echo $ac_n "checking whether yytext is a pointer""... $ac_c" 1>&6
-echo "configure:3568: checking whether yytext is a pointer" >&5
+echo "configure:3558: checking whether yytext is a pointer" >&5
if eval "test \"`echo '$''{'ac_cv_prog_lex_yytext_pointer'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_save_LIBS="$LIBS"
LIBS="$LIBS $LEXLIB"
cat > conftest.$ac_ext <<EOF
-#line 3580 "configure"
+#line 3570 "configure"
#include "confdefs.h"
`cat $LEX_OUTPUT_ROOT.c`
int main() {
; return 0; }
EOF
-if { (eval echo configure:3587: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3577: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
ac_cv_prog_lex_yytext_pointer=yes
else
# Extract the first word of "ranlib", so it can be a program name with args.
set dummy ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3613: checking for $ac_word" >&5
+echo "configure:3603: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
fi
echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
-echo "configure:3641: checking for ANSI C header files" >&5
+echo "configure:3631: checking for ANSI C header files" >&5
if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3646 "configure"
+#line 3636 "configure"
#include "confdefs.h"
#include <stdlib.h>
#include <stdarg.h>
#include <float.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3654: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3644: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
if test $ac_cv_header_stdc = yes; then
# SunOS 4.x string.h does not declare mem*, contrary to ANSI.
cat > conftest.$ac_ext <<EOF
-#line 3671 "configure"
+#line 3661 "configure"
#include "confdefs.h"
#include <string.h>
EOF
if test $ac_cv_header_stdc = yes; then
# ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
cat > conftest.$ac_ext <<EOF
-#line 3689 "configure"
+#line 3679 "configure"
#include "confdefs.h"
#include <stdlib.h>
EOF
:
else
cat > conftest.$ac_ext <<EOF
-#line 3710 "configure"
+#line 3700 "configure"
#include "confdefs.h"
#include <ctype.h>
#define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
exit (0); }
EOF
-if { (eval echo configure:3721: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:3711: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
:
else
fi
echo $ac_n "checking for working const""... $ac_c" 1>&6
-echo "configure:3745: checking for working const" >&5
+echo "configure:3735: checking for working const" >&5
if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3750 "configure"
+#line 3740 "configure"
#include "confdefs.h"
int main() {
; return 0; }
EOF
-if { (eval echo configure:3799: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:3789: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_c_const=yes
else
fi
echo $ac_n "checking for inline""... $ac_c" 1>&6
-echo "configure:3820: checking for inline" >&5
+echo "configure:3810: checking for inline" >&5
if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_cv_c_inline=no
for ac_kw in inline __inline__ __inline; do
cat > conftest.$ac_ext <<EOF
-#line 3827 "configure"
+#line 3817 "configure"
#include "confdefs.h"
int main() {
} $ac_kw foo() {
; return 0; }
EOF
-if { (eval echo configure:3834: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:3824: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_c_inline=$ac_kw; break
else
esac
echo $ac_n "checking for off_t""... $ac_c" 1>&6
-echo "configure:3860: checking for off_t" >&5
+echo "configure:3850: checking for off_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3865 "configure"
+#line 3855 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
fi
echo $ac_n "checking for size_t""... $ac_c" 1>&6
-echo "configure:3893: checking for size_t" >&5
+echo "configure:3883: checking for size_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3898 "configure"
+#line 3888 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
# for constant arguments. Useless!
echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6
-echo "configure:3928: checking for working alloca.h" >&5
+echo "configure:3918: checking for working alloca.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3933 "configure"
+#line 3923 "configure"
#include "confdefs.h"
#include <alloca.h>
int main() {
char *p = alloca(2 * sizeof(int));
; return 0; }
EOF
-if { (eval echo configure:3940: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3930: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
ac_cv_header_alloca_h=yes
else
fi
echo $ac_n "checking for alloca""... $ac_c" 1>&6
-echo "configure:3961: checking for alloca" >&5
+echo "configure:3951: checking for alloca" >&5
if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3966 "configure"
+#line 3956 "configure"
#include "confdefs.h"
#ifdef __GNUC__
char *p = (char *) alloca(1);
; return 0; }
EOF
-if { (eval echo configure:3994: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3984: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
ac_cv_func_alloca_works=yes
else
echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6
-echo "configure:4026: checking whether alloca needs Cray hooks" >&5
+echo "configure:4016: checking whether alloca needs Cray hooks" >&5
if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4031 "configure"
+#line 4021 "configure"
#include "confdefs.h"
#if defined(CRAY) && ! defined(CRAY2)
webecray
if test $ac_cv_os_cray = yes; then
for ac_func in _getb67 GETB67 getb67; do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:4056: checking for $ac_func" >&5
+echo "configure:4046: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4061 "configure"
+#line 4051 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:4084: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4074: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
fi
echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6
-echo "configure:4111: checking stack direction for C alloca" >&5
+echo "configure:4101: checking stack direction for C alloca" >&5
if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_cv_c_stack_direction=0
else
cat > conftest.$ac_ext <<EOF
-#line 4119 "configure"
+#line 4109 "configure"
#include "confdefs.h"
find_stack_direction ()
{
exit (find_stack_direction() < 0);
}
EOF
-if { (eval echo configure:4138: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:4128: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_c_stack_direction=1
else
fi
-for ac_hdr in unistd.h
+for ac_hdr in stdlib.h unistd.h sys/stat.h sys/types.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:4163: checking for $ac_hdr" >&5
+echo "configure:4153: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4168 "configure"
+#line 4158 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:4173: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:4163: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
for ac_func in getpagesize
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:4202: checking for $ac_func" >&5
+echo "configure:4192: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4207 "configure"
+#line 4197 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:4230: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4220: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
done
echo $ac_n "checking for working mmap""... $ac_c" 1>&6
-echo "configure:4255: checking for working mmap" >&5
+echo "configure:4245: checking for working mmap" >&5
if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_cv_func_mmap_fixed_mapped=no
else
cat > conftest.$ac_ext <<EOF
-#line 4263 "configure"
+#line 4253 "configure"
#include "confdefs.h"
/* Thanks to Mike Haertel and Jim Avera for this test.
#include <fcntl.h>
#include <sys/mman.h>
+#if HAVE_SYS_TYPES_H
+# include <sys/types.h>
+#endif
+
+#if HAVE_STDLIB_H
+# include <stdlib.h>
+#endif
+
+#if HAVE_SYS_STAT_H
+# include <sys/stat.h>
+#endif
+
+#if HAVE_UNISTD_H
+# include <unistd.h>
+#endif
+
/* This mess was copied from the GNU getpagesize.h. */
#ifndef HAVE_GETPAGESIZE
-# ifdef HAVE_UNISTD_H
-# include <unistd.h>
-# endif
/* Assume that all systems that can run configure have sys/param.h. */
# ifndef HAVE_SYS_PARAM_H
}
EOF
-if { (eval echo configure:4403: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:4406: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_func_mmap_fixed_mapped=yes
else
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:4431: checking for $ac_hdr" >&5
+echo "configure:4434: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4436 "configure"
+#line 4439 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:4441: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:4444: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
__argz_count __argz_stringify __argz_next
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:4471: checking for $ac_func" >&5
+echo "configure:4474: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4476 "configure"
+#line 4479 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:4499: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4502: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
for ac_func in stpcpy
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:4528: checking for $ac_func" >&5
+echo "configure:4531: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4533 "configure"
+#line 4536 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:4556: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4559: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
if test $ac_cv_header_locale_h = yes; then
echo $ac_n "checking for LC_MESSAGES""... $ac_c" 1>&6
-echo "configure:4590: checking for LC_MESSAGES" >&5
+echo "configure:4593: checking for LC_MESSAGES" >&5
if eval "test \"`echo '$''{'am_cv_val_LC_MESSAGES'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4595 "configure"
+#line 4598 "configure"
#include "confdefs.h"
#include <locale.h>
int main() {
return LC_MESSAGES
; return 0; }
EOF
-if { (eval echo configure:4602: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4605: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
am_cv_val_LC_MESSAGES=yes
else
fi
fi
echo $ac_n "checking whether NLS is requested""... $ac_c" 1>&6
-echo "configure:4623: checking whether NLS is requested" >&5
+echo "configure:4626: checking whether NLS is requested" >&5
# Check whether --enable-nls or --disable-nls was given.
if test "${enable_nls+set}" = set; then
enableval="$enable_nls"
EOF
echo $ac_n "checking whether included gettext is requested""... $ac_c" 1>&6
-echo "configure:4643: checking whether included gettext is requested" >&5
+echo "configure:4646: checking whether included gettext is requested" >&5
# Check whether --with-included-gettext or --without-included-gettext was given.
if test "${with_included_gettext+set}" = set; then
withval="$with_included_gettext"
ac_safe=`echo "libintl.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for libintl.h""... $ac_c" 1>&6
-echo "configure:4662: checking for libintl.h" >&5
+echo "configure:4665: checking for libintl.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4667 "configure"
+#line 4670 "configure"
#include "confdefs.h"
#include <libintl.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:4672: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:4675: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
echo "$ac_t""yes" 1>&6
echo $ac_n "checking for gettext in libc""... $ac_c" 1>&6
-echo "configure:4689: checking for gettext in libc" >&5
+echo "configure:4692: checking for gettext in libc" >&5
if eval "test \"`echo '$''{'gt_cv_func_gettext_libc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4694 "configure"
+#line 4697 "configure"
#include "confdefs.h"
#include <libintl.h>
int main() {
return (int) gettext ("")
; return 0; }
EOF
-if { (eval echo configure:4701: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4704: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
gt_cv_func_gettext_libc=yes
else
if test "$gt_cv_func_gettext_libc" != "yes"; then
echo $ac_n "checking for bindtextdomain in -lintl""... $ac_c" 1>&6
-echo "configure:4717: checking for bindtextdomain in -lintl" >&5
+echo "configure:4720: checking for bindtextdomain in -lintl" >&5
ac_lib_var=`echo intl'_'bindtextdomain | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lintl $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 4725 "configure"
+#line 4728 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
bindtextdomain()
; return 0; }
EOF
-if { (eval echo configure:4736: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4739: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
echo "$ac_t""yes" 1>&6
echo $ac_n "checking for gettext in libintl""... $ac_c" 1>&6
-echo "configure:4752: checking for gettext in libintl" >&5
+echo "configure:4755: checking for gettext in libintl" >&5
if eval "test \"`echo '$''{'gt_cv_func_gettext_libintl'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4757 "configure"
+#line 4760 "configure"
#include "confdefs.h"
int main() {
return (int) gettext ("")
; return 0; }
EOF
-if { (eval echo configure:4764: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4767: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
gt_cv_func_gettext_libintl=yes
else
# Extract the first word of "msgfmt", so it can be a program name with args.
set dummy msgfmt; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4792: checking for $ac_word" >&5
+echo "configure:4795: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
for ac_func in dcgettext
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:4826: checking for $ac_func" >&5
+echo "configure:4829: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4831 "configure"
+#line 4834 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:4854: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4857: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
# Extract the first word of "gmsgfmt", so it can be a program name with args.
set dummy gmsgfmt; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4881: checking for $ac_word" >&5
+echo "configure:4884: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "xgettext", so it can be a program name with args.
set dummy xgettext; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4917: checking for $ac_word" >&5
+echo "configure:4920: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
fi
cat > conftest.$ac_ext <<EOF
-#line 4949 "configure"
+#line 4952 "configure"
#include "confdefs.h"
int main() {
return _nl_msg_cat_cntr
; return 0; }
EOF
-if { (eval echo configure:4957: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4960: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
CATOBJEXT=.gmo
DATADIRNAME=share
# Extract the first word of "msgfmt", so it can be a program name with args.
set dummy msgfmt; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4989: checking for $ac_word" >&5
+echo "configure:4992: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "gmsgfmt", so it can be a program name with args.
set dummy gmsgfmt; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:5023: checking for $ac_word" >&5
+echo "configure:5026: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "xgettext", so it can be a program name with args.
set dummy xgettext; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:5059: checking for $ac_word" >&5
+echo "configure:5062: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
LINGUAS=
else
echo $ac_n "checking for catalogs to be installed""... $ac_c" 1>&6
-echo "configure:5149: checking for catalogs to be installed" >&5
+echo "configure:5152: checking for catalogs to be installed" >&5
NEW_LINGUAS=
for lang in ${LINGUAS=$ALL_LINGUAS}; do
case "$ALL_LINGUAS" in
if test "$CATOBJEXT" = ".cat"; then
ac_safe=`echo "linux/version.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for linux/version.h""... $ac_c" 1>&6
-echo "configure:5177: checking for linux/version.h" >&5
+echo "configure:5180: checking for linux/version.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5182 "configure"
+#line 5185 "configure"
#include "confdefs.h"
#include <linux/version.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:5187: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:5190: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:5250: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:5253: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
-echo "configure:5275: checking for executable suffix" >&5
+echo "configure:5278: checking for executable suffix" >&5
if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
rm -f conftest*
echo 'int main () { return 0; }' > conftest.$ac_ext
ac_cv_exeext=
- if { (eval echo configure:5285: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
+ if { (eval echo configure:5288: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
for file in conftest.*; do
case $file in
- *.c | *.o | *.obj | *.ilk | *.pdb) ;;
+ *.c | *.o | *.obj) ;;
*) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;;
esac
done
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:5310: checking for $ac_hdr" >&5
+echo "configure:5313: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5315 "configure"
+#line 5318 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:5320: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:5323: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
# Put this here so that autoconf's "cross-compiling" message doesn't confuse
# people who are not cross-compiling but are compiling cross-assemblers.
echo $ac_n "checking whether compiling a cross-assembler""... $ac_c" 1>&6
-echo "configure:5350: checking whether compiling a cross-assembler" >&5
+echo "configure:5353: checking whether compiling a cross-assembler" >&5
if test "${host}" = "${target}"; then
cross_gas=no
else
# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
# for constant arguments. Useless!
echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6
-echo "configure:5365: checking for working alloca.h" >&5
+echo "configure:5368: checking for working alloca.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5370 "configure"
+#line 5373 "configure"
#include "confdefs.h"
#include <alloca.h>
int main() {
char *p = alloca(2 * sizeof(int));
; return 0; }
EOF
-if { (eval echo configure:5377: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:5380: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
ac_cv_header_alloca_h=yes
else
fi
echo $ac_n "checking for alloca""... $ac_c" 1>&6
-echo "configure:5398: checking for alloca" >&5
+echo "configure:5401: checking for alloca" >&5
if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5403 "configure"
+#line 5406 "configure"
#include "confdefs.h"
#ifdef __GNUC__
char *p = (char *) alloca(1);
; return 0; }
EOF
-if { (eval echo configure:5431: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:5434: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
ac_cv_func_alloca_works=yes
else
echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6
-echo "configure:5463: checking whether alloca needs Cray hooks" >&5
+echo "configure:5466: checking whether alloca needs Cray hooks" >&5
if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5468 "configure"
+#line 5471 "configure"
#include "confdefs.h"
#if defined(CRAY) && ! defined(CRAY2)
webecray
if test $ac_cv_os_cray = yes; then
for ac_func in _getb67 GETB67 getb67; do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:5493: checking for $ac_func" >&5
+echo "configure:5496: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5498 "configure"
+#line 5501 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:5521: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:5524: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
fi
echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6
-echo "configure:5548: checking stack direction for C alloca" >&5
+echo "configure:5551: checking stack direction for C alloca" >&5
if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_cv_c_stack_direction=0
else
cat > conftest.$ac_ext <<EOF
-#line 5556 "configure"
+#line 5559 "configure"
#include "confdefs.h"
find_stack_direction ()
{
exit (find_stack_direction() < 0);
}
EOF
-if { (eval echo configure:5575: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:5578: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_c_stack_direction=1
else
fi
echo $ac_n "checking for inline""... $ac_c" 1>&6
-echo "configure:5597: checking for inline" >&5
+echo "configure:5600: checking for inline" >&5
if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_cv_c_inline=no
for ac_kw in inline __inline__ __inline; do
cat > conftest.$ac_ext <<EOF
-#line 5604 "configure"
+#line 5607 "configure"
#include "confdefs.h"
int main() {
} $ac_kw foo() {
; return 0; }
EOF
-if { (eval echo configure:5611: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5614: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_c_inline=$ac_kw; break
else
for ac_func in unlink remove
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:5641: checking for $ac_func" >&5
+echo "configure:5644: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5646 "configure"
+#line 5649 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:5669: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:5672: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
for ac_func in sbrk
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:5698: checking for $ac_func" >&5
+echo "configure:5701: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5703 "configure"
+#line 5706 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:5726: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:5729: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
;;
*-ncr-sysv4.3*)
echo $ac_n "checking for _mwvalidcheckl in -lmw""... $ac_c" 1>&6
-echo "configure:5761: checking for _mwvalidcheckl in -lmw" >&5
+echo "configure:5764: checking for _mwvalidcheckl in -lmw" >&5
ac_lib_var=`echo mw'_'_mwvalidcheckl | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lmw $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 5769 "configure"
+#line 5772 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
_mwvalidcheckl()
; return 0; }
EOF
-if { (eval echo configure:5780: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:5783: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
fi
echo $ac_n "checking for main in -lm""... $ac_c" 1>&6
-echo "configure:5801: checking for main in -lm" >&5
+echo "configure:5804: checking for main in -lm" >&5
ac_lib_var=`echo m'_'main | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lm $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 5809 "configure"
+#line 5812 "configure"
#include "confdefs.h"
int main() {
main()
; return 0; }
EOF
-if { (eval echo configure:5816: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:5819: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
;;
*)
echo $ac_n "checking for main in -lm""... $ac_c" 1>&6
-echo "configure:5839: checking for main in -lm" >&5
+echo "configure:5842: checking for main in -lm" >&5
ac_lib_var=`echo m'_'main | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lm $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 5847 "configure"
+#line 5850 "configure"
#include "confdefs.h"
int main() {
main()
; return 0; }
EOF
-if { (eval echo configure:5854: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:5857: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
# enough, but on some of those systems, the assert macro relies on requoting
# working properly!
echo $ac_n "checking for working assert macro""... $ac_c" 1>&6
-echo "configure:5885: checking for working assert macro" >&5
+echo "configure:5888: checking for working assert macro" >&5
if eval "test \"`echo '$''{'gas_cv_assert_ok'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5890 "configure"
+#line 5893 "configure"
#include "confdefs.h"
#include <assert.h>
#include <stdio.h>
; return 0; }
EOF
-if { (eval echo configure:5906: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:5909: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
gas_cv_assert_ok=yes
else
"
echo $ac_n "checking whether declaration is required for strstr""... $ac_c" 1>&6
-echo "configure:5947: checking whether declaration is required for strstr" >&5
+echo "configure:5950: checking whether declaration is required for strstr" >&5
if eval "test \"`echo '$''{'gas_cv_decl_needed_strstr'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5952 "configure"
+#line 5955 "configure"
#include "confdefs.h"
$gas_test_headers
int main() {
; return 0; }
EOF
-if { (eval echo configure:5963: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:5966: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
gas_cv_decl_needed_strstr=no
else
echo $ac_n "checking whether declaration is required for malloc""... $ac_c" 1>&6
-echo "configure:5984: checking whether declaration is required for malloc" >&5
+echo "configure:5987: checking whether declaration is required for malloc" >&5
if eval "test \"`echo '$''{'gas_cv_decl_needed_malloc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5989 "configure"
+#line 5992 "configure"
#include "confdefs.h"
$gas_test_headers
int main() {
; return 0; }
EOF
-if { (eval echo configure:6000: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6003: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
gas_cv_decl_needed_malloc=no
else
echo $ac_n "checking whether declaration is required for free""... $ac_c" 1>&6
-echo "configure:6021: checking whether declaration is required for free" >&5
+echo "configure:6024: checking whether declaration is required for free" >&5
if eval "test \"`echo '$''{'gas_cv_decl_needed_free'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 6026 "configure"
+#line 6029 "configure"
#include "confdefs.h"
$gas_test_headers
int main() {
; return 0; }
EOF
-if { (eval echo configure:6037: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6040: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
gas_cv_decl_needed_free=no
else
echo $ac_n "checking whether declaration is required for sbrk""... $ac_c" 1>&6
-echo "configure:6058: checking whether declaration is required for sbrk" >&5
+echo "configure:6061: checking whether declaration is required for sbrk" >&5
if eval "test \"`echo '$''{'gas_cv_decl_needed_sbrk'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 6063 "configure"
+#line 6066 "configure"
#include "confdefs.h"
$gas_test_headers
int main() {
; return 0; }
EOF
-if { (eval echo configure:6074: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6077: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
gas_cv_decl_needed_sbrk=no
else
echo $ac_n "checking whether declaration is required for environ""... $ac_c" 1>&6
-echo "configure:6095: checking whether declaration is required for environ" >&5
+echo "configure:6098: checking whether declaration is required for environ" >&5
if eval "test \"`echo '$''{'gas_cv_decl_needed_environ'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 6100 "configure"
+#line 6103 "configure"
#include "confdefs.h"
$gas_test_headers
int main() {
; return 0; }
EOF
-if { (eval echo configure:6111: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6114: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
gas_cv_decl_needed_environ=no
else
# for it?
echo $ac_n "checking whether declaration is required for errno""... $ac_c" 1>&6
-echo "configure:6135: checking whether declaration is required for errno" >&5
+echo "configure:6138: checking whether declaration is required for errno" >&5
if eval "test \"`echo '$''{'gas_cv_decl_needed_errno'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 6140 "configure"
+#line 6143 "configure"
#include "confdefs.h"
#ifdef HAVE_ERRNO_H
; return 0; }
EOF
-if { (eval echo configure:6155: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6158: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
gas_cv_decl_needed_errno=no
else
mips-*-elf* | mips-*-rtems* | mips-*-openbsd*)
fmt=elf ;;
mips-*-vxworks*) fmt=elf mips_stabs_elf=y ;;
+ mmix-*-*) fmt=elf bfd_gas=yes ;;
mn10200-*-*) fmt=elf bfd_gas=yes ;;
mn10300-*-*) fmt=elf bfd_gas=yes ;;
openrisc-*-*) fmt=elf bfd_gas=yes ;;
c-m68k.texi \
c-m88k.texi \
c-mips.texi \
+ c-mmix.texi \
c-ns32k.texi \
c-pdp11.texi \
c-pj.texi \
-# Makefile.in generated automatically by automake 1.4 from Makefile.am
+# Makefile.in generated automatically by automake 1.4-p5 from Makefile.am
-# Copyright (C) 1994, 1995-8, 1999 Free Software Foundation, Inc.
+# Copyright (C) 1994, 1995-8, 1999, 2001 Free Software Foundation, Inc.
# This Makefile.in is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
# with or without modifications, as long as this notice is preserved.
c-m68k.texi \
c-m88k.texi \
c-mips.texi \
+ c-mmix.texi \
c-ns32k.texi \
c-pdp11.texi \
c-pj.texi \
DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) $(TEXINFOS) $(EXTRA_DIST)
-TAR = tar
+TAR = gtar
GZIP_ENV = --best
all: all-redirect
.SUFFIXES:
else ii=; fi; \
list='$(INFO_DEPS)'; \
for file in $$list; do \
- test -z "$ii" \
+ test -z "$$ii" \
|| install-info --info-dir=$(DESTDIR)$(infodir) --remove $$file; \
done
@$(NORMAL_UNINSTALL)
@set M880X0
@set MCORE
@set MIPS
+@set MMIX
@set PDP11
@set PJ
@set PPC
@set M880X0
@set MCORE
@set MIPS
+@set MMIX
@set PDP11
@set PJ
@set PPC
[ -m4650 ] [ -no-m4650 ]
[ --trap ] [ --break ] [ -n ]
[ --emulation=@var{name} ]
+@end ifset
+@ifset MMIX
+ [ --fixed-special-register-names ] [ --globalize-symbols ]
+ [ --gnu-syntax ] [ --relax ] [ --no-predefined-symbols ]
+ [ --no-expand ] [ --no-merge-gregs ] [ -x ]
@end ifset
[ -- | @var{files} @dots{} ]
@c man end
@end table
@end ifset
+@ifset MMIX
+See the info pages for documentation of the MMIX-specific options.
+@end ifset
+
@c man end
@menu
@ifset MIPS
* MIPS-Dependent:: MIPS Dependent Features
@end ifset
+@ifset MMIX
+* MMIX-Dependent:: MMIX Dependent Features
+@end ifset
@ifset SH
* SH-Dependent:: Hitachi SH Dependent Features
@end ifset
@include c-mips.texi
@end ifset
+@ifset MMIX
+@include c-mmix.texi
+@end ifset
+
@ifset NS32K
@include c-ns32k.texi
@end ifset
--- /dev/null
+@c Copyright 2001 Free Software Foundation, Inc.
+@c This is part of the GAS manual.
+@c For copying conditions, see the file as.texinfo.
+@c MMIX description by Hans-Peter Nilsson, hp@bitrange.com
+@ifset GENERIC
+@page
+@node MMIX-Dependent
+@chapter MMIX Dependent Features
+@end ifset
+@ifclear GENERIC
+@node Machine Dependencies
+@chapter MMIX Dependent Features
+@end ifclear
+
+@cindex MMIX support
+@menu
+* MMIX-Opts:: Command-line Options
+* MMIX-Expand:: Instruction expansion
+* MMIX-Syntax:: Syntax
+* MMIX-mmixal:: Differences to @code{mmixal} syntax and semantics
+@end menu
+
+@node MMIX-Opts
+@section Command-line Options
+
+@cindex options, MMIX
+@cindex MMIX options
+The MMIX version of @code{@value{AS}} has some machine-dependent options.
+
+@cindex @samp{--fixed-special-register-names} command line option, MMIX
+When @samp{--fixed-special-register-names} is specified, only the register
+names specified in @ref{MMIX-Regs} are recognized in the instructions
+@code{PUT} and @code{GET}.
+
+@cindex @samp{--globalize-symbols} command line option, MMIX
+You can use the @samp{--globalize-symbols} to make all symbols global.
+This option is useful when splitting up a @code{mmixal} program into
+several files.
+
+@cindex @samp{--gnu-syntax} command line option, MMIX
+The @samp{--gnu-syntax} turns off most syntax compatibility with
+@code{mmixal}. Its usability is currently doubtful.
+
+@cindex @samp{--relax} command line option, MMIX
+The @samp{--relax} option is not fully supported, but will eventually make
+the object file prepared for linker relaxation.
+
+@cindex @samp{--no-predefined-syms} command line option, MMIX
+If you want to avoid inadvertently calling a predefined symbol and would
+rather get an error, for example when using @code{@value{AS}} with a
+compiler or other machine-generated code, specify
+@samp{--no-predefined-syms}. This turns off built-in predefined
+definitions of all such symbols, including rounding-mode symbols, segment
+symbols, @samp{BIT} symbols, and @code{TRAP} symbols used in @code{mmix}
+``system calls''. It also turns off predefined special-register names,
+except when used in @code{PUT} and @code{GET} instructions.
+
+@cindex @samp{--no-expand} command line option, MMIX
+By default, some instructions are expanded to fit the size of the operand
+or an external symbol (@pxref{MMIX-Expand}). By passing
+@samp{--no-expand}, no such expansion will be done, instead causing errors
+at link time if the operand does not fit.
+
+@cindex @samp{--no-merge-gregs} command line option, MMIX
+The @code{mmixal} documentation (@pxref{MMIX-Syntax}) specifies that global
+registers allocated with the @samp{GREG} directive (@pxref{MMIX-Pseudos}) and
+initialized to the same non-zero value, will refer to the same global
+register. This isn't strictly enforcable in @code{@value{AS}} since the
+final addresses aren't known until link-time, but it will do an effort
+unless the @samp{--no-merge-gregs} option is specified. (Register merging
+isn't yet implemented in @code{@value{LD}}.)
+
+@cindex @samp{-x} command line option, MMIX
+@code{@value{AS}} will warn every time it expands an instruction to fit an
+operand unless the option @samp{-x} is specified. It is believed that
+this behaviour is more useful than just mimicking @code{mmixal}'s
+behaviour, in which instructions are only expanded if the @samp{-x} option
+is specified, and assembly fails otherwise, when an instruction needs to
+be expanded. It needs to be kept in mind that @code{mmixal} is both an
+assembler and linker, while @code{@value{AS}} will expand instructions
+that at link stage can be contracted. (Though linker relaxation isn't yet
+implemented in @code{@value{LD}}.)
+
+@node MMIX-Expand
+@section Instruction expansion
+
+@cindex instruction expansion, MMIX
+When @code{@value{AS}} encounters an instruction with an operand that is
+either not known or does not fit the operand size of the instruction,
+@code{@value{AS}} (and @code{@value{LD}}) will expand the instruction into
+a sequence of instructions semantically equivalent to the operand fitting
+the instruction. Expansion will take place for the following
+instructions:
+
+@table @asis
+@item @samp{GETA}
+Expands to a sequence of four instructions: @code{SETL}, @code{INCML},
+@code{INCMH} and @code{INCH}. The operand must be a multiple of four.
+@item Conditional branches
+A branch instruction is turned into a branch with the complemented
+condition and prediction bit over five instructions; four instructions
+setting @code{$255} to the operand value, which like with @code{GETA} must
+be a multiple of four, and a final @code{GO $255,$255,0}.
+@item @samp{PUSHJ}
+Similar to expansion for conditional branches; four instructions set
+@code{$255} to the operand value, followed by a @code{PUSHGO $255,$255,0}.
+@item @samp{JMP}
+Similar to conditional branches and @code{PUSHJ}. The final instruction
+is @code{GO $255,$255,0}.
+@end table
+
+The linker @code{@value{LD}} is expected to shrink these expansions for
+code assembled with @samp{--relax} (though not currently implemented).
+
+@node MMIX-Syntax
+@section Syntax
+
+The assembly syntax is supposed to be upward compatible with that
+described in Sections 1.3 and 1.4 of @samp{The Art of Computer
+Programming, Volume 1}. Draft versions of those chapters as well as other
+MMIX information is located at
+@emph{mmixsite} @emph{http://www-cs-faculty.stanford.edu/~knuth/mmix-news.html}.
+Most code examples from the mmixal package located there should work
+unmodified when assembled and linked as single files, with a few
+noteworthy exceptions (@pxref{MMIX-mmixal}).
+
+Before an instruction is emitted, the current location is aligned to the
+next four-byte boundary. If a label is defined at the beginning of the
+line, its value will be the aligned value.
+
+In addition to the traditional hex-prefix @samp{0x}, a hexadecimal number
+can also be specified by the prefix character @samp{#}.
+
+After all operands to an MMIX instruction or directive have been
+specified, the rest of the line is ignored, treated as a comment.
+
+@menu
+* MMIX-Chars:: Special Characters
+* MMIX-Symbols:: Symbols
+* MMIX-Regs:: Register Names
+* MMIX-Pseudos:: Assembler Directives
+@end menu
+
+@node MMIX-Chars
+@subsection Special Characters
+@cindex line comment characters, MMIX
+@cindex MMIX line comment characters
+
+The characters @samp{*} and @samp{#} are line comment characters; each
+start a comment at the beginning of a line, but only at the beginning of a
+line. A @samp{#} prefixes a hexadecimal number if found elsewhere on a
+line.
+
+Two other characters, @samp{%} and @samp{!}, each start a comment anywhere
+on the line. Thus you can't use the @samp{modulus} and @samp{not}
+operators in expressions normally associated with these two characters.
+
+A @samp{;} is a line separator, treated as a new-line, so separate
+instructions can be specified on a single line.
+
+@node MMIX-Symbols
+@subsection Symbols
+The character @samp{:} is permitted in identifiers. There are two
+exceptions to it being treated as any other symbol character: if a symbol
+begins with @samp{:}, it means that the symbol is in the global namespace
+and that the current prefix should not be prepended to that symbol
+(@pxref{MMIX-Pseudos}). The @samp{:} is then not considered part of the
+symbol. For a symbol in the label position (first on a line), a @samp{:}
+at the end of a symbol is silently stripped off. A label is permitted,
+but not required, to be followed by a @samp{:}, as with many other
+assembly formats.
+
+The character @samp{@@} in an expression, is a synonym for @samp{.}, the
+current location.
+
+In addition to the common forward and backward local symbol formats
+(@pxref{Symbol Names}), they can be specified with upper-case @samp{B} and
+@samp{F}, as in @samp{8B} and @samp{9F}. A local label defined for the
+current position is written with a @samp{H} appended to the number:
+@smallexample
+3H LDB $0,$1,2
+@end smallexample
+This and traditional local-label formats cannot be mixed: a label must be
+defined and referred to using the same format.
+
+There's a minor caveat: just as for the ordinary local symbols, the local
+symbols are translated into ordinary symbols using control characters are
+to hide the ordinal number of the symbol. Unfortunately, these symbols
+are not translated back in error messages. Thus you may see confusing
+error messages when local symbols are used. Control characters
+@samp{\003} (control-C) and @samp{\004} (control-D) are used for the
+MMIX-specific local-symbol syntax.
+
+The symbol @samp{Main} is handled specially; it is always global.
+
+By defining the symbols @samp{__.MMIX.start..text} and
+@samp{__.MMIX.start..data}, the address of respectively the @samp{.text}
+and @samp{.data} segments of the final program can be defined, though when
+linking more than one object file, the code or data in the object file
+containing the symbol is not guaranteed to be start at that position; just
+the final executable. @xref{MMIX-Pseudos}.
+
+@node MMIX-Regs
+@subsection Register names
+@cindex register names, MMIX
+@cindex MMIX register names
+
+Local and global registers are specified as @samp{$0} to @samp{$255}.
+The recognized special register names are @samp{rJ}, @samp{rA}, @samp{rB},
+@samp{rC}, @samp{rD}, @samp{rE}, @samp{rF}, @samp{rG}, @samp{rH},
+@samp{rI}, @samp{rK}, @samp{rL}, @samp{rM}, @samp{rN}, @samp{rO},
+@samp{rP}, @samp{rQ}, @samp{rR}, @samp{rS}, @samp{rT}, @samp{rU},
+@samp{rV}, @samp{rW}, @samp{rX}, @samp{rY}, @samp{rZ}, @samp{rBB},
+@samp{rTT}, @samp{rWW}, @samp{rXX}, @samp{rYY} and @samp{rZZ}. A leading
+@samp{:} is optional for special register names.
+
+Local and global symbols can be equated to register names and used in
+place of ordinary registers.
+
+Similarly for special registers, local and global symbols can be used.
+Also, symbols equated from numbers and constant expressions are allowed in
+place of a special register, except when either of the options
+@code{--no-predefined-syms} and @code{--fixed-special-register-names} are
+specified. Then only the special register names above are allowed for the
+instructions having a special register operand; @code{GET} and @code{PUT}.
+
+@node MMIX-Pseudos
+@subsection Assembler Directives
+@cindex assembler directives, MMIX
+@cindex pseudo-ops, MMIX
+@cindex MMIX assembler directives
+@cindex MMIX pseudo-ops
+
+@table @code
+@item LOC
+@cindex assembler directive LOC, MMIX
+@cindex pseudo-op LOC, MMIX
+@cindex MMIX assembler directive LOC
+@cindex MMIX pseudo-op LOC
+
+@emph{MMIX-loc}
+The @code{LOC} directive sets the current location to the value of the
+operand field, which may include changing sections. If the operand is a
+constant, the section is set to either @code{.data} if the value is
+@code{0x2000000000000000} or larger, else it is set to @code{.text}.
+Within a section, the current location may only be changed to
+monotonically higher addresses. A LOC expression must be a previously
+defined symbol or a ``pure'' constant.
+
+An example, which sets the label @var{prev} to the current location, and
+updates the current location to eight bytes forward:
+@smallexample
+prev LOC @@+8
+@end smallexample
+
+When a LOC has a constant as its operand, a symbol
+@code{__.MMIX.start..text} or @code{__.MMIX.start..data} is defined
+depending on the address as mentioned above. Each such symbol is
+interpreted as special by the linker, locating the section at that
+address. Note that if multiple files are linked, the first object file
+with that section will be mapped to that address (not necessarily the file
+with the LOC definition).
+
+@item LOCAL
+@cindex assembler directive LOCAL, MMIX
+@cindex pseudo-op LOCAL, MMIX
+@cindex MMIX assembler directive LOCAL
+@cindex MMIX pseudo-op LOCAL
+
+@emph{MMIX-local}
+Example:
+@smallexample
+ LOCAL external_symbol
+ LOCAL 42
+ .local asymbol
+@end smallexample
+
+This directive-operation generates a link-time assertion that the operand
+does not correspond to a global register. The operand is an expression
+that at link-time resolves to a register symbol or a number. A number is
+treated as the register having that number. There is one restriction on
+the use of this directive: the pseudo-directive must be placed in a
+section with contents, code or data.
+
+@item IS
+@cindex assembler directive IS, MMIX
+@cindex pseudo-op IS, MMIX
+@cindex MMIX assembler directive IS
+@cindex MMIX pseudo-op IS
+
+@emph{MMIX-is}
+The @code{IS} directive:
+@smallexample
+asymbol IS an_expression
+@end smallexample
+sets the symbol @samp{asymbol} to @samp{an_expression}. A symbol may not
+be set more than once using this directive. Local labels may be set using
+this directive, for example:
+@smallexample
+5H IS @@+4
+@end smallexample
+
+@item GREG
+@cindex assembler directive GREG, MMIX
+@cindex pseudo-op GREG, MMIX
+@cindex MMIX assembler directive GREG
+@cindex MMIX pseudo-op GREG
+
+@emph{MMIX-greg}
+This directive reserves a global register, gives it an initial value and
+optionally gives it a symbolic name. Some examples:
+
+@smallexample
+areg GREG
+breg GREG data_value
+ GREG data_buffer
+ .greg creg, another_data_value
+@end smallexample
+
+The symbolic register name can be used in place of a (non-special)
+register. If a value isn't provided, it defaults to zero. Unless the
+option @samp{--no-merge-gregs} is specified, non-zero registers allocated
+with this directive may be eliminated by @code{@value{AS}}; another
+register with the same value used in its place.
+Any of the instructions
+@samp{CSWAP},
+@samp{GO},
+@samp{LDA},
+@samp{LDBU},
+@samp{LDB},
+@samp{LDHT},
+@samp{LDOU},
+@samp{LDO},
+@samp{LDSF},
+@samp{LDTU},
+@samp{LDT},
+@samp{LDUNC},
+@samp{LDVTS},
+@samp{LDWU},
+@samp{LDW},
+@samp{PREGO},
+@samp{PRELD},
+@samp{PREST},
+@samp{PUSHGO},
+@samp{STBU},
+@samp{STB},
+@samp{STCO},
+@samp{STHT},
+@samp{STOU},
+@samp{STSF},
+@samp{STTU},
+@samp{STT},
+@samp{STUNC},
+@samp{SYNCD},
+@samp{SYNCID},
+can have a value nearby @emph{GREG-base}an initial value in place of its
+second and third operands. Here, ``nearby'' is defined as within the
+range 0@dots{}255 from the initial value of such an allocated register.
+
+@smallexample
+buffer1 BYTE 0,0,0,0,0
+buffer2 BYTE 0,0,0,0,0
+ @dots{}
+ GREG buffer1
+ LDOU $42,buffer2
+@end smallexample
+In the example above, the @samp{Y} field of the @code{LDOUI} instruction
+(LDOU with a constant Z) will be replaced with the global register
+allocated for @samp{buffer1}, and the @samp{Z} field will have the value
+5, the offset from @samp{buffer1} to @samp{buffer2}. The result is
+equivalent to this code:
+@smallexample
+buffer1 BYTE 0,0,0,0,0
+buffer2 BYTE 0,0,0,0,0
+ @dots{}
+tmpreg GREG buffer1
+ LDOU $42,tmpreg,(buffer2-buffer1)
+@end smallexample
+
+Global registers allocated with this directive are allocated in order
+higher-to-lower within a file. Other than that, the exact order of
+register allocation and elimination is undefined. For example, the order
+is undefined when more than one file with such directives are linked
+together.
+
+@item BYTE
+@cindex assembler directive BYTE, MMIX
+@cindex pseudo-op BYTE, MMIX
+@cindex MMIX assembler directive BYTE
+@cindex MMIX pseudo-op BYTE
+
+@emph{MMIX-byte}
+The @samp{BYTE} directive takes a series of operands separated by a comma.
+If an operand is a string (@pxref{Strings}), each character of that string
+is emitted as a byte. Other operands must be constant expressions without
+forward references, in the range 0@dots{}255. If you need operands having
+expressions with forward references, use @samp{.byte} (@pxref{Byte}). An
+operand can be omitted, defaulting to a zero value.
+
+@item WYDE
+@itemx TETRA
+@itemx OCTA
+@cindex assembler directive WYDE, MMIX
+@cindex pseudo-op WYDE, MMIX
+@cindex MMIX assembler directive WYDE
+@cindex MMIX pseudo-op WYDE
+@cindex assembler directive TETRA, MMIX
+@cindex pseudo-op TETRA, MMIX
+@cindex MMIX assembler directive TETRA
+@cindex MMIX pseudo-op TETRA
+@cindex assembler directive OCTA, MMIX
+@cindex pseudo-op OCTA, MMIX
+@cindex MMIX assembler directive OCTA
+@cindex MMIX pseudo-op OCTA
+
+@emph{MMIX-constants}
+The directives @samp{WYDE}, @samp{TETRA} and @samp{OCTA} emit constants of
+two, four and eight bytes size respectively. Before anything else happens
+for the directive, the current location is aligned to the respective
+constant-size bondary. If a label is defined at the beginning of the
+line, its value will be that after the alignment. A single operand can be
+omitted, defaulting to a zero value emitted for the directive. Operands
+can be expressed as strings (@pxref{Strings}), in which case each
+character in the string is emitted as a separate constant of the size
+indicated by the directive.
+
+@item PREFIX
+@cindex assembler directive PREFIX, MMIX
+@cindex pseudo-op PREFIX, MMIX
+@cindex MMIX assembler directive PREFIX
+@cindex MMIX pseudo-op PREFIX
+
+@emph{MMIX-prefix}
+The @samp{PREFIX} directive sets a symbol name prefix to be prepended to
+all symbols (except local symbols, @pxref{MMIX-Symbols}), that are not
+prefixed with @samp{:}, until the next @samp{PREFIX} directive. Such
+prefixes accumulate. For example,
+@smallexample
+ PREFIX a
+ PREFIX b
+c IS 0
+@end smallexample
+defines a symbol @samp{abc} with the value 0.
+
+@item BSPEC
+@itemx ESPEC
+@cindex assembler directive BSPEC, MMIX
+@cindex pseudo-op BSPEC, MMIX
+@cindex MMIX assembler directive BSPEC
+@cindex MMIX pseudo-op BSPEC
+@cindex assembler directive ESPEC, MMIX
+@cindex pseudo-op ESPEC, MMIX
+@cindex MMIX assembler directive ESPEC
+@cindex MMIX pseudo-op ESPEC
+
+@emph{MMIX-spec}
+A pair of @samp{BSPEC} and @samp{ESPEC} directives delimit a section of
+special contents (without specified semantics). Example:
+@smallexample
+ BSPEC 42
+ TETRA 1,2,3
+ ESPEC
+@end smallexample
+The single operand to @samp{BSPEC} must be number in the range
+0@dots{}255. The @samp{BSPEC} number 80 is used by the GNU binutils
+implementation.
+@end table
+
+@node MMIX-mmixal
+@section Differences to @code{mmixal}
+@cindex mmixal differences
+@cindex differences, mmixal
+
+The binutils @code{@value{AS}} and @code{@value{LD}} combination has a few
+differences in function compared to @code{mmixal} (@pxref{MMIX-Syntax}).
+
+The replacement of a symbol with a GREG-allocated register
+(@xref{MMIX-Pseudos}) is not handled the exactly same way in
+@code{@value{AS}} as in @code{mmixal}. This is apparent in the
+@code{mmixal} example file @code{inout.mms}, where different registers
+with different offsets, eventually yielding the same address, are used in
+the first instruction. This type of difference should however not affect
+the function of any program unless it has specific assumptions about the
+allocated register number.
+
+Line numbers (in the @samp{mmo} object format) are currently not
+supported.
+
+Expression operator precedence is not that of mmixal: operator precedence
+is that of the C programming language. It's recommended to use
+parentheses to explicitly specify wanted operator precedence whenever more
+than one type of operators are used.
+
+The serialize unary operator @code{&}, the fractional division operator
+@samp{//}, the logical not operator @code{!} and the modulus operator
+@samp{%} are not available.
+
+Symbols are not global by default, unless the option
+@samp{--globalize-symbols} is passed. Use the @samp{.global} directive to
+globalize symbols (@pxref{Global}).
+
+Operand syntax is a bit stricter with @code{@value{AS}} than
+@code{mmixal}. For example, you can't say @code{addu 1,2,3}, instead you
+must write @code{addu $1,$2,3}.
+
+You can't LOC to a lower address than those already visited
+(i.e. ``backwards'').
+
+A LOC directive must come before any emitted code.
+
+Predefined symbols are visible as file-local symbols after use. (In the
+ELF file, that is---the linked mmo file has no notion of a file-local
+symbol.)
+
+Some mapping of constant expressions to sections in LOC expressions is
+attempted, but that functionality is easily confused and should be avoided
+unless compatibility with @code{mmixal} is required. A LOC expression to
+@samp{0x2000000000000000} or higher, maps to the @samp{.data} section and
+lower addresses map to the @samp{.text} section (@pxref{MMIX-Pseudos}).
+
+The code and data areas are each contiguous. Sparse programs with
+far-away LOC directives will take up the same amount of space as a
+contiguous program with zeros filled in the gaps between the LOC
+directives. If you need sparse programs, you might try and get the wanted
+effect with a linker script and splitting up the code parts into sections
+(@pxref{Section}). Assembly code for this, to be compatible with
+@code{mmixal}, would look something like:
+@smallexample
+ .if 0
+ LOC away_expression
+ .else
+ .section away,"ax"
+ .fi
+@end smallexample
+@code{@value{AS}} will not execute the LOC directive and @code{mmixal}
+ignores the lines with @code{.}. This construct can be used generally to
+help compatibility.
+
+Symbols can't be defined twice--not even to the same value.
+
+Instruction mnemonics are recognized case-insensitive, though the
+@samp{IS} and @samp{GREG} pseudo-operations must be specified in
+upper-case characters.
+
+There's no unicode support.
+
+The following is a list of programs in
+@emph{http://www-cs-faculty.stanford.edu/~knuth/mmix-news.html} dated
+2001-08-25 (md5sum c393470cfc86fac040487d22d2bf0172) that assembles with
+@code{mmixal} but don't with @code{@value{AS}}:
+
+@table @code
+@item silly.mms
+LOC to a previous address.
+@item sim.mms
+Redefines symbol @samp{Done}.
+@item test.mms
+Uses the serial operator @samp{&}.
+@end table
+2001-10-30 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * gas/mmix: New testsuite directory.
+
2001-10-24 Chris Demetriou <cgd@broadcom.com>
* gas/mips/ld-empic.d: Remove extra whitespace at beginning of
--- /dev/null
+# objdump: -dr
+# source: 1cjmp1b.s
+# as: -no-expand
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: fd000000 swym 0,0,0
+ 4: f0000001 jmp 8 <Main\+0x8>
+ 8: f0000000 jmp 8 <Main\+0x8>
+ c: f1ffffff jmp 8 <Main\+0x8>
--- /dev/null
+# objdump: -dr
+# as: -linkrelax
+# source: 1cjmp1b.s
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: fd000000 swym 0,0,0
+ 4: f0000001 jmp 8 <Main\+0x8>
+ 4: R_MMIX_ADDR27 \.text\+0x8
+ 8: f0000000 jmp 8 <Main\+0x8>
+ 8: R_MMIX_ADDR27 \.text\+0x8
+ c: f1ffffff jmp 8 <Main\+0x8>
+ c: R_MMIX_ADDR27 \.text\+0x8
--- /dev/null
+# objdump: -dr
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: fd000000 swym 0,0,0
+ 4: f0000001 jmp 8 <Main\+0x8>
+ 8: f0000000 jmp 8 <Main\+0x8>
+ c: f1ffffff jmp 8 <Main\+0x8>
--- /dev/null
+GAS for MMIX .*/1cjmp1b.s page 1
+
+
+ 1 0000 FD000000 Main SWYM 0,0,0
+ 2 0004 F0000001 1: JMP 1f
+ 3 0008 F0000000 1: JMP 1b
+ 4 000c F1FFFFFF JMP 1b
+\fGAS for MMIX .*/1cjmp1b.s page 2
+
+
+DEFINED SYMBOLS
+.*/1cjmp1b.s:1 .text:0000000000000000 Main
+
+NO UNDEFINED SYMBOLS
--- /dev/null
+Main SWYM 0,0,0
+1: JMP 1f
+1: JMP 1b
+ JMP 1b
--- /dev/null
+# objdump: -dr
+# source: 1cjmp1b.s
+# as: -linkrelax -no-expand
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: fd000000 swym 0,0,0
+ 4: f0000000 jmp 4 <Main\+0x4>
+ 4: R_MMIX_ADDR27 \.text\+0x8
+ 8: f0000000 jmp 8 <Main\+0x8>
+ 8: R_MMIX_ADDR27 \.text\+0x8
+ c: f0000000 jmp c <Main\+0xc>
+ c: R_MMIX_ADDR27 \.text\+0x8
--- /dev/null
+# objdump: -dr
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: fd000000 swym 0,0,0
+ 4: f0000001 jmp 8 <Main\+0x8>
+ 8: f1ffffff jmp 4 <Main\+0x4>
+ c: f1ffffff jmp 8 <Main\+0x8>
--- /dev/null
+GAS for MMIX .*/1hjmp1b.s page 1
+
+
+ 1 0000 FD000000 Main SWYM 0,0,0
+ 2 0004 F0000001 1H JMP 1F
+ 3 0008 F1FFFFFF 1H JMP 1B
+ 4 000c F1FFFFFF JMP 1B
+\fGAS for MMIX .*/1hjmp1b.s page 2
+
+
+DEFINED SYMBOLS
+.*/1hjmp1b.s:1 .text:0000000000000000 Main
+
+NO UNDEFINED SYMBOLS
--- /dev/null
+Main SWYM 0,0,0
+1H JMP 1F
+1H JMP 1B
+ JMP 1B
--- /dev/null
+#objdump: -srt
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0000000000000000 l d \.text 0000000000000000
+0000000000000000 l d \.data 0000000000000000
+0000000000000000 l d \.bss 0000000000000000
+0000000000000002 l \.text 0000000000000000 a
+0000000000000008 l \.text 0000000000000000 b
+0000000000000010 l \.text 0000000000000000 c
+000000000000001c g F \.text 0000000000000000 Main
+
+
+Contents of section \.text:
+ 0000 00000001 02000000 00000003 04000000 .*
+ 0010 00000000 00000005 06000000 fd000102 .*
+Contents of section \.data:
--- /dev/null
+# Check that alignment is applied for instructions and pseudos, and that
+# labels to such entities are aligned.
+
+ BYTE 0
+a WYDE 1
+ BYTE 2
+b TETRA 3
+ BYTE 4
+c OCTA 5
+ BYTE 6
+Main SWYM 0,1,2
--- /dev/null
+#objdump: -dr
+
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0+ <a>:
+ 0: 0000002a trap 0,0,42
+ 4: 8d2b0034 ldo \$43,\$0,52
+ 6: R_MMIX_REG \.MMIX\.reg_contents
--- /dev/null
+# Simple base-plus-offset
+b GREG @
+a TETRA 42
+ LDO $43,a+52
--- /dev/null
+#as: --no-predefined-syms
+#objdump: -dr
+
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <a>:
+ 0: 0000002a trap 0,0,42
+ 4: 8d2b0034 ldo \$43,\$0,52
+ 6: R_MMIX_REG \.MMIX\.reg_contents\+0x8
+ \.\.\.
+
+0000000000000108 <d>:
+ 108: 0000001c trap 0,0,28
+ 10c: 8d8f000c ldo \$143,\$0,12
+ 10e: R_MMIX_REG \.MMIX\.reg_contents
+ 110: 8df3000c ldo \$243,\$0,12
+ 112: R_MMIX_REG \.MMIX\.reg_contents\+0x8
+ 114: 23670028 addu \$103,\$0,40
+ 116: R_MMIX_REG \.MMIX\.reg_contents
+ 118: 230d0018 addu \$13,\$0,24
+ 11a: R_MMIX_REG \.MMIX\.reg_contents\+0x8
--- /dev/null
+# Simple base-plus-offset
+b GREG @
+a TETRA 42
+ LDO $43,a+52
+
+ LOC @+256
+c GREG @
+d TETRA 28
+ LDO $143,d+12
+ LDO $243,a+12
+ LDA $103,d+40
+ LDA $13,a+24
--- /dev/null
+#objdump: -dr
+
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0+ <Main>:
+ 0: bf2a0000 pushgo \$42,\$0,0
+ 2: R_MMIX_REG \.MMIX\.reg_contents
+ 4: fd000000 swym 0,0,0
+
+0+8 <extfn>:
+ 8: f8000000 pop 0,0
--- /dev/null
+# PUSHGO is eligible for base-plus-offset addressing.
+ GREG fn
+Main PUSHGO $42,fn
+ SWYM 0
+extfn POP 0,0
--- /dev/null
+#readelf: -Ssr -x1 -x4
+
+There are 9 section headers, starting at offset 0xa0:
+
+Section Headers:
+ \[Nr\] Name Type Address Offset
+ Size EntSize Flags Link Info Align
+ \[ 0\] NULL 0000000000000000 00000000
+ 0000000000000000 0000000000000000 0 0 0
+ \[ 1\] \.text PROGBITS 0000000000000000 00000040
+ 0000000000000004 0000000000000000 AX 0 0 4
+ \[ 2\] \.data PROGBITS 0000000000000000 00000044
+ 0000000000000000 0000000000000000 WA 0 0 1
+ \[ 3\] \.bss NOBITS 0000000000000000 00000044
+ 0000000000000000 0000000000000000 WA 0 0 1
+ \[ 4\] \.MMIX\.spec_data\.2 PROGBITS 0000000000000000 00000044
+ 0000000000000004 0000000000000000 0 0 4
+ \[ 5\] \.rela\.MMIX\.spec_d RELA 0000000000000000 00000378
+ 0000000000000018 0000000000000018 7 4 8
+ \[ 6\] \.shstrtab STRTAB 0000000000000000 00000048
+ 0000000000000055 0000000000000000 0 0 1
+ \[ 7\] \.symtab SYMTAB 0000000000000000 000002e0
+ 0000000000000090 0000000000000018 8 5 8
+ \[ 8\] \.strtab STRTAB 0000000000000000 00000370
+ 0000000000000006 0000000000000000 0 0 1
+Key to Flags:
+ W \(write\), A \(alloc\), X \(execute\), M \(merge\), S \(strings\)
+ I \(info\), L \(link order\), G \(group\), x \(unknown\)
+ O \(extra OS processing required\) o \(OS specific\), p \(processor specific\)
+
+Relocation section '\.rela\.MMIX\.spec_data\.2' at offset 0x378 contains 1 entries:
+[ ]+Offset[ ]+Info[ ]+Type[ ]+Symbol's Value[ ]+Symbol's Name[ ]+Addend
+0+ 0+500000004 R_MMIX_32 0+ forw \+ 0
+
+Symbol table '\.symtab' contains 6 entries:
+ Num: Value Size Type Bind Vis Ndx Name
+ 0: 0+ 0 NOTYPE LOCAL DEFAULT UND
+ 1: 0+ 0 SECTION LOCAL DEFAULT 1
+ 2: 0+ 0 SECTION LOCAL DEFAULT 2
+ 3: 0+ 0 SECTION LOCAL DEFAULT 3
+ 4: 0+ 0 SECTION LOCAL DEFAULT 4
+ 5: 0+ 0 NOTYPE GLOBAL DEFAULT UND forw
+
+Hex dump of section '\.text':
+ 0x00000000 fd010203 .*
+
+Hex dump of section '\.MMIX\.spec_data\.2':
+ 0x00000000 00000000 .*
--- /dev/null
+ SWYM 1,2,3
+ BSPEC 2
+ TETRA forw
+ ESPEC
--- /dev/null
+#readelf: -Sr -x1 -x4
+There are 11 section headers, starting at offset 0xe0:
+
+Section Headers:
+ \[Nr\] Name Type Address Offset
+ Size EntSize Flags Link Info Align
+ \[ 0\] NULL 0+ 0+
+ 0+ 0+ 0 0 0
+ \[ 1\] \.text PROGBITS 0+ 0+40
+ 0+4 0+ AX 0 0 4
+ \[ 2\] \.data PROGBITS 0+ 0+44
+ 0+ 0+ WA 0 0 1
+ \[ 3\] \.bss NOBITS 0+ 0+44
+ 0+ 0+ WA 0 0 1
+ \[ 4\] \.MMIX\.spec_data\.2 PROGBITS 0+ 0+48
+ 0+10 0+ 0 0 8
+ \[ 5\] \.rela\.MMIX\.spec_d RELA 0+ 0+470
+ 0+30 0+18 9 4 8
+ \[ 6\] \.MMIX\.spec_data\.3 PROGBITS 0+ 0+58
+ 0+8 0+ 0 0 8
+ \[ 7\] \.rela\.MMIX\.spec_d RELA 0+ 0+4a0
+ 0+18 0+18 9 6 8
+ \[ 8\] \.shstrtab STRTAB 0+ 0+60
+ 0+7e 0+ 0 0 1
+ \[ 9\] \.symtab SYMTAB 0+ 0+3a0
+ 0+c0 0+18 10 6 8
+ \[10\] \.strtab STRTAB 0+ 0+460
+ 0+c 0+ 0 0 1
+Key to Flags:
+ W \(write\), A \(alloc\), X \(execute\), M \(merge\), S \(strings\)
+ I \(info\), L \(link order\), G \(group\), x \(unknown\)
+ O \(extra OS processing required\) o \(OS specific\), p \(processor specific\)
+
+Relocation section '\.rela\.MMIX\.spec_data\.2' at offset 0x470 contains 2 entries:
+[ ]+Offset[ ]+Info[ ]+Type[ ]+Symbol's Value[ ]+Symbol's Name[ ]+Addend
+0+ 0+600000004 R_MMIX_32 0+ forw \+ 0
+0+8 0+700000005 R_MMIX_64 0+ other \+ 0
+
+Relocation section '\.rela\.MMIX\.spec_data\.3' at offset 0x4a0 contains 1 entries:
+[ ]+Offset[ ]+Info[ ]+Type[ ]+Symbol's Value[ ]+Symbol's Name[ ]+Addend
+0+ 0+700000005 R_MMIX_64 0+ other \+ 0
+
+Hex dump of section '\.text':
+ 0x00000000 fd010203 .*
+
+Hex dump of section '\.MMIX\.spec_data\.2':
+ 0x00000000 00000000 0000002a 00000000 00000000 .*
--- /dev/null
+ SWYM 1,2,3
+ BSPEC 2
+ TETRA forw
+ ESPEC
+ BSPEC 3
+ OCTA other
+ ESPEC
+ BSPEC 2
+ TETRA 42
+ OCTA other
+ ESPEC
--- /dev/null
+# objdump: -dtr
+
+# Make sure we can override a built-in symbol with a known constant, like
+# with mmixal.
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+14 l \*ABS\* 0+ rJ
+0+ l d \.text 0+
+0+ l d \.data 0+
+0+ l d \.bss 0+
+0+ g F \.text 0+ Main
+
+
+Disassembly of section \.text:
+
+0+ <Main>:
+ 0: fe050014 get \$5,rL
+ 4: fe060014 get \$6,rL
+ 8: f6140007 put rL,\$7
+ c: f6140008 put rL,\$8
--- /dev/null
+# When disallowing built-in names, we have to treat GET and PUT
+# specially, so when parsing the special register operand we do
+# not use the symbol table.
+rJ IS 20
+Main GET $5,rJ
+ GET $6,:rJ
+ PUT rJ,$7
+ PUT :rJ,$8
--- /dev/null
+# as: -no-predefined-syms
+# objdump: -dtr
+# source: builtin1.s
+
+# Make sure we don't look at the symbol table when parsing special
+# register names.
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+ l d \.text 0+
+0+ l d \.data 0+
+0+ l d \.bss 0+
+0+14 l \*ABS\* 0+ rJ
+0+ g F \.text 0+ Main
+
+
+Disassembly of section \.text:
+
+0+ <Main>:
+ 0: fe050004 get \$5,rJ
+ 4: fe060004 get \$6,rJ
+ 8: f6040007 put rJ,\$7
+ c: f6040008 put rJ,\$8
--- /dev/null
+# as: -fixed-special-register-names
+# objdump: -dtr
+# source: builtin1.s
+
+# Make sure we don't look at the symbol table when parsing special
+# register names.
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+14 l \*ABS\* 0+ rJ
+0+ l d \.text 0+
+0+ l d \.data 0+
+0+ l d \.bss 0+
+0+ g F \.text 0+ Main
+
+
+Disassembly of section \.text:
+
+0+ <Main>:
+ 0: fe050004 get \$5,rJ
+ 4: fe060004 get \$6,rJ
+ 8: f6040007 put rJ,\$7
+ c: f6040008 put rJ,\$8
--- /dev/null
+#readelf: -Ssrx1
+There are 7 section headers, starting at offset 0x88:
+
+Section Headers:
+ \[Nr\] Name Type Address Offset
+ Size EntSize Flags Link Info Align
+ \[ 0\] NULL 0000000000000000 00000000
+ 0000000000000000 0000000000000000 0 0 0
+ \[ 1\] \.text PROGBITS 0000000000000000 00000040
+ 0000000000000018 0000000000000000 AX 0 0 4
+ \[ 2\] \.data PROGBITS 0000000000000000 00000058
+ 0000000000000000 0000000000000000 WA 0 0 1
+ \[ 3\] \.bss NOBITS 0000000000000000 00000058
+ 0000000000000000 0000000000000000 WA 0 0 1
+ \[ 4\] \.shstrtab STRTAB 0000000000000000 00000058
+ 000000000000002c 0000000000000000 0 0 1
+ \[ 5\] \.symtab SYMTAB 0000000000000000 00000248
+ 00000000000000c0 0000000000000018 6 7 8
+ \[ 6\] \.strtab STRTAB 0000000000000000 00000308
+ 0000000000000018 0000000000000000 0 0 1
+Key to Flags:
+ W \(write\), A \(alloc\), X \(execute\), M \(merge\), S \(strings\)
+ I \(info\), L \(link order\), G \(group\), x \(unknown\)
+ O \(extra OS processing required\) o \(OS specific\), p \(processor specific\)
+
+There are no relocations in this file\.
+
+Symbol table '\.symtab' contains 8 entries:
+ Num: Value Size Type Bind Vis Ndx Name
+ 0: 0+ 0 NOTYPE LOCAL DEFAULT UND
+ 1: 0+ 0 SECTION LOCAL DEFAULT 1
+ 2: 0+ 0 SECTION LOCAL DEFAULT 2
+ 3: 0+ 0 SECTION LOCAL DEFAULT 3
+ 4: 0+2a 0 NOTYPE LOCAL DEFAULT ABS number
+ 5: 0+4 0 NOTYPE LOCAL DEFAULT 1 label
+ 6: 0+c 0 NOTYPE LOCAL DEFAULT 1 lab2
+ 7: 0+ 0 FUNC GLOBAL DEFAULT 1 Main
+
+Hex dump of section '\.text':
+ 0x00000000 fd2b2a29 73747269 6e670aff 8e007374 .*
+ 0x00000010 72696e67 320a0000 .*
--- /dev/null
+# Test BYTE sequences, excercising code paths for valid input.
+number IS 42
+Main SWYM 43,number,41
+
+label BYTE "string",#a,255
+lab2 BYTE number+100,0,"string2",#a
--- /dev/null
+#as: -x
+#objdump: -tdr
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+ l d .text 0+
+0+ l d .data 0+
+0+ l d .bss 0+
+ffff0000ffff0000 l \*ABS\* 0+ i1
+ffff0000ffff0000 l \*ABS\* 0+ i2
+0+ g F .text 0+ Main
+
+Disassembly of section .text:
+
+0+ <Main>:
+ 0: 42ff0000 bz \$255,0 <Main>
+ 0: R_MMIX_CBRANCH \*ABS\*\+0xffff0000ffff0000
+ 4: fd000000 swym 0,0,0
+ 8: fd000000 swym 0,0,0
+ c: fd000000 swym 0,0,0
+ 10: fd000000 swym 0,0,0
+ 14: fd000000 swym 0,0,0
+ 18: 42ff0000 bz \$255,18 <Main\+0x18>
+ 18: R_MMIX_CBRANCH i2
+ 1c: fd000000 swym 0,0,0
+ 20: fd000000 swym 0,0,0
+ 24: fd000000 swym 0,0,0
+ 28: fd000000 swym 0,0,0
+ 2c: fd000000 swym 0,0,0
--- /dev/null
+% BZ far away must not fail
+i1 IS #ffff0000ffff0000
+Main BZ $255,i1
+ BZ $255,i2
+i2 IS #ffff0000ffff0000
--- /dev/null
+#as: -no-expand
+#readelf: -Ssrx1 -x6
+
+There are 10 section headers, starting at offset 0x130:
+
+Section Headers:
+ \[Nr\] Name Type Address Offset
+ Size EntSize Flags Link Info Align
+ \[ 0\] NULL 0+ 0+
+ 0+ 0+ 0 0 0
+ \[ 1\] \.text PROGBITS 0+ 0+40
+ 0+88 0+ AX 0 0 8
+ \[ 2\] \.rela\.text RELA 0+ 0+4f8
+ 0+78 0+18 8 1 8
+ \[ 3\] \.data PROGBITS 0+ 0+c8
+ 0+ 0+ WA 0 0 1
+ \[ 4\] \.bss NOBITS 0+ 0+c8
+ 0+ 0+ WA 0 0 1
+ \[ 5\] \.MMIX\.spec_data\.4 PROGBITS 0+ 0+c8
+ 0+ 0+ 0 0 1
+ \[ 6\] \.MMIX\.reg_content PROGBITS 0+ 0+c8
+ 0+8 0+ W 0 0 1
+ \[ 7\] \.shstrtab STRTAB 0+ 0+d0
+ 0+5d 0+ 0 0 1
+ \[ 8\] \.symtab SYMTAB 0+ 0+3b0
+ 0+120 0+18 9 8 8
+ \[ 9\] \.strtab STRTAB 0+ 0+4d0
+ 0+21 0+ 0 0 1
+Key to Flags:
+ W \(write\), A \(alloc\), X \(execute\), M \(merge\), S \(strings\)
+ I \(info\), L \(link order\), G \(group\), x \(unknown\)
+ O \(extra OS processing required\) o \(OS specific\), p \(processor specific\)
+
+Relocation section '\.rela\.text' at offset 0x4f8 contains 5 entries:
+[ ]+Offset[ ]+Info[ ]+Type[ ]+Symbol's Value[ ]+Symbol's Name[ ]+Addend
+0+34 0+90000001e R_MMIX_ADDR19 0+ target \+ 2c
+0+46 0+a00000002 R_MMIX_16 0+ target2 \+ 30
+0+48 0+b0000001f R_MMIX_ADDR27 0+ target3 \+ 38
+0+54 0+b0000001e R_MMIX_ADDR19 0+ target3 \+ 0
+0+78 0+23 R_MMIX_LOCAL 0+30
+
+Symbol table '\.symtab' contains 12 entries:
+ Num: Value Size Type Bind Vis Ndx Name
+ 0: 0+ 0 NOTYPE LOCAL DEFAULT UND
+ 1: 0+ 0 SECTION LOCAL DEFAULT 1
+ 2: 0+ 0 SECTION LOCAL DEFAULT 3
+ 3: 0+ 0 SECTION LOCAL DEFAULT 4
+ 4: 0+18 0 NOTYPE LOCAL DEFAULT ABS z
+ 5: 0+80 0 NOTYPE LOCAL DEFAULT 1 x
+ 6: 0+ 0 SECTION LOCAL DEFAULT 5
+ 7: 0+ 0 SECTION LOCAL DEFAULT 6
+ 8: 0+ 0 FUNC GLOBAL DEFAULT 1 Main
+ 9: 0+ 0 NOTYPE GLOBAL DEFAULT UND target
+ 10: 0+ 0 NOTYPE GLOBAL DEFAULT UND target2
+ 11: 0+ 0 NOTYPE GLOBAL DEFAULT UND target3
+
+Hex dump of section '\.text':
+ 0x0+ 0000007b 00010017 00010203 01030201 .*
+ 0x0+10 09050006 09070208 0509000a 050b030c .*
+ 0x0+20 230f1011 23121300 23141516 34170018 .*
+ 0x0+30 34191a1b 401c0000 b91d1e1f bf202122 .*
+ 0x0+40 c1232400 e0250000 f0000000 f8260027 .*
+ 0x0+50 f9000028 f2290000 fa2a0000 fb00002b .*
+ 0x0+60 f604002c fe2d0004 00000000 03020104 .*
+ 0x0+70 0007000c 00000014 00000000 0000001c .*
+ 0x0+80 fd221538 00000000 .*
+
+Hex dump of section '\.MMIX\.reg_contents':
+ 0x0+ 00000000 00000033 .*
--- /dev/null
+# Check that "naked" comments are accepted and ignored on all different
+# mnemonic types and pseudos. The goal is to use all combinations of
+# operands where varying number of operands are allowed. If any
+# combinations are missing, for simplicity, add them to another file.
+Main TRAP 123 ignore; x y z
+ TRAP 1,23 all; x y z
+ TRAP 1,2,3 these; x y z
+ FCMP $3,$2,$1 comments; x y z
+ FLOT $5,6 and; x y z
+ FLOT $7,ROUND_UP,8 do; x y z
+ FIX $9,$10 nothing; x y z
+ FIX $11,ROUND_DOWN,$12 that; x y z
+ ADDU $15,$16,17 would make; x y z
+ LDA $18,$19 a; x y z
+ LDA $20,$21,22 difference; x y z
+ NEG $23,$24 in; x y z
+ NEG $25,26,$27 the; x y z
+ bn $28,target + 44 generated; x y z
+ SYNCD 29,$30,31 code; x y z
+ PUSHGO 32,$33,34 so; x y z
+ SET $35,$36 it; x y z
+ SETH $37,target2 + 48 is; x y z
+ JMP target3 + 56 as; x y z
+ POP 38,39 if; x y z
+ RESUME 40 it; x y z
+ PUSHJ $41,target3 had; x y z
+ SAVE $42,0 never; x y z
+ UNSAVE 0,$43 been; x y z
+ PUT rJ,$44 there; x y z
+ GET $45,rJ at all.; x y z
+
+ LOC @+4 likewise; x y z
+ PREFIX : with; x y z
+ BYTE 3,2,1,0+4 the; x y z
+ WYDE 7,4+8 different; x y z
+ TETRA 8+12 pseudo; x y z
+ OCTA 12+16 ops,; x y z
+ LOCAL 48 they; x y z
+ BSPEC 49 too; x y z
+# Specifying an operand field (although ignored) is necessary for a comment
+# with a ';' to be ignorable and not interpreted as eoln, both for GAS and
+# mmixal.
+ ESPEC 0 ignore; x y z
+ GREG 50 + 1 naked; x y z
+z IS 9 + 8 + 7 comments; x y z
+x SWYM 34,21,56
--- /dev/null
+#objdump: -drt
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+ l d \.text 0+
+0+ l d \.data 0+
+0+ l d \.bss 0+
+0+ g F \.text 0+ Main
+
+
+Disassembly of section \.text:
+
+0+ <Main>:
+ 0: f801e240 pop 1,57920
--- /dev/null
+Main POP 123456 ignore; x y z
--- /dev/null
+#objdump: -srt
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0000000000000000 l d \.text 0000000000000000
+0000000000000000 l d \.data 0000000000000000
+0000000000000000 l d \.bss 0000000000000000
+0000000000000000 l \.MMIX\.reg_contents 0000000000000000 im
+0000000000000000 l d \.MMIX\.reg_contents 0000000000000000
+
+
+RELOCATION RECORDS FOR \[\.MMIX\.reg_contents\]:
+OFFSET TYPE VALUE
+0000000000000000 R_MMIX_64 \.text
+
+
+Contents of section \.text:
+Contents of section \.data:
+Contents of section \.MMIX\.reg_contents:
+ 0000 00000000 00000000 .*
--- /dev/null
+# If we aren't careful, '@' will be considered an operator.
+im GREG @ home
--- /dev/null
+#objdump: -sr
+
+.*: file format elf64-mmix
+
+Contents of section \.text:
+ 0000 00000000 00000000 .*
+Contents of section \.data:
--- /dev/null
+# Empty expressions are a single zero.
+d OCTA
--- /dev/null
+#objdump: -str
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+ l d \.text 0+
+0+ l d \.data 0+
+0+ l d \.bss 0+
+0+ g F \.text 0+ Main
+
+Contents of section \.text:
+ 0000 61623b00 00000000 00000000 00000064 .*
+ 0010 00000000 00000065 .*
+Contents of section \.data:
--- /dev/null
+# Character constants. We actually see e.g. 'b' as 98, so ww just check
+# that we get the right output with this test.
+Main BYTE 'a','b',';'
+ OCTA 'd','e'
--- /dev/null
+% { dg-do assemble { target mmix-*-* } }
+
+% SAVE, UNSAVE are not valid with base-plus-offset
+
+ .data
+buffer OCTA 0,0,0
+
+ .text
+ GREG buffer
+Main SWYM 0
+ SAVE buffer,0 % { dg-error "operands" "" }
+ UNSAVE 0,buffer % { dg-error "operands" "" }
--- /dev/null
+% { dg-do assemble { target mmix-*-* } }
+Main SET $45,23
+ BSPEC 5 % { dg-error "BSPEC without ESPEC" "" }
+ TETRA 4
--- /dev/null
+% { dg-do assemble { target mmix-*-* } }
+Main SET $45,23
+ BSPEC 5
+ TETRA 4
+ BSPEC 6 % { dg-error "BSPEC already active" "" }
+ TETRA 5
+ ESPEC
--- /dev/null
+% { dg-do assemble { target mmix-*-* } }
+Main SET $45,23
+ TETRA 4
+ ESPEC % { dg-error "ESPEC without preceding BSPEC" "" }
--- /dev/null
+% { dg-do assemble { target mmix-*-* } }
+Main SET $45,23
+ BSPEC 2
+ TETRA 4
+ ESPEC
+ TETRA 5
+ ESPEC % { dg-error "ESPEC without preceding BSPEC" "" }
--- /dev/null
+% { dg-do assemble { target mmix-*-* } }
+Main SET $45,23
+here SWYM 0,0,0
+ BSPEC 0
+ TETRA 4
+ ESPEC
+ BSPEC 65535
+ TETRA 4
+ ESPEC
+ BSPEC 65536 % { dg-error "invalid BSPEC expression" "" }
+ TETRA 4
+ ESPEC
+ BSPEC forw % { dg-error "invalid BSPEC expression" "" }
+ TETRA 4
+ ESPEC
+ BSPEC here % { dg-error "invalid BSPEC expression" "" }
+ TETRA 4
+ ESPEC
+ BSPEC -1 % { dg-error "invalid BSPEC expression" "" }
+ TETRA 4
+ ESPEC
+
+
--- /dev/null
+% { dg-do assemble { target mmix-*-* } }
+% { dg-options "-no-predefined-syms" }
+% When disallowing built-in names, we have to treat GET and PUT
+% specially, so when parsing the special register operand we do
+% not use the symbol table. Make sure an error is emitted for
+% invalid registers despite there being a valid user label and
+% the construct being valid without the -no-builtin-syms option.
+% FIXME: Another option? Or is this just the consequence?
+RJ IS 4
+other IS 20
+Main GET $5,RJ % { dg-error "invalid operands" "" }
+ PUT other,$7 % { dg-error "invalid operands" "" }
+ GET garbage % { dg-error "invalid operands" "" }
+ PUT garbage % { dg-error "invalid operands" "" }
--- /dev/null
+% { dg-do assemble { target mmix-*-* } }
+% { dg-error "unterminated string" "" { target mmix-*-* } 10 }
+% { dg-bogus "end of file" "" { xfail mmix-*-* } 0 }
+
+# Note that the error is detected in the preformatter, before the text
+# gets to the assembler. It also gets confused about the unterminated
+# string. Well, at least we get error messages for it, so no worries.
+
+Main SWYM 0,0,0
+ BYTE 2,"no end
+ BYTE 0
--- /dev/null
+% { dg-do assemble { target mmix-*-* } }
+
+m1 IS -1
+zero IS 0
+zero2 IS 0
+1H IS 42
+2H IS 5
+Main SWYM 0,0,0
+ BYTE 0
+ BYTE -1 % { dg-error "BYTE expression not in the range 0..255" "" }
+ BYTE m1 % { dg-error "BYTE expression not in the range 0..255" "" }
+ BYTE zero2
+ BYTE 1B+2B+55
+ BYTE zero+m1 % { dg-error "BYTE expression not in the range 0..255" "" }
+ BYTE 255
+ BYTE 256 % { dg-error "BYTE expression not in the range 0..255" "" }
+ BYTE unk+1 % { dg-error "BYTE expression not a pure number" "" }
--- /dev/null
+% Check that lowercase pseudos with mmixal syntax (no dot prefix) aren't
+% recognized. Since local is handled as an insn, it's actually
+% misrecognized in lower case.
+% { dg-do assemble { target mmix-*-* } }
+Main SWYM 0,0,0
+X is 42 % { dg-error "unknown opcode: \`is\'" "" }
+ local 56 % { dg-error "unknown opcode: \`fatal\'" "" { xfail *-*-* } }
+a greg 94 % { dg-error "unknown opcode: \`greg\'" "" }
--- /dev/null
+% { dg-do assemble { target mmix-*-* } }
+% { dg-error "may not appear alone on a line" "" { target mmix-*-* } 5 }
+% { dg-error "may not appear alone on a line" "" { target mmix-*-* } 6 }
+0H .local 32 % { dg-error "do not mix with dot-pseudos" "" }
+1H
+2H
+3H .set s,32 % { dg-error "do not mix with dot-pseudos" "" }
--- /dev/null
+% { dg-do assemble { target mmix-*-* } }
+
+% One more than greg9.s is one too many.
+% The error is reported on the wrong line. Methinks that error is
+% attributable to the .rept machinery. No xfail+bogus for this one.
+
+Main SWYM 0
+ .rept 223
+ GREG
+ .endr % { dg-error "too many GREG registers allocated" "" }
--- /dev/null
+% { dg-do assemble { target mmix-*-* } }
+Main SWYM 0,0,0
+ FLOT $112,$223,$41 % { dg-error "invalid operands" "Y field of FLOT 1" }
+ FLOT $112,$223,141 % { dg-error "invalid operands" "Y field of FLOT 2" }
+ LDA $122,$203,256 % { dg-error "invalid operands" "Z field too large" }
--- /dev/null
+% { dg-do assemble { target mmix-*-* } }
+ IS 42 % { dg-error "empty label field for IS" "" }
+2H IS 1
+ IS 2B % { dg-error "empty label field for IS" "" }
--- /dev/null
+% { dg-do assemble { target mmix-*-* } }
+ LOC #200
+Main SET $45,23
+ LOC #100 % { dg-error "LOC expression stepping backwards" "" }
+ SET $57,$67
--- /dev/null
+% { dg-do assemble { target mmix-*-* } }
+ LOC (#20 << 56) + #200
+ TETRA 1
+ LOC (#20 << 56) + #100 % { dg-error "LOC expression stepping backwards" "" }
+ TETRA 2
--- /dev/null
+% { dg-do assemble { target mmix-*-* } }
+ LOC (#20 << 56) + #202
+ TETRA 1
+ OCTA 1 % { dg-error "data item with alignment larger than location" "" }
--- /dev/null
+% { dg-do assemble { target mmix-*-* } }
+ LOC #201
+ WYDE 1
+ SWYM 1 % { dg-error "specified location wasn't TETRA-aligned" "" }
--- /dev/null
+% { dg-do assemble { target mmix-*-* } }
+ LOC (#20<<56)|1
+ .p2align 0
+ SWYM 1 % { dg-error "unaligned data at an absolute location" "" }
--- /dev/null
+% { dg-do assemble { target mmix-*-* } }
+ LOC #201
+ .p2align 0
+ SWYM 1 % { dg-error "unaligned data at an absolute location" "" }
--- /dev/null
+% { dg-do assemble { target mmix-*-* } }
+ LOC (#20<<56)|1
+ .p2align 0
+ TETRA 1 % { dg-error "unaligned data at an absolute location" "" }
--- /dev/null
+% { dg-do assemble { target mmix-*-* } }
+ LOC #201
+ .p2align 0
+ TETRA 1 % { dg-error "unaligned data at an absolute location" "" }
--- /dev/null
+% { dg-do assemble { target mmix-*-* } }
+% Check that error handling for the restrictions on LOCAL works.
+ LOCAL 128 % { dg-error "LOCAL must be placed in code or data" "" }
+
+ LOC Data_Segment
+ OCTA 0
--- /dev/null
+% { dg-do assemble { target mmix-*-* } }
+% Check that error handling for the restrictions on LOCAL works.
+ LOCAL 128 % { dg-error "LOCAL must be placed in code or data" "" }
--- /dev/null
+% { dg-do assemble { target mmix-*-* } }
+% { dg-bogus "bad expression" "" { xfail mmix-*-* } 9 }
+% { dg-bogus "bad expression" "" { xfail mmix-*-* } 10 }
+
+% Make sure we correctly diagnose the serial-number operator.
+% We can't stop the "bad expression" error, though; hence the "bogus" errors.
+
+a IS 42
+Main TETRA &a<<8 { dg-error "serial number operator is not supported" "" }
+ TETRA 3+&a<<8 { dg-error "serial number operator is not supported" "" }
--- /dev/null
+% { dg-do assemble { target mmix-*-* } }
+Main SET $45,23
+ SET $57,$67 % Valid, Z is 0.
+ SET $78,X % Valid, Z is 0.
+ SET $7,Y % { dg-error "invalid operands.*value of 967 too large" "" }
+X IS $31
+Y IS 967
--- /dev/null
+# objdump: -s
+
+.*: file format elf64-mmix
+
+Contents of section \.text:
+ 0000 000000ab 00000100 .*
+Contents of section \.data:
--- /dev/null
+% Test expression example from TAOCP. Nothing problematic; does not have
+% the known expression evaluation order mismatch problem.
+
+k IS #cdef00
+Main OCTA #ab<<32+k&~(k-1)
+
--- /dev/null
+#objdump: -str
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+ l d \.text 0+
+0+ l d \.data 0+
+0+ l d \.bss 0+
+0+ l d \.MMIX\.reg_contents 0+
+
+
+RELOCATION RECORDS FOR \[\.text\]:
+OFFSET TYPE VALUE
+0+2 R_MMIX_REG \.MMIX\.reg_contents
+
+
+Contents of section \.text:
+ 0+ dd2d0038 .*
+Contents of section \.data:
+Contents of section \.MMIX\.reg_contents:
+ 0+ 00000000 aabbccdd 00000000 00112233 .*
--- /dev/null
+# FB-labels are valid in GREG definitions.
+9H GREG #112233
+9H GREG #aabbccdd
+1H MOR $45,9B,56
--- /dev/null
+#objdump: -str
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+ l d \.text 0+
+0+ l d \.data 0+
+0+ l d \.bss 0+
+0+ l d \.MMIX\.reg_contents 0+
+0+10 g \*ABS\* 0+ __\.MMIX\.start\.\.text
+
+
+RELOCATION RECORDS FOR \[\.text\]:
+OFFSET TYPE VALUE
+0+2a R_MMIX_REG \.MMIX\.reg_contents
+0+30 R_MMIX_64 \.text\+0x0+28
+0+38 R_MMIX_64 \.text\+0x0+40
+
+
+RELOCATION RECORDS FOR \[\.MMIX\.reg_contents\]:
+OFFSET TYPE VALUE
+0+ R_MMIX_64 \.text\+0x0+5a
+
+
+Contents of section \.text:
+ 0000 05000000 00000000 00000000 00000000 .*
+ 0010 00000000 00000000 00000000 00000000 .*
+ 0020 00000000 fd000000 231e0000 00000000 .*
+ 0030 00000000 00000000 00000000 00000000 .*
+ 0040 fd000000 002a002b 002b002c 00000000 .*
+Contents of section \.data:
+Contents of section \.MMIX\.reg_contents:
+ 0000 00000000 00000000 .*
--- /dev/null
+# Test fb-label where the insn or pseudo on line with definition uses an
+# argment with a same-number label.
+1H IS 5
+0H LOC #10
+1H BYTE 1B
+0H LOC 0B+#20+0F
+0H IS 4
+1H IS 50
+1H GREG 1B+1F
+ SWYM
+1H LDA $30,1B
+1H OCTA 1B,1F
+1H SWYM
+
+9H IS 42
+ WYDE 9B,9F
+9H IS 9B+1
+ WYDE 9B,9F
+9H IS 9B+1
+
--- /dev/null
+# objdump: -dr
+# as: -linkrelax
+# source: get-op.s
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: fe7b0004 get \$123,rJ
+ 4: fe2d0013 get \$45,rG
+ 8: fef5001f get \$245,rZZ
--- /dev/null
+# objdump: -dr
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: fe7b0004 get \$123,rJ
+ 4: fe2d0013 get \$45,rG
+ 8: fef5001f get \$245,rZZ
--- /dev/null
+GAS for MMIX .*/get-op\.s page 1
+
+
+ 1 #.*
+ 2 #.*
+ 3 0000 FE7B0004 Main GET X,rJ
+ 4 0004 FE2D0013 GET \$45,rG
+ 5 0008 FEF5001F GET \$245,rZZ
+ 6 X IS \$123
+\fGAS for MMIX .*/get-op\.s page 2
+
+
+DEFINED SYMBOLS
+.*/get-op\.s:3 \.text:0000000000000000 Main
+ \*REG\*:000000000000007b X
+
+NO UNDEFINED SYMBOLS
--- /dev/null
+# For 'g'-type operands: GET.
+#
+Main GET X,rJ
+ GET $45,rG
+ GET $245,rZZ
+X IS $123
--- /dev/null
+#as: -x
+#objdump: -tdr
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+ l d .text 0+
+0+ l d .data 0+
+0+ l d .bss 0+
+ffff0000ffff0000 l \*ABS\* 0+ i1
+ffff0000ffff0000 l \*ABS\* 0+ i2
+0+ g F .text 0+ Main
+
+Disassembly of section .text:
+
+0+ <Main>:
+ 0: f4ff0000 geta \$255,0 <Main>
+ 0: R_MMIX_GETA \*ABS\*\+0xffff0000ffff0000
+ 4: fd000000 swym 0,0,0
+ 8: fd000000 swym 0,0,0
+ c: fd000000 swym 0,0,0
+ 10: f4ff0000 geta \$255,10 <Main\+0x10>
+ 10: R_MMIX_GETA i2
+ 14: fd000000 swym 0,0,0
+ 18: fd000000 swym 0,0,0
+ 1c: fd000000 swym 0,0,0
--- /dev/null
+% GETA with a large constant must not fail
+i1 IS #ffff0000ffff0000
+Main GETA $255,i1
+ GETA $255,i2
+i2 IS #ffff0000ffff0000
--- /dev/null
+# objdump: -dr
+# as: -linkrelax
+# source: geta-op.s
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: fd000000 swym 0,0,0
+
+0000000000000004 <here>:
+ 4: fd000000 swym 0,0,0
+ 8: f519ffff geta \$25,4 <here>
+ 8: R_MMIX_ADDR19 \.text\+0x4
+
+000000000000000c <at>:
+ c: f4200000 geta \$32,c <at>
+ c: R_MMIX_ADDR19 \.text\+0xc
+ 10: 424e0008 bz \$78,30 <there>
+ 10: R_MMIX_ADDR19 \.text\+0x30
+ 14: f35bfffc pushj \$91,4 <here>
+ 14: R_MMIX_ADDR19 \.text\+0x4
+ 18: f387fffb pushj \$135,4 <here>
+ 18: R_MMIX_ADDR19 \.text\+0x4
+ 1c: f4870005 geta \$135,30 <there>
+ 1c: R_MMIX_ADDR19 \.text\+0x30
+ 20: f2870004 pushj \$135,30 <there>
+ 20: R_MMIX_ADDR19 \.text\+0x30
+ 24: f2490003 pushj \$73,30 <there>
+ 24: R_MMIX_ADDR19 \.text\+0x30
+ 28: f2380002 pushj \$56,30 <there>
+ 28: R_MMIX_ADDR19 \.text\+0x30
+ 2c: 5f87fff6 pbev \$135,4 <here>
+ 2c: R_MMIX_ADDR19 \.text\+0x4
+
+0000000000000030 <there>:
+ 30: fd000000 swym 0,0,0
--- /dev/null
+# objdump: -dr
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: fd000000 swym 0,0,0
+
+0000000000000004 <here>:
+ 4: fd000000 swym 0,0,0
+ 8: f519ffff geta \$25,4 <here>
+
+000000000000000c <at>:
+ c: f4200000 geta \$32,c <at>
+ 10: 424e0008 bz \$78,30 <there>
+ 14: f35bfffc pushj \$91,4 <here>
+ 18: f387fffb pushj \$135,4 <here>
+ 1c: f4870005 geta \$135,30 <there>
+ 20: f2870004 pushj \$135,30 <there>
+ 24: f2490003 pushj \$73,30 <there>
+ 28: f2380002 pushj \$56,30 <there>
+ 2c: 5f87fff6 pbev \$135,4 <here>
+
+0000000000000030 <there>:
+ 30: fd000000 swym 0,0,0
--- /dev/null
+GAS for MMIX .*/geta-op\.s page 1
+
+
+ 1 #.*
+ 2 0000 FD000000 Main SWYM 0,0,0
+ 3 0004 FD000000 here SWYM 0,0,0
+ 4 0008 F519FFFF GETA \$25,here
+ 5 000c F4200000 at GETA \$32,at
+ 6 0010 424E0008 BZ \$78,there
+ 7 0014 F35BFFFC PUSHJ X0,here
+ 8 0018 F387FFFB PUSHJ X,here
+ 9 001c F4870005 GETA X,there
+ 10 0020 F2870004 PUSHJ X,there
+ 11 0024 F2490003 PUSHJ \$73,there
+ 12 0028 F2380002 PUSHJ 56,there
+ 13 002c 5F87FFF6 PBEV X,here
+ 14 0030 FD000000 there SWYM 0,0,0
+ 15 X IS \$135
+ 16 X0 IS 91
+\fGAS for MMIX .*/geta-op\.s page 2
+
+
+DEFINED SYMBOLS
+.*/geta-op\.s:2 \.text:0000000000000000 Main
+.*/geta-op\.s:3 \.text:0000000000000004 here
+.*/geta-op\.s:5 \.text:000000000000000c at
+.*/geta-op\.s:14 \.text:0000000000000030 there
+ \*ABS\*:000000000000005b X0
+ \*REG\*:0000000000000087 X
+
+NO UNDEFINED SYMBOLS
--- /dev/null
+# Simple GETA/BRANCH/PUSHJ operands.
+Main SWYM 0,0,0
+here SWYM 0,0,0
+ GETA $25,here
+at GETA $32,at
+ BZ $78,there
+ PUSHJ X0,here
+ PUSHJ X,here
+ GETA X,there
+ PUSHJ X,there
+ PUSHJ $73,there
+ PUSHJ 56,there
+ PBEV X,here
+there SWYM 0,0,0
+X IS $135
+X0 IS 91
--- /dev/null
+# objdump: -dr
+# source: geta-op.s
+# as: -no-expand
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: fd000000 swym 0,0,0
+
+0000000000000004 <here>:
+ 4: fd000000 swym 0,0,0
+ 8: f519ffff geta \$25,4 <here>
+
+000000000000000c <at>:
+ c: f4200000 geta \$32,c <at>
+ 10: 424e0008 bz \$78,30 <there>
+ 14: f35bfffc pushj \$91,4 <here>
+ 18: f387fffb pushj \$135,4 <here>
+ 1c: f4870005 geta \$135,30 <there>
+ 20: f2870004 pushj \$135,30 <there>
+ 24: f2490003 pushj \$73,30 <there>
+ 28: f2380002 pushj \$56,30 <there>
+ 2c: 5f87fff6 pbev \$135,4 <here>
+
+0000000000000030 <there>:
+ 30: fd000000 swym 0,0,0
--- /dev/null
+# objdump: -dr
+# as: -linkrelax -no-expand
+# source: geta-op.s
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: fd000000 swym 0,0,0
+
+0000000000000004 <here>:
+ 4: fd000000 swym 0,0,0
+ 8: f4190000 geta \$25,8 <here\+0x4>
+ 8: R_MMIX_ADDR19 \.text\+0x4
+
+000000000000000c <at>:
+ c: f4200000 geta \$32,c <at>
+ c: R_MMIX_ADDR19 \.text\+0xc
+ 10: 424e0000 bz \$78,10 <at\+0x4>
+ 10: R_MMIX_ADDR19 \.text\+0x30
+ 14: f25b0000 pushj \$91,14 <at\+0x8>
+ 14: R_MMIX_ADDR19 \.text\+0x4
+ 18: f2870000 pushj \$135,18 <at\+0xc>
+ 18: R_MMIX_ADDR19 \.text\+0x4
+ 1c: f4870000 geta \$135,1c <at\+0x10>
+ 1c: R_MMIX_ADDR19 \.text\+0x30
+ 20: f2870000 pushj \$135,20 <at\+0x14>
+ 20: R_MMIX_ADDR19 \.text\+0x30
+ 24: f2490000 pushj \$73,24 <at\+0x18>
+ 24: R_MMIX_ADDR19 \.text\+0x30
+ 28: f2380000 pushj \$56,28 <at\+0x1c>
+ 28: R_MMIX_ADDR19 \.text\+0x30
+ 2c: 5e870000 pbev \$135,2c <at\+0x20>
+ 2c: R_MMIX_ADDR19 \.text\+0x4
+
+0000000000000030 <there>:
+ 30: fd000000 swym 0,0,0
--- /dev/null
+# objdump: -rst
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+ l d \.text 0+
+0+ l d \.data 0+
+0+ l d \.bss 0+
+0+ l \.text 0+ D4
+0+4 l \.text 0+ E6
+0+ l \.MMIX\.reg_contents 0+ H9
+0+8 l \.MMIX\.reg_contents 0+ G8
+0+ l \.MMIX\.reg_contents 0+ F7
+0+18 l \.MMIX\.reg_contents 0+ D5
+0+20 l \.MMIX\.reg_contents 0+ C3
+0+28 l \.MMIX\.reg_contents 0+ B1
+0+30 l \.MMIX\.reg_contents 0+ A0
+0+0 l d \.MMIX\.reg_contents 0+
+0+c g F \.text 0+ Main
+
+
+RELOCATION RECORDS FOR \[\.MMIX\.reg_contents\]:
+OFFSET TYPE VALUE
+0+ R_MMIX_64 \.text\+0x0+8
+0+10 R_MMIX_64 \.text\+0x0+1c
+0+20 R_MMIX_64 \.text
+
+
+Contents of section \.text:
+ 0000 e37b01c8 e3ea1edb fd020304 fd010203 .*
+Contents of section \.data:
+Contents of section \.MMIX\.reg_contents:
+ 0000 00000000 00000000 00000000 000000f7 .*
+ 0010 00000000 00000000 00000000 00000000 .*
+ 0020 00000000 00000000 00000000 00000001 .*
+ 0030 00000000 00000000 .*
--- /dev/null
+# Use of GREG with mmixal syntax.
+D4 SET $123,456
+E6 SET $234,7899
+
+A0 GREG 0
+B1 GREG 1
+C3 GREG D4
+D5 GREG
+ GREG E6+24
+F7 GREG @
+ GREG @ % Equivalent to F7, unless -no-merge-gregs.
+G8 GREG #F7
+H9 GREG @ % Equivalent to F7, unless -no-merge-gregs.
+
+ SWYM 2,3,4
+Main SWYM 1,2,3
+
--- /dev/null
+# source: greg1.s
+# as: -no-merge-gregs
+# objdump: -rst
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+ l d \.text 0+
+0+ l d \.data 0+
+0+ l d \.bss 0+
+0+ l \.text 0+ D4
+0+4 l \.text 0+ E6
+0+ l \.MMIX\.reg_contents 0+ H9
+0+8 l \.MMIX\.reg_contents 0+ G8
+0+18 l \.MMIX\.reg_contents 0+ F7
+0+28 l \.MMIX\.reg_contents 0+ D5
+0+30 l \.MMIX\.reg_contents 0+ C3
+0+38 l \.MMIX\.reg_contents 0+ B1
+0+40 l \.MMIX\.reg_contents 0+ A0
+0+0 l d \.MMIX\.reg_contents 0+
+0+c g F \.text 0+ Main
+
+
+RELOCATION RECORDS FOR \[\.MMIX\.reg_contents\]:
+OFFSET TYPE VALUE
+0+ R_MMIX_64 \.text\+0x0+8
+0+10 R_MMIX_64 \.text\+0x0+8
+0+18 R_MMIX_64 \.text\+0x0+8
+0+20 R_MMIX_64 \.text\+0x0+1c
+0+30 R_MMIX_64 .text
+
+Contents of section \.text:
+ 0000 e37b01c8 e3ea1edb fd020304 fd010203 .*
+Contents of section \.data:
+Contents of section \.MMIX\.reg_contents:
+ 0000 00000000 00000000 00000000 000000f7 .*
+ 0010 00000000 00000000 00000000 00000000 .*
+ 0020 00000000 00000000 00000000 00000000 .*
+ 0030 00000000 00000000 00000000 00000001 .*
+ 0040 00000000 00000000 .*
--- /dev/null
+# objdump: -rst
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+ l d \.text 0+
+0+ l d \.data 0+
+0+ l d \.bss 0+
+0+ l \.text 0+ D4
+0+4 l \.text 0+ E6
+0+ l \.MMIX\.reg_contents 0+ H9
+0+8 l \.MMIX\.reg_contents 0+ G8
+0+ l \.MMIX\.reg_contents 0+ F7
+0+18 l \.MMIX\.reg_contents 0+ D5
+0+20 l \.MMIX\.reg_contents 0+ C3
+0+28 l \.MMIX\.reg_contents 0+ B1
+0+30 l \.MMIX\.reg_contents 0+ A0
+0+0 l d \.MMIX\.reg_contents 0+
+0+c g F \.text 0+ Main
+
+
+RELOCATION RECORDS FOR \[\.MMIX\.reg_contents\]:
+OFFSET TYPE VALUE
+0+ R_MMIX_64 \.text\+0x0+8
+0+10 R_MMIX_64 \.text\+0x0+1c
+0+20 R_MMIX_64 \.text
+
+
+Contents of section \.text:
+ 0000 e37b01c8 e3ea1edb fd020304 fd010203 .*
+Contents of section \.data:
+Contents of section \.MMIX\.reg_contents:
+ 0000 00000000 00000000 00000000 000000f7 .*
+ 0010 00000000 00000000 00000000 00000000 .*
+ 0020 00000000 00000000 00000000 00000001 .*
+ 0030 00000000 00000000 .*
--- /dev/null
+# Use of .greg; non-mmixal syntax though somewhat corresponding to greg1.
+# Note that use-before-definition is allowed.
+ .text
+
+ .greg A0,0
+ .greg B1,1
+ .greg C3,D4
+ .greg D5,
+ .greg ,E6+24 % Somewhat unusable, but hey...
+ .greg F7,.+8
+ .greg ,.+8
+ .greg G8,0xf7
+ .greg H9,.+8
+
+D4:
+ set $123,456
+E6:
+ set $234,7899
+ swym 2,3,4
+Main:
+ swym 1,2,3
--- /dev/null
+# source: greg2.s
+# as: -no-merge-gregs
+# objdump: -rst
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+ l d \.text 0+
+0+ l d \.data 0+
+0+ l d \.bss 0+
+0+ l \.text 0+ D4
+0+4 l \.text 0+ E6
+0+ l \.MMIX\.reg_contents 0+ H9
+0+8 l \.MMIX\.reg_contents 0+ G8
+0+18 l \.MMIX\.reg_contents 0+ F7
+0+28 l \.MMIX\.reg_contents 0+ D5
+0+30 l \.MMIX\.reg_contents 0+ C3
+0+38 l \.MMIX\.reg_contents 0+ B1
+0+40 l \.MMIX\.reg_contents 0+ A0
+0+0 l d \.MMIX\.reg_contents 0+
+0+c g F \.text 0+ Main
+
+
+RELOCATION RECORDS FOR \[\.MMIX\.reg_contents\]:
+OFFSET TYPE VALUE
+0+ R_MMIX_64 \.text\+0x0+8
+0+10 R_MMIX_64 \.text\+0x0+8
+0+18 R_MMIX_64 \.text\+0x0+8
+0+20 R_MMIX_64 \.text\+0x0+1c
+0+30 R_MMIX_64 .text
+
+Contents of section \.text:
+ 0000 e37b01c8 e3ea1edb fd020304 fd010203 .*
+Contents of section \.data:
+Contents of section \.MMIX\.reg_contents:
+ 0000 00000000 00000000 00000000 000000f7 .*
+ 0010 00000000 00000000 00000000 00000000 .*
+ 0020 00000000 00000000 00000000 00000000 .*
+ 0030 00000000 00000000 00000000 00000001 .*
+ 0040 00000000 00000000 .*
--- /dev/null
+# objdump: -rst
+
+# Check that we emit the right relocations for greg operands.
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+ l d \.text 0+
+0+ l d \.data 0+
+0+ l d \.bss 0+
+0+ l d \.MMIX\.reg_contents 0+
+0+ g \.MMIX\.reg_contents 0+ areg
+0+c g F \.text 0+ Main
+
+RELOCATION RECORDS FOR \[\.text\]:
+OFFSET TYPE VALUE
+0+2 R_MMIX_REG \.MMIX\.reg_contents
+0+7 R_MMIX_REG_OR_BYTE \.MMIX\.reg_contents
+0+a R_MMIX_REG \.MMIX\.reg_contents
+
+RELOCATION RECORDS FOR \[\.MMIX\.reg_contents\]:
+OFFSET TYPE VALUE
+0+ R_MMIX_64 \.text\+0x0+10
+
+Contents of section \.text:
+ 0000 8f030010 8e030700 8f050004 fd000001 .*
+ 0010 fd000002 fd000003 fd000004 fd000005 .*
+ 0020 fd000006 .*
+Contents of section \.data:
+Contents of section \.MMIX\.reg_contents:
+ 0000 00000000 00000000 .*
--- /dev/null
+ .global areg
+areg GREG Main+4
+ LDOU $3,areg,16
+ LDOU $3,$7,areg
+ LDOU $5,Main+8
+Main SWYM 1
+ SWYM 2
+ SWYM 3
+ SWYM 4
+ SWYM 5
+ SWYM 6
--- /dev/null
+#objdump: -str
+
+# Branches can have base-plus-offset operands too.
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+ l d \.text 0+
+0+ l d \.data 0+
+0+ l d \.bss 0+
+0+4 l \.text 0+ x
+0+ l d \.MMIX\.reg_contents 0+
+
+
+RELOCATION RECORDS FOR \[\.text\]:
+OFFSET TYPE VALUE
+0+a R_MMIX_REG \.MMIX\.reg_contents
+
+
+RELOCATION RECORDS FOR \[\.MMIX\.reg_contents\]:
+OFFSET TYPE VALUE
+0+ R_MMIX_64 \.text
+
+
+Contents of section \.text:
+ 0000 fd000000 fd000001 9f000004 .*
+Contents of section \.data:
+Contents of section \.MMIX\.reg_contents:
+ 0000 00000000 00000000 .*
--- /dev/null
+ GREG @
+ SWYM 0
+x SWYM 1
+ GO $0,x
--- /dev/null
+#objdump: -str
+
+# GAS must know that .data and expressions around #20 << 56 can be
+# equivalent for GREGs.
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+ l d \.text 0+
+0+ l d \.data 0+
+0+ l d \.bss 0+
+0+ l \.text 0+ t
+2000000000000004 l \*ABS\* 0+ x
+2000000000000000 l \*ABS\* 0+ Data_Segment
+0+ l \.data 0+ y
+0+ l d \.MMIX\.reg_contents 0+
+0+ g F \.text 0+ Main
+2000000000000008 g \*ABS\* 0+ __\.MMIX\.start\.\.data
+
+RELOCATION RECORDS FOR \[\.text\]:
+OFFSET TYPE VALUE
+0+2 R_MMIX_REG \.MMIX\.reg_contents
+
+Contents of section \.text:
+ 0000 232c0004 .*
+Contents of section \.data:
+ 0000 00000000 00000021 .*
+Contents of section \.MMIX\.reg_contents:
+ 0000 20000000 00000004 .*
--- /dev/null
+t IS @
+x IS Data_Segment+4
+
+ LOC x+4
+y OCTA 33
+ GREG x
+
+ LOC t
+Main LDA $44,y
--- /dev/null
+#objdump: -str
+
+# GAS must know that .data and expressions around #20 << 56 can be
+# equivalent for GREGs; like greg5 but the other way round.
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+ l d \.text 0+
+0+ l d \.data 0+
+0+ l d \.bss 0+
+0+ l \.text 0+ t
+2000000000000004 l \*ABS\* 0+ x
+2000000000000000 l \*ABS\* 0+ Data_Segment
+0+ l \.data 0+ y
+0+ l d \.MMIX\.reg_contents 0+
+0+ g F \.text 0+ Main
+2000000000000008 g \*ABS\* 0+ __\.MMIX\.start\.\.data
+
+
+RELOCATION RECORDS FOR \[\.text\]:
+OFFSET TYPE VALUE
+0+2 R_MMIX_REG \.MMIX\.reg_contents
+
+
+RELOCATION RECORDS FOR \[\.MMIX\.reg_contents\]:
+OFFSET TYPE VALUE
+0+ R_MMIX_64 \.data
+
+
+Contents of section \.text:
+ 0000 232c0054 .*
+Contents of section \.data:
+ 0000 00000000 00000021 .*
+Contents of section \.MMIX\.reg_contents:
+ 0000 00000000 00000000 .*
--- /dev/null
+t IS @
+x IS Data_Segment+4
+
+ LOC x+4
+y OCTA 33
+ GREG y
+
+ LOC t
+Main LDA $44,x+88
+
+
--- /dev/null
+#objdump: -str
+
+# GAS must know that .text and expressions around 0 can be equivalent for
+# GREGs.
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+ l d \.text 0+
+0+ l d \.data 0+
+0+ l d \.bss 0+
+0+ l \.text 0+ t
+0+4 l \*ABS\* 0+ x
+0+ l \.text 0+ y
+0+ l d \.MMIX\.reg_contents 0+
+0+8 g F \.text 0+ Main
+0+8 g \*ABS\* 0+ __\.MMIX\.start\.\.text
+
+
+RELOCATION RECORDS FOR \[\.text\]:
+OFFSET TYPE VALUE
+0+a R_MMIX_REG \.MMIX\.reg_contents
+
+Contents of section \.text:
+ 0000 00000000 00000021 232c0004 00000000 .*
+Contents of section \.data:
+Contents of section \.MMIX\.reg_contents:
+ 0000 00000000 00000004 .*
--- /dev/null
+t IS @
+x IS 4
+
+ LOC x+4
+y OCTA 33
+ GREG x
+
+Main LDA $44,y
--- /dev/null
+#objdump: -str
+
+# GAS must know that .text and expressions around 0 can be
+# equivalent for GREGs; like greg7 but the other way round.
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+ l d \.text 0+
+0+ l d \.data 0+
+0+ l d \.bss 0+
+0+ l \.text 0+ t
+0+4 l \*ABS\* 0+ x
+0+ l \.text 0+ y
+0+ l d \.MMIX\.reg_contents 0+
+0+8 g F \.text 0+ Main
+0+8 g \*ABS\* 0+ __\.MMIX\.start\.\.text
+
+
+RELOCATION RECORDS FOR \[\.text\]:
+OFFSET TYPE VALUE
+0+a R_MMIX_REG \.MMIX\.reg_contents
+
+
+RELOCATION RECORDS FOR \[\.MMIX\.reg_contents\]:
+OFFSET TYPE VALUE
+0+ R_MMIX_64 \.text
+
+Contents of section \.text:
+ 0000 00000000 00000021 232c0054 00000000 .*
+Contents of section \.data:
+Contents of section \.MMIX\.reg_contents:
+ 0000 00000000 00000000 .*
--- /dev/null
+t IS @
+x IS 4
+
+ LOC x+4
+y OCTA 33
+ GREG y
+
+Main LDA $44,x+88
+
+
--- /dev/null
+# objdump: -h
+
+.*: file format elf64-mmix
+
+Sections:
+Idx Name Size VMA LMA File off Algn
+ 0 \.text 0+4 0+ 0+ 0+40 2\*\*2
+ CONTENTS, ALLOC, LOAD, READONLY, CODE
+ 1 \.data 0+ 0+ 0+ 0+44 2\*\*0
+ CONTENTS, ALLOC, LOAD, DATA
+ 2 \.bss 0+ 0+ 0+ 0+44 2\*\*0
+ ALLOC
+ 3 \.MMIX\.reg_contents 0+6f0 0+ 0+ 0+44 2\*\*0
+ CONTENTS
--- /dev/null
+% Check that we can allocate max number of GREGs.
+% A bit cheesy: we allocate anonymous GREGs with no handle. This isn't
+% generally useful, but it helps keeping the number of lines down, and we
+% check that the right thing happened in the object file.
+Main SWYM 0
+ .rept 222
+ GREG
+ .endr
--- /dev/null
+# objdump: -dr
+# as: -linkrelax
+# source: hex.s
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: e3362009 setl \$54,0x2009
+ 4: e320125e setl \$32,0x125e
+ 8: e31f00b1 setl \$31,0xb1
--- /dev/null
+# objdump: -dr
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: e3362009 setl \$54,0x2009
+ 4: e320125e setl \$32,0x125e
+ 8: e31f00b1 setl \$31,0xb1
--- /dev/null
+GAS for MMIX .*/hex\.s page 1
+
+
+ 1 0000 E3362009 Main SETL \$54,#2009
+ 2 0004 E320125E SETL \$32,42\+#1234
+ 3 0008 E31F00B1 SETL \$31,#72\+63
+\fGAS for MMIX .*/hex\.s page 2
+
+
+DEFINED SYMBOLS
+.*/hex\.s:1 \.text:0000000000000000 Main
+
+NO UNDEFINED SYMBOLS
--- /dev/null
+Main SETL $54,#2009
+ SETL $32,42+#1234
+ SETL $31,#72+63
--- /dev/null
+#objdump: -str
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+ l d \.text 0+
+0+ l d \.data 0+
+0+ l d \.bss 0+
+
+Contents of section \.text:
+ 0+ 00000026 0000001f 0000000d 0000001e .*
+Contents of section \.data:
--- /dev/null
+# IS must handle a here-label.
+9H IS 30
+7H IS 8F+7
+6H IS 2F
+ TETRA 7B,8F,6B,9B
+8H IS 9B+1
+2H IS 13
--- /dev/null
+# objdump: -dr
+# source: jmp-op.s
+# as: -no-expand
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: fd000000 swym 0,0,0
+
+0000000000000004 <here>:
+ 4: fd000000 swym 0,0,0
+ 8: f1ffffff jmp 4 <here>
+
+000000000000000c <at>:
+ c: f0000000 jmp c <at>
+ 10: f0000004 jmp 20 <there>
+ 14: f1fffffc jmp 4 <here>
+ 18: f0000002 jmp 20 <there>
+ 1c: f1fffffa jmp 4 <here>
+
+0000000000000020 <there>:
+ 20: fd000000 swym 0,0,0
--- /dev/null
+# objdump: -dr
+# as: -linkrelax
+# source: jmp-op.s
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: fd000000 swym 0,0,0
+
+0000000000000004 <here>:
+ 4: fd000000 swym 0,0,0
+ 8: f1ffffff jmp 4 <here>
+ 8: R_MMIX_ADDR27 \.text\+0x4
+
+000000000000000c <at>:
+ c: f0000000 jmp c <at>
+ c: R_MMIX_ADDR27 \.text\+0xc
+ 10: f0000004 jmp 20 <there>
+ 10: R_MMIX_ADDR27 \.text\+0x20
+ 14: f1fffffc jmp 4 <here>
+ 14: R_MMIX_ADDR27 \.text\+0x4
+ 18: f0000002 jmp 20 <there>
+ 18: R_MMIX_ADDR27 \.text\+0x20
+ 1c: f1fffffa jmp 4 <here>
+ 1c: R_MMIX_ADDR27 \.text\+0x4
+
+0000000000000020 <there>:
+ 20: fd000000 swym 0,0,0
--- /dev/null
+# objdump: -dr
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: fd000000 swym 0,0,0
+
+0000000000000004 <here>:
+ 4: fd000000 swym 0,0,0
+ 8: f1ffffff jmp 4 <here>
+
+000000000000000c <at>:
+ c: f0000000 jmp c <at>
+ 10: f0000004 jmp 20 <there>
+ 14: f1fffffc jmp 4 <here>
+ 18: f0000002 jmp 20 <there>
+ 1c: f1fffffa jmp 4 <here>
+
+0000000000000020 <there>:
+ 20: fd000000 swym 0,0,0
--- /dev/null
+GAS for MMIX .*/jmp-op\.s page 1
+
+
+ 1 #.*
+ 2 0000 FD000000 Main SWYM 0,0,0
+ 3 0004 FD000000 here SWYM 0,0,0
+ 4 0008 F1FFFFFF JMP here
+ 5 000c F0000000 at JMP at
+ 6 0010 F0000004 JMP there
+ 7 0014 F1FFFFFC JMP here
+ 8 0018 F0000002 JMP there
+ 9 001c F1FFFFFA JMP here
+ 10 0020 FD000000 there SWYM 0,0,0
+\fGAS for MMIX .*/jmp-op\.s page 2
+
+
+DEFINED SYMBOLS
+.*/jmp-op\.s:2 \.text:0000000000000000 Main
+.*/jmp-op\.s:3 \.text:0000000000000004 here
+.*/jmp-op\.s:5 \.text:000000000000000c at
+.*/jmp-op\.s:10 \.text:0000000000000020 there
+
+NO UNDEFINED SYMBOLS
--- /dev/null
+# A small jumble of JMP:s.
+Main SWYM 0,0,0
+here SWYM 0,0,0
+ JMP here
+at JMP at
+ JMP there
+ JMP here
+ JMP there
+ JMP here
+there SWYM 0,0,0
--- /dev/null
+# objdump: -dr
+# as: -linkrelax -no-expand
+# source: jmp-op.s
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: fd000000 swym 0,0,0
+
+0000000000000004 <here>:
+ 4: fd000000 swym 0,0,0
+ 8: f0000000 jmp 8 <here\+0x4>
+ 8: R_MMIX_ADDR27 \.text\+0x4
+
+000000000000000c <at>:
+ c: f0000000 jmp c <at>
+ c: R_MMIX_ADDR27 \.text\+0xc
+ 10: f0000000 jmp 10 <at\+0x4>
+ 10: R_MMIX_ADDR27 \.text\+0x20
+ 14: f0000000 jmp 14 <at\+0x8>
+ 14: R_MMIX_ADDR27 \.text\+0x4
+ 18: f0000000 jmp 18 <at\+0xc>
+ 18: R_MMIX_ADDR27 \.text\+0x20
+ 1c: f0000000 jmp 1c <at\+0x10>
+ 1c: R_MMIX_ADDR27 \.text\+0x4
+
+0000000000000020 <there>:
+ 20: fd000000 swym 0,0,0
--- /dev/null
+#as: -x
+#objdump: -tdr
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+ l d .text 0+
+0+ l d .data 0+
+0+ l d .bss 0+
+ffff0000ffff0000 l \*ABS\* 0+ i1
+ffff0000ffff0000 l \*ABS\* 0+ i2
+0+ g F .text 0+ Main
+
+Disassembly of section .text:
+
+0+ <Main>:
+ 0: f0000000 jmp 0 <Main>
+ 0: R_MMIX_JMP \*ABS\*\+0xffff0000ffff0000
+ 4: fd000000 swym 0,0,0
+ 8: fd000000 swym 0,0,0
+ c: fd000000 swym 0,0,0
+ 10: fd000000 swym 0,0,0
+ 14: f0000000 jmp 14 <Main\+0x14>
+ 14: R_MMIX_JMP i2
+ 18: fd000000 swym 0,0,0
+ 1c: fd000000 swym 0,0,0
+ 20: fd000000 swym 0,0,0
+ 24: fd000000 swym 0,0,0
--- /dev/null
+% JMP with a large constant must not fail
+i1 IS #ffff0000ffff0000
+Main JMP i1
+ JMP i2
+i2 IS #ffff0000ffff0000
--- /dev/null
+# objdump: -dr
+# source: list-insns.s
+# as: -no-expand
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: 00000003 trap 0,0,3
+ 4: 00030405 trap 3,4,5
+ 8: 010c17f1 fcmp \$12,\$23,\$241
+ c: 08700129 flot \$112,ROUND_OFF,\$41
+ 10: 0970048d flot \$112,ROUND_NEAR,141
+ 14: 08bf00f2 flot \$191,\$242
+ 18: 09c3002a flot \$195,42
+ 1c: 027acb04 fun \$122,\$203,\$4
+ 20: 03661e28 feql \$102,\$30,\$40
+ 24: 0a66000e flotu \$102,\$14
+ 28: 0a84020e flotu \$132,ROUND_UP,\$14
+ 2c: 0a660368 flotu \$102,ROUND_DOWN,\$104
+ 30: 0aac048c flotu \$172,ROUND_NEAR,\$140
+ 34: 0a010186 flotu \$1,ROUND_OFF,\$134
+ 38: 0470df29 fadd \$112,\$223,\$41
+ 3c: 05700129 fix \$112,ROUND_OFF,\$41
+ 40: 050b008d fix \$11,\$141
+ 44: 0c700129 sflot \$112,ROUND_OFF,\$41
+ 48: 0d70048d sflot \$112,ROUND_NEAR,141
+ 4c: 0670df29 fsub \$112,\$223,\$41
+ 50: 0766000e fixu \$102,\$14
+ 54: 0784020e fixu \$132,ROUND_UP,\$14
+ 58: 0e0b008d sflotu \$11,\$141
+ 5c: 0f70008d sflotu \$112,141
+ 60: 0f70048d sflotu \$112,ROUND_NEAR,141
+ 64: 0e700129 sflotu \$112,ROUND_OFF,\$41
+ 68: 10661e28 fmul \$102,\$30,\$40
+ 6c: 110cdf01 fcmpe \$12,\$223,\$1
+ 70: 197acb2c mul \$122,\$203,44
+ 74: 18661e28 mul \$102,\$30,\$40
+ 78: 130cdf01 feqle \$12,\$223,\$1
+ 7c: 120cdf0b fune \$12,\$223,\$11
+ 80: 1b7ad52c mulu \$122,\$213,44
+ 84: 1a841e28 mulu \$132,\$30,\$40
+ 88: 140cdf0b fdiv \$12,\$223,\$11
+ 8c: 1584020e fsqrt \$132,ROUND_UP,\$14
+ 90: 150b008d fsqrt \$11,\$141
+ 94: 1d7ad52c div \$122,\$213,44
+ 98: 1c841e28 div \$132,\$30,\$40
+ 9c: 160cdf0b frem \$12,\$223,\$11
+ a0: 1784020e fint \$132,ROUND_UP,\$14
+ a4: 170b008d fint \$11,\$141
+ a8: 1e0cdf01 divu \$12,\$223,\$1
+ ac: 1f7acbff divu \$122,\$203,255
+ b0: 200cdf01 add \$12,\$223,\$1
+ b4: 217acbff add \$122,\$203,255
+ b8: 280cdf0b 2addu \$12,\$223,\$11
+ bc: 297acb00 2addu \$122,\$203,0
+ c0: 237acbff addu \$122,\$203,255
+ c4: 220cdf0b addu \$12,\$223,\$11
+ c8: 237acbff addu \$122,\$203,255
+ cc: 220cdf0b addu \$12,\$223,\$11
+ d0: 2b7acbcd 4addu \$122,\$203,205
+ d4: 2a0cdf6f 4addu \$12,\$223,\$111
+ d8: 240cdf0b sub \$12,\$223,\$11
+ dc: 257acbcd sub \$122,\$203,205
+ e0: 2c0cdf0b 8addu \$12,\$223,\$11
+ e4: 2d7acbcd 8addu \$122,\$203,205
+ e8: 2602df0b subu \$2,\$223,\$11
+ ec: 270c14cd subu \$12,\$20,205
+ f0: 2e02df0b 16addu \$2,\$223,\$11
+ f4: 2f0c14cd 16addu \$12,\$20,205
+ f8: 3002df0b cmp \$2,\$223,\$11
+ fc: 310c14cd cmp \$12,\$20,205
+ 100: 3802df0b sl \$2,\$223,\$11
+ 104: 390c14cd sl \$12,\$20,205
+ 108: 3202df0b cmpu \$2,\$223,\$11
+ 10c: 330c14cd cmpu \$12,\$20,205
+ 110: 3a02df0b slu \$2,\$223,\$11
+ 114: 3b0c14cd slu \$12,\$20,205
+ 118: 3402170b neg \$2,23,\$11
+ 11c: 350c00cd neg \$12,0,205
+ 120: 35c00acd neg \$192,10,205
+ 124: 3d0c14cd sr \$12,\$20,205
+ 128: 3c02df0b sr \$2,\$223,\$11
+ 12c: 3602170b negu \$2,23,\$11
+ 130: 370c00cd negu \$12,0,205
+ 134: 3f0c14cd sru \$12,\$20,205
+ 138: 3e02df0b sru \$2,\$223,\$11
+ 13c: 40020001 bn \$2,140 <Main\+0x140>
+ 140: 4102ffff bn \$2,13c <Main\+0x13c>
+ 144: 4902ffff bnn \$2,140 <Main\+0x140>
+ 148: 4902ffff bnn \$2,144 <Main\+0x144>
+ 14c: 42ff0001 bz \$255,150 <Main\+0x150>
+ 150: 43ffffff bz \$255,14c <Main\+0x14c>
+ 154: 4aff0001 bnz \$255,158 <Main\+0x158>
+ 158: 4bffffff bnz \$255,154 <Main\+0x154>
+ 15c: 44190001 bp \$25,160 <Main\+0x160>
+ 160: 4519ffff bp \$25,15c <Main\+0x15c>
+ 164: 4c190001 bnp \$25,168 <Main\+0x168>
+ 168: 4d19ffff bnp \$25,164 <Main\+0x164>
+ 16c: 46190001 bod \$25,170 <Main\+0x170>
+ 170: 4719ffff bod \$25,16c <Main\+0x16c>
+ 174: 4e190001 bev \$25,178 <Main\+0x178>
+ 178: 4f19ffff bev \$25,174 <Main\+0x174>
+ 17c: 50020001 pbn \$2,180 <Main\+0x180>
+ 180: 5102ffff pbn \$2,17c <Main\+0x17c>
+ 184: 58020001 pbnn \$2,188 <Main\+0x188>
+ 188: 5902ffff pbnn \$2,184 <Main\+0x184>
+ 18c: 520c0001 pbz \$12,190 <Main\+0x190>
+ 190: 5316ffff pbz \$22,18c <Main\+0x18c>
+ 194: 5a200001 pbnz \$32,198 <Main\+0x198>
+ 198: 5b34ffff pbnz \$52,194 <Main\+0x194>
+ 19c: 56190001 pbod \$25,1a0 <Main\+0x1a0>
+ 1a0: 5719ffff pbod \$25,19c <Main\+0x19c>
+ 1a4: 5e190001 pbev \$25,1a8 <Main\+0x1a8>
+ 1a8: 5f19ffff pbev \$25,1a4 <Main\+0x1a4>
+ 1ac: 6002df0b csn \$2,\$223,\$11
+ 1b0: 610c14cd csn \$12,\$20,205
+ 1b4: 6802df0b csnn \$2,\$223,\$11
+ 1b8: 690c14cd csnn \$12,\$20,205
+ 1bc: 6202cb0b csz \$2,\$203,\$11
+ 1c0: 630cc8cd csz \$12,\$200,205
+ 1c4: 6a02cb0b csnz \$2,\$203,\$11
+ 1c8: 6b0cc8cd csnz \$12,\$200,205
+ 1cc: 6402cb0b csp \$2,\$203,\$11
+ 1d0: 650cc8cd csp \$12,\$200,205
+ 1d4: 6c02cb0b csnp \$2,\$203,\$11
+ 1d8: 6d0cc8cd csnp \$12,\$200,205
+ 1dc: 6602cb0b csod \$2,\$203,\$11
+ 1e0: 670cc8cd csod \$12,\$200,205
+ 1e4: 6e02cb0b csev \$2,\$203,\$11
+ 1e8: 6f0cc8cd csev \$12,\$200,205
+ 1ec: 7002df0b zsn \$2,\$223,\$11
+ 1f0: 710c14cd zsn \$12,\$20,205
+ 1f4: 7802df0b zsnn \$2,\$223,\$11
+ 1f8: 790c14cd zsnn \$12,\$20,205
+ 1fc: 7202cb0b zsz \$2,\$203,\$11
+ 200: 730cc8cd zsz \$12,\$200,205
+ 204: 7a02cb0b zsnz \$2,\$203,\$11
+ 208: 7b0cc8cd zsnz \$12,\$200,205
+ 20c: 7402cb0b zsp \$2,\$203,\$11
+ 210: 750cc8cd zsp \$12,\$200,205
+ 214: 7c02cb0b zsnp \$2,\$203,\$11
+ 218: 7d0cc8cd zsnp \$12,\$200,205
+ 21c: 7602cb0b zsod \$2,\$203,\$11
+ 220: 770cc8cd zsod \$12,\$200,205
+ 224: 7e02cb0b zsev \$2,\$203,\$11
+ 228: 7f0cc8cd zsev \$12,\$200,205
+ 22c: 8002000b ldb \$2,\$0,\$11
+ 230: 810c14cd ldb \$12,\$20,205
+ 234: 8802000b ldt \$2,\$0,\$11
+ 238: 890c14cd ldt \$12,\$20,205
+ 23c: 8202000b ldbu \$2,\$0,\$11
+ 240: 830c14cd ldbu \$12,\$20,205
+ 244: 8a02000b ldtu \$2,\$0,\$11
+ 248: 8b0c14cd ldtu \$12,\$20,205
+ 24c: 8402000b ldw \$2,\$0,\$11
+ 250: 850c14cd ldw \$12,\$20,205
+ 254: 8c02000b ldo \$2,\$0,\$11
+ 258: 8d0c14cd ldo \$12,\$20,205
+ 25c: 8602000b ldwu \$2,\$0,\$11
+ 260: 870c14cd ldwu \$12,\$20,205
+ 264: 8e02000b ldou \$2,\$0,\$11
+ 268: 8f0c14cd ldou \$12,\$20,205
+ 26c: 9802000b ldvts \$2,\$0,\$11
+ 270: 990c14cd ldvts \$12,\$20,205
+ 274: 9202000b ldht \$2,\$0,\$11
+ 278: 930c14cd ldht \$12,\$20,205
+ 27c: 9b7014cd preld 112,\$20,205
+ 280: 9a7014e1 preld 112,\$20,\$225
+ 284: 9402000b cswap \$2,\$0,\$11
+ 288: 950c14cd cswap \$12,\$20,205
+ 28c: 9d7014cd prego 112,\$20,205
+ 290: 9c7014e1 prego 112,\$20,\$225
+ 294: 9602000b ldunc \$2,\$0,\$11
+ 298: 970c14cd ldunc \$12,\$20,205
+ 29c: 9e02000b go \$2,\$0,\$11
+ 2a0: 9f0c14cd go \$12,\$20,205
+ 2a4: a0020a97 stb \$2,\$10,\$151
+ 2a8: a10c14cd stb \$12,\$20,205
+ 2ac: a8200a97 stt \$32,\$10,\$151
+ 2b0: a90c14cd stt \$12,\$20,205
+ 2b4: a2020a97 stbu \$2,\$10,\$151
+ 2b8: a30c14cd stbu \$12,\$20,205
+ 2bc: aa200a97 sttu \$32,\$10,\$151
+ 2c0: ab0c14cd sttu \$12,\$20,205
+ 2c4: a4020a97 stw \$2,\$10,\$151
+ 2c8: a50cdccd stw \$12,\$220,205
+ 2cc: ac20aa97 sto \$32,\$170,\$151
+ 2d0: adb614f5 sto \$182,\$20,245
+ 2d4: a6020a97 stwu \$2,\$10,\$151
+ 2d8: a70cdccd stwu \$12,\$220,205
+ 2dc: ae20aa97 stou \$32,\$170,\$151
+ 2e0: afb614f5 stou \$182,\$20,245
+ 2e4: b020aa97 stsf \$32,\$170,\$151
+ 2e8: b1b614f5 stsf \$182,\$20,245
+ 2ec: b97014cd syncd 112,\$20,205
+ 2f0: b87014e1 syncd 112,\$20,\$225
+ 2f4: b220aa97 stht \$32,\$170,\$151
+ 2f8: b3b614f5 stht \$182,\$20,245
+ 2fc: bb7014cd prest 112,\$20,205
+ 300: ba7014e1 prest 112,\$20,\$225
+ 304: b420aa97 stco 32,\$170,\$151
+ 308: b5b614f5 stco 182,\$20,245
+ 30c: bd7014cd syncid 112,\$20,205
+ 310: bc0014e1 syncid 0,\$20,\$225
+ 314: b620aa97 stunc \$32,\$170,\$151
+ 318: b7b614f5 stunc \$182,\$20,245
+ 31c: be20aa97 pushgo \$32,\$170,\$151
+ 320: bfb614f5 pushgo \$182,\$20,245
+ 324: c18ec800 set \$142,\$200
+ 328: c020aa97 or \$32,\$170,\$151
+ 32c: c1b614f5 or \$182,\$20,245
+ 330: c820aa97 and \$32,\$170,\$151
+ 334: c9b614f5 and \$182,\$20,245
+ 338: c220aa97 orn \$32,\$170,\$151
+ 33c: c3b614f5 orn \$182,\$20,245
+ 340: ca20aa97 andn \$32,\$170,\$151
+ 344: cbb614f5 andn \$182,\$20,245
+ 348: c420aa97 nor \$32,\$170,\$151
+ 34c: c5b614f5 nor \$182,\$20,245
+ 350: cc20aa97 nand \$32,\$170,\$151
+ 354: cdb614f5 nand \$182,\$20,245
+ 358: c620aa97 xor \$32,\$170,\$151
+ 35c: c7b614f5 xor \$182,\$20,245
+ 360: ce20aa97 nxor \$32,\$170,\$151
+ 364: cfb614f5 nxor \$182,\$20,245
+ 368: d020aa97 bdif \$32,\$170,\$151
+ 36c: d1b614f5 bdif \$182,\$20,245
+ 370: d820aa97 mux \$32,\$170,\$151
+ 374: d9b614f5 mux \$182,\$20,245
+ 378: d220aa97 wdif \$32,\$170,\$151
+ 37c: d3b614f5 wdif \$182,\$20,245
+ 380: da20aa97 sadd \$32,\$170,\$151
+ 384: dbb600f5 sadd \$182,\$0,245
+ 388: d420aa97 tdif \$32,\$170,\$151
+ 38c: d5b614f5 tdif \$182,\$20,245
+ 390: dc20aa97 mor \$32,\$170,\$151
+ 394: ddb614f5 mor \$182,\$20,245
+ 398: d620aa97 odif \$32,\$170,\$151
+ 39c: d7b614f5 odif \$182,\$20,245
+ 3a0: de201197 mxor \$32,\$17,\$151
+ 3a4: df52b418 mxor \$82,\$180,24
+ 3a8: e004ffff seth \$4,0xffff
+ 3ac: e05e0000 seth \$94,0x0
+ 3b0: e00400ff seth \$4,0xff
+ 3b4: e05e04d2 seth \$94,0x4d2
+ 3b8: e15e04d2 setmh \$94,0x4d2
+ 3bc: e85e04d2 orh \$94,0x4d2
+ 3c0: e95e04d2 ormh \$94,0x4d2
+ 3c4: e25e04d2 setml \$94,0x4d2
+ 3c8: e35e04d2 setl \$94,0x4d2
+ 3cc: ea5e04d2 orml \$94,0x4d2
+ 3d0: eb5e04d2 orl \$94,0x4d2
+ 3d4: e45e04d2 inch \$94,0x4d2
+ 3d8: e55e04d2 incmh \$94,0x4d2
+ 3dc: ec5e04d2 andnh \$94,0x4d2
+ 3e0: ed5e04d2 andnmh \$94,0x4d2
+ 3e4: e65e04d2 incml \$94,0x4d2
+ 3e8: e75e04d2 incl \$94,0x4d2
+ 3ec: ee5e04d2 andnml \$94,0x4d2
+ 3f0: ef5e04d2 andnl \$94,0x4d2
+ 3f4: f1ffffff jmp 3f0 <Main\+0x3f0>
+ 3f8: f0000001 jmp 3fc <Main\+0x3fc>
+ 3fc: f82afffe pop 42,65534
+ 400: f90000ff resume 255
+ 404: f9000000 resume 0
+ 408: f9000001 resume 1
+ 40c: f2190001 pushj \$25,410 <Main\+0x410>
+ 410: f319ffff pushj \$25,40c <Main\+0x40c>
+ 414: fa040000 save \$4,0
+ 418: fb0000ea unsave 0,\$234
+ 41c: f4190001 geta \$25,420 <Main\+0x420>
+ 420: f519ffff geta \$25,41c <Main\+0x41c>
+ 424: fc7a1201 sync 8000001
+ 428: fd010203 swym 1,2,3
+ 42c: fd000000 swym 0,0,0
+ 430: f7040022 put rJ,34
+ 434: f6040086 put rJ,\$134
+ 438: feea0004 get \$234,rJ
+ 43c: ff000000 trip 0,0,0
+ 440: ff050607 trip 5,6,7
--- /dev/null
+# objdump: -dr
+# as: -linkrelax
+# source: list-insns.s
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: 00000003 trap 0,0,3
+ 4: 00030405 trap 3,4,5
+ 8: 010c17f1 fcmp \$12,\$23,\$241
+ c: 08700129 flot \$112,ROUND_OFF,\$41
+ 10: 0970048d flot \$112,ROUND_NEAR,141
+ 14: 08bf00f2 flot \$191,\$242
+ 18: 09c3002a flot \$195,42
+ 1c: 027acb04 fun \$122,\$203,\$4
+ 20: 03661e28 feql \$102,\$30,\$40
+ 24: 0a66000e flotu \$102,\$14
+ 28: 0a84020e flotu \$132,ROUND_UP,\$14
+ 2c: 0a660368 flotu \$102,ROUND_DOWN,\$104
+ 30: 0aac048c flotu \$172,ROUND_NEAR,\$140
+ 34: 0a010186 flotu \$1,ROUND_OFF,\$134
+ 38: 0470df29 fadd \$112,\$223,\$41
+ 3c: 05700129 fix \$112,ROUND_OFF,\$41
+ 40: 050b008d fix \$11,\$141
+ 44: 0c700129 sflot \$112,ROUND_OFF,\$41
+ 48: 0d70048d sflot \$112,ROUND_NEAR,141
+ 4c: 0670df29 fsub \$112,\$223,\$41
+ 50: 0766000e fixu \$102,\$14
+ 54: 0784020e fixu \$132,ROUND_UP,\$14
+ 58: 0e0b008d sflotu \$11,\$141
+ 5c: 0f70008d sflotu \$112,141
+ 60: 0f70048d sflotu \$112,ROUND_NEAR,141
+ 64: 0e700129 sflotu \$112,ROUND_OFF,\$41
+ 68: 10661e28 fmul \$102,\$30,\$40
+ 6c: 110cdf01 fcmpe \$12,\$223,\$1
+ 70: 197acb2c mul \$122,\$203,44
+ 74: 18661e28 mul \$102,\$30,\$40
+ 78: 130cdf01 feqle \$12,\$223,\$1
+ 7c: 120cdf0b fune \$12,\$223,\$11
+ 80: 1b7ad52c mulu \$122,\$213,44
+ 84: 1a841e28 mulu \$132,\$30,\$40
+ 88: 140cdf0b fdiv \$12,\$223,\$11
+ 8c: 1584020e fsqrt \$132,ROUND_UP,\$14
+ 90: 150b008d fsqrt \$11,\$141
+ 94: 1d7ad52c div \$122,\$213,44
+ 98: 1c841e28 div \$132,\$30,\$40
+ 9c: 160cdf0b frem \$12,\$223,\$11
+ a0: 1784020e fint \$132,ROUND_UP,\$14
+ a4: 170b008d fint \$11,\$141
+ a8: 1e0cdf01 divu \$12,\$223,\$1
+ ac: 1f7acbff divu \$122,\$203,255
+ b0: 200cdf01 add \$12,\$223,\$1
+ b4: 217acbff add \$122,\$203,255
+ b8: 280cdf0b 2addu \$12,\$223,\$11
+ bc: 297acb00 2addu \$122,\$203,0
+ c0: 237acbff addu \$122,\$203,255
+ c4: 220cdf0b addu \$12,\$223,\$11
+ c8: 237acbff addu \$122,\$203,255
+ cc: 220cdf0b addu \$12,\$223,\$11
+ d0: 2b7acbcd 4addu \$122,\$203,205
+ d4: 2a0cdf6f 4addu \$12,\$223,\$111
+ d8: 240cdf0b sub \$12,\$223,\$11
+ dc: 257acbcd sub \$122,\$203,205
+ e0: 2c0cdf0b 8addu \$12,\$223,\$11
+ e4: 2d7acbcd 8addu \$122,\$203,205
+ e8: 2602df0b subu \$2,\$223,\$11
+ ec: 270c14cd subu \$12,\$20,205
+ f0: 2e02df0b 16addu \$2,\$223,\$11
+ f4: 2f0c14cd 16addu \$12,\$20,205
+ f8: 3002df0b cmp \$2,\$223,\$11
+ fc: 310c14cd cmp \$12,\$20,205
+ 100: 3802df0b sl \$2,\$223,\$11
+ 104: 390c14cd sl \$12,\$20,205
+ 108: 3202df0b cmpu \$2,\$223,\$11
+ 10c: 330c14cd cmpu \$12,\$20,205
+ 110: 3a02df0b slu \$2,\$223,\$11
+ 114: 3b0c14cd slu \$12,\$20,205
+ 118: 3402170b neg \$2,23,\$11
+ 11c: 350c00cd neg \$12,0,205
+ 120: 35c00acd neg \$192,10,205
+ 124: 3d0c14cd sr \$12,\$20,205
+ 128: 3c02df0b sr \$2,\$223,\$11
+ 12c: 3602170b negu \$2,23,\$11
+ 130: 370c00cd negu \$12,0,205
+ 134: 3f0c14cd sru \$12,\$20,205
+ 138: 3e02df0b sru \$2,\$223,\$11
+ 13c: 40020001 bn \$2,140 <Main\+0x140>
+ 13c: R_MMIX_ADDR19 \.text\+0x140
+ 140: 4102ffff bn \$2,13c <Main\+0x13c>
+ 140: R_MMIX_ADDR19 \.text\+0x13c
+ 144: 4902ffff bnn \$2,140 <Main\+0x140>
+ 144: R_MMIX_ADDR19 \.text\+0x140
+ 148: 4902ffff bnn \$2,144 <Main\+0x144>
+ 148: R_MMIX_ADDR19 \.text\+0x144
+ 14c: 42ff0001 bz \$255,150 <Main\+0x150>
+ 14c: R_MMIX_ADDR19 \.text\+0x150
+ 150: 43ffffff bz \$255,14c <Main\+0x14c>
+ 150: R_MMIX_ADDR19 \.text\+0x14c
+ 154: 4aff0001 bnz \$255,158 <Main\+0x158>
+ 154: R_MMIX_ADDR19 \.text\+0x158
+ 158: 4bffffff bnz \$255,154 <Main\+0x154>
+ 158: R_MMIX_ADDR19 \.text\+0x154
+ 15c: 44190001 bp \$25,160 <Main\+0x160>
+ 15c: R_MMIX_ADDR19 \.text\+0x160
+ 160: 4519ffff bp \$25,15c <Main\+0x15c>
+ 160: R_MMIX_ADDR19 \.text\+0x15c
+ 164: 4c190001 bnp \$25,168 <Main\+0x168>
+ 164: R_MMIX_ADDR19 \.text\+0x168
+ 168: 4d19ffff bnp \$25,164 <Main\+0x164>
+ 168: R_MMIX_ADDR19 \.text\+0x164
+ 16c: 46190001 bod \$25,170 <Main\+0x170>
+ 16c: R_MMIX_ADDR19 \.text\+0x170
+ 170: 4719ffff bod \$25,16c <Main\+0x16c>
+ 170: R_MMIX_ADDR19 \.text\+0x16c
+ 174: 4e190001 bev \$25,178 <Main\+0x178>
+ 174: R_MMIX_ADDR19 \.text\+0x178
+ 178: 4f19ffff bev \$25,174 <Main\+0x174>
+ 178: R_MMIX_ADDR19 \.text\+0x174
+ 17c: 50020001 pbn \$2,180 <Main\+0x180>
+ 17c: R_MMIX_ADDR19 \.text\+0x180
+ 180: 5102ffff pbn \$2,17c <Main\+0x17c>
+ 180: R_MMIX_ADDR19 \.text\+0x17c
+ 184: 58020001 pbnn \$2,188 <Main\+0x188>
+ 184: R_MMIX_ADDR19 \.text\+0x188
+ 188: 5902ffff pbnn \$2,184 <Main\+0x184>
+ 188: R_MMIX_ADDR19 \.text\+0x184
+ 18c: 520c0001 pbz \$12,190 <Main\+0x190>
+ 18c: R_MMIX_ADDR19 \.text\+0x190
+ 190: 5316ffff pbz \$22,18c <Main\+0x18c>
+ 190: R_MMIX_ADDR19 \.text\+0x18c
+ 194: 5a200001 pbnz \$32,198 <Main\+0x198>
+ 194: R_MMIX_ADDR19 \.text\+0x198
+ 198: 5b34ffff pbnz \$52,194 <Main\+0x194>
+ 198: R_MMIX_ADDR19 \.text\+0x194
+ 19c: 56190001 pbod \$25,1a0 <Main\+0x1a0>
+ 19c: R_MMIX_ADDR19 \.text\+0x1a0
+ 1a0: 5719ffff pbod \$25,19c <Main\+0x19c>
+ 1a0: R_MMIX_ADDR19 \.text\+0x19c
+ 1a4: 5e190001 pbev \$25,1a8 <Main\+0x1a8>
+ 1a4: R_MMIX_ADDR19 \.text\+0x1a8
+ 1a8: 5f19ffff pbev \$25,1a4 <Main\+0x1a4>
+ 1a8: R_MMIX_ADDR19 \.text\+0x1a4
+ 1ac: 6002df0b csn \$2,\$223,\$11
+ 1b0: 610c14cd csn \$12,\$20,205
+ 1b4: 6802df0b csnn \$2,\$223,\$11
+ 1b8: 690c14cd csnn \$12,\$20,205
+ 1bc: 6202cb0b csz \$2,\$203,\$11
+ 1c0: 630cc8cd csz \$12,\$200,205
+ 1c4: 6a02cb0b csnz \$2,\$203,\$11
+ 1c8: 6b0cc8cd csnz \$12,\$200,205
+ 1cc: 6402cb0b csp \$2,\$203,\$11
+ 1d0: 650cc8cd csp \$12,\$200,205
+ 1d4: 6c02cb0b csnp \$2,\$203,\$11
+ 1d8: 6d0cc8cd csnp \$12,\$200,205
+ 1dc: 6602cb0b csod \$2,\$203,\$11
+ 1e0: 670cc8cd csod \$12,\$200,205
+ 1e4: 6e02cb0b csev \$2,\$203,\$11
+ 1e8: 6f0cc8cd csev \$12,\$200,205
+ 1ec: 7002df0b zsn \$2,\$223,\$11
+ 1f0: 710c14cd zsn \$12,\$20,205
+ 1f4: 7802df0b zsnn \$2,\$223,\$11
+ 1f8: 790c14cd zsnn \$12,\$20,205
+ 1fc: 7202cb0b zsz \$2,\$203,\$11
+ 200: 730cc8cd zsz \$12,\$200,205
+ 204: 7a02cb0b zsnz \$2,\$203,\$11
+ 208: 7b0cc8cd zsnz \$12,\$200,205
+ 20c: 7402cb0b zsp \$2,\$203,\$11
+ 210: 750cc8cd zsp \$12,\$200,205
+ 214: 7c02cb0b zsnp \$2,\$203,\$11
+ 218: 7d0cc8cd zsnp \$12,\$200,205
+ 21c: 7602cb0b zsod \$2,\$203,\$11
+ 220: 770cc8cd zsod \$12,\$200,205
+ 224: 7e02cb0b zsev \$2,\$203,\$11
+ 228: 7f0cc8cd zsev \$12,\$200,205
+ 22c: 8002000b ldb \$2,\$0,\$11
+ 230: 810c14cd ldb \$12,\$20,205
+ 234: 8802000b ldt \$2,\$0,\$11
+ 238: 890c14cd ldt \$12,\$20,205
+ 23c: 8202000b ldbu \$2,\$0,\$11
+ 240: 830c14cd ldbu \$12,\$20,205
+ 244: 8a02000b ldtu \$2,\$0,\$11
+ 248: 8b0c14cd ldtu \$12,\$20,205
+ 24c: 8402000b ldw \$2,\$0,\$11
+ 250: 850c14cd ldw \$12,\$20,205
+ 254: 8c02000b ldo \$2,\$0,\$11
+ 258: 8d0c14cd ldo \$12,\$20,205
+ 25c: 8602000b ldwu \$2,\$0,\$11
+ 260: 870c14cd ldwu \$12,\$20,205
+ 264: 8e02000b ldou \$2,\$0,\$11
+ 268: 8f0c14cd ldou \$12,\$20,205
+ 26c: 9802000b ldvts \$2,\$0,\$11
+ 270: 990c14cd ldvts \$12,\$20,205
+ 274: 9202000b ldht \$2,\$0,\$11
+ 278: 930c14cd ldht \$12,\$20,205
+ 27c: 9b7014cd preld 112,\$20,205
+ 280: 9a7014e1 preld 112,\$20,\$225
+ 284: 9402000b cswap \$2,\$0,\$11
+ 288: 950c14cd cswap \$12,\$20,205
+ 28c: 9d7014cd prego 112,\$20,205
+ 290: 9c7014e1 prego 112,\$20,\$225
+ 294: 9602000b ldunc \$2,\$0,\$11
+ 298: 970c14cd ldunc \$12,\$20,205
+ 29c: 9e02000b go \$2,\$0,\$11
+ 2a0: 9f0c14cd go \$12,\$20,205
+ 2a4: a0020a97 stb \$2,\$10,\$151
+ 2a8: a10c14cd stb \$12,\$20,205
+ 2ac: a8200a97 stt \$32,\$10,\$151
+ 2b0: a90c14cd stt \$12,\$20,205
+ 2b4: a2020a97 stbu \$2,\$10,\$151
+ 2b8: a30c14cd stbu \$12,\$20,205
+ 2bc: aa200a97 sttu \$32,\$10,\$151
+ 2c0: ab0c14cd sttu \$12,\$20,205
+ 2c4: a4020a97 stw \$2,\$10,\$151
+ 2c8: a50cdccd stw \$12,\$220,205
+ 2cc: ac20aa97 sto \$32,\$170,\$151
+ 2d0: adb614f5 sto \$182,\$20,245
+ 2d4: a6020a97 stwu \$2,\$10,\$151
+ 2d8: a70cdccd stwu \$12,\$220,205
+ 2dc: ae20aa97 stou \$32,\$170,\$151
+ 2e0: afb614f5 stou \$182,\$20,245
+ 2e4: b020aa97 stsf \$32,\$170,\$151
+ 2e8: b1b614f5 stsf \$182,\$20,245
+ 2ec: b97014cd syncd 112,\$20,205
+ 2f0: b87014e1 syncd 112,\$20,\$225
+ 2f4: b220aa97 stht \$32,\$170,\$151
+ 2f8: b3b614f5 stht \$182,\$20,245
+ 2fc: bb7014cd prest 112,\$20,205
+ 300: ba7014e1 prest 112,\$20,\$225
+ 304: b420aa97 stco 32,\$170,\$151
+ 308: b5b614f5 stco 182,\$20,245
+ 30c: bd7014cd syncid 112,\$20,205
+ 310: bc0014e1 syncid 0,\$20,\$225
+ 314: b620aa97 stunc \$32,\$170,\$151
+ 318: b7b614f5 stunc \$182,\$20,245
+ 31c: be20aa97 pushgo \$32,\$170,\$151
+ 320: bfb614f5 pushgo \$182,\$20,245
+ 324: c18ec800 set \$142,\$200
+ 328: c020aa97 or \$32,\$170,\$151
+ 32c: c1b614f5 or \$182,\$20,245
+ 330: c820aa97 and \$32,\$170,\$151
+ 334: c9b614f5 and \$182,\$20,245
+ 338: c220aa97 orn \$32,\$170,\$151
+ 33c: c3b614f5 orn \$182,\$20,245
+ 340: ca20aa97 andn \$32,\$170,\$151
+ 344: cbb614f5 andn \$182,\$20,245
+ 348: c420aa97 nor \$32,\$170,\$151
+ 34c: c5b614f5 nor \$182,\$20,245
+ 350: cc20aa97 nand \$32,\$170,\$151
+ 354: cdb614f5 nand \$182,\$20,245
+ 358: c620aa97 xor \$32,\$170,\$151
+ 35c: c7b614f5 xor \$182,\$20,245
+ 360: ce20aa97 nxor \$32,\$170,\$151
+ 364: cfb614f5 nxor \$182,\$20,245
+ 368: d020aa97 bdif \$32,\$170,\$151
+ 36c: d1b614f5 bdif \$182,\$20,245
+ 370: d820aa97 mux \$32,\$170,\$151
+ 374: d9b614f5 mux \$182,\$20,245
+ 378: d220aa97 wdif \$32,\$170,\$151
+ 37c: d3b614f5 wdif \$182,\$20,245
+ 380: da20aa97 sadd \$32,\$170,\$151
+ 384: dbb600f5 sadd \$182,\$0,245
+ 388: d420aa97 tdif \$32,\$170,\$151
+ 38c: d5b614f5 tdif \$182,\$20,245
+ 390: dc20aa97 mor \$32,\$170,\$151
+ 394: ddb614f5 mor \$182,\$20,245
+ 398: d620aa97 odif \$32,\$170,\$151
+ 39c: d7b614f5 odif \$182,\$20,245
+ 3a0: de201197 mxor \$32,\$17,\$151
+ 3a4: df52b418 mxor \$82,\$180,24
+ 3a8: e004ffff seth \$4,0xffff
+ 3ac: e05e0000 seth \$94,0x0
+ 3b0: e00400ff seth \$4,0xff
+ 3b4: e05e04d2 seth \$94,0x4d2
+ 3b8: e15e04d2 setmh \$94,0x4d2
+ 3bc: e85e04d2 orh \$94,0x4d2
+ 3c0: e95e04d2 ormh \$94,0x4d2
+ 3c4: e25e04d2 setml \$94,0x4d2
+ 3c8: e35e04d2 setl \$94,0x4d2
+ 3cc: ea5e04d2 orml \$94,0x4d2
+ 3d0: eb5e04d2 orl \$94,0x4d2
+ 3d4: e45e04d2 inch \$94,0x4d2
+ 3d8: e55e04d2 incmh \$94,0x4d2
+ 3dc: ec5e04d2 andnh \$94,0x4d2
+ 3e0: ed5e04d2 andnmh \$94,0x4d2
+ 3e4: e65e04d2 incml \$94,0x4d2
+ 3e8: e75e04d2 incl \$94,0x4d2
+ 3ec: ee5e04d2 andnml \$94,0x4d2
+ 3f0: ef5e04d2 andnl \$94,0x4d2
+ 3f4: f1ffffff jmp 3f0 <Main\+0x3f0>
+ 3f4: R_MMIX_ADDR27 \.text\+0x3f0
+ 3f8: f0000001 jmp 3fc <Main\+0x3fc>
+ 3f8: R_MMIX_ADDR27 \.text\+0x3fc
+ 3fc: f82afffe pop 42,65534
+ 400: f90000ff resume 255
+ 404: f9000000 resume 0
+ 408: f9000001 resume 1
+ 40c: f2190001 pushj \$25,410 <Main\+0x410>
+ 40c: R_MMIX_ADDR19 \.text\+0x410
+ 410: f319ffff pushj \$25,40c <Main\+0x40c>
+ 410: R_MMIX_ADDR19 \.text\+0x40c
+ 414: fa040000 save \$4,0
+ 418: fb0000ea unsave 0,\$234
+ 41c: f4190001 geta \$25,420 <Main\+0x420>
+ 41c: R_MMIX_ADDR19 \.text\+0x420
+ 420: f519ffff geta \$25,41c <Main\+0x41c>
+ 420: R_MMIX_ADDR19 \.text\+0x41c
+ 424: fc7a1201 sync 8000001
+ 428: fd010203 swym 1,2,3
+ 42c: fd000000 swym 0,0,0
+ 430: f7040022 put rJ,34
+ 434: f6040086 put rJ,\$134
+ 438: feea0004 get \$234,rJ
+ 43c: ff000000 trip 0,0,0
+ 440: ff050607 trip 5,6,7
--- /dev/null
+# objdump: -dr
+# as: -no-expand -linkrelax
+# source: list-insns.s
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: 00000003 trap 0,0,3
+ 4: 00030405 trap 3,4,5
+ 8: 010c17f1 fcmp \$12,\$23,\$241
+ c: 08700129 flot \$112,ROUND_OFF,\$41
+ 10: 0970048d flot \$112,ROUND_NEAR,141
+ 14: 08bf00f2 flot \$191,\$242
+ 18: 09c3002a flot \$195,42
+ 1c: 027acb04 fun \$122,\$203,\$4
+ 20: 03661e28 feql \$102,\$30,\$40
+ 24: 0a66000e flotu \$102,\$14
+ 28: 0a84020e flotu \$132,ROUND_UP,\$14
+ 2c: 0a660368 flotu \$102,ROUND_DOWN,\$104
+ 30: 0aac048c flotu \$172,ROUND_NEAR,\$140
+ 34: 0a010186 flotu \$1,ROUND_OFF,\$134
+ 38: 0470df29 fadd \$112,\$223,\$41
+ 3c: 05700129 fix \$112,ROUND_OFF,\$41
+ 40: 050b008d fix \$11,\$141
+ 44: 0c700129 sflot \$112,ROUND_OFF,\$41
+ 48: 0d70048d sflot \$112,ROUND_NEAR,141
+ 4c: 0670df29 fsub \$112,\$223,\$41
+ 50: 0766000e fixu \$102,\$14
+ 54: 0784020e fixu \$132,ROUND_UP,\$14
+ 58: 0e0b008d sflotu \$11,\$141
+ 5c: 0f70008d sflotu \$112,141
+ 60: 0f70048d sflotu \$112,ROUND_NEAR,141
+ 64: 0e700129 sflotu \$112,ROUND_OFF,\$41
+ 68: 10661e28 fmul \$102,\$30,\$40
+ 6c: 110cdf01 fcmpe \$12,\$223,\$1
+ 70: 197acb2c mul \$122,\$203,44
+ 74: 18661e28 mul \$102,\$30,\$40
+ 78: 130cdf01 feqle \$12,\$223,\$1
+ 7c: 120cdf0b fune \$12,\$223,\$11
+ 80: 1b7ad52c mulu \$122,\$213,44
+ 84: 1a841e28 mulu \$132,\$30,\$40
+ 88: 140cdf0b fdiv \$12,\$223,\$11
+ 8c: 1584020e fsqrt \$132,ROUND_UP,\$14
+ 90: 150b008d fsqrt \$11,\$141
+ 94: 1d7ad52c div \$122,\$213,44
+ 98: 1c841e28 div \$132,\$30,\$40
+ 9c: 160cdf0b frem \$12,\$223,\$11
+ a0: 1784020e fint \$132,ROUND_UP,\$14
+ a4: 170b008d fint \$11,\$141
+ a8: 1e0cdf01 divu \$12,\$223,\$1
+ ac: 1f7acbff divu \$122,\$203,255
+ b0: 200cdf01 add \$12,\$223,\$1
+ b4: 217acbff add \$122,\$203,255
+ b8: 280cdf0b 2addu \$12,\$223,\$11
+ bc: 297acb00 2addu \$122,\$203,0
+ c0: 237acbff addu \$122,\$203,255
+ c4: 220cdf0b addu \$12,\$223,\$11
+ c8: 237acbff addu \$122,\$203,255
+ cc: 220cdf0b addu \$12,\$223,\$11
+ d0: 2b7acbcd 4addu \$122,\$203,205
+ d4: 2a0cdf6f 4addu \$12,\$223,\$111
+ d8: 240cdf0b sub \$12,\$223,\$11
+ dc: 257acbcd sub \$122,\$203,205
+ e0: 2c0cdf0b 8addu \$12,\$223,\$11
+ e4: 2d7acbcd 8addu \$122,\$203,205
+ e8: 2602df0b subu \$2,\$223,\$11
+ ec: 270c14cd subu \$12,\$20,205
+ f0: 2e02df0b 16addu \$2,\$223,\$11
+ f4: 2f0c14cd 16addu \$12,\$20,205
+ f8: 3002df0b cmp \$2,\$223,\$11
+ fc: 310c14cd cmp \$12,\$20,205
+ 100: 3802df0b sl \$2,\$223,\$11
+ 104: 390c14cd sl \$12,\$20,205
+ 108: 3202df0b cmpu \$2,\$223,\$11
+ 10c: 330c14cd cmpu \$12,\$20,205
+ 110: 3a02df0b slu \$2,\$223,\$11
+ 114: 3b0c14cd slu \$12,\$20,205
+ 118: 3402170b neg \$2,23,\$11
+ 11c: 350c00cd neg \$12,0,205
+ 120: 35c00acd neg \$192,10,205
+ 124: 3d0c14cd sr \$12,\$20,205
+ 128: 3c02df0b sr \$2,\$223,\$11
+ 12c: 3602170b negu \$2,23,\$11
+ 130: 370c00cd negu \$12,0,205
+ 134: 3f0c14cd sru \$12,\$20,205
+ 138: 3e02df0b sru \$2,\$223,\$11
+ 13c: 40020000 bn \$2,.*
+ 13c: R_MMIX_ADDR19 \.text\+0x140
+ 140: 40020000 bn \$2,.*
+ 140: R_MMIX_ADDR19 \.text\+0x13c
+ 144: 48020000 bnn \$2,.*
+ 144: R_MMIX_ADDR19 \.text\+0x140
+ 148: 48020000 bnn \$2,.*
+ 148: R_MMIX_ADDR19 \.text\+0x144
+ 14c: 42ff0000 bz \$255,.*
+ 14c: R_MMIX_ADDR19 \.text\+0x150
+ 150: 42ff0000 bz \$255,.*
+ 150: R_MMIX_ADDR19 \.text\+0x14c
+ 154: 4aff0000 bnz \$255,.*
+ 154: R_MMIX_ADDR19 \.text\+0x158
+ 158: 4aff0000 bnz \$255,.*
+ 158: R_MMIX_ADDR19 \.text\+0x154
+ 15c: 44190000 bp \$25,.*
+ 15c: R_MMIX_ADDR19 \.text\+0x160
+ 160: 44190000 bp \$25,.*
+ 160: R_MMIX_ADDR19 \.text\+0x15c
+ 164: 4c190000 bnp \$25,.*
+ 164: R_MMIX_ADDR19 \.text\+0x168
+ 168: 4c190000 bnp \$25,.*
+ 168: R_MMIX_ADDR19 \.text\+0x164
+ 16c: 46190000 bod \$25,.*
+ 16c: R_MMIX_ADDR19 \.text\+0x170
+ 170: 46190000 bod \$25,.*
+ 170: R_MMIX_ADDR19 \.text\+0x16c
+ 174: 4e190000 bev \$25,.*
+ 174: R_MMIX_ADDR19 \.text\+0x178
+ 178: 4e190000 bev \$25,.*
+ 178: R_MMIX_ADDR19 \.text\+0x174
+ 17c: 50020000 pbn \$2,.*
+ 17c: R_MMIX_ADDR19 \.text\+0x180
+ 180: 50020000 pbn \$2,.*
+ 180: R_MMIX_ADDR19 \.text\+0x17c
+ 184: 58020000 pbnn \$2,.*
+ 184: R_MMIX_ADDR19 \.text\+0x188
+ 188: 58020000 pbnn \$2,.*
+ 188: R_MMIX_ADDR19 \.text\+0x184
+ 18c: 520c0000 pbz \$12,.*
+ 18c: R_MMIX_ADDR19 \.text\+0x190
+ 190: 52160000 pbz \$22,.*
+ 190: R_MMIX_ADDR19 \.text\+0x18c
+ 194: 5a200000 pbnz \$32,.*
+ 194: R_MMIX_ADDR19 \.text\+0x198
+ 198: 5a340000 pbnz \$52,.*
+ 198: R_MMIX_ADDR19 \.text\+0x194
+ 19c: 56190000 pbod \$25,.*
+ 19c: R_MMIX_ADDR19 \.text\+0x1a0
+ 1a0: 56190000 pbod \$25,.*
+ 1a0: R_MMIX_ADDR19 \.text\+0x19c
+ 1a4: 5e190000 pbev \$25,.*
+ 1a4: R_MMIX_ADDR19 \.text\+0x1a8
+ 1a8: 5e190000 pbev \$25,.*
+ 1a8: R_MMIX_ADDR19 \.text\+0x1a4
+ 1ac: 6002df0b csn \$2,\$223,\$11
+ 1b0: 610c14cd csn \$12,\$20,205
+ 1b4: 6802df0b csnn \$2,\$223,\$11
+ 1b8: 690c14cd csnn \$12,\$20,205
+ 1bc: 6202cb0b csz \$2,\$203,\$11
+ 1c0: 630cc8cd csz \$12,\$200,205
+ 1c4: 6a02cb0b csnz \$2,\$203,\$11
+ 1c8: 6b0cc8cd csnz \$12,\$200,205
+ 1cc: 6402cb0b csp \$2,\$203,\$11
+ 1d0: 650cc8cd csp \$12,\$200,205
+ 1d4: 6c02cb0b csnp \$2,\$203,\$11
+ 1d8: 6d0cc8cd csnp \$12,\$200,205
+ 1dc: 6602cb0b csod \$2,\$203,\$11
+ 1e0: 670cc8cd csod \$12,\$200,205
+ 1e4: 6e02cb0b csev \$2,\$203,\$11
+ 1e8: 6f0cc8cd csev \$12,\$200,205
+ 1ec: 7002df0b zsn \$2,\$223,\$11
+ 1f0: 710c14cd zsn \$12,\$20,205
+ 1f4: 7802df0b zsnn \$2,\$223,\$11
+ 1f8: 790c14cd zsnn \$12,\$20,205
+ 1fc: 7202cb0b zsz \$2,\$203,\$11
+ 200: 730cc8cd zsz \$12,\$200,205
+ 204: 7a02cb0b zsnz \$2,\$203,\$11
+ 208: 7b0cc8cd zsnz \$12,\$200,205
+ 20c: 7402cb0b zsp \$2,\$203,\$11
+ 210: 750cc8cd zsp \$12,\$200,205
+ 214: 7c02cb0b zsnp \$2,\$203,\$11
+ 218: 7d0cc8cd zsnp \$12,\$200,205
+ 21c: 7602cb0b zsod \$2,\$203,\$11
+ 220: 770cc8cd zsod \$12,\$200,205
+ 224: 7e02cb0b zsev \$2,\$203,\$11
+ 228: 7f0cc8cd zsev \$12,\$200,205
+ 22c: 8002000b ldb \$2,\$0,\$11
+ 230: 810c14cd ldb \$12,\$20,205
+ 234: 8802000b ldt \$2,\$0,\$11
+ 238: 890c14cd ldt \$12,\$20,205
+ 23c: 8202000b ldbu \$2,\$0,\$11
+ 240: 830c14cd ldbu \$12,\$20,205
+ 244: 8a02000b ldtu \$2,\$0,\$11
+ 248: 8b0c14cd ldtu \$12,\$20,205
+ 24c: 8402000b ldw \$2,\$0,\$11
+ 250: 850c14cd ldw \$12,\$20,205
+ 254: 8c02000b ldo \$2,\$0,\$11
+ 258: 8d0c14cd ldo \$12,\$20,205
+ 25c: 8602000b ldwu \$2,\$0,\$11
+ 260: 870c14cd ldwu \$12,\$20,205
+ 264: 8e02000b ldou \$2,\$0,\$11
+ 268: 8f0c14cd ldou \$12,\$20,205
+ 26c: 9802000b ldvts \$2,\$0,\$11
+ 270: 990c14cd ldvts \$12,\$20,205
+ 274: 9202000b ldht \$2,\$0,\$11
+ 278: 930c14cd ldht \$12,\$20,205
+ 27c: 9b7014cd preld 112,\$20,205
+ 280: 9a7014e1 preld 112,\$20,\$225
+ 284: 9402000b cswap \$2,\$0,\$11
+ 288: 950c14cd cswap \$12,\$20,205
+ 28c: 9d7014cd prego 112,\$20,205
+ 290: 9c7014e1 prego 112,\$20,\$225
+ 294: 9602000b ldunc \$2,\$0,\$11
+ 298: 970c14cd ldunc \$12,\$20,205
+ 29c: 9e02000b go \$2,\$0,\$11
+ 2a0: 9f0c14cd go \$12,\$20,205
+ 2a4: a0020a97 stb \$2,\$10,\$151
+ 2a8: a10c14cd stb \$12,\$20,205
+ 2ac: a8200a97 stt \$32,\$10,\$151
+ 2b0: a90c14cd stt \$12,\$20,205
+ 2b4: a2020a97 stbu \$2,\$10,\$151
+ 2b8: a30c14cd stbu \$12,\$20,205
+ 2bc: aa200a97 sttu \$32,\$10,\$151
+ 2c0: ab0c14cd sttu \$12,\$20,205
+ 2c4: a4020a97 stw \$2,\$10,\$151
+ 2c8: a50cdccd stw \$12,\$220,205
+ 2cc: ac20aa97 sto \$32,\$170,\$151
+ 2d0: adb614f5 sto \$182,\$20,245
+ 2d4: a6020a97 stwu \$2,\$10,\$151
+ 2d8: a70cdccd stwu \$12,\$220,205
+ 2dc: ae20aa97 stou \$32,\$170,\$151
+ 2e0: afb614f5 stou \$182,\$20,245
+ 2e4: b020aa97 stsf \$32,\$170,\$151
+ 2e8: b1b614f5 stsf \$182,\$20,245
+ 2ec: b97014cd syncd 112,\$20,205
+ 2f0: b87014e1 syncd 112,\$20,\$225
+ 2f4: b220aa97 stht \$32,\$170,\$151
+ 2f8: b3b614f5 stht \$182,\$20,245
+ 2fc: bb7014cd prest 112,\$20,205
+ 300: ba7014e1 prest 112,\$20,\$225
+ 304: b420aa97 stco 32,\$170,\$151
+ 308: b5b614f5 stco 182,\$20,245
+ 30c: bd7014cd syncid 112,\$20,205
+ 310: bc0014e1 syncid 0,\$20,\$225
+ 314: b620aa97 stunc \$32,\$170,\$151
+ 318: b7b614f5 stunc \$182,\$20,245
+ 31c: be20aa97 pushgo \$32,\$170,\$151
+ 320: bfb614f5 pushgo \$182,\$20,245
+ 324: c18ec800 set \$142,\$200
+ 328: c020aa97 or \$32,\$170,\$151
+ 32c: c1b614f5 or \$182,\$20,245
+ 330: c820aa97 and \$32,\$170,\$151
+ 334: c9b614f5 and \$182,\$20,245
+ 338: c220aa97 orn \$32,\$170,\$151
+ 33c: c3b614f5 orn \$182,\$20,245
+ 340: ca20aa97 andn \$32,\$170,\$151
+ 344: cbb614f5 andn \$182,\$20,245
+ 348: c420aa97 nor \$32,\$170,\$151
+ 34c: c5b614f5 nor \$182,\$20,245
+ 350: cc20aa97 nand \$32,\$170,\$151
+ 354: cdb614f5 nand \$182,\$20,245
+ 358: c620aa97 xor \$32,\$170,\$151
+ 35c: c7b614f5 xor \$182,\$20,245
+ 360: ce20aa97 nxor \$32,\$170,\$151
+ 364: cfb614f5 nxor \$182,\$20,245
+ 368: d020aa97 bdif \$32,\$170,\$151
+ 36c: d1b614f5 bdif \$182,\$20,245
+ 370: d820aa97 mux \$32,\$170,\$151
+ 374: d9b614f5 mux \$182,\$20,245
+ 378: d220aa97 wdif \$32,\$170,\$151
+ 37c: d3b614f5 wdif \$182,\$20,245
+ 380: da20aa97 sadd \$32,\$170,\$151
+ 384: dbb600f5 sadd \$182,\$0,245
+ 388: d420aa97 tdif \$32,\$170,\$151
+ 38c: d5b614f5 tdif \$182,\$20,245
+ 390: dc20aa97 mor \$32,\$170,\$151
+ 394: ddb614f5 mor \$182,\$20,245
+ 398: d620aa97 odif \$32,\$170,\$151
+ 39c: d7b614f5 odif \$182,\$20,245
+ 3a0: de201197 mxor \$32,\$17,\$151
+ 3a4: df52b418 mxor \$82,\$180,24
+ 3a8: e004ffff seth \$4,0xffff
+ 3ac: e05e0000 seth \$94,0x0
+ 3b0: e00400ff seth \$4,0xff
+ 3b4: e05e04d2 seth \$94,0x4d2
+ 3b8: e15e04d2 setmh \$94,0x4d2
+ 3bc: e85e04d2 orh \$94,0x4d2
+ 3c0: e95e04d2 ormh \$94,0x4d2
+ 3c4: e25e04d2 setml \$94,0x4d2
+ 3c8: e35e04d2 setl \$94,0x4d2
+ 3cc: ea5e04d2 orml \$94,0x4d2
+ 3d0: eb5e04d2 orl \$94,0x4d2
+ 3d4: e45e04d2 inch \$94,0x4d2
+ 3d8: e55e04d2 incmh \$94,0x4d2
+ 3dc: ec5e04d2 andnh \$94,0x4d2
+ 3e0: ed5e04d2 andnmh \$94,0x4d2
+ 3e4: e65e04d2 incml \$94,0x4d2
+ 3e8: e75e04d2 incl \$94,0x4d2
+ 3ec: ee5e04d2 andnml \$94,0x4d2
+ 3f0: ef5e04d2 andnl \$94,0x4d2
+ 3f4: f0000000 jmp .*
+ 3f4: R_MMIX_ADDR27 \.text\+0x3f0
+ 3f8: f0000000 jmp .*
+ 3f8: R_MMIX_ADDR27 \.text\+0x3fc
+ 3fc: f82afffe pop 42,65534
+ 400: f90000ff resume 255
+ 404: f9000000 resume 0
+ 408: f9000001 resume 1
+ 40c: f2190000 pushj \$25,.*
+ 40c: R_MMIX_ADDR19 \.text\+0x410
+ 410: f2190000 pushj \$25,.*
+ 410: R_MMIX_ADDR19 \.text\+0x40c
+ 414: fa040000 save \$4,0
+ 418: fb0000ea unsave 0,\$234
+ 41c: f4190000 geta \$25,.*
+ 41c: R_MMIX_ADDR19 \.text\+0x420
+ 420: f4190000 geta \$25,.*
+ 420: R_MMIX_ADDR19 \.text\+0x41c
+ 424: fc7a1201 sync 8000001
+ 428: fd010203 swym 1,2,3
+ 42c: fd000000 swym 0,0,0
+ 430: f7040022 put rJ,34
+ 434: f6040086 put rJ,\$134
+ 438: feea0004 get \$234,rJ
+ 43c: ff000000 trip 0,0,0
+ 440: ff050607 trip 5,6,7
--- /dev/null
+# objdump: -dr
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: 00000003 trap 0,0,3
+ 4: 00030405 trap 3,4,5
+ 8: 010c17f1 fcmp \$12,\$23,\$241
+ c: 08700129 flot \$112,ROUND_OFF,\$41
+ 10: 0970048d flot \$112,ROUND_NEAR,141
+ 14: 08bf00f2 flot \$191,\$242
+ 18: 09c3002a flot \$195,42
+ 1c: 027acb04 fun \$122,\$203,\$4
+ 20: 03661e28 feql \$102,\$30,\$40
+ 24: 0a66000e flotu \$102,\$14
+ 28: 0a84020e flotu \$132,ROUND_UP,\$14
+ 2c: 0a660368 flotu \$102,ROUND_DOWN,\$104
+ 30: 0aac048c flotu \$172,ROUND_NEAR,\$140
+ 34: 0a010186 flotu \$1,ROUND_OFF,\$134
+ 38: 0470df29 fadd \$112,\$223,\$41
+ 3c: 05700129 fix \$112,ROUND_OFF,\$41
+ 40: 050b008d fix \$11,\$141
+ 44: 0c700129 sflot \$112,ROUND_OFF,\$41
+ 48: 0d70048d sflot \$112,ROUND_NEAR,141
+ 4c: 0670df29 fsub \$112,\$223,\$41
+ 50: 0766000e fixu \$102,\$14
+ 54: 0784020e fixu \$132,ROUND_UP,\$14
+ 58: 0e0b008d sflotu \$11,\$141
+ 5c: 0f70008d sflotu \$112,141
+ 60: 0f70048d sflotu \$112,ROUND_NEAR,141
+ 64: 0e700129 sflotu \$112,ROUND_OFF,\$41
+ 68: 10661e28 fmul \$102,\$30,\$40
+ 6c: 110cdf01 fcmpe \$12,\$223,\$1
+ 70: 197acb2c mul \$122,\$203,44
+ 74: 18661e28 mul \$102,\$30,\$40
+ 78: 130cdf01 feqle \$12,\$223,\$1
+ 7c: 120cdf0b fune \$12,\$223,\$11
+ 80: 1b7ad52c mulu \$122,\$213,44
+ 84: 1a841e28 mulu \$132,\$30,\$40
+ 88: 140cdf0b fdiv \$12,\$223,\$11
+ 8c: 1584020e fsqrt \$132,ROUND_UP,\$14
+ 90: 150b008d fsqrt \$11,\$141
+ 94: 1d7ad52c div \$122,\$213,44
+ 98: 1c841e28 div \$132,\$30,\$40
+ 9c: 160cdf0b frem \$12,\$223,\$11
+ a0: 1784020e fint \$132,ROUND_UP,\$14
+ a4: 170b008d fint \$11,\$141
+ a8: 1e0cdf01 divu \$12,\$223,\$1
+ ac: 1f7acbff divu \$122,\$203,255
+ b0: 200cdf01 add \$12,\$223,\$1
+ b4: 217acbff add \$122,\$203,255
+ b8: 280cdf0b 2addu \$12,\$223,\$11
+ bc: 297acb00 2addu \$122,\$203,0
+ c0: 237acbff addu \$122,\$203,255
+ c4: 220cdf0b addu \$12,\$223,\$11
+ c8: 237acbff addu \$122,\$203,255
+ cc: 220cdf0b addu \$12,\$223,\$11
+ d0: 2b7acbcd 4addu \$122,\$203,205
+ d4: 2a0cdf6f 4addu \$12,\$223,\$111
+ d8: 240cdf0b sub \$12,\$223,\$11
+ dc: 257acbcd sub \$122,\$203,205
+ e0: 2c0cdf0b 8addu \$12,\$223,\$11
+ e4: 2d7acbcd 8addu \$122,\$203,205
+ e8: 2602df0b subu \$2,\$223,\$11
+ ec: 270c14cd subu \$12,\$20,205
+ f0: 2e02df0b 16addu \$2,\$223,\$11
+ f4: 2f0c14cd 16addu \$12,\$20,205
+ f8: 3002df0b cmp \$2,\$223,\$11
+ fc: 310c14cd cmp \$12,\$20,205
+ 100: 3802df0b sl \$2,\$223,\$11
+ 104: 390c14cd sl \$12,\$20,205
+ 108: 3202df0b cmpu \$2,\$223,\$11
+ 10c: 330c14cd cmpu \$12,\$20,205
+ 110: 3a02df0b slu \$2,\$223,\$11
+ 114: 3b0c14cd slu \$12,\$20,205
+ 118: 3402170b neg \$2,23,\$11
+ 11c: 350c00cd neg \$12,0,205
+ 120: 35c00acd neg \$192,10,205
+ 124: 3d0c14cd sr \$12,\$20,205
+ 128: 3c02df0b sr \$2,\$223,\$11
+ 12c: 3602170b negu \$2,23,\$11
+ 130: 370c00cd negu \$12,0,205
+ 134: 3f0c14cd sru \$12,\$20,205
+ 138: 3e02df0b sru \$2,\$223,\$11
+ 13c: 40020001 bn \$2,140 <Main\+0x140>
+ 140: 4102ffff bn \$2,13c <Main\+0x13c>
+ 144: 4902ffff bnn \$2,140 <Main\+0x140>
+ 148: 4902ffff bnn \$2,144 <Main\+0x144>
+ 14c: 42ff0001 bz \$255,150 <Main\+0x150>
+ 150: 43ffffff bz \$255,14c <Main\+0x14c>
+ 154: 4aff0001 bnz \$255,158 <Main\+0x158>
+ 158: 4bffffff bnz \$255,154 <Main\+0x154>
+ 15c: 44190001 bp \$25,160 <Main\+0x160>
+ 160: 4519ffff bp \$25,15c <Main\+0x15c>
+ 164: 4c190001 bnp \$25,168 <Main\+0x168>
+ 168: 4d19ffff bnp \$25,164 <Main\+0x164>
+ 16c: 46190001 bod \$25,170 <Main\+0x170>
+ 170: 4719ffff bod \$25,16c <Main\+0x16c>
+ 174: 4e190001 bev \$25,178 <Main\+0x178>
+ 178: 4f19ffff bev \$25,174 <Main\+0x174>
+ 17c: 50020001 pbn \$2,180 <Main\+0x180>
+ 180: 5102ffff pbn \$2,17c <Main\+0x17c>
+ 184: 58020001 pbnn \$2,188 <Main\+0x188>
+ 188: 5902ffff pbnn \$2,184 <Main\+0x184>
+ 18c: 520c0001 pbz \$12,190 <Main\+0x190>
+ 190: 5316ffff pbz \$22,18c <Main\+0x18c>
+ 194: 5a200001 pbnz \$32,198 <Main\+0x198>
+ 198: 5b34ffff pbnz \$52,194 <Main\+0x194>
+ 19c: 56190001 pbod \$25,1a0 <Main\+0x1a0>
+ 1a0: 5719ffff pbod \$25,19c <Main\+0x19c>
+ 1a4: 5e190001 pbev \$25,1a8 <Main\+0x1a8>
+ 1a8: 5f19ffff pbev \$25,1a4 <Main\+0x1a4>
+ 1ac: 6002df0b csn \$2,\$223,\$11
+ 1b0: 610c14cd csn \$12,\$20,205
+ 1b4: 6802df0b csnn \$2,\$223,\$11
+ 1b8: 690c14cd csnn \$12,\$20,205
+ 1bc: 6202cb0b csz \$2,\$203,\$11
+ 1c0: 630cc8cd csz \$12,\$200,205
+ 1c4: 6a02cb0b csnz \$2,\$203,\$11
+ 1c8: 6b0cc8cd csnz \$12,\$200,205
+ 1cc: 6402cb0b csp \$2,\$203,\$11
+ 1d0: 650cc8cd csp \$12,\$200,205
+ 1d4: 6c02cb0b csnp \$2,\$203,\$11
+ 1d8: 6d0cc8cd csnp \$12,\$200,205
+ 1dc: 6602cb0b csod \$2,\$203,\$11
+ 1e0: 670cc8cd csod \$12,\$200,205
+ 1e4: 6e02cb0b csev \$2,\$203,\$11
+ 1e8: 6f0cc8cd csev \$12,\$200,205
+ 1ec: 7002df0b zsn \$2,\$223,\$11
+ 1f0: 710c14cd zsn \$12,\$20,205
+ 1f4: 7802df0b zsnn \$2,\$223,\$11
+ 1f8: 790c14cd zsnn \$12,\$20,205
+ 1fc: 7202cb0b zsz \$2,\$203,\$11
+ 200: 730cc8cd zsz \$12,\$200,205
+ 204: 7a02cb0b zsnz \$2,\$203,\$11
+ 208: 7b0cc8cd zsnz \$12,\$200,205
+ 20c: 7402cb0b zsp \$2,\$203,\$11
+ 210: 750cc8cd zsp \$12,\$200,205
+ 214: 7c02cb0b zsnp \$2,\$203,\$11
+ 218: 7d0cc8cd zsnp \$12,\$200,205
+ 21c: 7602cb0b zsod \$2,\$203,\$11
+ 220: 770cc8cd zsod \$12,\$200,205
+ 224: 7e02cb0b zsev \$2,\$203,\$11
+ 228: 7f0cc8cd zsev \$12,\$200,205
+ 22c: 8002000b ldb \$2,\$0,\$11
+ 230: 810c14cd ldb \$12,\$20,205
+ 234: 8802000b ldt \$2,\$0,\$11
+ 238: 890c14cd ldt \$12,\$20,205
+ 23c: 8202000b ldbu \$2,\$0,\$11
+ 240: 830c14cd ldbu \$12,\$20,205
+ 244: 8a02000b ldtu \$2,\$0,\$11
+ 248: 8b0c14cd ldtu \$12,\$20,205
+ 24c: 8402000b ldw \$2,\$0,\$11
+ 250: 850c14cd ldw \$12,\$20,205
+ 254: 8c02000b ldo \$2,\$0,\$11
+ 258: 8d0c14cd ldo \$12,\$20,205
+ 25c: 8602000b ldwu \$2,\$0,\$11
+ 260: 870c14cd ldwu \$12,\$20,205
+ 264: 8e02000b ldou \$2,\$0,\$11
+ 268: 8f0c14cd ldou \$12,\$20,205
+ 26c: 9802000b ldvts \$2,\$0,\$11
+ 270: 990c14cd ldvts \$12,\$20,205
+ 274: 9202000b ldht \$2,\$0,\$11
+ 278: 930c14cd ldht \$12,\$20,205
+ 27c: 9b7014cd preld 112,\$20,205
+ 280: 9a7014e1 preld 112,\$20,\$225
+ 284: 9402000b cswap \$2,\$0,\$11
+ 288: 950c14cd cswap \$12,\$20,205
+ 28c: 9d7014cd prego 112,\$20,205
+ 290: 9c7014e1 prego 112,\$20,\$225
+ 294: 9602000b ldunc \$2,\$0,\$11
+ 298: 970c14cd ldunc \$12,\$20,205
+ 29c: 9e02000b go \$2,\$0,\$11
+ 2a0: 9f0c14cd go \$12,\$20,205
+ 2a4: a0020a97 stb \$2,\$10,\$151
+ 2a8: a10c14cd stb \$12,\$20,205
+ 2ac: a8200a97 stt \$32,\$10,\$151
+ 2b0: a90c14cd stt \$12,\$20,205
+ 2b4: a2020a97 stbu \$2,\$10,\$151
+ 2b8: a30c14cd stbu \$12,\$20,205
+ 2bc: aa200a97 sttu \$32,\$10,\$151
+ 2c0: ab0c14cd sttu \$12,\$20,205
+ 2c4: a4020a97 stw \$2,\$10,\$151
+ 2c8: a50cdccd stw \$12,\$220,205
+ 2cc: ac20aa97 sto \$32,\$170,\$151
+ 2d0: adb614f5 sto \$182,\$20,245
+ 2d4: a6020a97 stwu \$2,\$10,\$151
+ 2d8: a70cdccd stwu \$12,\$220,205
+ 2dc: ae20aa97 stou \$32,\$170,\$151
+ 2e0: afb614f5 stou \$182,\$20,245
+ 2e4: b020aa97 stsf \$32,\$170,\$151
+ 2e8: b1b614f5 stsf \$182,\$20,245
+ 2ec: b97014cd syncd 112,\$20,205
+ 2f0: b87014e1 syncd 112,\$20,\$225
+ 2f4: b220aa97 stht \$32,\$170,\$151
+ 2f8: b3b614f5 stht \$182,\$20,245
+ 2fc: bb7014cd prest 112,\$20,205
+ 300: ba7014e1 prest 112,\$20,\$225
+ 304: b420aa97 stco 32,\$170,\$151
+ 308: b5b614f5 stco 182,\$20,245
+ 30c: bd7014cd syncid 112,\$20,205
+ 310: bc0014e1 syncid 0,\$20,\$225
+ 314: b620aa97 stunc \$32,\$170,\$151
+ 318: b7b614f5 stunc \$182,\$20,245
+ 31c: be20aa97 pushgo \$32,\$170,\$151
+ 320: bfb614f5 pushgo \$182,\$20,245
+ 324: c18ec800 set \$142,\$200
+ 328: c020aa97 or \$32,\$170,\$151
+ 32c: c1b614f5 or \$182,\$20,245
+ 330: c820aa97 and \$32,\$170,\$151
+ 334: c9b614f5 and \$182,\$20,245
+ 338: c220aa97 orn \$32,\$170,\$151
+ 33c: c3b614f5 orn \$182,\$20,245
+ 340: ca20aa97 andn \$32,\$170,\$151
+ 344: cbb614f5 andn \$182,\$20,245
+ 348: c420aa97 nor \$32,\$170,\$151
+ 34c: c5b614f5 nor \$182,\$20,245
+ 350: cc20aa97 nand \$32,\$170,\$151
+ 354: cdb614f5 nand \$182,\$20,245
+ 358: c620aa97 xor \$32,\$170,\$151
+ 35c: c7b614f5 xor \$182,\$20,245
+ 360: ce20aa97 nxor \$32,\$170,\$151
+ 364: cfb614f5 nxor \$182,\$20,245
+ 368: d020aa97 bdif \$32,\$170,\$151
+ 36c: d1b614f5 bdif \$182,\$20,245
+ 370: d820aa97 mux \$32,\$170,\$151
+ 374: d9b614f5 mux \$182,\$20,245
+ 378: d220aa97 wdif \$32,\$170,\$151
+ 37c: d3b614f5 wdif \$182,\$20,245
+ 380: da20aa97 sadd \$32,\$170,\$151
+ 384: dbb600f5 sadd \$182,\$0,245
+ 388: d420aa97 tdif \$32,\$170,\$151
+ 38c: d5b614f5 tdif \$182,\$20,245
+ 390: dc20aa97 mor \$32,\$170,\$151
+ 394: ddb614f5 mor \$182,\$20,245
+ 398: d620aa97 odif \$32,\$170,\$151
+ 39c: d7b614f5 odif \$182,\$20,245
+ 3a0: de201197 mxor \$32,\$17,\$151
+ 3a4: df52b418 mxor \$82,\$180,24
+ 3a8: e004ffff seth \$4,0xffff
+ 3ac: e05e0000 seth \$94,0x0
+ 3b0: e00400ff seth \$4,0xff
+ 3b4: e05e04d2 seth \$94,0x4d2
+ 3b8: e15e04d2 setmh \$94,0x4d2
+ 3bc: e85e04d2 orh \$94,0x4d2
+ 3c0: e95e04d2 ormh \$94,0x4d2
+ 3c4: e25e04d2 setml \$94,0x4d2
+ 3c8: e35e04d2 setl \$94,0x4d2
+ 3cc: ea5e04d2 orml \$94,0x4d2
+ 3d0: eb5e04d2 orl \$94,0x4d2
+ 3d4: e45e04d2 inch \$94,0x4d2
+ 3d8: e55e04d2 incmh \$94,0x4d2
+ 3dc: ec5e04d2 andnh \$94,0x4d2
+ 3e0: ed5e04d2 andnmh \$94,0x4d2
+ 3e4: e65e04d2 incml \$94,0x4d2
+ 3e8: e75e04d2 incl \$94,0x4d2
+ 3ec: ee5e04d2 andnml \$94,0x4d2
+ 3f0: ef5e04d2 andnl \$94,0x4d2
+ 3f4: f1ffffff jmp 3f0 <Main\+0x3f0>
+ 3f8: f0000001 jmp 3fc <Main\+0x3fc>
+ 3fc: f82afffe pop 42,65534
+ 400: f90000ff resume 255
+ 404: f9000000 resume 0
+ 408: f9000001 resume 1
+ 40c: f2190001 pushj \$25,410 <Main\+0x410>
+ 410: f319ffff pushj \$25,40c <Main\+0x40c>
+ 414: fa040000 save \$4,0
+ 418: fb0000ea unsave 0,\$234
+ 41c: f4190001 geta \$25,420 <Main\+0x420>
+ 420: f519ffff geta \$25,41c <Main\+0x41c>
+ 424: fc7a1201 sync 8000001
+ 428: fd010203 swym 1,2,3
+ 42c: fd000000 swym 0,0,0
+ 430: f7040022 put rJ,34
+ 434: f6040086 put rJ,\$134
+ 438: feea0004 get \$234,rJ
+ 43c: ff000000 trip 0,0,0
+ 440: ff050607 trip 5,6,7
--- /dev/null
+GAS for MMIX .*/list-insns.s page 1
+
+
+ 1 #.*
+ 2 #.*
+ 3 #.*
+ 4 #.*
+ 5 #.*
+ 6 #.*
+ 7 0000 00000003 Main TETRA 3
+ 8 0004 00030405 TRAP 3,4,5
+ 9 0008 010C17F1 FCMP \$12,\$23,\$241
+ 10 000c 08700129 FLOT \$112,ROUND_OFF,\$41
+ 11 0010 0970048D FLOT \$112,ROUND_NEAR,141
+ 12 0014 08BF00F2 FLOT \$191,\$242
+ 13 0018 09C3002A FLOT \$195,42
+ 14 001c 027ACB04 FUN \$122,\$203,\$4
+ 15 0020 03661E28 FEQL \$102,\$30,\$40
+ 16 0024 0A66000E FLOTU \$102,\$14
+ 17 0028 0A84020E FLOTU \$132,ROUND_UP,\$14
+ 18 002c 0A660368 FLOTU \$102,ROUND_DOWN,\$104
+ 19 0030 0AAC048C FLOTU \$172,ROUND_NEAR,\$140
+ 20 0034 0A010186 FLOTU \$1,ROUND_OFF,\$134
+ 21 0038 0470DF29 FADD \$112,\$223,\$41
+ 22 003c 05700129 FIX \$112,ROUND_OFF,\$41
+ 23 0040 050B008D FIX \$11,\$141
+ 24 0044 0C700129 SFLOT \$112,ROUND_OFF,\$41
+ 25 0048 0D70048D SFLOT \$112,ROUND_NEAR,141
+ 26 004c 0670DF29 FSUB \$112,\$223,\$41
+ 27 0050 0766000E FIXU \$102,\$14
+ 28 0054 0784020E FIXU \$132,ROUND_UP,\$14
+ 29 0058 0E0B008D SFLOTU \$11,\$141
+ 30 005c 0F70008D SFLOTU \$112,141
+ 31 0060 0F70048D SFLOTU \$112,ROUND_NEAR,141
+ 32 0064 0E700129 SFLOTU \$112,ROUND_OFF,\$41
+ 33 0068 10661E28 FMUL \$102,\$30,\$40
+ 34 006c 110CDF01 FCMPE \$12,\$223,\$1
+ 35 0070 197ACB2C MUL \$122,\$203,44
+ 36 0074 18661E28 MUL \$102,\$30,\$40
+ 37 0078 130CDF01 FEQLE \$12,\$223,\$1
+ 38 007c 120CDF0B FUNE \$12,\$223,\$11
+ 39 0080 1B7AD52C MULU \$122,\$213,44
+ 40 0084 1A841E28 MULU \$132,\$30,\$40
+ 41 0088 140CDF0B FDIV \$12,\$223,\$11
+ 42 008c 1584020E FSQRT \$132,ROUND_UP,\$14
+ 43 0090 150B008D FSQRT \$11,\$141
+ 44 0094 1D7AD52C DIV \$122,\$213,44
+ 45 0098 1C841E28 DIV \$132,\$30,\$40
+ 46 009c 160CDF0B FREM \$12,\$223,\$11
+ 47 00a0 1784020E FINT \$132,ROUND_UP,\$14
+ 48 00a4 170B008D FINT \$11,\$141
+ 49 00a8 1E0CDF01 DIVU \$12,\$223,\$1
+ 50 00ac 1F7ACBFF DIVU \$122,\$203,255
+ 51 00b0 200CDF01 ADD \$12,\$223,\$1
+ 52 00b4 217ACBFF ADD \$122,\$203,255
+ 53 00b8 280CDF0B 2ADDU \$12,\$223,\$11
+ 54 00bc 297ACB00 2ADDU \$122,\$203,0
+ 55 00c0 237ACBFF ADDU \$122,\$203,255
+ 56 00c4 220CDF0B ADDU \$12,\$223,\$11
+ 57 00c8 237ACBFF LDA \$122,\$203,255
+\fGAS for MMIX .*/list-insns.s page 2
+
+
+ 58 00cc 220CDF0B LDA \$12,\$223,\$11
+ 59 00d0 2B7ACBCD 4ADDU \$122,\$203,205
+ 60 00d4 2A0CDF6F 4ADDU \$12,\$223,\$111
+ 61 00d8 240CDF0B SUB \$12,\$223,\$11
+ 62 00dc 257ACBCD SUB \$122,\$203,205
+ 63 00e0 2C0CDF0B 8ADDU \$12,\$223,\$11
+ 64 00e4 2D7ACBCD 8ADDU \$122,\$203,205
+ 65 00e8 2602DF0B SUBU \$2,\$223,\$11
+ 66 00ec 270C14CD SUBU \$12,\$20,205
+ 67 00f0 2E02DF0B 16ADDU \$2,\$223,\$11
+ 68 00f4 2F0C14CD 16ADDU \$12,\$20,205
+ 69 00f8 3002DF0B CMP \$2,\$223,\$11
+ 70 00fc 310C14CD CMP \$12,\$20,205
+ 71 0100 3802DF0B SL \$2,\$223,\$11
+ 72 0104 390C14CD SL \$12,\$20,205
+ 73 0108 3202DF0B CMPU \$2,\$223,\$11
+ 74 010c 330C14CD CMPU \$12,\$20,205
+ 75 0110 3A02DF0B SLU \$2,\$223,\$11
+ 76 0114 3B0C14CD SLU \$12,\$20,205
+ 77 0118 3402170B NEG \$2,23,\$11
+ 78 011c 350C00CD NEG \$12,0,205
+ 79 0120 35C00ACD NEG \$192,10,205
+ 80 0124 3D0C14CD SR \$12,\$20,205
+ 81 0128 3C02DF0B SR \$2,\$223,\$11
+ 82 012c 3602170B NEGU \$2,23,\$11
+ 83 0130 370C00CD NEGU \$12,0,205
+ 84 0134 3F0C14CD SRU \$12,\$20,205
+ 85 0138 3E02DF0B SRU \$2,\$223,\$11
+ 86 013c 40020001 1H BN \$2,2F
+ 87 0140 4102FFFF 2H BN \$2,1B
+ 88 0144 4902FFFF 1H BNN \$2,2B
+ 89 0148 4902FFFF 2H BNN \$2,1B
+ 90 014c 42FF0001 1H BZ \$255,2F
+ 91 0150 43FFFFFF 2H BZ \$255,1B
+ 92 0154 4AFF0001 1H BNZ \$255,2F
+ 93 0158 4BFFFFFF 2H BNZ \$255,1B
+ 94 015c 44190001 1H BP \$25,2F
+ 95 0160 4519FFFF 2H BP \$25,1B
+ 96 0164 4C190001 1H BNP \$25,2F
+ 97 0168 4D19FFFF 2H BNP \$25,1B
+ 98 016c 46190001 1H BOD \$25,2F
+ 99 0170 4719FFFF 2H BOD \$25,1B
+ 100 0174 4E190001 1H BEV \$25,2F
+ 101 0178 4F19FFFF 2H BEV \$25,1B
+ 102 017c 50020001 1H PBN \$2,2F
+ 103 0180 5102FFFF 2H PBN \$2,1B
+ 104 0184 58020001 1H PBNN \$2,2F
+ 105 0188 5902FFFF 2H PBNN \$2,1B
+ 106 018c 520C0001 1H PBZ \$12,2F
+ 107 0190 5316FFFF 2H PBZ \$22,1B
+ 108 0194 5A200001 1H PBNZ \$32,2F
+ 109 0198 5B34FFFF 2H PBNZ \$52,1B
+ 110 019c 56190001 1H PBOD \$25,2F
+ 111 01a0 5719FFFF 2H PBOD \$25,1B
+ 112 01a4 5E190001 1H PBEV \$25,2F
+ 113 01a8 5F19FFFF 2H PBEV \$25,1B
+ 114 01ac 6002DF0B CSN \$2,\$223,\$11
+\fGAS for MMIX .*/list-insns.s page 3
+
+
+ 115 01b0 610C14CD CSN \$12,\$20,205
+ 116 01b4 6802DF0B CSNN \$2,\$223,\$11
+ 117 01b8 690C14CD CSNN \$12,\$20,205
+ 118 01bc 6202CB0B CSZ \$2,\$203,\$11
+ 119 01c0 630CC8CD CSZ \$12,\$200,205
+ 120 01c4 6A02CB0B CSNZ \$2,\$203,\$11
+ 121 01c8 6B0CC8CD CSNZ \$12,\$200,205
+ 122 01cc 6402CB0B CSP \$2,\$203,\$11
+ 123 01d0 650CC8CD CSP \$12,\$200,205
+ 124 01d4 6C02CB0B CSNP \$2,\$203,\$11
+ 125 01d8 6D0CC8CD CSNP \$12,\$200,205
+ 126 01dc 6602CB0B CSOD \$2,\$203,\$11
+ 127 01e0 670CC8CD CSOD \$12,\$200,205
+ 128 01e4 6E02CB0B CSEV \$2,\$203,\$11
+ 129 01e8 6F0CC8CD CSEV \$12,\$200,205
+ 130 01ec 7002DF0B ZSN \$2,\$223,\$11
+ 131 01f0 710C14CD ZSN \$12,\$20,205
+ 132 01f4 7802DF0B ZSNN \$2,\$223,\$11
+ 133 01f8 790C14CD ZSNN \$12,\$20,205
+ 134 01fc 7202CB0B ZSZ \$2,\$203,\$11
+ 135 0200 730CC8CD ZSZ \$12,\$200,205
+ 136 0204 7A02CB0B ZSNZ \$2,\$203,\$11
+ 137 0208 7B0CC8CD ZSNZ \$12,\$200,205
+ 138 020c 7402CB0B ZSP \$2,\$203,\$11
+ 139 0210 750CC8CD ZSP \$12,\$200,205
+ 140 0214 7C02CB0B ZSNP \$2,\$203,\$11
+ 141 0218 7D0CC8CD ZSNP \$12,\$200,205
+ 142 021c 7602CB0B ZSOD \$2,\$203,\$11
+ 143 0220 770CC8CD ZSOD \$12,\$200,205
+ 144 0224 7E02CB0B ZSEV \$2,\$203,\$11
+ 145 0228 7F0CC8CD ZSEV \$12,\$200,205
+ 146 022c 8002000B LDB \$2,\$0,\$11
+ 147 0230 810C14CD LDB \$12,\$20,205
+ 148 0234 8802000B LDT \$2,\$0,\$11
+ 149 0238 890C14CD LDT \$12,\$20,205
+ 150 023c 8202000B LDBU \$2,\$0,\$11
+ 151 0240 830C14CD LDBU \$12,\$20,205
+ 152 0244 8A02000B LDTU \$2,\$0,\$11
+ 153 0248 8B0C14CD LDTU \$12,\$20,205
+ 154 024c 8402000B LDW \$2,\$0,\$11
+ 155 0250 850C14CD LDW \$12,\$20,205
+ 156 0254 8C02000B LDO \$2,\$0,\$11
+ 157 0258 8D0C14CD LDO \$12,\$20,205
+ 158 025c 8602000B LDWU \$2,\$0,\$11
+ 159 0260 870C14CD LDWU \$12,\$20,205
+ 160 0264 8E02000B LDOU \$2,\$0,\$11
+ 161 0268 8F0C14CD LDOU \$12,\$20,205
+ 162 026c 9802000B LDVTS \$2,\$0,\$11
+ 163 0270 990C14CD LDVTS \$12,\$20,205
+ 164 0274 9202000B LDHT \$2,\$0,\$11
+ 165 0278 930C14CD LDHT \$12,\$20,205
+ 166 027c 9B7014CD PRELD 112,\$20,205
+ 167 0280 9A7014E1 PRELD 112,\$20,\$225
+ 168 0284 9402000B CSWAP \$2,\$0,\$11
+ 169 0288 950C14CD CSWAP \$12,\$20,205
+ 170 028c 9D7014CD PREGO 112,\$20,205
+ 171 0290 9C7014E1 PREGO 112,\$20,\$225
+\fGAS for MMIX .*/list-insns.s page 4
+
+
+ 172 0294 9602000B LDUNC \$2,\$0,\$11
+ 173 0298 970C14CD LDUNC \$12,\$20,205
+ 174 029c 9E02000B GO \$2,\$0,\$11
+ 175 02a0 9F0C14CD GO \$12,\$20,205
+ 176 02a4 A0020A97 STB \$2,\$10,\$151
+ 177 02a8 A10C14CD STB \$12,\$20,205
+ 178 02ac A8200A97 STT \$32,\$10,\$151
+ 179 02b0 A90C14CD STT \$12,\$20,205
+ 180 02b4 A2020A97 STBU \$2,\$10,\$151
+ 181 02b8 A30C14CD STBU \$12,\$20,205
+ 182 02bc AA200A97 STTU \$32,\$10,\$151
+ 183 02c0 AB0C14CD STTU \$12,\$20,205
+ 184 02c4 A4020A97 STW \$2,\$10,\$151
+ 185 02c8 A50CDCCD STW \$12,\$220,205
+ 186 02cc AC20AA97 STO \$32,\$170,\$151
+ 187 02d0 ADB614F5 STO \$182,\$20,245
+ 188 02d4 A6020A97 STWU \$2,\$10,\$151
+ 189 02d8 A70CDCCD STWU \$12,\$220,205
+ 190 02dc AE20AA97 STOU \$32,\$170,\$151
+ 191 02e0 AFB614F5 STOU \$182,\$20,245
+ 192 02e4 B020AA97 STSF \$32,\$170,\$151
+ 193 02e8 B1B614F5 STSF \$182,\$20,245
+ 194 02ec B97014CD SYNCD 112,\$20,205
+ 195 02f0 B87014E1 SYNCD 112,\$20,\$225
+ 196 02f4 B220AA97 STHT \$32,\$170,\$151
+ 197 02f8 B3B614F5 STHT \$182,\$20,245
+ 198 02fc BB7014CD PREST 112,\$20,205
+ 199 0300 BA7014E1 PREST 112,\$20,\$225
+ 200 0304 B420AA97 STCO 32,\$170,\$151
+ 201 0308 B5B614F5 STCO 182,\$20,245
+ 202 030c BD7014CD SYNCID 112,\$20,205
+ 203 0310 BC0014E1 SYNCID 0,\$20,\$225
+ 204 0314 B620AA97 STUNC \$32,\$170,\$151
+ 205 0318 B7B614F5 STUNC \$182,\$20,245
+ 206 031c BE20AA97 PUSHGO \$32,\$170,\$151
+ 207 0320 BFB614F5 PUSHGO \$182,\$20,245
+ 208 0324 C18EC800 SET \$142,\$200
+ 209 0328 C020AA97 OR \$32,\$170,\$151
+ 210 032c C1B614F5 OR \$182,\$20,245
+ 211 0330 C820AA97 AND \$32,\$170,\$151
+ 212 0334 C9B614F5 AND \$182,\$20,245
+ 213 0338 C220AA97 ORN \$32,\$170,\$151
+ 214 033c C3B614F5 ORN \$182,\$20,245
+ 215 0340 CA20AA97 ANDN \$32,\$170,\$151
+ 216 0344 CBB614F5 ANDN \$182,\$20,245
+ 217 0348 C420AA97 NOR \$32,\$170,\$151
+ 218 034c C5B614F5 NOR \$182,\$20,245
+ 219 0350 CC20AA97 NAND \$32,\$170,\$151
+ 220 0354 CDB614F5 NAND \$182,\$20,245
+ 221 0358 C620AA97 XOR \$32,\$170,\$151
+ 222 035c C7B614F5 XOR \$182,\$20,245
+ 223 0360 CE20AA97 NXOR \$32,\$170,\$151
+ 224 0364 CFB614F5 NXOR \$182,\$20,245
+ 225 0368 D020AA97 BDIF \$32,\$170,\$151
+ 226 036c D1B614F5 BDIF \$182,\$20,245
+ 227 0370 D820AA97 MUX \$32,\$170,\$151
+ 228 0374 D9B614F5 MUX \$182,\$20,245
+\fGAS for MMIX .*/list-insns.s page 5
+
+
+ 229 0378 D220AA97 WDIF \$32,\$170,\$151
+ 230 037c D3B614F5 WDIF \$182,\$20,245
+ 231 0380 DA20AA97 SADD \$32,\$170,\$151
+ 232 0384 DBB600F5 SADD \$182,\$0,245
+ 233 0388 D420AA97 TDIF \$32,\$170,\$151
+ 234 038c D5B614F5 TDIF \$182,\$20,245
+ 235 0390 DC20AA97 MOR \$32,\$170,\$151
+ 236 0394 DDB614F5 MOR \$182,\$20,245
+ 237 0398 D620AA97 ODIF \$32,\$170,\$151
+ 238 039c D7B614F5 ODIF \$182,\$20,245
+ 239 03a0 DE201197 MXOR \$32,\$17,\$151
+ 240 03a4 DF52B418 MXOR \$82,\$180,24
+ 241 03a8 E004FFFF SETH \$4,65535
+ 242 03ac E05E0000 SETH \$94,0
+ 243 03b0 E00400FF SETH \$4,255
+ 244 03b4 E05E04D2 SETH \$94,1234
+ 245 03b8 E15E04D2 SETMH \$94,1234
+ 246 03bc E85E04D2 ORH \$94,1234
+ 247 03c0 E95E04D2 ORMH \$94,1234
+ 248 03c4 E25E04D2 SETML \$94,1234
+ 249 03c8 E35E04D2 SETL \$94,1234
+ 250 03cc EA5E04D2 ORML \$94,1234
+ 251 03d0 EB5E04D2 ORL \$94,1234
+ 252 03d4 E45E04D2 INCH \$94,1234
+ 253 03d8 E55E04D2 INCMH \$94,1234
+ 254 03dc EC5E04D2 ANDNH \$94,1234
+ 255 03e0 ED5E04D2 ANDNMH \$94,1234
+ 256 03e4 E65E04D2 INCML \$94,1234
+ 257 03e8 E75E04D2 INCL \$94,1234
+ 258 03ec EE5E04D2 ANDNML \$94,1234
+ 259 03f0 EF5E04D2 0H ANDNL \$94,1234
+ 260 03f4 F1FFFFFF JMP 0B
+ 261 03f8 F0000001 JMP 0F
+ 262 03fc F82AFFFE 0H POP 42,65534
+ 263 0400 F90000FF RESUME 255
+ 264 0404 F9000000 RESUME 0
+ 265 0408 F9000001 RESUME 1
+ 266 040c F2190001 1H PUSHJ \$25,2F
+ 267 0410 F319FFFF 2H PUSHJ \$25,1B
+ 268 0414 FA040000 SAVE \$4,0
+ 269 0418 FB0000EA UNSAVE 0,\$234
+ 270 041c F4190001 1H GETA \$25,2F
+ 271 0420 F519FFFF 2H GETA \$25,1B
+ 272 0424 FC7A1201 SYNC 8000001
+ 273 0428 FD010203 SWYM 1,2,3
+ 274 042c FD000000 SWYM 0,0,0
+ 275 0430 F7040022 PUT rJ,34
+ 276 0434 F6040086 PUT rJ,\$134
+ 277 0438 FEEA0004 GET \$234,rJ
+ 278 043c FF000000 TRIP 0,0,0
+ 279 0440 FF050607 TRIP 5,6,7
+\fGAS for MMIX .*/list-insns.s page 6
+
+
+DEFINED SYMBOLS
+.*/list-insns.s:7 .text:0000000000000000 Main
+
+NO UNDEFINED SYMBOLS
--- /dev/null
+#
+# Somewhat complete instruction set and operand type check. No
+# relocations or deferred register definitions here.
+#
+#
+#
+Main TETRA 3
+ TRAP 3,4,5
+ FCMP $12,$23,$241
+ FLOT $112,ROUND_OFF,$41
+ FLOT $112,ROUND_NEAR,141
+ FLOT $191,$242
+ FLOT $195,42
+ FUN $122,$203,$4
+ FEQL $102,$30,$40
+ FLOTU $102,$14
+ FLOTU $132,ROUND_UP,$14
+ FLOTU $102,ROUND_DOWN,$104
+ FLOTU $172,ROUND_NEAR,$140
+ FLOTU $1,ROUND_OFF,$134
+ FADD $112,$223,$41
+ FIX $112,ROUND_OFF,$41
+ FIX $11,$141
+ SFLOT $112,ROUND_OFF,$41
+ SFLOT $112,ROUND_NEAR,141
+ FSUB $112,$223,$41
+ FIXU $102,$14
+ FIXU $132,ROUND_UP,$14
+ SFLOTU $11,$141
+ SFLOTU $112,141
+ SFLOTU $112,ROUND_NEAR,141
+ SFLOTU $112,ROUND_OFF,$41
+ FMUL $102,$30,$40
+ FCMPE $12,$223,$1
+ MUL $122,$203,44
+ MUL $102,$30,$40
+ FEQLE $12,$223,$1
+ FUNE $12,$223,$11
+ MULU $122,$213,44
+ MULU $132,$30,$40
+ FDIV $12,$223,$11
+ FSQRT $132,ROUND_UP,$14
+ FSQRT $11,$141
+ DIV $122,$213,44
+ DIV $132,$30,$40
+ FREM $12,$223,$11
+ FINT $132,ROUND_UP,$14
+ FINT $11,$141
+ DIVU $12,$223,$1
+ DIVU $122,$203,255
+ ADD $12,$223,$1
+ ADD $122,$203,255
+ 2ADDU $12,$223,$11
+ 2ADDU $122,$203,0
+ ADDU $122,$203,255
+ ADDU $12,$223,$11
+ LDA $122,$203,255
+ LDA $12,$223,$11
+ 4ADDU $122,$203,205
+ 4ADDU $12,$223,$111
+ SUB $12,$223,$11
+ SUB $122,$203,205
+ 8ADDU $12,$223,$11
+ 8ADDU $122,$203,205
+ SUBU $2,$223,$11
+ SUBU $12,$20,205
+ 16ADDU $2,$223,$11
+ 16ADDU $12,$20,205
+ CMP $2,$223,$11
+ CMP $12,$20,205
+ SL $2,$223,$11
+ SL $12,$20,205
+ CMPU $2,$223,$11
+ CMPU $12,$20,205
+ SLU $2,$223,$11
+ SLU $12,$20,205
+ NEG $2,23,$11
+ NEG $12,0,205
+ NEG $192,10,205
+ SR $12,$20,205
+ SR $2,$223,$11
+ NEGU $2,23,$11
+ NEGU $12,0,205
+ SRU $12,$20,205
+ SRU $2,$223,$11
+1H BN $2,2F
+2H BN $2,1B
+1H BNN $2,2B
+2H BNN $2,1B
+1H BZ $255,2F
+2H BZ $255,1B
+1H BNZ $255,2F
+2H BNZ $255,1B
+1H BP $25,2F
+2H BP $25,1B
+1H BNP $25,2F
+2H BNP $25,1B
+1H BOD $25,2F
+2H BOD $25,1B
+1H BEV $25,2F
+2H BEV $25,1B
+1H PBN $2,2F
+2H PBN $2,1B
+1H PBNN $2,2F
+2H PBNN $2,1B
+1H PBZ $12,2F
+2H PBZ $22,1B
+1H PBNZ $32,2F
+2H PBNZ $52,1B
+1H PBOD $25,2F
+2H PBOD $25,1B
+1H PBEV $25,2F
+2H PBEV $25,1B
+ CSN $2,$223,$11
+ CSN $12,$20,205
+ CSNN $2,$223,$11
+ CSNN $12,$20,205
+ CSZ $2,$203,$11
+ CSZ $12,$200,205
+ CSNZ $2,$203,$11
+ CSNZ $12,$200,205
+ CSP $2,$203,$11
+ CSP $12,$200,205
+ CSNP $2,$203,$11
+ CSNP $12,$200,205
+ CSOD $2,$203,$11
+ CSOD $12,$200,205
+ CSEV $2,$203,$11
+ CSEV $12,$200,205
+ ZSN $2,$223,$11
+ ZSN $12,$20,205
+ ZSNN $2,$223,$11
+ ZSNN $12,$20,205
+ ZSZ $2,$203,$11
+ ZSZ $12,$200,205
+ ZSNZ $2,$203,$11
+ ZSNZ $12,$200,205
+ ZSP $2,$203,$11
+ ZSP $12,$200,205
+ ZSNP $2,$203,$11
+ ZSNP $12,$200,205
+ ZSOD $2,$203,$11
+ ZSOD $12,$200,205
+ ZSEV $2,$203,$11
+ ZSEV $12,$200,205
+ LDB $2,$0,$11
+ LDB $12,$20,205
+ LDT $2,$0,$11
+ LDT $12,$20,205
+ LDBU $2,$0,$11
+ LDBU $12,$20,205
+ LDTU $2,$0,$11
+ LDTU $12,$20,205
+ LDW $2,$0,$11
+ LDW $12,$20,205
+ LDO $2,$0,$11
+ LDO $12,$20,205
+ LDWU $2,$0,$11
+ LDWU $12,$20,205
+ LDOU $2,$0,$11
+ LDOU $12,$20,205
+ LDVTS $2,$0,$11
+ LDVTS $12,$20,205
+ LDHT $2,$0,$11
+ LDHT $12,$20,205
+ PRELD 112,$20,205
+ PRELD 112,$20,$225
+ CSWAP $2,$0,$11
+ CSWAP $12,$20,205
+ PREGO 112,$20,205
+ PREGO 112,$20,$225
+ LDUNC $2,$0,$11
+ LDUNC $12,$20,205
+ GO $2,$0,$11
+ GO $12,$20,205
+ STB $2,$10,$151
+ STB $12,$20,205
+ STT $32,$10,$151
+ STT $12,$20,205
+ STBU $2,$10,$151
+ STBU $12,$20,205
+ STTU $32,$10,$151
+ STTU $12,$20,205
+ STW $2,$10,$151
+ STW $12,$220,205
+ STO $32,$170,$151
+ STO $182,$20,245
+ STWU $2,$10,$151
+ STWU $12,$220,205
+ STOU $32,$170,$151
+ STOU $182,$20,245
+ STSF $32,$170,$151
+ STSF $182,$20,245
+ SYNCD 112,$20,205
+ SYNCD 112,$20,$225
+ STHT $32,$170,$151
+ STHT $182,$20,245
+ PREST 112,$20,205
+ PREST 112,$20,$225
+ STCO 32,$170,$151
+ STCO 182,$20,245
+ SYNCID 112,$20,205
+ SYNCID 0,$20,$225
+ STUNC $32,$170,$151
+ STUNC $182,$20,245
+ PUSHGO $32,$170,$151
+ PUSHGO $182,$20,245
+ SET $142,$200
+ OR $32,$170,$151
+ OR $182,$20,245
+ AND $32,$170,$151
+ AND $182,$20,245
+ ORN $32,$170,$151
+ ORN $182,$20,245
+ ANDN $32,$170,$151
+ ANDN $182,$20,245
+ NOR $32,$170,$151
+ NOR $182,$20,245
+ NAND $32,$170,$151
+ NAND $182,$20,245
+ XOR $32,$170,$151
+ XOR $182,$20,245
+ NXOR $32,$170,$151
+ NXOR $182,$20,245
+ BDIF $32,$170,$151
+ BDIF $182,$20,245
+ MUX $32,$170,$151
+ MUX $182,$20,245
+ WDIF $32,$170,$151
+ WDIF $182,$20,245
+ SADD $32,$170,$151
+ SADD $182,$0,245
+ TDIF $32,$170,$151
+ TDIF $182,$20,245
+ MOR $32,$170,$151
+ MOR $182,$20,245
+ ODIF $32,$170,$151
+ ODIF $182,$20,245
+ MXOR $32,$17,$151
+ MXOR $82,$180,24
+ SETH $4,65535
+ SETH $94,0
+ SETH $4,255
+ SETH $94,1234
+ SETMH $94,1234
+ ORH $94,1234
+ ORMH $94,1234
+ SETML $94,1234
+ SETL $94,1234
+ ORML $94,1234
+ ORL $94,1234
+ INCH $94,1234
+ INCMH $94,1234
+ ANDNH $94,1234
+ ANDNMH $94,1234
+ INCML $94,1234
+ INCL $94,1234
+ ANDNML $94,1234
+0H ANDNL $94,1234
+ JMP 0B
+ JMP 0F
+0H POP 42,65534
+ RESUME 255
+ RESUME 0
+ RESUME 1
+1H PUSHJ $25,2F
+2H PUSHJ $25,1B
+ SAVE $4,0
+ UNSAVE 0,$234
+1H GETA $25,2F
+2H GETA $25,1B
+ SYNC 8000001
+ SWYM 1,2,3
+ SWYM 0,0,0
+ PUT rJ,34
+ PUT rJ,$134
+ GET $234,rJ
+ TRIP 0,0,0
+ TRIP 5,6,7
--- /dev/null
+GAS for MMIX .*/list-pseudoints.s page 1
+
+
+ 1 start
+ 2 0000 424344EE tetra 0x424344ee
+ 3 start2
+ 4 0004 00000000 octa 0xde0045007821329e
+ 4 DE004500
+ 4 7821329E
+ 5 0010 07D9 wyde 2009
+ 6 0012 99000000 byte 0x99
+ 6 0000
+\fGAS for MMIX .*/list-pseudoints.s page 2
+
+
+DEFINED SYMBOLS
+.*/list-pseudoints.s:1 .text:0000000000000000 start
+.*/list-pseudoints.s:3 .text:0000000000000004 start2
+
+NO UNDEFINED SYMBOLS
--- /dev/null
+start
+ tetra 0x424344ee
+start2
+ octa 0xde0045007821329e
+ wyde 2009
+ byte 0x99
--- /dev/null
+ data
+here:
+ tetra 42
+.text
+ set $1,$2
--- /dev/null
+GAS for MMIX .*/list-textfirst\.s page 1
+
+
+ 1 \.data
+ 2 here:
+ 3 0000 0000002A tetra 42
+ 4 \.text
+ 5 there:
+ 6 0000 EA \.byte 0xea
+\fGAS for MMIX .*/list-textfirst\.s page 2
+
+
+DEFINED SYMBOLS
+.*/list-textfirst\.s:2 \.data:0000000000000000 here
+.*/list-textfirst\.s:5 \.text:0000000000000000 there
+
+NO UNDEFINED SYMBOLS
--- /dev/null
+ .data
+here:
+ tetra 42
+.text
+there:
+ .byte 0xea
--- /dev/null
+#readelf: -Ssrx1 -x2
+
+There are 7 section headers, starting at offset 0x90:
+
+Section Headers:
+ \[Nr\] Name Type Address Offset
+ Size EntSize Flags Link Info Align
+ \[ 0\] NULL 0000000000000000 00000000
+ 0000000000000000 0000000000000000 0 0 0
+ \[ 1\] \.text PROGBITS 0000000000000000 00000040
+ 0000000000000020 0000000000000000 AX 0 0 4
+ \[ 2\] \.data PROGBITS 0000000000000000 00000060
+ 0000000000000004 0000000000000000 WA 0 0 4
+ \[ 3\] \.bss NOBITS 0000000000000000 00000064
+ 0000000000000000 0000000000000000 WA 0 0 1
+ \[ 4\] \.shstrtab STRTAB 0000000000000000 00000064
+ 000000000000002c 0000000000000000 0 0 1
+ \[ 5\] \.symtab SYMTAB 0000000000000000 00000250
+ 00000000000000c0 0000000000000018 6 6 8
+ \[ 6\] \.strtab STRTAB 0000000000000000 00000310
+ 000000000000002a 0000000000000000 0 0 1
+Key to Flags:
+ W \(write\), A \(alloc\), X \(execute\), M \(merge\), S \(strings\)
+ I \(info\), L \(link order\), G \(group\), x \(unknown\)
+ O \(extra OS processing required\) o \(OS specific\), p \(processor specific\)
+
+There are no relocations in this file\.
+
+Symbol table '\.symtab' contains 8 entries:
+ Num: Value Size Type Bind Vis Ndx Name
+ 0: 0+ 0 NOTYPE LOCAL DEFAULT UND
+ 1: 0+ 0 SECTION LOCAL DEFAULT 1
+ 2: 0+ 0 SECTION LOCAL DEFAULT 2
+ 3: 0+ 0 SECTION LOCAL DEFAULT 3
+ 4: 0+4 0 NOTYPE LOCAL DEFAULT 1 m2
+ 5: 2000000000000000 0 NOTYPE LOCAL DEFAULT ABS Data_Segment
+ 6: 0+ 0 FUNC GLOBAL DEFAULT 1 Main
+ 7: 2000000000000000 0 NOTYPE GLOBAL DEFAULT ABS __\.MMIX\.start\.\.data
+
+Hex dump of section '\.text':
+ 0x00000000 fd000000 00000000 00000000 00000000 .*
+ 0x00000010 00000000 00000000 00000000 fd010203 .*
+
+Hex dump of section '\.data':
+ 0x00000000 00000004 .*
--- /dev/null
+# Check that we don't get anything strange from a single LOC to data and a
+# LOC back (with an offset).
+Main SWYM 0,0,0
+m2 LOC Data_Segment
+ TETRA 4
+ LOC m2+24
+ SWYM 1,2,3
--- /dev/null
+#readelf: -Ssrx1
+
+There are 7 section headers, starting at offset 0x78:
+
+Section Headers:
+ \[Nr\] Name Type Address Offset
+ Size EntSize Flags Link Info Align
+ \[ 0\] NULL 0000000000000000 00000000
+ 0000000000000000 0000000000000000 0 0 0
+ \[ 1\] \.text PROGBITS 0000000000000000 00000040
+ 0000000000000008 0000000000000000 AX 0 0 4
+ \[ 2\] \.data PROGBITS 0000000000000000 00000048
+ 0000000000000000 0000000000000000 WA 0 0 1
+ \[ 3\] \.bss NOBITS 0000000000000000 00000048
+ 0000000000000000 0000000000000000 WA 0 0 1
+ \[ 4\] \.shstrtab STRTAB 0000000000000000 00000048
+ 000000000000002c 0000000000000000 0 0 1
+ \[ 5\] \.symtab SYMTAB 0000000000000000 00000238
+ 0000000000000090 0000000000000018 6 4 8
+ \[ 6\] \.strtab STRTAB 0000000000000000 000002c8
+ 000000000000001a 0000000000000000 0 0 1
+Key to Flags:
+ W \(write\), A \(alloc\), X \(execute\), M \(merge\), S \(strings\)
+ I \(info\), L \(link order\), G \(group\), x \(unknown\)
+ O \(extra OS processing required\) o \(OS specific\), p \(processor specific\)
+
+There are no relocations in this file\.
+
+Symbol table '\.symtab' contains 6 entries:
+ Num: Value Size Type Bind Vis Ndx Name
+ 0: 0+ 0 NOTYPE LOCAL DEFAULT UND
+ 1: 0+ 0 SECTION LOCAL DEFAULT 1
+ 2: 0+ 0 SECTION LOCAL DEFAULT 2
+ 3: 0+ 0 SECTION LOCAL DEFAULT 3
+ 4: 0+4 0 FUNC GLOBAL DEFAULT 1 Main
+ 5: 0+100 0 NOTYPE GLOBAL DEFAULT ABS __\.MMIX\.start\.\.text
+
+Hex dump of section '\.text':
+ 0x00000000 fd010102 fd000070 .*
--- /dev/null
+# Check that a LOC before any code gets translated into the right
+# symbol being set.
+ LOC 256
+ SWYM 1,1,2
+Main SWYM 112
--- /dev/null
+#readelf: -Ssrx1 -x2
+There are 7 section headers, starting at offset 0x80:
+
+Section Headers:
+ \[Nr\] Name Type Address Offset
+ Size EntSize Flags Link Info Align
+ \[ 0\] NULL 0000000000000000 00000000
+ 0000000000000000 0000000000000000 0 0 0
+ \[ 1\] \.text PROGBITS 0000000000000000 00000040
+ 000000000000000c 0000000000000000 AX 0 0 4
+ \[ 2\] \.data PROGBITS 0000000000000000 0000004c
+ 0000000000000008 0000000000000000 WA 0 0 4
+ \[ 3\] \.bss NOBITS 0000000000000000 00000054
+ 0000000000000000 0000000000000000 WA 0 0 1
+ \[ 4\] \.shstrtab STRTAB 0000000000000000 00000054
+ 000000000000002c 0000000000000000 0 0 1
+ \[ 5\] \.symtab SYMTAB 0000000000000000 00000240
+ 00000000000000c0 0000000000000018 6 5 8
+ \[ 6\] \.strtab STRTAB 0000000000000000 00000300
+ 0000000000000030 0000000000000000 0 0 1
+Key to Flags:
+ W \(write\), A \(alloc\), X \(execute\), M \(merge\), S \(strings\)
+ I \(info\), L \(link order\), G \(group\), x \(unknown\)
+ O \(extra OS processing required\) o \(OS specific\), p \(processor specific\)
+
+There are no relocations in this file\.
+
+Symbol table '\.symtab' contains 8 entries:
+ Num: Value Size Type Bind Vis Ndx Name
+ 0: 0+ 0 NOTYPE LOCAL DEFAULT UND
+ 1: 0+ 0 SECTION LOCAL DEFAULT 1
+ 2: 0+ 0 SECTION LOCAL DEFAULT 2
+ 3: 0+ 0 SECTION LOCAL DEFAULT 3
+ 4: 0+ 0 NOTYPE LOCAL DEFAULT 2 a
+ 5: 0+4 0 FUNC GLOBAL DEFAULT 1 Main
+ 6: 0+200 0 NOTYPE GLOBAL DEFAULT ABS __\.MMIX\.start\.\.text
+ 7: 2000000000000000 0 NOTYPE GLOBAL DEFAULT ABS __\.MMIX\.start\.\.data
+
+Hex dump of section '\.text':
+ 0x00000000 fd00038f fd090101 fd000065 .*
+
+Hex dump of section '\.data':
+ 0x00000000 00000010 00000040 .*
--- /dev/null
+# Check that a little bit of LOC:ing back and forward between code and
+# data section doesn't hurt.
+ LOC #20 << 56
+a TETRA 4*4
+
+ LOC #200
+ SWYM 911
+Main SWYM 9,1,1
+
+ LOC a+4
+ TETRA 8*8
+
+ LOC Main+4
+ SWYM 101
--- /dev/null
+#readelf: -Ssrx1 -x2
+There are 7 section headers, starting at offset 0x88:
+
+Section Headers:
+ \[Nr\] Name Type Address Offset
+ Size EntSize Flags Link Info Align
+ \[ 0\] NULL 0000000000000000 00000000
+ 0000000000000000 0000000000000000 0 0 0
+ \[ 1\] \.text PROGBITS 0000000000000000 00000040
+ 0000000000000018 0000000000000000 AX 0 0 4
+ \[ 2\] \.data PROGBITS 0000000000000000 00000058
+ 0000000000000004 0000000000000000 WA 0 0 4
+ \[ 3\] \.bss NOBITS 0000000000000000 0000005c
+ 0000000000000000 0000000000000000 WA 0 0 1
+ \[ 4\] \.shstrtab STRTAB 0000000000000000 0000005c
+ 000000000000002c 0000000000000000 0 0 1
+ \[ 5\] \.symtab SYMTAB 0000000000000000 00000248
+ 00000000000000c0 0000000000000018 6 5 8
+ \[ 6\] \.strtab STRTAB 0000000000000000 00000308
+ 000000000000003b 0000000000000000 0 0 1
+Key to Flags:
+ W \(write\), A \(alloc\), X \(execute\), M \(merge\), S \(strings\)
+ I \(info\), L \(link order\), G \(group\), x \(unknown\)
+ O \(extra OS processing required\) o \(OS specific\), p \(processor specific\)
+
+There are no relocations in this file\.
+
+Symbol table '\.symtab' contains 8 entries:
+ Num: Value Size Type Bind Vis Ndx Name
+ 0: 0+ 0 NOTYPE LOCAL DEFAULT UND
+ 1: 0+ 0 SECTION LOCAL DEFAULT 1
+ 2: 0+ 0 SECTION LOCAL DEFAULT 2
+ 3: 0+ 0 SECTION LOCAL DEFAULT 3
+ 4: 2000000000000000 0 NOTYPE LOCAL DEFAULT ABS Data_Segment
+ 5: 0+14 0 FUNC GLOBAL DEFAULT 1 Main
+ 6: 0+ 0 NOTYPE GLOBAL DEFAULT ABS __\.MMIX\.start\.\.text
+ 7: 2000000000000000 0 NOTYPE GLOBAL DEFAULT ABS __\.MMIX\.start\.\.data
+
+Hex dump of section '\.text':
+ 0x00000000 fd001807 00000000 00000000 00000000 .*
+ 0x00000010 fd00038f fd090101 .*
+
+Hex dump of section '\.data':
+ 0x00000000 00000100 .*
--- /dev/null
+# Hit a few remaining code-paths.
+ SWYM 0,24,7
+ LOC Data_Segment
+ TETRA 4*4*4*4
+
+ LOC #10
+ SWYM 911
+Main SWYM 9,1,1
--- /dev/null
+#readelf: -Ssrx1 -x2
+There are 7 section headers, starting at offset 0x98:
+
+Section Headers:
+ \[Nr\] Name Type Address Offset
+ Size EntSize Flags Link Info Align
+ \[ 0\] NULL 0+ 0+
+ 0+ 0+ 0 0 0
+ \[ 1\] \.text PROGBITS 0+ 0+40
+ 0+8 0+ AX 0 0 4
+ \[ 2\] \.data PROGBITS 0+ 0+48
+ 0+24 0+ WA 0 0 4
+ \[ 3\] \.bss NOBITS 0+ 0+6c
+ 0+ 0+ WA 0 0 1
+ \[ 4\] \.shstrtab STRTAB 0+ 0+6c
+ 0+2c 0+ 0 0 1
+ \[ 5\] \.symtab SYMTAB 0+ 0+258
+ 0+c0 0+18 6 6 8
+ \[ 6\] \.strtab STRTAB 0+ 0+318
+ 0+29 0+ 0 0 1
+Key to Flags:
+ W \(write\), A \(alloc\), X \(execute\), M \(merge\), S \(strings\)
+ I \(info\), L \(link order\), G \(group\), x \(unknown\)
+ O \(extra OS processing required\) o \(OS specific\), p \(processor specific\)
+
+There are no relocations in this file\.
+
+Symbol table '\.symtab' contains 8 entries:
+ Num: Value Size Type Bind Vis Ndx Name
+ 0: 0+ 0 NOTYPE LOCAL DEFAULT UND
+ 1: 0+ 0 SECTION LOCAL DEFAULT 1
+ 2: 0+ 0 SECTION LOCAL DEFAULT 2
+ 3: 0+ 0 SECTION LOCAL DEFAULT 3
+ 4: 0+ 0 NOTYPE LOCAL DEFAULT 1 t
+ 5: 2000000000000000 0 NOTYPE LOCAL DEFAULT ABS Data_Segment
+ 6: 0+4 0 FUNC GLOBAL DEFAULT 1 Main
+ 7: 2000000000000000 0 NOTYPE GLOBAL DEFAULT ABS __\.MMIX\.start\.\.data
+
+Hex dump of section '\.text':
+ 0x0+ fd001807 fd090101 .*
+
+Hex dump of section '\.data':
+ 0x0+ 00000100 00000000 00000000 00000000 .*
+ 0x00000010 00000000 00000000 00000000 00000000 .*
+ 0x00000020 00000038 .*
--- /dev/null
+# Hit a few remaining code-paths.
+t SWYM 0,24,7
+
+ LOC Data_Segment
+ TETRA 4*4*4*4
+
+ LOC (#20 << 56) + #20
+ TETRA 56
+
+ LOC t+4
+Main SWYM 9,1,1
--- /dev/null
+# objdump: -xsr
+
+.*: file format elf64-mmix
+.*
+architecture: mmix, flags 0x00000011:
+HAS_RELOC, HAS_SYMS
+start address 0x0000000000000000
+
+Sections:
+Idx Name Size VMA LMA File off Algn
+ 0 \.text 00000004 0000000000000000 0000000000000000 00000040 2\*\*2
+ CONTENTS, ALLOC, LOAD, RELOC, READONLY, CODE
+ 1 \.data 00000000 0000000000000000 0000000000000000 00000044 2\*\*0
+ CONTENTS, ALLOC, LOAD, DATA
+ 2 \.bss 00000000 0000000000000000 0000000000000000 00000044 2\*\*0
+ ALLOC
+SYMBOL TABLE:
+0+ l d \.text 0+
+0+ l d \.data 0+
+0+ l d \.bss 0+
+0+90 l \*REG\* 0+ reghere
+0+2d l \*ABS\* 0+ consthere
+0+ \*UND\* 0+ extreg
+
+
+RELOCATION RECORDS FOR \[\.text\]:
+OFFSET TYPE VALUE
+0+ R_MMIX_LOCAL extreg
+0+ R_MMIX_LOCAL reghere
+0+ R_MMIX_LOCAL consthere
+0+ R_MMIX_LOCAL \*ABS\*\+0x0000000000000064
+0+ R_MMIX_LOCAL \*ABS\*\+0x00000000000000c8
+
+
+Contents of section \.text:
+ 0000 fd000000 .*
+
+Contents of section \.data:
--- /dev/null
+ LOCAL extreg
+ LOCAL reghere
+ LOCAL consthere
+ LOCAL 100
+ LOCAL $200
+
+reghere IS $144
+consthere IS 45
+
+ # Restrictions on the implementation means we have to have the LOCAL in
+ # code or data.
+ SWYM 0,0,0
--- /dev/null
+# objdump: -t
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+ l d \.text 0+
+0+ l d \.data 0+
+0+ l d \.bss 0+
+0+14 l \.text 0+ L9
+0+18 l \.text 0+ L12
+0+1c l \.text 0+ L21
+0+20 l \.text 0+ LC32
+0+24 l \.text 0+ LC23
+0+8 g \.text 0+ L:21
+0+10 g \.text 0+ LC:23
--- /dev/null
+% Get rid of labels that look compiler-generated, matching: "L.*:[0-9]+".
+% Only if they're local, of course.
+ .global L:21
+ .global LC:23
+L:9 SWYM 0
+L:12 SWYM 1
+L:21 SWYM 2
+LC:32 SWYM 3
+LC:23 SWYM 4
+L9 SWYM 10
+L12 SWYM 11
+L21 SWYM 12
+LC32 SWYM 13
+LC23 SWYM 14
--- /dev/null
+# Copyright (C) 2001 Free Software Foundation, Inc.
+
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+
+if { ! [istarget "mmix-*"] } {
+ return
+}
+
+proc run_mmix_err_tests { } {
+ global srcdir subdir runtests
+
+ load_lib gas-dg.exp
+ dg-init
+ dg-runtest [lsort [glob -nocomplain $srcdir/$subdir/err-*.s]] "" ""
+ dg-finish
+}
+
+run_mmix_err_tests
--- /dev/null
+# Copyright (C) 2001 Free Software Foundation, Inc.
+
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+
+if { ! [istarget "mmix-*"] } {
+ return
+}
+
+proc run_list_test { name opts } {
+ global srcdir subdir runtests
+
+ if ![runtest_file_p $runtests $name] then {
+ return
+ }
+
+ set testname "mmix list $name"
+ set file $srcdir/$subdir/$name
+ gas_run ${name}.s $opts ">&dump.out"
+ if { [regexp_diff "dump.out" "${file}.l"] } then {
+ fail $testname
+ verbose "output is [file_contents "dump.out"]" 2
+ return
+ }
+ pass $testname
+}
+
+proc run_mmix_list_tests { } {
+ global srcdir subdir runtests
+ foreach test_name [lsort [find ${srcdir}/${subdir} *.l]] {
+ # Keep basename.
+ regsub -all ".*/\(\[^\.\]*\)\.l$" $test_name "\\1" test_name
+ run_list_test $test_name "-a -x"
+ }
+}
+
+run_mmix_list_tests
--- /dev/null
+# Copyright (C) 2001 Free Software Foundation, Inc.
+
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+
+if { ! [istarget "mmix-*"] } {
+ return
+}
+
+proc run_mmix_tests { } {
+ global srcdir subdir runtests
+ foreach test_name [lsort [find ${srcdir}/${subdir} *.d]] {
+ # Keep basename.
+ regsub -all ".*/\(\[^\.\]*\)\.d$" $test_name "\\1" test_name
+
+ run_dump_test $test_name
+ }
+
+ # FIXME: more tests needed.
+ # BFD_RELOC_MMIX_REG_OR_BYTE with symbol-difference with
+ # relaxable thing in between.
+ #
+ # Other normal reloc with symbol-difference with
+ # relaxable thing in between.
+}
+
+run_mmix_tests
--- /dev/null
+#objdump: -str
+
+# A few odd mmixal compatibility cases.
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+ l d \.text 0+
+0+ l d \.data 0+
+0+ l d \.bss 0+
+0+ l \.MMIX\.reg_contents 0+ small
+0+ l d \.MMIX\.reg_contents 0+
+0+ g F \.text 0+ Main
+
+
+RELOCATION RECORDS FOR \[\.text\]:
+OFFSET TYPE VALUE
+0+7 R_MMIX_REG_OR_BYTE \.MMIX\.reg_contents
+0+f R_MMIX_REG \.MMIX\.reg_contents
+0+15 R_MMIX_REG \.MMIX\.reg_contents
+0+19 R_MMIX_REG \.MMIX\.reg_contents
+
+Contents of section \.text:
+ 0000 f9000000 ff016400 fb0000ff fb000000 .*
+ 0010 00000001 33000408 c1000200 0004022a .*
+Contents of section \.data:
+Contents of section \.MMIX\.reg_contents:
+ 0000 00000000 00000abc .*
--- /dev/null
+small GREG #abc
+Main RESUME
+ TRIP 1,$100,small
+ UNSAVE $255
+ UNSAVE small
+ TRAP 0,$1
+ CMPU small,$4,rC
+ SET small,$2
+ BYTE 0,4,rE,#2a
--- /dev/null
+#objdump: -srt
+#as: -x
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+ l d \.text 0+
+0+ l d \.data 0+
+0+ l d \.bss 0+
+0+ l \*ABS\* 0+ zero0
+0+ l \*ABS\* 0+ zero1
+0+ l \*ABS\* 0+ zero2
+0+ g F \.text 0+ Main
+
+
+RELOCATION RECORDS FOR \[\.text\]:
+OFFSET TYPE VALUE
+0+ R_MMIX_JMP \*ABS\*
+0+14 R_MMIX_GETA \*ABS\*
+0+24 R_MMIX_PUSHJ \*ABS\*
+
+
+Contents of section \.text:
+ 0000 f0000000 fd000000 fd000000 fd000000 .*
+ 0010 fd000000 f4070000 fd000000 fd000000 .*
+ 0020 fd000000 f2080000 fd000000 fd000000 .*
+ 0030 fd000000 fd000000 .*
+Contents of section \.data:
--- /dev/null
+zero0 IS 0
+zero1 IS 0
+zero2 IS 0
+Main JMP zero0
+ GETA $7,zero1
+ PUSHJ $8,zero2
+
+
--- /dev/null
+#source: op-0-1.s
+#as: -no-expand
+#objdump: -srt
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+ l d \.text 0+
+0+ l d \.data 0+
+0+ l d \.bss 0+
+0+ l \*ABS\* 0+ zero0
+0+ l \*ABS\* 0+ zero1
+0+ l \*ABS\* 0+ zero2
+0+ g F \.text 0+ Main
+
+
+RELOCATION RECORDS FOR \[\.text\]:
+OFFSET TYPE VALUE
+0+ R_MMIX_ADDR27 \*ABS\*
+0+4 R_MMIX_ADDR19 \*ABS\*
+0+8 R_MMIX_ADDR19 \*ABS\*
+
+
+Contents of section \.text:
+ 0000 f0000000 f4070000 f2080000 .*
+Contents of section \.data:
--- /dev/null
+# objdump: -dr
+# as: -linkrelax
+# source: pop-op.s
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: f8840def pop 132,3567
+ 4: f8845678 pop 132,22136
+ 8: f8170def pop 23,3567
+ c: f8175678 pop 23,22136
--- /dev/null
+# objdump: -dr
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: f8840def pop 132,3567
+ 4: f8845678 pop 132,22136
+ 8: f8170def pop 23,3567
+ c: f8175678 pop 23,22136
--- /dev/null
+GAS for MMIX .*/pop-op\.s page 1
+
+
+ 1 #.*
+ 2 #.*
+ 3 0000 F8840DEF Main POP 132,3567
+ 4 0004 F8845678 POP 132,YZ
+ 5 0008 F8170DEF POP X,3567
+ 6 000c F8175678 POP X,YZ
+ 7 X IS 23
+ 8 YZ IS #5678
+ 9
+\fGAS for MMIX .*/pop-op\.s page 2
+
+
+DEFINED SYMBOLS
+.*/pop-op\.s:3 \.text:0000000000000000 Main
+ \*ABS\*:0000000000005678 YZ
+ \*ABS\*:0000000000000017 X
+
+NO UNDEFINED SYMBOLS
--- /dev/null
+# Check different type of operands to SWYM etc.
+# No need to check the canonical three constants.
+Main POP 132,3567
+ POP 132,YZ
+ POP X,3567
+ POP X,YZ
+X IS 23
+YZ IS #5678
+
--- /dev/null
+# objdump: -rt
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+ l d \.text 0+
+0+ l d \.data 0+
+0+ l d \.bss 0+
+0+ l \.text 0+ a
+0+4 l \.text 0+ c
+0+24 l \.text 0+ d
+0+8 l \.text 0+ prea
+0+c l \.text 0+ pre:c
+0+10 l \.text 0+ prefixa
+0+14 l \.text 0+ pre:fix:c
+0+18 l \.text 0+ aprefixa
+0+1c l \.text 0+ aprefix:c
+0+20 l \.text 0+ a0
+0+ \*UND\* 0+ b
+0+ \*UND\* 0+ preb
+0+ \*UND\* 0+ pre:d
+0+ \*UND\* 0+ prefixb
+0+ \*UND\* 0+ pre:fix:d
+0+ \*UND\* 0+ aprefixb
+0+ \*UND\* 0+ aprefix:d
+
+RELOCATION RECORDS FOR \[\.text\]:
+OFFSET TYPE VALUE
+0+ R_MMIX_32 b
+0+4 R_MMIX_32 \.text\+0x0+24
+0+8 R_MMIX_32 preb
+0+c R_MMIX_32 pre:d
+0+10 R_MMIX_32 prefixb
+0+14 R_MMIX_32 pre:fix:d
+0+18 R_MMIX_32 aprefixb
+0+1c R_MMIX_32 aprefix:d
+0+20 R_MMIX_32 \.text
+0+24 R_MMIX_32 \.text\+0x0+4
--- /dev/null
+# Use of PREFIX; sanity check only.
+ .text
+a TETRA b
+:c TETRA :d
+
+ PREFIX pre
+a TETRA b
+:pre:c TETRA :pre:d
+
+ PREFIX fix
+a TETRA b
+:pre:fix:c TETRA :pre:fix:d
+
+ PREFIX :aprefix
+a TETRA b
+:aprefix:c TETRA :aprefix:d
+
+ PREFIX :
+a0 TETRA a
+d TETRA c
+
--- /dev/null
+# objdump: -dtr
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+ l d \.text 0+
+0+ l d \.data 0+
+0+ l d \.bss 0+
+0+ g F \.text 0+ Main
+
+
+Disassembly of section \.text:
+
+0+ <Main>:
+ 0: 220116e9 addu \$1,\$22,\$233
--- /dev/null
+# Prefix must not interfere with register names.
+ PREFIX pre
+:Main ADDU $1,$22,$233
--- /dev/null
+#objdump: -str
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+ l d \.text 0+
+0+ l d \.data 0+
+0+ l d \.bss 0+
+0+8 l \.text 0+ someplace
+0+ l \.text 0+ bc:h
+0+8 l \.MMIX\.reg_contents 0+ a1
+0+ l \.MMIX\.reg_contents 0+ ba2
+0+ l d \.MMIX\.reg_contents 0+
+0+4 g F \.text 0+ Main
+
+
+RELOCATION RECORDS FOR \[\.text\]:
+OFFSET TYPE VALUE
+0+2 R_MMIX_REG \.MMIX\.reg_contents\+0x0+8
+0+6 R_MMIX_REG \.MMIX\.reg_contents
+
+
+RELOCATION RECORDS FOR \[\.MMIX\.reg_contents\]:
+OFFSET TYPE VALUE
+0+8 R_MMIX_64 \.text\+0x0+8
+
+
+Contents of section \.text:
+ 0000 81ff0000 81fe0000 .*
+Contents of section \.data:
+Contents of section \.MMIX\.reg_contents:
+ 0000 00000000 0008aa52 00000000 00000000 .*
--- /dev/null
+% Check that changing prefixes between the GREG definition, its use and
+% the end of the assembly file does not change the GREG definition.
+a1 GREG someplace
+ PREFIX b
+a2 GREG 567890
+ PREFIX c:
+h LDB $255,:a1
+:Main LDB $254,:ba2
+:someplace IS @
--- /dev/null
+#objdump: -str
+
+# Check that some pseudos get output right.
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+ l d \.text 0+
+0+ l d \.data 0+
+0+ l d \.bss 0+
+0+ g F \.text 0+ Main
+
+Contents of section \.text:
+ 0000 00000020 00000020 00000020 00000020 .*
+ 0010 0000000a 00000000 .*
+Contents of section \.data:
--- /dev/null
+Main TETRA " ",#a,0
--- /dev/null
+# objdump: -dr
+# as: -linkrelax
+# source: pushgo-op.s
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: be170c43 pushgo \$23,\$12,\$67
+ 4: becb0c43 pushgo \$203,\$12,\$67
+ 8: be200c43 pushgo \$32,\$12,\$67
+ c: be200c43 pushgo \$32,\$12,\$67
+ 10: be172043 pushgo \$23,\$32,\$67
+ 14: becb2043 pushgo \$203,\$32,\$67
+ 18: bee88543 pushgo \$232,\$133,\$67
+ 1c: bee88543 pushgo \$232,\$133,\$67
+ 20: be170c49 pushgo \$23,\$12,\$73
+ 24: becb0c49 pushgo \$203,\$12,\$73
+ 28: be1f0ce9 pushgo \$31,\$12,\$233
+ 2c: be1f0ce9 pushgo \$31,\$12,\$233
+ 30: be1726d4 pushgo \$23,\$38,\$212
+ 34: becb26d4 pushgo \$203,\$38,\$212
+ 38: be04afb5 pushgo \$4,\$175,\$181
+ 3c: be04afb5 pushgo \$4,\$175,\$181
+ 40: bf170cb0 pushgo \$23,\$12,176
+ 44: bfcb0cb0 pushgo \$203,\$12,176
+ 48: bf200cb0 pushgo \$32,\$12,176
+ 4c: bf200cb0 pushgo \$32,\$12,176
+ 50: bf1720b0 pushgo \$23,\$32,176
+ 54: bfcb20b0 pushgo \$203,\$32,176
+ 58: bfe885b0 pushgo \$232,\$133,176
+ 5c: bfe885b0 pushgo \$232,\$133,176
+ 60: bf170ccb pushgo \$23,\$12,203
+ 64: bfcb0ccb pushgo \$203,\$12,203
+ 68: bf1f0cd5 pushgo \$31,\$12,213
+ 6c: bf1f0cd5 pushgo \$31,\$12,213
+ 70: bf1726d3 pushgo \$23,\$38,211
+ 74: bfcb26d3 pushgo \$203,\$38,211
+ 78: bf04afa1 pushgo \$4,\$175,161
+ 7c: bf04afa1 pushgo \$4,\$175,161
+ 80: bf170c00 pushgo \$23,\$12,0
+ 84: bfcb0c00 pushgo \$203,\$12,0
+ 88: bf290c00 pushgo \$41,\$12,0
+ 8c: bff10c00 pushgo \$241,\$12,0
+ 90: bf171b00 pushgo \$23,\$27,0
+ 94: bfcb3000 pushgo \$203,\$48,0
+ 98: bfdfdb00 pushgo \$223,\$219,0
+ 9c: bfdfe500 pushgo \$223,\$229,0
+ a0: bf170c00 pushgo \$23,\$12,0
+ a4: bfcb0c00 pushgo \$203,\$12,0
+ a8: bf200c00 pushgo \$32,\$12,0
+ ac: bf200c00 pushgo \$32,\$12,0
+ b0: bf172000 pushgo \$23,\$32,0
+ b4: bfcb2000 pushgo \$203,\$32,0
+ b8: bfe88500 pushgo \$232,\$133,0
+ bc: bfe88500 pushgo \$232,\$133,0
+ c0: bf170c00 pushgo \$23,\$12,0
+ c4: bfcb0c00 pushgo \$203,\$12,0
+ c8: bf1f0c00 pushgo \$31,\$12,0
+ cc: bf1f0c00 pushgo \$31,\$12,0
+ d0: bf172600 pushgo \$23,\$38,0
+ d4: bfcb2600 pushgo \$203,\$38,0
+ d8: bf04af00 pushgo \$4,\$175,0
+ dc: bf04af00 pushgo \$4,\$175,0
--- /dev/null
+# objdump: -dr
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: be170c43 pushgo \$23,\$12,\$67
+ 4: becb0c43 pushgo \$203,\$12,\$67
+ 8: be200c43 pushgo \$32,\$12,\$67
+ c: be200c43 pushgo \$32,\$12,\$67
+ 10: be172043 pushgo \$23,\$32,\$67
+ 14: becb2043 pushgo \$203,\$32,\$67
+ 18: bee88543 pushgo \$232,\$133,\$67
+ 1c: bee88543 pushgo \$232,\$133,\$67
+ 20: be170c49 pushgo \$23,\$12,\$73
+ 24: becb0c49 pushgo \$203,\$12,\$73
+ 28: be1f0ce9 pushgo \$31,\$12,\$233
+ 2c: be1f0ce9 pushgo \$31,\$12,\$233
+ 30: be1726d4 pushgo \$23,\$38,\$212
+ 34: becb26d4 pushgo \$203,\$38,\$212
+ 38: be04afb5 pushgo \$4,\$175,\$181
+ 3c: be04afb5 pushgo \$4,\$175,\$181
+ 40: bf170cb0 pushgo \$23,\$12,176
+ 44: bfcb0cb0 pushgo \$203,\$12,176
+ 48: bf200cb0 pushgo \$32,\$12,176
+ 4c: bf200cb0 pushgo \$32,\$12,176
+ 50: bf1720b0 pushgo \$23,\$32,176
+ 54: bfcb20b0 pushgo \$203,\$32,176
+ 58: bfe885b0 pushgo \$232,\$133,176
+ 5c: bfe885b0 pushgo \$232,\$133,176
+ 60: bf170ccb pushgo \$23,\$12,203
+ 64: bfcb0ccb pushgo \$203,\$12,203
+ 68: bf1f0cd5 pushgo \$31,\$12,213
+ 6c: bf1f0cd5 pushgo \$31,\$12,213
+ 70: bf1726d3 pushgo \$23,\$38,211
+ 74: bfcb26d3 pushgo \$203,\$38,211
+ 78: bf04afa1 pushgo \$4,\$175,161
+ 7c: bf04afa1 pushgo \$4,\$175,161
+ 80: bf170c00 pushgo \$23,\$12,0
+ 84: bfcb0c00 pushgo \$203,\$12,0
+ 88: bf290c00 pushgo \$41,\$12,0
+ 8c: bff10c00 pushgo \$241,\$12,0
+ 90: bf171b00 pushgo \$23,\$27,0
+ 94: bfcb3000 pushgo \$203,\$48,0
+ 98: bfdfdb00 pushgo \$223,\$219,0
+ 9c: bfdfe500 pushgo \$223,\$229,0
+ a0: bf170c00 pushgo \$23,\$12,0
+ a4: bfcb0c00 pushgo \$203,\$12,0
+ a8: bf200c00 pushgo \$32,\$12,0
+ ac: bf200c00 pushgo \$32,\$12,0
+ b0: bf172000 pushgo \$23,\$32,0
+ b4: bfcb2000 pushgo \$203,\$32,0
+ b8: bfe88500 pushgo \$232,\$133,0
+ bc: bfe88500 pushgo \$232,\$133,0
+ c0: bf170c00 pushgo \$23,\$12,0
+ c4: bfcb0c00 pushgo \$203,\$12,0
+ c8: bf1f0c00 pushgo \$31,\$12,0
+ cc: bf1f0c00 pushgo \$31,\$12,0
+ d0: bf172600 pushgo \$23,\$38,0
+ d4: bfcb2600 pushgo \$203,\$38,0
+ d8: bf04af00 pushgo \$4,\$175,0
+ dc: bf04af00 pushgo \$4,\$175,0
--- /dev/null
+GAS for MMIX .*/pushgo-op\.s page 1
+
+
+ 1 #.*
+ 2 #.*
+ 3 0000 BE170C43 Main PUSHGO X,Y,Z
+ 4 0004 BECB0C43 PUSHGO XC,Y,Z
+ 5 0008 BE200C43 PUSHGO \$32,Y,Z
+ 6 000c BE200C43 PUSHGO 32,Y,Z
+ 7 0010 BE172043 PUSHGO X,\$32,Z
+ 8 0014 BECB2043 PUSHGO XC,\$32,Z
+ 9 0018 BEE88543 PUSHGO \$232,\$133,Z
+ 10 001c BEE88543 PUSHGO 232,\$133,Z
+ 11 0020 BE170C49 PUSHGO X,Y,\$73
+ 12 0024 BECB0C49 PUSHGO XC,Y,\$73
+ 13 0028 BE1F0CE9 PUSHGO \$31,Y,\$233
+ 14 002c BE1F0CE9 PUSHGO 31,Y,\$233
+ 15 0030 BE1726D4 PUSHGO X,\$38,\$212
+ 16 0034 BECB26D4 PUSHGO XC,\$38,\$212
+ 17 0038 BE04AFB5 PUSHGO \$4,\$175,\$181
+ 18 003c BE04AFB5 PUSHGO 4,\$175,\$181
+ 19
+ 20 0040 BF170CB0 PUSHGO X,Y,Z0
+ 21 0044 BFCB0CB0 PUSHGO XC,Y,Z0
+ 22 0048 BF200CB0 PUSHGO \$32,Y,Z0
+ 23 004c BF200CB0 PUSHGO 32,Y,Z0
+ 24 0050 BF1720B0 PUSHGO X,\$32,Z0
+ 25 0054 BFCB20B0 PUSHGO XC,\$32,Z0
+ 26 0058 BFE885B0 PUSHGO \$232,\$133,Z0
+ 27 005c BFE885B0 PUSHGO 232,\$133,Z0
+ 28 0060 BF170CCB PUSHGO X,Y,203
+ 29 0064 BFCB0CCB PUSHGO XC,Y,203
+ 30 0068 BF1F0CD5 PUSHGO \$31,Y,213
+ 31 006c BF1F0CD5 PUSHGO 31,Y,213
+ 32 0070 BF1726D3 PUSHGO X,\$38,211
+ 33 0074 BFCB26D3 PUSHGO XC,\$38,211
+ 34 0078 BF04AFA1 PUSHGO \$4,\$175,161
+ 35 007c BF04AFA1 PUSHGO 4,\$175,161
+ 36
+ 37 0080 BF170C00 PUSHGO X,Y
+ 38 0084 BFCB0C00 PUSHGO XC,Y
+ 39
+ 40 0088 BF290C00 PUSHGO \$41,Y
+ 41 008c BFF10C00 PUSHGO 241,Y
+ 42
+ 43 0090 BF171B00 PUSHGO X,\$27
+ 44 0094 BFCB3000 PUSHGO XC,\$48
+ 45
+ 46 0098 BFDFDB00 PUSHGO \$223,\$219
+ 47 009c BFDFE500 PUSHGO 223,\$229
+ 48
+ 49 00a0 BF170C00 PUSHGO X,Y,0
+ 50 00a4 BFCB0C00 PUSHGO XC,Y,0
+ 51 00a8 BF200C00 PUSHGO \$32,Y,0
+ 52 00ac BF200C00 PUSHGO 32,Y,0
+ 53 00b0 BF172000 PUSHGO X,\$32,0
+ 54 00b4 BFCB2000 PUSHGO XC,\$32,0
+ 55 00b8 BFE88500 PUSHGO \$232,\$133,0
+ 56 00bc BFE88500 PUSHGO 232,\$133,0
+ 57 00c0 BF170C00 PUSHGO X,Y,0
+\fGAS for MMIX .*/pushgo-op\.s page 2
+
+
+ 58 00c4 BFCB0C00 PUSHGO XC,Y,0
+ 59 00c8 BF1F0C00 PUSHGO \$31,Y,0
+ 60 00cc BF1F0C00 PUSHGO 31,Y,0
+ 61 00d0 BF172600 PUSHGO X,\$38,0
+ 62 00d4 BFCB2600 PUSHGO XC,\$38,0
+ 63 00d8 BF04AF00 PUSHGO \$4,\$175,0
+ 64 00dc BF04AF00 PUSHGO 4,\$175,0
+ 65 X IS \$23
+ 66 XC IS 203
+ 67 Y IS \$12
+ 68 Z IS \$67
+ 69 Z0 IS 176
+\fGAS for MMIX .*/pushgo-op\.s page 3
+
+
+DEFINED SYMBOLS
+.*/pushgo-op\.s:3 \.text:0000000000000000 Main
+ \*REG\*:0000000000000017 X
+ \*REG\*:000000000000000c Y
+ \*REG\*:0000000000000043 Z
+ \*ABS\*:00000000000000cb XC
+ \*ABS\*:00000000000000b0 Z0
+
+NO UNDEFINED SYMBOLS
--- /dev/null
+# PUSHGO. Like T, but $X can be expressed as a constant.
+# Using regt-op as a template caused this to go out of control.
+Main PUSHGO X,Y,Z
+ PUSHGO XC,Y,Z
+ PUSHGO $32,Y,Z
+ PUSHGO 32,Y,Z
+ PUSHGO X,$32,Z
+ PUSHGO XC,$32,Z
+ PUSHGO $232,$133,Z
+ PUSHGO 232,$133,Z
+ PUSHGO X,Y,$73
+ PUSHGO XC,Y,$73
+ PUSHGO $31,Y,$233
+ PUSHGO 31,Y,$233
+ PUSHGO X,$38,$212
+ PUSHGO XC,$38,$212
+ PUSHGO $4,$175,$181
+ PUSHGO 4,$175,$181
+
+ PUSHGO X,Y,Z0
+ PUSHGO XC,Y,Z0
+ PUSHGO $32,Y,Z0
+ PUSHGO 32,Y,Z0
+ PUSHGO X,$32,Z0
+ PUSHGO XC,$32,Z0
+ PUSHGO $232,$133,Z0
+ PUSHGO 232,$133,Z0
+ PUSHGO X,Y,203
+ PUSHGO XC,Y,203
+ PUSHGO $31,Y,213
+ PUSHGO 31,Y,213
+ PUSHGO X,$38,211
+ PUSHGO XC,$38,211
+ PUSHGO $4,$175,161
+ PUSHGO 4,$175,161
+
+ PUSHGO X,Y
+ PUSHGO XC,Y
+
+ PUSHGO $41,Y
+ PUSHGO 241,Y
+
+ PUSHGO X,$27
+ PUSHGO XC,$48
+
+ PUSHGO $223,$219
+ PUSHGO 223,$229
+
+ PUSHGO X,Y,0
+ PUSHGO XC,Y,0
+ PUSHGO $32,Y,0
+ PUSHGO 32,Y,0
+ PUSHGO X,$32,0
+ PUSHGO XC,$32,0
+ PUSHGO $232,$133,0
+ PUSHGO 232,$133,0
+ PUSHGO X,Y,0
+ PUSHGO XC,Y,0
+ PUSHGO $31,Y,0
+ PUSHGO 31,Y,0
+ PUSHGO X,$38,0
+ PUSHGO XC,$38,0
+ PUSHGO $4,$175,0
+ PUSHGO 4,$175,0
+X IS $23
+XC IS 203
+Y IS $12
+Z IS $67
+Z0 IS 176
--- /dev/null
+#as: -x
+#objdump: -tdr
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+ l d .text 0+
+0+ l d .data 0+
+0+ l d .bss 0+
+ffff0000ffff0000 l \*ABS\* 0+ i1
+ffff0000ffff0000 l \*ABS\* 0+ i2
+0+ g F .text 0+ Main
+
+Disassembly of section .text:
+
+0+ <Main>:
+ 0: f2010000 pushj \$1,0 <Main>
+ 0: R_MMIX_PUSHJ \*ABS\*\+0xffff0000ffff0000
+ 4: fd000000 swym 0,0,0
+ 8: fd000000 swym 0,0,0
+ c: fd000000 swym 0,0,0
+ 10: fd000000 swym 0,0,0
+ 14: f2020000 pushj \$2,14 <Main\+0x14>
+ 14: R_MMIX_PUSHJ i2
+ 18: fd000000 swym 0,0,0
+ 1c: fd000000 swym 0,0,0
+ 20: fd000000 swym 0,0,0
+ 24: fd000000 swym 0,0,0
--- /dev/null
+% PUSHJ far away must not fail
+i1 IS #ffff0000ffff0000
+Main PUSHJ $1,i1
+ PUSHJ $2,i2
+i2 IS #ffff0000ffff0000
--- /dev/null
+# objdump: -dr
+# as: -linkrelax
+# source: put-op.s
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: f604007b put rJ,\$123
+ 4: f613002d put rG,\$45
+ 8: f61f00f5 put rZZ,\$245
+ c: f604006f put rJ,\$111
+ 10: f713002d put rG,45
+ 14: f71f00f5 put rZZ,245
+ 18: f7040000 put rJ,0
+ 1c: f7130000 put rG,0
+ 20: f71f0000 put rZZ,0
--- /dev/null
+# objdump: -dr
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: f604007b put rJ,\$123
+ 4: f613002d put rG,\$45
+ 8: f61f00f5 put rZZ,\$245
+ c: f604006f put rJ,\$111
+ 10: f713002d put rG,45
+ 14: f71f00f5 put rZZ,245
+ 18: f7040000 put rJ,0
+ 1c: f7130000 put rG,0
+ 20: f71f0000 put rZZ,0
--- /dev/null
+GAS for MMIX .*/put-op\.s page 1
+
+
+ 1 #.*
+ 2 #.*
+ 3 0000 F604007B Main PUT rJ,X
+ 4 0004 F613002D PUT rG,\$45
+ 5 0008 F61F00F5 PUT rZZ,\$245
+ 6 000c F604006F PUT rJ,X0
+ 7 0010 F713002D PUT rG,45
+ 8 0014 F71F00F5 PUT rZZ,245
+ 9 0018 F7040000 PUT rJ,X00
+ 10 001c F7130000 PUT rG,0
+ 11 0020 F71F0000 PUT rZZ,0
+ 12 X IS \$123
+ 13 X0 IS \$111
+ 14 X00 IS 0
+\fGAS for MMIX .*/put-op\.s page 2
+
+
+DEFINED SYMBOLS
+.*/put-op\.s:3 \.text:0000000000000000 Main
+ \*REG\*:000000000000007b X
+ \*REG\*:000000000000006f X0
+ \*ABS\*:0000000000000000 X00
+
+NO UNDEFINED SYMBOLS
--- /dev/null
+# For 'p'-type operands: PUT.
+#
+Main PUT rJ,X
+ PUT rG,$45
+ PUT rZZ,$245
+ PUT rJ,X0
+ PUT rG,45
+ PUT rZZ,245
+ PUT rJ,X00
+ PUT rG,0
+ PUT rZZ,0
+X IS $123
+X0 IS $111
+X00 IS 0
--- /dev/null
+# objdump: -dr
+# as: -linkrelax
+# source: reg-op.s
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: 10170c43 fmul \$23,\$12,\$67
+ 4: 01200c43 fcmp \$32,\$12,\$67
+ 8: 040c2043 fadd \$12,\$32,\$67
+ c: 02e88543 fun \$232,\$133,\$67
+ 10: 03170c49 feql \$23,\$12,\$73
+ 14: 161f0ce9 frem \$31,\$12,\$233
+ 18: 061726d4 fsub \$23,\$38,\$212
+ 1c: 1304afb5 feqle \$4,\$175,\$181
--- /dev/null
+# objdump: -dr
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: 10170c43 fmul \$23,\$12,\$67
+ 4: 01200c43 fcmp \$32,\$12,\$67
+ 8: 040c2043 fadd \$12,\$32,\$67
+ c: 02e88543 fun \$232,\$133,\$67
+ 10: 03170c49 feql \$23,\$12,\$73
+ 14: 161f0ce9 frem \$31,\$12,\$233
+ 18: 061726d4 fsub \$23,\$38,\$212
+ 1c: 1304afb5 feqle \$4,\$175,\$181
--- /dev/null
+GAS for MMIX .*/reg-op\.s page 1
+
+
+ 1 #.*
+ 2 #.*
+ 3 0000 10170C43 Main FMUL X,Y,Z
+ 4 0004 01200C43 FCMP \$32,Y,Z
+ 5 0008 040C2043 FADD Y,\$32,Z
+ 6 000c 02E88543 FUN \$232,\$133,Z
+ 7 0010 03170C49 FEQL X,Y,\$73
+ 8 0014 161F0CE9 FREM \$31,Y,\$233
+ 9 0018 061726D4 FSUB X,\$38,\$212
+ 10 001c 1304AFB5 FEQLE \$4,\$175,\$181
+ 11 X IS \$23
+ 12 Y IS \$12
+ 13 Z IS \$67
+\fGAS for MMIX .*/reg-op\.s page 2
+
+
+DEFINED SYMBOLS
+.*/reg-op\.s:3 \.text:0000000000000000 Main
+ \*REG\*:0000000000000017 X
+ \*REG\*:000000000000000c Y
+ \*REG\*:0000000000000043 Z
+
+NO UNDEFINED SYMBOLS
--- /dev/null
+# All-registers, '$'-type operands.
+#
+Main FMUL X,Y,Z
+ FCMP $32,Y,Z
+ FADD Y,$32,Z
+ FUN $232,$133,Z
+ FEQL X,Y,$73
+ FREM $31,Y,$233
+ FSUB X,$38,$212
+ FEQLE $4,$175,$181
+X IS $23
+Y IS $12
+Z IS $67
--- /dev/null
+# objdump: -dr
+# as: -linkrelax
+# source: reg3-op.s
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: 18170c43 mul \$23,\$12,\$67
+ 4: 20200c43 add \$32,\$12,\$67
+ 8: 2a0c2043 4addu \$12,\$32,\$67
+ c: 2ce88543 8addu \$232,\$133,\$67
+ 10: 2e170c49 16addu \$23,\$12,\$73
+ 14: 3e1f0ce9 sru \$31,\$12,\$233
+ 18: 601726d4 csn \$23,\$38,\$212
+ 1c: 7c04afb5 zsnp \$4,\$175,\$181
+ 20: 1b170cb0 mulu \$23,\$12,176
+ 24: 39200cb0 sl \$32,\$12,176
+ 28: 330c20b0 cmpu \$12,\$32,176
+ 2c: 29e885b0 2addu \$232,\$133,176
+ 30: df170ccb mxor \$23,\$12,203
+ 34: c11f0cd5 or \$31,\$12,213
+ 38: cd1726d3 nand \$23,\$38,211
+ 3c: d304afa1 wdif \$4,\$175,161
+ 40: db170c00 sadd \$23,\$12,0
+ 44: df200c00 mxor \$32,\$12,0
+ 48: c30c2000 orn \$12,\$32,0
+ 4c: cbe88500 andn \$232,\$133,0
+ 50: 2f170c00 16addu \$23,\$12,0
+ 54: 391f0c00 sl \$31,\$12,0
+ 58: 23172600 addu \$23,\$38,0
+ 5c: 3104af00 cmp \$4,\$175,0
--- /dev/null
+# objdump: -dr
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: 18170c43 mul \$23,\$12,\$67
+ 4: 20200c43 add \$32,\$12,\$67
+ 8: 2a0c2043 4addu \$12,\$32,\$67
+ c: 2ce88543 8addu \$232,\$133,\$67
+ 10: 2e170c49 16addu \$23,\$12,\$73
+ 14: 3e1f0ce9 sru \$31,\$12,\$233
+ 18: 601726d4 csn \$23,\$38,\$212
+ 1c: 7c04afb5 zsnp \$4,\$175,\$181
+ 20: 1b170cb0 mulu \$23,\$12,176
+ 24: 39200cb0 sl \$32,\$12,176
+ 28: 330c20b0 cmpu \$12,\$32,176
+ 2c: 29e885b0 2addu \$232,\$133,176
+ 30: df170ccb mxor \$23,\$12,203
+ 34: c11f0cd5 or \$31,\$12,213
+ 38: cd1726d3 nand \$23,\$38,211
+ 3c: d304afa1 wdif \$4,\$175,161
+ 40: db170c00 sadd \$23,\$12,0
+ 44: df200c00 mxor \$32,\$12,0
+ 48: c30c2000 orn \$12,\$32,0
+ 4c: cbe88500 andn \$232,\$133,0
+ 50: 2f170c00 16addu \$23,\$12,0
+ 54: 391f0c00 sl \$31,\$12,0
+ 58: 23172600 addu \$23,\$38,0
+ 5c: 3104af00 cmp \$4,\$175,0
--- /dev/null
+GAS for MMIX .*/reg3-op\.s page 1
+
+
+ 1 #.*
+ 2 #.*
+ 3 0000 18170C43 Main MUL X,Y,Z
+ 4 0004 20200C43 ADD \$32,Y,Z
+ 5 0008 2A0C2043 4ADDU Y,\$32,Z
+ 6 000c 2CE88543 8ADDU \$232,\$133,Z
+ 7 0010 2E170C49 16ADDU X,Y,\$73
+ 8 0014 3E1F0CE9 SRU \$31,Y,\$233
+ 9 0018 601726D4 CSN X,\$38,\$212
+ 10 001c 7C04AFB5 ZSNP \$4,\$175,\$181
+ 11
+ 12 0020 1B170CB0 MULU X,Y,Z0
+ 13 0024 39200CB0 SL \$32,Y,Z0
+ 14 0028 330C20B0 CMPU Y,\$32,Z0
+ 15 002c 29E885B0 2ADDU \$232,\$133,Z0
+ 16 0030 DF170CCB MXOR X,Y,203
+ 17 0034 C11F0CD5 OR \$31,Y,213
+ 18 0038 CD1726D3 NAND X,\$38,211
+ 19 003c D304AFA1 WDIF \$4,\$175,161
+ 20
+ 21 0040 DB170C00 SADD X,Y,0
+ 22 0044 DF200C00 MXOR \$32,Y,0
+ 23 0048 C30C2000 ORN Y,\$32,0
+ 24 004c CBE88500 ANDN \$232,\$133,0
+ 25 0050 2F170C00 16ADDU X,Y,0
+ 26 0054 391F0C00 SL \$31,Y,0
+ 27 0058 23172600 ADDU X,\$38,0
+ 28 005c 3104AF00 CMP \$4,\$175,0
+ 29 X IS \$23
+ 30 Y IS \$12
+ 31 Z IS \$67
+ 32 Z0 IS 176
+\fGAS for MMIX .*/reg3-op\.s page 2
+
+
+DEFINED SYMBOLS
+.*/reg3-op\.s:3 \.text:0000000000000000 Main
+ \*REG\*:0000000000000017 X
+ \*REG\*:000000000000000c Y
+ \*REG\*:0000000000000043 Z
+ \*ABS\*:00000000000000b0 Z0
+
+NO UNDEFINED SYMBOLS
--- /dev/null
+# All-registers, '3'-type operands; third operand is
+# register or constant.
+Main MUL X,Y,Z
+ ADD $32,Y,Z
+ 4ADDU Y,$32,Z
+ 8ADDU $232,$133,Z
+ 16ADDU X,Y,$73
+ SRU $31,Y,$233
+ CSN X,$38,$212
+ ZSNP $4,$175,$181
+
+ MULU X,Y,Z0
+ SL $32,Y,Z0
+ CMPU Y,$32,Z0
+ 2ADDU $232,$133,Z0
+ MXOR X,Y,203
+ OR $31,Y,213
+ NAND X,$38,211
+ WDIF $4,$175,161
+
+ SADD X,Y,0
+ MXOR $32,Y,0
+ ORN Y,$32,0
+ ANDN $232,$133,0
+ 16ADDU X,Y,0
+ SL $31,Y,0
+ ADDU X,$38,0
+ CMP $4,$175,0
+X IS $23
+Y IS $12
+Z IS $67
+Z0 IS 176
--- /dev/null
+# objdump: -dr
+# as: -linkrelax
+# source: regt-op.s
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: 22170c43 addu \$23,\$12,\$67
+ 4: 88200c43 ldt \$32,\$12,\$67
+ 8: 820c2043 ldbu \$12,\$32,\$67
+ c: 8ae88543 ldtu \$232,\$133,\$67
+ 10: 8c170c49 ldo \$23,\$12,\$73
+ 14: 8e1f0ce9 ldou \$31,\$12,\$233
+ 18: 841726d4 ldw \$23,\$38,\$212
+ 1c: 8604afb5 ldwu \$4,\$175,\$181
+ 20: 81170cb0 ldb \$23,\$12,176
+ 24: 91200cb0 ldsf \$32,\$12,176
+ 28: 990c20b0 ldvts \$12,\$32,176
+ 2c: 97e885b0 ldunc \$232,\$133,176
+ 30: b3170ccb stht \$23,\$12,203
+ 34: 931f0cd5 ldht \$31,\$12,213
+ 38: 951726d3 cswap \$23,\$38,211
+ 3c: 9f04afa1 go \$4,\$175,161
+ 40: 23170c00 addu \$23,\$12,0
+ 44: 81170c00 ldb \$23,\$12,0
+ 48: 89170c00 ldt \$23,\$12,0
+ 4c: 83170c00 ldbu \$23,\$12,0
+ 50: 8b170c00 ldtu \$23,\$12,0
+ 54: 8d170c00 ldo \$23,\$12,0
+ 58: 8f170c00 ldou \$23,\$12,0
+ 5c: 85170c00 ldw \$23,\$12,0
+ 60: 87170c00 ldwu \$23,\$12,0
+ 64: 91170c00 ldsf \$23,\$12,0
+ 68: 93170c00 ldht \$23,\$12,0
+ 6c: 95170c00 cswap \$23,\$12,0
+ 70: 97170c00 ldunc \$23,\$12,0
+ 74: 99170c00 ldvts \$23,\$12,0
+ 78: 9f170c00 go \$23,\$12,0
+ 7c: a1170c00 stb \$23,\$12,0
+ 80: a9170c00 stt \$23,\$12,0
+ 84: a3170c00 stbu \$23,\$12,0
+ 88: ab170c00 sttu \$23,\$12,0
+ 8c: ad170c00 sto \$23,\$12,0
+ 90: af170c00 stou \$23,\$12,0
+ 94: a5170c00 stw \$23,\$12,0
+ 98: a7170c00 stwu \$23,\$12,0
+ 9c: b1170c00 stsf \$23,\$12,0
+ a0: b3170c00 stht \$23,\$12,0
+ a4: b7170c00 stunc \$23,\$12,0
+ a8: 23290c00 addu \$41,\$12,0
+ ac: 81790c00 ldb \$121,\$12,0
+ b0: 894e0c00 ldt \$78,\$12,0
+ b4: 837f0c00 ldbu \$127,\$12,0
+ b8: 8b310c00 ldtu \$49,\$12,0
+ bc: 8d340c00 ldo \$52,\$12,0
+ c0: 8f2a0c00 ldou \$42,\$12,0
+ c4: 857b0c00 ldw \$123,\$12,0
+ c8: 87ea0c00 ldwu \$234,\$12,0
+ cc: 91290c00 ldsf \$41,\$12,0
+ d0: 93590c00 ldht \$89,\$12,0
+ d4: 955d0c00 cswap \$93,\$12,0
+ d8: 972a0c00 ldunc \$42,\$12,0
+ dc: 99210c00 ldvts \$33,\$12,0
+ e0: 9f3b0c00 go \$59,\$12,0
+ e4: a13b0c00 stb \$59,\$12,0
+ e8: a93b0c00 stt \$59,\$12,0
+ ec: a33b0c00 stbu \$59,\$12,0
+ f0: ab3b0c00 sttu \$59,\$12,0
+ f4: ad3b0c00 sto \$59,\$12,0
+ f8: af3b0c00 stou \$59,\$12,0
+ fc: a53b0c00 stw \$59,\$12,0
+ 100: a73b0c00 stwu \$59,\$12,0
+ 104: b13b0c00 stsf \$59,\$12,0
+ 108: b33b0c00 stht \$59,\$12,0
+ 10c: b73b0c00 stunc \$59,\$12,0
+ 110: 23171b00 addu \$23,\$27,0
+ 114: 81173000 ldb \$23,\$48,0
+ 118: 8917a800 ldt \$23,\$168,0
+ 11c: 8317ea00 ldbu \$23,\$234,0
+ 120: 8b17b000 ldtu \$23,\$176,0
+ 124: 8d171d00 ldo \$23,\$29,0
+ 128: 8f17de00 ldou \$23,\$222,0
+ 12c: 8517de00 ldw \$23,\$222,0
+ 130: 8717de00 ldwu \$23,\$222,0
+ 134: 9117de00 ldsf \$23,\$222,0
+ 138: 9317de00 ldht \$23,\$222,0
+ 13c: 9517de00 cswap \$23,\$222,0
+ 140: 9717de00 ldunc \$23,\$222,0
+ 144: 9917de00 ldvts \$23,\$222,0
+ 148: 9f17de00 go \$23,\$222,0
+ 14c: a117de00 stb \$23,\$222,0
+ 150: a917de00 stt \$23,\$222,0
+ 154: a317de00 stbu \$23,\$222,0
+ 158: ab17de00 sttu \$23,\$222,0
+ 15c: ad17de00 sto \$23,\$222,0
+ 160: af17de00 stou \$23,\$222,0
+ 164: a517de00 stw \$23,\$222,0
+ 168: a717de00 stwu \$23,\$222,0
+ 16c: b117de00 stsf \$23,\$222,0
+ 170: b317de00 stht \$23,\$222,0
+ 174: b717de00 stunc \$23,\$222,0
+ 178: 23dfdb00 addu \$223,\$219,0
+ 17c: 81dfef00 ldb \$223,\$239,0
+ 180: 89dfef00 ldt \$223,\$239,0
+ 184: 83df1d00 ldbu \$223,\$29,0
+ 188: 8bdfef00 ldtu \$223,\$239,0
+ 18c: 8d17ef00 ldo \$23,\$239,0
+ 190: 8fdfef00 ldou \$223,\$239,0
+ 194: 85dfd100 ldw \$223,\$209,0
+ 198: 877bef00 ldwu \$123,\$239,0
+ 19c: 91dfef00 ldsf \$223,\$239,0
+ 1a0: 93df1d00 ldht \$223,\$29,0
+ 1a4: 95dfef00 cswap \$223,\$239,0
+ 1a8: 977bef00 ldunc \$123,\$239,0
+ 1ac: 99dfef00 ldvts \$223,\$239,0
+ 1b0: 9fdfef00 go \$223,\$239,0
+ 1b4: a1dfef00 stb \$223,\$239,0
+ 1b8: a9dff900 stt \$223,\$249,0
+ 1bc: a3cbef00 stbu \$203,\$239,0
+ 1c0: ab49ef00 sttu \$73,\$239,0
+ 1c4: addfef00 sto \$223,\$239,0
+ 1c8: afdf2700 stou \$223,\$39,0
+ 1cc: a5dfef00 stw \$223,\$239,0
+ 1d0: a7e9ef00 stwu \$233,\$239,0
+ 1d4: b1dfef00 stsf \$223,\$239,0
+ 1d8: b3df1700 stht \$223,\$23,0
+ 1dc: b7dfef00 stunc \$223,\$239,0
+ 1e0: 9f170c00 go \$23,\$12,0
+ 1e4: 99200c00 ldvts \$32,\$12,0
+ 1e8: a10c2000 stb \$12,\$32,0
+ 1ec: b7e88500 stunc \$232,\$133,0
+ 1f0: a7170c00 stwu \$23,\$12,0
+ 1f4: ad1f0c00 sto \$31,\$12,0
+ 1f8: 9f172600 go \$23,\$38,0
+ 1fc: 9504af00 cswap \$4,\$175,0
--- /dev/null
+# objdump: -dr
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: 22170c43 addu \$23,\$12,\$67
+ 4: 88200c43 ldt \$32,\$12,\$67
+ 8: 820c2043 ldbu \$12,\$32,\$67
+ c: 8ae88543 ldtu \$232,\$133,\$67
+ 10: 8c170c49 ldo \$23,\$12,\$73
+ 14: 8e1f0ce9 ldou \$31,\$12,\$233
+ 18: 841726d4 ldw \$23,\$38,\$212
+ 1c: 8604afb5 ldwu \$4,\$175,\$181
+ 20: 81170cb0 ldb \$23,\$12,176
+ 24: 91200cb0 ldsf \$32,\$12,176
+ 28: 990c20b0 ldvts \$12,\$32,176
+ 2c: 97e885b0 ldunc \$232,\$133,176
+ 30: b3170ccb stht \$23,\$12,203
+ 34: 931f0cd5 ldht \$31,\$12,213
+ 38: 951726d3 cswap \$23,\$38,211
+ 3c: 9f04afa1 go \$4,\$175,161
+ 40: 23170c00 addu \$23,\$12,0
+ 44: 81170c00 ldb \$23,\$12,0
+ 48: 89170c00 ldt \$23,\$12,0
+ 4c: 83170c00 ldbu \$23,\$12,0
+ 50: 8b170c00 ldtu \$23,\$12,0
+ 54: 8d170c00 ldo \$23,\$12,0
+ 58: 8f170c00 ldou \$23,\$12,0
+ 5c: 85170c00 ldw \$23,\$12,0
+ 60: 87170c00 ldwu \$23,\$12,0
+ 64: 91170c00 ldsf \$23,\$12,0
+ 68: 93170c00 ldht \$23,\$12,0
+ 6c: 95170c00 cswap \$23,\$12,0
+ 70: 97170c00 ldunc \$23,\$12,0
+ 74: 99170c00 ldvts \$23,\$12,0
+ 78: 9f170c00 go \$23,\$12,0
+ 7c: a1170c00 stb \$23,\$12,0
+ 80: a9170c00 stt \$23,\$12,0
+ 84: a3170c00 stbu \$23,\$12,0
+ 88: ab170c00 sttu \$23,\$12,0
+ 8c: ad170c00 sto \$23,\$12,0
+ 90: af170c00 stou \$23,\$12,0
+ 94: a5170c00 stw \$23,\$12,0
+ 98: a7170c00 stwu \$23,\$12,0
+ 9c: b1170c00 stsf \$23,\$12,0
+ a0: b3170c00 stht \$23,\$12,0
+ a4: b7170c00 stunc \$23,\$12,0
+ a8: 23290c00 addu \$41,\$12,0
+ ac: 81790c00 ldb \$121,\$12,0
+ b0: 894e0c00 ldt \$78,\$12,0
+ b4: 837f0c00 ldbu \$127,\$12,0
+ b8: 8b310c00 ldtu \$49,\$12,0
+ bc: 8d340c00 ldo \$52,\$12,0
+ c0: 8f2a0c00 ldou \$42,\$12,0
+ c4: 857b0c00 ldw \$123,\$12,0
+ c8: 87ea0c00 ldwu \$234,\$12,0
+ cc: 91290c00 ldsf \$41,\$12,0
+ d0: 93590c00 ldht \$89,\$12,0
+ d4: 955d0c00 cswap \$93,\$12,0
+ d8: 972a0c00 ldunc \$42,\$12,0
+ dc: 99210c00 ldvts \$33,\$12,0
+ e0: 9f3b0c00 go \$59,\$12,0
+ e4: a13b0c00 stb \$59,\$12,0
+ e8: a93b0c00 stt \$59,\$12,0
+ ec: a33b0c00 stbu \$59,\$12,0
+ f0: ab3b0c00 sttu \$59,\$12,0
+ f4: ad3b0c00 sto \$59,\$12,0
+ f8: af3b0c00 stou \$59,\$12,0
+ fc: a53b0c00 stw \$59,\$12,0
+ 100: a73b0c00 stwu \$59,\$12,0
+ 104: b13b0c00 stsf \$59,\$12,0
+ 108: b33b0c00 stht \$59,\$12,0
+ 10c: b73b0c00 stunc \$59,\$12,0
+ 110: 23171b00 addu \$23,\$27,0
+ 114: 81173000 ldb \$23,\$48,0
+ 118: 8917a800 ldt \$23,\$168,0
+ 11c: 8317ea00 ldbu \$23,\$234,0
+ 120: 8b17b000 ldtu \$23,\$176,0
+ 124: 8d171d00 ldo \$23,\$29,0
+ 128: 8f17de00 ldou \$23,\$222,0
+ 12c: 8517de00 ldw \$23,\$222,0
+ 130: 8717de00 ldwu \$23,\$222,0
+ 134: 9117de00 ldsf \$23,\$222,0
+ 138: 9317de00 ldht \$23,\$222,0
+ 13c: 9517de00 cswap \$23,\$222,0
+ 140: 9717de00 ldunc \$23,\$222,0
+ 144: 9917de00 ldvts \$23,\$222,0
+ 148: 9f17de00 go \$23,\$222,0
+ 14c: a117de00 stb \$23,\$222,0
+ 150: a917de00 stt \$23,\$222,0
+ 154: a317de00 stbu \$23,\$222,0
+ 158: ab17de00 sttu \$23,\$222,0
+ 15c: ad17de00 sto \$23,\$222,0
+ 160: af17de00 stou \$23,\$222,0
+ 164: a517de00 stw \$23,\$222,0
+ 168: a717de00 stwu \$23,\$222,0
+ 16c: b117de00 stsf \$23,\$222,0
+ 170: b317de00 stht \$23,\$222,0
+ 174: b717de00 stunc \$23,\$222,0
+ 178: 23dfdb00 addu \$223,\$219,0
+ 17c: 81dfef00 ldb \$223,\$239,0
+ 180: 89dfef00 ldt \$223,\$239,0
+ 184: 83df1d00 ldbu \$223,\$29,0
+ 188: 8bdfef00 ldtu \$223,\$239,0
+ 18c: 8d17ef00 ldo \$23,\$239,0
+ 190: 8fdfef00 ldou \$223,\$239,0
+ 194: 85dfd100 ldw \$223,\$209,0
+ 198: 877bef00 ldwu \$123,\$239,0
+ 19c: 91dfef00 ldsf \$223,\$239,0
+ 1a0: 93df1d00 ldht \$223,\$29,0
+ 1a4: 95dfef00 cswap \$223,\$239,0
+ 1a8: 977bef00 ldunc \$123,\$239,0
+ 1ac: 99dfef00 ldvts \$223,\$239,0
+ 1b0: 9fdfef00 go \$223,\$239,0
+ 1b4: a1dfef00 stb \$223,\$239,0
+ 1b8: a9dff900 stt \$223,\$249,0
+ 1bc: a3cbef00 stbu \$203,\$239,0
+ 1c0: ab49ef00 sttu \$73,\$239,0
+ 1c4: addfef00 sto \$223,\$239,0
+ 1c8: afdf2700 stou \$223,\$39,0
+ 1cc: a5dfef00 stw \$223,\$239,0
+ 1d0: a7e9ef00 stwu \$233,\$239,0
+ 1d4: b1dfef00 stsf \$223,\$239,0
+ 1d8: b3df1700 stht \$223,\$23,0
+ 1dc: b7dfef00 stunc \$223,\$239,0
+ 1e0: 9f170c00 go \$23,\$12,0
+ 1e4: 99200c00 ldvts \$32,\$12,0
+ 1e8: a10c2000 stb \$12,\$32,0
+ 1ec: b7e88500 stunc \$232,\$133,0
+ 1f0: a7170c00 stwu \$23,\$12,0
+ 1f4: ad1f0c00 sto \$31,\$12,0
+ 1f8: 9f172600 go \$23,\$38,0
+ 1fc: 9504af00 cswap \$4,\$175,0
--- /dev/null
+GAS for MMIX .*/regt-op\.s page 1
+
+
+ 1 #.*
+ 2 #.*
+ 3 0000 22170C43 Main LDA X,Y,Z
+ 4 0004 88200C43 LDT \$32,Y,Z
+ 5 0008 820C2043 LDBU Y,\$32,Z
+ 6 000c 8AE88543 LDTU \$232,\$133,Z
+ 7 0010 8C170C49 LDO X,Y,\$73
+ 8 0014 8E1F0CE9 LDOU \$31,Y,\$233
+ 9 0018 841726D4 LDW X,\$38,\$212
+ 10 001c 8604AFB5 LDWU \$4,\$175,\$181
+ 11
+ 12 0020 81170CB0 LDB X,Y,Z0
+ 13 0024 91200CB0 LDSF \$32,Y,Z0
+ 14 0028 990C20B0 LDVTS Y,\$32,Z0
+ 15 002c 97E885B0 LDUNC \$232,\$133,Z0
+ 16 0030 B3170CCB STHT X,Y,203
+ 17 0034 931F0CD5 LDHT \$31,Y,213
+ 18 0038 951726D3 CSWAP X,\$38,211
+ 19 003c 9F04AFA1 GO \$4,\$175,161
+ 20
+ 21 0040 23170C00 LDA X,Y
+ 22 0044 81170C00 LDB X,Y
+ 23 0048 89170C00 LDT X,Y
+ 24 004c 83170C00 LDBU X,Y
+ 25 0050 8B170C00 LDTU X,Y
+ 26 0054 8D170C00 LDO X,Y
+ 27 0058 8F170C00 LDOU X,Y
+ 28 005c 85170C00 LDW X,Y
+ 29 0060 87170C00 LDWU X,Y
+ 30 0064 91170C00 LDSF X,Y
+ 31 0068 93170C00 LDHT X,Y
+ 32 006c 95170C00 CSWAP X,Y
+ 33 0070 97170C00 LDUNC X,Y
+ 34 0074 99170C00 LDVTS X,Y
+ 35 0078 9F170C00 GO X,Y
+ 36 007c A1170C00 STB X,Y
+ 37 0080 A9170C00 STT X,Y
+ 38 0084 A3170C00 STBU X,Y
+ 39 0088 AB170C00 STTU X,Y
+ 40 008c AD170C00 STO X,Y
+ 41 0090 AF170C00 STOU X,Y
+ 42 0094 A5170C00 STW X,Y
+ 43 0098 A7170C00 STWU X,Y
+ 44 009c B1170C00 STSF X,Y
+ 45 00a0 B3170C00 STHT X,Y
+ 46 00a4 B7170C00 STUNC X,Y
+ 47
+ 48 00a8 23290C00 LDA \$41,Y
+ 49 00ac 81790C00 LDB \$121,Y
+ 50 00b0 894E0C00 LDT \$78,Y
+ 51 00b4 837F0C00 LDBU \$127,Y
+ 52 00b8 8B310C00 LDTU \$49,Y
+ 53 00bc 8D340C00 LDO \$52,Y
+ 54 00c0 8F2A0C00 LDOU \$42,Y
+ 55 00c4 857B0C00 LDW \$123,Y
+ 56 00c8 87EA0C00 LDWU \$234,Y
+ 57 00cc 91290C00 LDSF \$41,Y
+\fGAS for MMIX .*/regt-op\.s page 2
+
+
+ 58 00d0 93590C00 LDHT \$89,Y
+ 59 00d4 955D0C00 CSWAP \$93,Y
+ 60 00d8 972A0C00 LDUNC \$42,Y
+ 61 00dc 99210C00 LDVTS \$33,Y
+ 62 00e0 9F3B0C00 GO \$59,Y
+ 63 00e4 A13B0C00 STB \$59,Y
+ 64 00e8 A93B0C00 STT \$59,Y
+ 65 00ec A33B0C00 STBU \$59,Y
+ 66 00f0 AB3B0C00 STTU \$59,Y
+ 67 00f4 AD3B0C00 STO \$59,Y
+ 68 00f8 AF3B0C00 STOU \$59,Y
+ 69 00fc A53B0C00 STW \$59,Y
+ 70 0100 A73B0C00 STWU \$59,Y
+ 71 0104 B13B0C00 STSF \$59,Y
+ 72 0108 B33B0C00 STHT \$59,Y
+ 73 010c B73B0C00 STUNC \$59,Y
+ 74
+ 75 0110 23171B00 LDA X,\$27
+ 76 0114 81173000 LDB X,\$48
+ 77 0118 8917A800 LDT X,\$168
+ 78 011c 8317EA00 LDBU X,\$234
+ 79 0120 8B17B000 LDTU X,\$176
+ 80 0124 8D171D00 LDO X,\$29
+ 81 0128 8F17DE00 LDOU X,\$222
+ 82 012c 8517DE00 LDW X,\$222
+ 83 0130 8717DE00 LDWU X,\$222
+ 84 0134 9117DE00 LDSF X,\$222
+ 85 0138 9317DE00 LDHT X,\$222
+ 86 013c 9517DE00 CSWAP X,\$222
+ 87 0140 9717DE00 LDUNC X,\$222
+ 88 0144 9917DE00 LDVTS X,\$222
+ 89 0148 9F17DE00 GO X,\$222
+ 90 014c A117DE00 STB X,\$222
+ 91 0150 A917DE00 STT X,\$222
+ 92 0154 A317DE00 STBU X,\$222
+ 93 0158 AB17DE00 STTU X,\$222
+ 94 015c AD17DE00 STO X,\$222
+ 95 0160 AF17DE00 STOU X,\$222
+ 96 0164 A517DE00 STW X,\$222
+ 97 0168 A717DE00 STWU X,\$222
+ 98 016c B117DE00 STSF X,\$222
+ 99 0170 B317DE00 STHT X,\$222
+ 100 0174 B717DE00 STUNC X,\$222
+ 101
+ 102 0178 23DFDB00 LDA \$223,\$219
+ 103 017c 81DFEF00 LDB \$223,\$239
+ 104 0180 89DFEF00 LDT \$223,\$239
+ 105 0184 83DF1D00 LDBU \$223,\$29
+ 106 0188 8BDFEF00 LDTU \$223,\$239
+ 107 018c 8D17EF00 LDO \$23,\$239
+ 108 0190 8FDFEF00 LDOU \$223,\$239
+ 109 0194 85DFD100 LDW \$223,\$209
+ 110 0198 877BEF00 LDWU \$123,\$239
+ 111 019c 91DFEF00 LDSF \$223,\$239
+ 112 01a0 93DF1D00 LDHT \$223,\$29
+ 113 01a4 95DFEF00 CSWAP \$223,\$239
+ 114 01a8 977BEF00 LDUNC \$123,\$239
+\fGAS for MMIX .*/regt-op\.s page 3
+
+
+ 115 01ac 99DFEF00 LDVTS \$223,\$239
+ 116 01b0 9FDFEF00 GO \$223,\$239
+ 117 01b4 A1DFEF00 STB \$223,\$239
+ 118 01b8 A9DFF900 STT \$223,\$249
+ 119 01bc A3CBEF00 STBU \$203,\$239
+ 120 01c0 AB49EF00 STTU \$73,\$239
+ 121 01c4 ADDFEF00 STO \$223,\$239
+ 122 01c8 AFDF2700 STOU \$223,\$39
+ 123 01cc A5DFEF00 STW \$223,\$239
+ 124 01d0 A7E9EF00 STWU \$233,\$239
+ 125 01d4 B1DFEF00 STSF \$223,\$239
+ 126 01d8 B3DF1700 STHT \$223,\$23
+ 127 01dc B7DFEF00 STUNC \$223,\$239
+ 128
+ 129 01e0 9F170C00 GO X,Y,0
+ 130 01e4 99200C00 LDVTS \$32,Y,0
+ 131 01e8 A10C2000 STB Y,\$32,0
+ 132 01ec B7E88500 STUNC \$232,\$133,0
+ 133 01f0 A7170C00 STWU X,Y,0
+ 134 01f4 AD1F0C00 STO \$31,Y,0
+ 135 01f8 9F172600 GO X,\$38,0
+ 136 01fc 9504AF00 CSWAP \$4,\$175,0
+ 137 X IS \$23
+ 138 Y IS \$12
+ 139 Z IS \$67
+ 140 Z0 IS 176
+\fGAS for MMIX .*/regt-op\.s page 4
+
+
+DEFINED SYMBOLS
+.*/regt-op\.s:3 \.text:0000000000000000 Main
+ \*REG\*:0000000000000017 X
+ \*REG\*:000000000000000c Y
+ \*REG\*:0000000000000043 Z
+ \*ABS\*:00000000000000b0 Z0
+
+NO UNDEFINED SYMBOLS
--- /dev/null
+# All-registers, 'T'-type operands; optional third operand is
+# register or constant.
+Main LDA X,Y,Z
+ LDT $32,Y,Z
+ LDBU Y,$32,Z
+ LDTU $232,$133,Z
+ LDO X,Y,$73
+ LDOU $31,Y,$233
+ LDW X,$38,$212
+ LDWU $4,$175,$181
+
+ LDB X,Y,Z0
+ LDSF $32,Y,Z0
+ LDVTS Y,$32,Z0
+ LDUNC $232,$133,Z0
+ STHT X,Y,203
+ LDHT $31,Y,213
+ CSWAP X,$38,211
+ GO $4,$175,161
+
+ LDA X,Y
+ LDB X,Y
+ LDT X,Y
+ LDBU X,Y
+ LDTU X,Y
+ LDO X,Y
+ LDOU X,Y
+ LDW X,Y
+ LDWU X,Y
+ LDSF X,Y
+ LDHT X,Y
+ CSWAP X,Y
+ LDUNC X,Y
+ LDVTS X,Y
+ GO X,Y
+ STB X,Y
+ STT X,Y
+ STBU X,Y
+ STTU X,Y
+ STO X,Y
+ STOU X,Y
+ STW X,Y
+ STWU X,Y
+ STSF X,Y
+ STHT X,Y
+ STUNC X,Y
+
+ LDA $41,Y
+ LDB $121,Y
+ LDT $78,Y
+ LDBU $127,Y
+ LDTU $49,Y
+ LDO $52,Y
+ LDOU $42,Y
+ LDW $123,Y
+ LDWU $234,Y
+ LDSF $41,Y
+ LDHT $89,Y
+ CSWAP $93,Y
+ LDUNC $42,Y
+ LDVTS $33,Y
+ GO $59,Y
+ STB $59,Y
+ STT $59,Y
+ STBU $59,Y
+ STTU $59,Y
+ STO $59,Y
+ STOU $59,Y
+ STW $59,Y
+ STWU $59,Y
+ STSF $59,Y
+ STHT $59,Y
+ STUNC $59,Y
+
+ LDA X,$27
+ LDB X,$48
+ LDT X,$168
+ LDBU X,$234
+ LDTU X,$176
+ LDO X,$29
+ LDOU X,$222
+ LDW X,$222
+ LDWU X,$222
+ LDSF X,$222
+ LDHT X,$222
+ CSWAP X,$222
+ LDUNC X,$222
+ LDVTS X,$222
+ GO X,$222
+ STB X,$222
+ STT X,$222
+ STBU X,$222
+ STTU X,$222
+ STO X,$222
+ STOU X,$222
+ STW X,$222
+ STWU X,$222
+ STSF X,$222
+ STHT X,$222
+ STUNC X,$222
+
+ LDA $223,$219
+ LDB $223,$239
+ LDT $223,$239
+ LDBU $223,$29
+ LDTU $223,$239
+ LDO $23,$239
+ LDOU $223,$239
+ LDW $223,$209
+ LDWU $123,$239
+ LDSF $223,$239
+ LDHT $223,$29
+ CSWAP $223,$239
+ LDUNC $123,$239
+ LDVTS $223,$239
+ GO $223,$239
+ STB $223,$239
+ STT $223,$249
+ STBU $203,$239
+ STTU $73,$239
+ STO $223,$239
+ STOU $223,$39
+ STW $223,$239
+ STWU $233,$239
+ STSF $223,$239
+ STHT $223,$23
+ STUNC $223,$239
+
+ GO X,Y,0
+ LDVTS $32,Y,0
+ STB Y,$32,0
+ STUNC $232,$133,0
+ STWU X,Y,0
+ STO $31,Y,0
+ GO X,$38,0
+ CSWAP $4,$175,0
+X IS $23
+Y IS $12
+Z IS $67
+Z0 IS 176
--- /dev/null
+# objdump: -dr
+# as: -linkrelax
+# source: regx-op.s
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: 9a7b0c43 preld 123,\$12,\$67
+ 4: 9c200c43 prego 32,\$12,\$67
+ 8: b87b2043 syncd 123,\$32,\$67
+ c: ba008543 prest 0,\$133,\$67
+ 10: b47b0c49 stco 123,\$12,\$73
+ 14: bc820ce9 syncid 130,\$12,\$233
+ 18: 9a7b26d4 preld 123,\$38,\$212
+ 1c: 9c01afb5 prego 1,\$175,\$181
+ 20: b97b0cb0 syncd 123,\$12,176
+ 24: bb200cb0 prest 32,\$12,176
+ 28: b57b84b0 stco 123,\$132,176
+ 2c: bde885b0 syncid 232,\$133,176
+ 30: 9b7b0ccb preld 123,\$12,203
+ 34: 9de70cd5 prego 231,\$12,213
+ 38: b97b26d3 syncd 123,\$38,211
+ 3c: bb04afa1 prest 4,\$175,161
+ 40: b57b0c00 stco 123,\$12,0
+ 44: bd170c00 syncid 23,\$12,0
+ 48: 9b020c00 preld 2,\$12,0
+ 4c: 9de88500 prego 232,\$133,0
+ 50: b97b0c00 syncd 123,\$12,0
+ 54: bb0d0c00 prest 13,\$12,0
+ 58: b57b2600 stco 123,\$38,0
+ 5c: bd04af00 syncid 4,\$175,0
+ 60: 9b7b0c00 preld 123,\$12,0
+ 64: 9d200c00 prego 32,\$12,0
+ 68: b97b2000 syncd 123,\$32,0
+ 6c: bbe88500 prest 232,\$133,0
--- /dev/null
+# objdump: -dr
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: 9a7b0c43 preld 123,\$12,\$67
+ 4: 9c200c43 prego 32,\$12,\$67
+ 8: b87b2043 syncd 123,\$32,\$67
+ c: ba008543 prest 0,\$133,\$67
+ 10: b47b0c49 stco 123,\$12,\$73
+ 14: bc820ce9 syncid 130,\$12,\$233
+ 18: 9a7b26d4 preld 123,\$38,\$212
+ 1c: 9c01afb5 prego 1,\$175,\$181
+ 20: b97b0cb0 syncd 123,\$12,176
+ 24: bb200cb0 prest 32,\$12,176
+ 28: b57b84b0 stco 123,\$132,176
+ 2c: bde885b0 syncid 232,\$133,176
+ 30: 9b7b0ccb preld 123,\$12,203
+ 34: 9de70cd5 prego 231,\$12,213
+ 38: b97b26d3 syncd 123,\$38,211
+ 3c: bb04afa1 prest 4,\$175,161
+ 40: b57b0c00 stco 123,\$12,0
+ 44: bd170c00 syncid 23,\$12,0
+ 48: 9b020c00 preld 2,\$12,0
+ 4c: 9de88500 prego 232,\$133,0
+ 50: b97b0c00 syncd 123,\$12,0
+ 54: bb0d0c00 prest 13,\$12,0
+ 58: b57b2600 stco 123,\$38,0
+ 5c: bd04af00 syncid 4,\$175,0
+ 60: 9b7b0c00 preld 123,\$12,0
+ 64: 9d200c00 prego 32,\$12,0
+ 68: b97b2000 syncd 123,\$32,0
+ 6c: bbe88500 prest 232,\$133,0
--- /dev/null
+GAS for MMIX .*/regx-op\.s page 1
+
+
+ 1 #.*
+ 2 #.*
+ 3 0000 9A7B0C43 Main PRELD X,Y,Z
+ 4 0004 9C200C43 PREGO 32,Y,Z
+ 5 0008 B87B2043 SYNCD X,\$32,Z
+ 6 000c BA008543 PREST 0,\$133,Z
+ 7 0010 B47B0C49 STCO X,Y,\$73
+ 8 0014 BC820CE9 SYNCID 130,Y,\$233
+ 9 0018 9A7B26D4 PRELD X,\$38,\$212
+ 10 001c 9C01AFB5 PREGO 1,\$175,\$181
+ 11
+ 12 0020 B97B0CB0 SYNCD X,Y,Z0
+ 13 0024 BB200CB0 PREST 32,Y,Z0
+ 14 0028 B57B84B0 STCO X,\$132,Z0
+ 15 002c BDE885B0 SYNCID 232,\$133,Z0
+ 16 0030 9B7B0CCB PRELD X,Y,203
+ 17 0034 9DE70CD5 PREGO 231,Y,213
+ 18 0038 B97B26D3 SYNCD X,\$38,211
+ 19 003c BB04AFA1 PREST 4,\$175,161
+ 20
+ 21 0040 B57B0C00 STCO X,Y,0
+ 22 0044 BD170C00 SYNCID 23,Y,0
+ 23 0048 9B020C00 PRELD 2,Y,0
+ 24 004c 9DE88500 PREGO 232,\$133,0
+ 25 0050 B97B0C00 SYNCD X,Y,0
+ 26 0054 BB0D0C00 PREST 13,Y,0
+ 27 0058 B57B2600 STCO X,\$38,0
+ 28 005c BD04AF00 SYNCID 4,\$175,0
+ 29
+ 30 0060 9B7B0C00 PRELD X,Y
+ 31 0064 9D200C00 PREGO 32,Y
+ 32 0068 B97B2000 SYNCD X,\$32
+ 33 006c BBE88500 PREST 232,\$133
+ 34 X IS 123
+ 35 Y IS \$12
+ 36 Z IS \$67
+ 37 Z0 IS 176
+\fGAS for MMIX .*/regx-op\.s page 2
+
+
+DEFINED SYMBOLS
+.*/regx-op\.s:3 \.text:0000000000000000 Main
+ \*ABS\*:000000000000007b X
+ \*REG\*:000000000000000c Y
+ \*REG\*:0000000000000043 Z
+ \*ABS\*:00000000000000b0 Z0
+
+NO UNDEFINED SYMBOLS
--- /dev/null
+# For insns where X is a constant: 'X'-type operands.
+#
+Main PRELD X,Y,Z
+ PREGO 32,Y,Z
+ SYNCD X,$32,Z
+ PREST 0,$133,Z
+ STCO X,Y,$73
+ SYNCID 130,Y,$233
+ PRELD X,$38,$212
+ PREGO 1,$175,$181
+
+ SYNCD X,Y,Z0
+ PREST 32,Y,Z0
+ STCO X,$132,Z0
+ SYNCID 232,$133,Z0
+ PRELD X,Y,203
+ PREGO 231,Y,213
+ SYNCD X,$38,211
+ PREST 4,$175,161
+
+ STCO X,Y,0
+ SYNCID 23,Y,0
+ PRELD 2,Y,0
+ PREGO 232,$133,0
+ SYNCD X,Y,0
+ PREST 13,Y,0
+ STCO X,$38,0
+ SYNCID 4,$175,0
+
+ PRELD X,Y
+ PREGO 32,Y
+ SYNCD X,$32
+ PREST 232,$133
+X IS 123
+Y IS $12
+Z IS $67
+Z0 IS 176
--- /dev/null
+# objdump: -dr
+# as: -linkrelax
+# source: regy-op.s
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: 347b0c43 neg \$123,12,\$67
+ 4: 36200c43 negu \$32,12,\$67
+ 8: 347b2043 neg \$123,32,\$67
+ c: 36008543 negu \$0,133,\$67
+ 10: 347b0c49 neg \$123,12,\$73
+ 14: 36820ce9 negu \$130,12,\$233
+ 18: 347b26d4 neg \$123,38,\$212
+ 1c: 3601afb5 negu \$1,175,\$181
+ 20: 357b0cb0 neg \$123,12,176
+ 24: 37200cb0 negu \$32,12,176
+ 28: 357b84b0 neg \$123,132,176
+ 2c: 37e885b0 negu \$232,133,176
+ 30: 357b0ccb neg \$123,12,203
+ 34: 37e70cd5 negu \$231,12,213
+ 38: 357b26d3 neg \$123,38,211
+ 3c: 3704afa1 negu \$4,175,161
+ 40: 357b0c00 neg \$123,12,0
+ 44: 37170c00 negu \$23,12,0
+ 48: 35020c00 neg \$2,12,0
+ 4c: 37e88500 negu \$232,133,0
+ 50: 347b0043 neg \$123,0,\$67
+ 54: 36200043 negu \$32,0,\$67
+ 58: 357b0020 neg \$123,0,32
+ 5c: 37e80085 negu \$232,0,133
+ 60: 357b00b0 neg \$123,0,176
+ 64: 372000b0 negu \$32,0,176
+ 68: 347b0020 neg \$123,0,\$32
+ 6c: 36e80085 negu \$232,0,\$133
--- /dev/null
+# objdump: -dr
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: 347b0c43 neg \$123,12,\$67
+ 4: 36200c43 negu \$32,12,\$67
+ 8: 347b2043 neg \$123,32,\$67
+ c: 36008543 negu \$0,133,\$67
+ 10: 347b0c49 neg \$123,12,\$73
+ 14: 36820ce9 negu \$130,12,\$233
+ 18: 347b26d4 neg \$123,38,\$212
+ 1c: 3601afb5 negu \$1,175,\$181
+ 20: 357b0cb0 neg \$123,12,176
+ 24: 37200cb0 negu \$32,12,176
+ 28: 357b84b0 neg \$123,132,176
+ 2c: 37e885b0 negu \$232,133,176
+ 30: 357b0ccb neg \$123,12,203
+ 34: 37e70cd5 negu \$231,12,213
+ 38: 357b26d3 neg \$123,38,211
+ 3c: 3704afa1 negu \$4,175,161
+ 40: 357b0c00 neg \$123,12,0
+ 44: 37170c00 negu \$23,12,0
+ 48: 35020c00 neg \$2,12,0
+ 4c: 37e88500 negu \$232,133,0
+ 50: 347b0043 neg \$123,0,\$67
+ 54: 36200043 negu \$32,0,\$67
+ 58: 357b0020 neg \$123,0,32
+ 5c: 37e80085 negu \$232,0,133
+ 60: 357b00b0 neg \$123,0,176
+ 64: 372000b0 negu \$32,0,176
+ 68: 347b0020 neg \$123,0,\$32
+ 6c: 36e80085 negu \$232,0,\$133
--- /dev/null
+GAS for MMIX .*/regy-op\.s page 1
+
+
+ 1 #.*
+ 2 #.*
+ 3 0000 347B0C43 Main NEG X,Y,Z
+ 4 0004 36200C43 NEGU \$32,Y,Z
+ 5 0008 347B2043 NEG X,32,Z
+ 6 000c 36008543 NEGU \$0,133,Z
+ 7 0010 347B0C49 NEG X,Y,\$73
+ 8 0014 36820CE9 NEGU \$130,Y,\$233
+ 9 0018 347B26D4 NEG X,38,\$212
+ 10 001c 3601AFB5 NEGU \$1,175,\$181
+ 11
+ 12 0020 357B0CB0 NEG X,Y,Z0
+ 13 0024 37200CB0 NEGU \$32,Y,Z0
+ 14 0028 357B84B0 NEG X,132,Z0
+ 15 002c 37E885B0 NEGU \$232,133,Z0
+ 16 0030 357B0CCB NEG X,Y,203
+ 17 0034 37E70CD5 NEGU \$231,Y,213
+ 18 0038 357B26D3 NEG X,38,211
+ 19 003c 3704AFA1 NEGU \$4,175,161
+ 20
+ 21 0040 357B0C00 NEG X,Y,0
+ 22 0044 37170C00 NEGU \$23,Y,0
+ 23 0048 35020C00 NEG \$2,Y,0
+ 24 004c 37E88500 NEGU \$232,133,0
+ 25
+ 26 0050 347B0043 NEG X,Z
+ 27 0054 36200043 NEGU \$32,Z
+ 28 0058 357B0020 NEG X,32
+ 29 005c 37E80085 NEGU \$232,133
+ 30 0060 357B00B0 NEG X,Z0
+ 31 0064 372000B0 NEGU \$32,Z0
+ 32 0068 347B0020 NEG X,\$32
+ 33 006c 36E80085 NEGU \$232,\$133
+ 34 X IS \$123
+ 35 Y IS 12
+ 36 Z IS \$67
+ 37 Z0 IS 176
+\fGAS for MMIX .*/regy-op\.s page 2
+
+
+DEFINED SYMBOLS
+.*/regy-op\.s:3 \.text:0000000000000000 Main
+ \*REG\*:000000000000007b X
+ \*ABS\*:000000000000000c Y
+ \*REG\*:0000000000000043 Z
+ \*ABS\*:00000000000000b0 Z0
+
+NO UNDEFINED SYMBOLS
--- /dev/null
+# For insns where Y is a constant: 'Y'-type operands.
+# Only NEG and NEGU, actually.
+Main NEG X,Y,Z
+ NEGU $32,Y,Z
+ NEG X,32,Z
+ NEGU $0,133,Z
+ NEG X,Y,$73
+ NEGU $130,Y,$233
+ NEG X,38,$212
+ NEGU $1,175,$181
+
+ NEG X,Y,Z0
+ NEGU $32,Y,Z0
+ NEG X,132,Z0
+ NEGU $232,133,Z0
+ NEG X,Y,203
+ NEGU $231,Y,213
+ NEG X,38,211
+ NEGU $4,175,161
+
+ NEG X,Y,0
+ NEGU $23,Y,0
+ NEG $2,Y,0
+ NEGU $232,133,0
+
+ NEG X,Z
+ NEGU $32,Z
+ NEG X,32
+ NEGU $232,133
+ NEG X,Z0
+ NEGU $32,Z0
+ NEG X,$32
+ NEGU $232,$133
+X IS $123
+Y IS 12
+Z IS $67
+Z0 IS 176
--- /dev/null
+#objdump: -dr
+#as: -no-expand -x
+#source: relax1.s
+#
+# FIXME: This test-case assumes that out-of-range errors cause relocs to
+# be emitted, rather than errors emitted.
+
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: f0020009 jmp 80024 <l6>
+
+0000000000000004 <l0>:
+ 4: f0020008 jmp 80024 <l6>
+
+0000000000000008 <l1>:
+ 8: f0020007 jmp 80024 <l6>
+
+000000000000000c <l01>:
+ c: f0020006 jmp 80024 <l6>
+ 10: f407ffff geta \$7,4000c <nearfar1>
+ 14: f2bfffff pushj \$191,40010 <nearfar2>
+
+0000000000000018 <l2>:
+ 18: f000fffe jmp 40010 <nearfar2>
+ \.\.\.
+ 40004: 4d480000 bnp \$72,4 <l0>
+ 40008: f5040000 geta \$4,8 <l1>
+
+000000000004000c <nearfar1>:
+ 4000c: f3050000 pushj \$5,c <l01>
+
+0000000000040010 <nearfar2>:
+ 40010: f4090000 geta \$9,40010 <nearfar2>
+ 40010: R_MMIX_ADDR19 \.text\+0x8
+ 40014: f20b0000 pushj \$11,40014 <nearfar2\+0x4>
+ 40014: R_MMIX_ADDR19 \.text\+0x80014
+
+0000000000040018 <l4>:
+ 40018: 4437ffff bp \$55,80014 <l3>
+ ...
+ 80010: f1fdfffe jmp 8 <l1>
+
+0000000000080014 <l3>:
+ 80014: f1fdfffc jmp 4 <l0>
+ 80018: 47580000 bod \$88,40018 <l4>
+ 8001c: 46580000 bod \$88,8001c <l3\+0x8>
+ 8001c: R_MMIX_ADDR19 \.text\+0x40018
+ 80020: f0000000 jmp 80020 <l3\+0xc>
+ 80020: R_MMIX_ADDR27 \.text\+0x4080020
+
+0000000000080024 <l6>:
+ 80024: f0ffffff jmp 4080020 <l5>
+ 80028: 436ffffb bz \$111,80014 <l3>
+ \.\.\.
+
+0000000004080020 <l5>:
+ 4080020: f0000004 jmp 4080030 <l8>
+ 4080024: f1000000 jmp 80024 <l6>
+ 4080028: f0000000 jmp 4080028 <l5\+0x8>
+ 4080028: R_MMIX_ADDR27 \.text\+0x80024
+ 408002c: 482c0000 bnn \$44,408002c <l5\+0xc>
+ 408002c: R_MMIX_ADDR19 \.text\+0x40c002c
+
+0000000004080030 <l8>:
+ 4080030: 482cffff bnn \$44,40c002c <l9>
+ 4080034: f1fffffb jmp 4080020 <l5>
+ 4080038: f1fffffa jmp 4080020 <l5>
+ \.\.\.
+
+00000000040c0028 <l10>:
+ 40c0028: f1fefffe jmp 4080020 <l5>
+
+00000000040c002c <l9>:
+ 40c002c: f0000003 jmp 40c0038 <l11>
+
+00000000040c0030 <l7>:
+ 40c0030: f3210000 pushj \$33,4080030 <l8>
+ 40c0034: f2210000 pushj \$33,40c0034 <l7\+0x4>
+ 40c0034: R_MMIX_ADDR19 \.text\+0x4080030
+
+00000000040c0038 <l11>:
+ 40c0038: f1fefffa jmp 4080020 <l5>
+ 40c003c: f1fefffd jmp 4080030 <l8>
+ \.\.\.
+ 4100038: f53d0000 geta \$61,40c0038 <l11>
+ 410003c: f4480000 geta \$72,410003c <l11\+0x40004>
+ 410003c: R_MMIX_ADDR19 \.text\+0x40c0038
--- /dev/null
+#objdump: -dr
+#as: -linkrelax -x
+#source: relax1.s
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: f0020019 jmp 80064 <l6>
+ 0: R_MMIX_ADDR27 \.text\+0x80064
+
+0000000000000004 <l0>:
+ 4: f0020018 jmp 80064 <l6>
+ 4: R_MMIX_ADDR27 \.text\+0x80064
+
+0000000000000008 <l1>:
+ 8: f0020017 jmp 80064 <l6>
+ 8: R_MMIX_ADDR27 \.text\+0x80064
+
+000000000000000c <l01>:
+ c: f0020016 jmp 80064 <l6>
+ c: R_MMIX_ADDR27 \.text\+0x80064
+ 10: f407ffff geta \$7,4000c <nearfar1>
+ 10: R_MMIX_ADDR19 \.text\+0x4000c
+ 14: f2bfffff pushj \$191,40010 <nearfar2>
+ 14: R_MMIX_ADDR19 \.text\+0x40010
+
+0000000000000018 <l2>:
+ 18: f000fffe jmp 40010 <nearfar2>
+ 18: R_MMIX_ADDR27 \.text\+0x40010
+ \.\.\.
+ 40004: 4d480000 bnp \$72,4 <l0>
+ 40004: R_MMIX_ADDR19 \.text\+0x4
+ 40008: f5040000 geta \$4,8 <l1>
+ 40008: R_MMIX_ADDR19 \.text\+0x8
+
+000000000004000c <nearfar1>:
+ 4000c: f3050000 pushj \$5,c <l01>
+ 4000c: R_MMIX_ADDR19 \.text\+0xc
+
+0000000000040010 <nearfar2>:
+ 40010: f4090000 geta \$9,40010 <nearfar2>
+ 40010: R_MMIX_GETA \.text\+0x8
+ 40014: fd000000 swym 0,0,0
+ 40018: fd000000 swym 0,0,0
+ 4001c: fd000000 swym 0,0,0
+ 40020: f20b0000 pushj \$11,40020 <nearfar2\+0x10>
+ 40020: R_MMIX_PUSHJ \.text\+0x80030
+ 40024: fd000000 swym 0,0,0
+ 40028: fd000000 swym 0,0,0
+ 4002c: fd000000 swym 0,0,0
+ 40030: fd000000 swym 0,0,0
+
+0000000000040034 <l4>:
+ 40034: 4437ffff bp \$55,80030 <l3>
+ 40034: R_MMIX_ADDR19 \.text\+0x80030
+ \.\.\.
+ 8002c: f1fdfff7 jmp 8 <l1>
+ 8002c: R_MMIX_ADDR27 \.text\+0x8
+
+0000000000080030 <l3>:
+ 80030: f1fdfff5 jmp 4 <l0>
+ 80030: R_MMIX_ADDR27 \.text\+0x4
+ 80034: 47580000 bod \$88,40034 <l4>
+ 80034: R_MMIX_ADDR19 \.text\+0x40034
+ 80038: 46580000 bod \$88,80038 <l3\+0x8>
+ 80038: R_MMIX_CBRANCH \.text\+0x40034
+ 8003c: fd000000 swym 0,0,0
+ 80040: fd000000 swym 0,0,0
+ 80044: fd000000 swym 0,0,0
+ 80048: fd000000 swym 0,0,0
+ 8004c: fd000000 swym 0,0,0
+ 80050: f0000000 jmp 80050 <l3\+0x20>
+ 80050: R_MMIX_JMP \.text\+0x4080060
+ 80054: fd000000 swym 0,0,0
+ 80058: fd000000 swym 0,0,0
+ 8005c: fd000000 swym 0,0,0
+ 80060: fd000000 swym 0,0,0
+
+0000000000080064 <l6>:
+ 80064: f0ffffff jmp 4080060 <l5>
+ 80064: R_MMIX_ADDR27 \.text\+0x4080060
+ 80068: 436ffff2 bz \$111,80030 <l3>
+ 80068: R_MMIX_ADDR19 \.text\+0x80030
+ \.\.\.
+
+0000000004080060 <l5>:
+ 4080060: f000000d jmp 4080094 <l8>
+ 4080060: R_MMIX_ADDR27 \.text\+0x4080094
+ 4080064: f1000000 jmp 80064 <l6>
+ 4080064: R_MMIX_ADDR27 \.text\+0x80064
+ 4080068: f0000000 jmp 4080068 <l5\+0x8>
+ 4080068: R_MMIX_JMP \.text\+0x80064
+ 408006c: fd000000 swym 0,0,0
+ 4080070: fd000000 swym 0,0,0
+ 4080074: fd000000 swym 0,0,0
+ 4080078: fd000000 swym 0,0,0
+ 408007c: 482c0000 bnn \$44,408007c <l5\+0x1c>
+ 408007c: R_MMIX_CBRANCH \.text\+0x40c0090
+ 4080080: fd000000 swym 0,0,0
+ 4080084: fd000000 swym 0,0,0
+ 4080088: fd000000 swym 0,0,0
+ 408008c: fd000000 swym 0,0,0
+ 4080090: fd000000 swym 0,0,0
+
+0000000004080094 <l8>:
+ 4080094: 482cffff bnn \$44,40c0090 <l9>
+ 4080094: R_MMIX_ADDR19 \.text\+0x40c0090
+ 4080098: f1fffff2 jmp 4080060 <l5>
+ 4080098: R_MMIX_ADDR27 \.text\+0x4080060
+ 408009c: f1fffff1 jmp 4080060 <l5>
+ 408009c: R_MMIX_ADDR27 \.text\+0x4080060
+ \.\.\.
+
+00000000040c008c <l10>:
+ 40c008c: f1fefff5 jmp 4080060 <l5>
+ 40c008c: R_MMIX_ADDR27 \.text\+0x4080060
+
+00000000040c0090 <l9>:
+ 40c0090: f0000007 jmp 40c00ac <l11>
+ 40c0090: R_MMIX_ADDR27 \.text\+0x40c00ac
+
+00000000040c0094 <l7>:
+ 40c0094: f3210000 pushj \$33,4080094 <l8>
+ 40c0094: R_MMIX_ADDR19 \.text\+0x4080094
+ 40c0098: f2210000 pushj \$33,40c0098 <l7\+0x4>
+ 40c0098: R_MMIX_PUSHJ \.text\+0x4080094
+ 40c009c: fd000000 swym 0,0,0
+ 40c00a0: fd000000 swym 0,0,0
+ 40c00a4: fd000000 swym 0,0,0
+ 40c00a8: fd000000 swym 0,0,0
+
+00000000040c00ac <l11>:
+ 40c00ac: f1feffed jmp 4080060 <l5>
+ 40c00ac: R_MMIX_ADDR27 \.text\+0x4080060
+ 40c00b0: f1fefff9 jmp 4080094 <l8>
+ 40c00b0: R_MMIX_ADDR27 \.text\+0x4080094
+ \.\.\.
+ 41000ac: f53d0000 geta \$61,40c00ac <l11>
+ 41000ac: R_MMIX_ADDR19 \.text\+0x40c00ac
+ 41000b0: f4480000 geta \$72,41000b0 <l11\+0x40004>
+ 41000b0: R_MMIX_GETA \.text\+0x40c00ac
+ 41000b4: fd000000 swym 0,0,0
+ 41000b8: fd000000 swym 0,0,0
+ 41000bc: fd000000 swym 0,0,0
--- /dev/null
+#objdump: -dr
+#as: -linkrelax -no-expand -x
+#source: relax1.s
+#
+# FIXME: This test-case assumes that out-of-range errors (still) cause
+# relocs to be emitted, rather than errors emitted.
+
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: f0000000 jmp 0 <Main>
+ 0: R_MMIX_ADDR27 \.text\+0x80024
+
+0000000000000004 <l0>:
+ 4: f0000000 jmp 4 <l0>
+ 4: R_MMIX_ADDR27 \.text\+0x80024
+
+0000000000000008 <l1>:
+ 8: f0000000 jmp 8 <l1>
+ 8: R_MMIX_ADDR27 \.text\+0x80024
+
+000000000000000c <l01>:
+ c: f0000000 jmp c <l01>
+ c: R_MMIX_ADDR27 \.text\+0x80024
+ 10: f4070000 geta \$7,10 <l01\+0x4>
+ 10: R_MMIX_ADDR19 \.text\+0x4000c
+ 14: f2bf0000 pushj \$191,14 <l01\+0x8>
+ 14: R_MMIX_ADDR19 \.text\+0x40010
+
+0000000000000018 <l2>:
+ 18: f0000000 jmp 18 <l2>
+ 18: R_MMIX_ADDR27 \.text\+0x40010
+ \.\.\.
+ 40004: 4c480000 bnp \$72,40004 <l2\+0x3ffec>
+ 40004: R_MMIX_ADDR19 \.text\+0x4
+ 40008: f4040000 geta \$4,40008 <l2\+0x3fff0>
+ 40008: R_MMIX_ADDR19 \.text\+0x8
+
+000000000004000c <nearfar1>:
+ 4000c: f2050000 pushj \$5,4000c <nearfar1>
+ 4000c: R_MMIX_ADDR19 \.text\+0xc
+
+0000000000040010 <nearfar2>:
+ 40010: f4090000 geta \$9,40010 <nearfar2>
+ 40010: R_MMIX_ADDR19 \.text\+0x8
+ 40014: f20b0000 pushj \$11,40014 <nearfar2\+0x4>
+ 40014: R_MMIX_ADDR19 \.text\+0x80014
+
+0000000000040018 <l4>:
+ 40018: 44370000 bp \$55,40018 <l4>
+ 40018: R_MMIX_ADDR19 \.text\+0x80014
+ \.\.\.
+ 80010: f0000000 jmp 80010 <l4\+0x3fff8>
+ 80010: R_MMIX_ADDR27 \.text\+0x8
+
+0000000000080014 <l3>:
+ 80014: f0000000 jmp 80014 <l3>
+ 80014: R_MMIX_ADDR27 \.text\+0x4
+ 80018: 46580000 bod \$88,80018 <l3\+0x4>
+ 80018: R_MMIX_ADDR19 \.text\+0x40018
+ 8001c: 46580000 bod \$88,8001c <l3\+0x8>
+ 8001c: R_MMIX_ADDR19 \.text\+0x40018
+ 80020: f0000000 jmp 80020 <l3\+0xc>
+ 80020: R_MMIX_ADDR27 \.text\+0x4080020
+
+0000000000080024 <l6>:
+ 80024: f0000000 jmp 80024 <l6>
+ 80024: R_MMIX_ADDR27 \.text\+0x4080020
+ 80028: 426f0000 bz \$111,80028 <l6\+0x4>
+ 80028: R_MMIX_ADDR19 \.text\+0x80014
+ \.\.\.
+
+0000000004080020 <l5>:
+ 4080020: f0000000 jmp 4080020 <l5>
+ 4080020: R_MMIX_ADDR27 \.text\+0x4080030
+ 4080024: f0000000 jmp 4080024 <l5\+0x4>
+ 4080024: R_MMIX_ADDR27 \.text\+0x80024
+ 4080028: f0000000 jmp 4080028 <l5\+0x8>
+ 4080028: R_MMIX_ADDR27 \.text\+0x80024
+ 408002c: 482c0000 bnn \$44,408002c <l5\+0xc>
+ 408002c: R_MMIX_ADDR19 \.text\+0x40c002c
+
+0000000004080030 <l8>:
+ 4080030: 482c0000 bnn \$44,4080030 <l8>
+ 4080030: R_MMIX_ADDR19 \.text\+0x40c002c
+ 4080034: f0000000 jmp 4080034 <l8\+0x4>
+ 4080034: R_MMIX_ADDR27 \.text\+0x4080020
+ 4080038: f0000000 jmp 4080038 <l8\+0x8>
+ 4080038: R_MMIX_ADDR27 \.text\+0x4080020
+ \.\.\.
+
+00000000040c0028 <l10>:
+ 40c0028: f0000000 jmp 40c0028 <l10>
+ 40c0028: R_MMIX_ADDR27 \.text\+0x4080020
+
+00000000040c002c <l9>:
+ 40c002c: f0000000 jmp 40c002c <l9>
+ 40c002c: R_MMIX_ADDR27 \.text\+0x40c0038
+
+00000000040c0030 <l7>:
+ 40c0030: f2210000 pushj \$33,40c0030 <l7>
+ 40c0030: R_MMIX_ADDR19 \.text\+0x4080030
+ 40c0034: f2210000 pushj \$33,40c0034 <l7\+0x4>
+ 40c0034: R_MMIX_ADDR19 \.text\+0x4080030
+
+00000000040c0038 <l11>:
+ 40c0038: f0000000 jmp 40c0038 <l11>
+ 40c0038: R_MMIX_ADDR27 \.text\+0x4080020
+ 40c003c: f0000000 jmp 40c003c <l11\+0x4>
+ 40c003c: R_MMIX_ADDR27 \.text\+0x4080030
+ \.\.\.
+ 4100038: f43d0000 geta \$61,4100038 <l11\+0x40000>
+ 4100038: R_MMIX_ADDR19 \.text\+0x40c0038
+ 410003c: f4480000 geta \$72,410003c <l11\+0x40004>
+ 410003c: R_MMIX_ADDR19 \.text\+0x40c0038
--- /dev/null
+#objdump: -dr
+#as: -x
+
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: f0020019 jmp 80064 <l6>
+
+0000000000000004 <l0>:
+ 4: f0020018 jmp 80064 <l6>
+
+0000000000000008 <l1>:
+ 8: f0020017 jmp 80064 <l6>
+
+000000000000000c <l01>:
+ c: f0020016 jmp 80064 <l6>
+ 10: f407ffff geta \$7,4000c <nearfar1>
+ 14: f2bfffff pushj \$191,40010 <nearfar2>
+
+0000000000000018 <l2>:
+ 18: f000fffe jmp 40010 <nearfar2>
+ \.\.\.
+ 40004: 4d480000 bnp \$72,4 <l0>
+ 40008: f5040000 geta \$4,8 <l1>
+
+000000000004000c <nearfar1>:
+ 4000c: f3050000 pushj \$5,c <l01>
+
+0000000000040010 <nearfar2>:
+ 40010: f4090000 geta \$9,40010 <nearfar2>
+ 40010: R_MMIX_GETA \.text\+0x8
+ 40014: fd000000 swym 0,0,0
+ 40018: fd000000 swym 0,0,0
+ 4001c: fd000000 swym 0,0,0
+ 40020: f20b0000 pushj \$11,40020 <nearfar2\+0x10>
+ 40020: R_MMIX_PUSHJ \.text\+0x80030
+ 40024: fd000000 swym 0,0,0
+ 40028: fd000000 swym 0,0,0
+ 4002c: fd000000 swym 0,0,0
+ 40030: fd000000 swym 0,0,0
+
+0000000000040034 <l4>:
+ 40034: 4437ffff bp \$55,80030 <l3>
+ \.\.\.
+ 8002c: f1fdfff7 jmp 8 <l1>
+
+0000000000080030 <l3>:
+ 80030: f1fdfff5 jmp 4 <l0>
+ 80034: 47580000 bod \$88,40034 <l4>
+ 80038: 46580000 bod \$88,80038 <l3\+0x8>
+ 80038: R_MMIX_CBRANCH \.text\+0x40034
+ 8003c: fd000000 swym 0,0,0
+ 80040: fd000000 swym 0,0,0
+ 80044: fd000000 swym 0,0,0
+ 80048: fd000000 swym 0,0,0
+ 8004c: fd000000 swym 0,0,0
+ 80050: f0000000 jmp 80050 <l3\+0x20>
+ 80050: R_MMIX_JMP \.text\+0x4080060
+ 80054: fd000000 swym 0,0,0
+ 80058: fd000000 swym 0,0,0
+ 8005c: fd000000 swym 0,0,0
+ 80060: fd000000 swym 0,0,0
+
+0000000000080064 <l6>:
+ 80064: f0ffffff jmp 4080060 <l5>
+ 80068: 436ffff2 bz \$111,80030 <l3>
+ \.\.\.
+
+0000000004080060 <l5>:
+ 4080060: f000000d jmp 4080094 <l8>
+ 4080064: f1000000 jmp 80064 <l6>
+ 4080068: f0000000 jmp 4080068 <l5\+0x8>
+ 4080068: R_MMIX_JMP \.text\+0x80064
+ 408006c: fd000000 swym 0,0,0
+ 4080070: fd000000 swym 0,0,0
+ 4080074: fd000000 swym 0,0,0
+ 4080078: fd000000 swym 0,0,0
+ 408007c: 482c0000 bnn \$44,408007c <l5\+0x1c>
+ 408007c: R_MMIX_CBRANCH \.text\+0x40c0090
+ 4080080: fd000000 swym 0,0,0
+ 4080084: fd000000 swym 0,0,0
+ 4080088: fd000000 swym 0,0,0
+ 408008c: fd000000 swym 0,0,0
+ 4080090: fd000000 swym 0,0,0
+
+0000000004080094 <l8>:
+ 4080094: 482cffff bnn \$44,40c0090 <l9>
+ 4080098: f1fffff2 jmp 4080060 <l5>
+ 408009c: f1fffff1 jmp 4080060 <l5>
+ \.\.\.
+
+00000000040c008c <l10>:
+ 40c008c: f1fefff5 jmp 4080060 <l5>
+
+00000000040c0090 <l9>:
+ 40c0090: f0000007 jmp 40c00ac <l11>
+
+00000000040c0094 <l7>:
+ 40c0094: f3210000 pushj \$33,4080094 <l8>
+ 40c0098: f2210000 pushj \$33,40c0098 <l7\+0x4>
+ 40c0098: R_MMIX_PUSHJ \.text\+0x4080094
+ 40c009c: fd000000 swym 0,0,0
+ 40c00a0: fd000000 swym 0,0,0
+ 40c00a4: fd000000 swym 0,0,0
+ 40c00a8: fd000000 swym 0,0,0
+
+00000000040c00ac <l11>:
+ 40c00ac: f1feffed jmp 4080060 <l5>
+ 40c00b0: f1fefff9 jmp 4080094 <l8>
+ \.\.\.
+ 41000ac: f53d0000 geta \$61,40c00ac <l11>
+ 41000b0: f4480000 geta \$72,41000b0 <l11\+0x40004>
+ 41000b0: R_MMIX_GETA \.text\+0x40c00ac
+ 41000b4: fd000000 swym 0,0,0
+ 41000b8: fd000000 swym 0,0,0
+ 41000bc: fd000000 swym 0,0,0
--- /dev/null
+GAS for MMIX .*/relax1\.s page 1
+
+
+ 1 #.*
+ 2 #.*
+ 3 #.*
+ 4 0000 F0020019 Main JMP l6
+ 5 0004 F0020018 l0 JMP l6
+ 6 0008 F0020017 l1 JMP l6
+ 7 000c F0020016 l01 JMP l6
+ 8 0010 F407FFFF GETA \$7,nearfar1 % Within reach\.
+ 9 0014 F2BFFFFF PUSHJ \$191,nearfar2 % Within reach\.
+ 10 0018 F000FFFE l2 JMP nearfar2 % Dummy\.
+ 11 001c 00000000 \.space 65530\*4,0
+ 11 00000000
+ 11 00000000
+ 11 00000000
+ 11 00000000
+ 11 00000000
+ 12 40004 4D480000 BNP \$72,l0 % Within reach
+ 13 40008 F5040000 GETA \$4,l1 % Within reach\.
+ 14 4000c F3050000 nearfar1 PUSHJ 5,l01 % Within reach\.
+ 15 40010 F4090000 nearfar2 GETA \$9,l1 % Out of reach\.
+ 15 FD000000
+ 15 FD000000
+ 15 FD000000
+ 16 40020 F20B0000 PUSHJ \$11,l3 % Out of reach\.
+ 16 FD000000
+ 16 FD000000
+ 16 FD000000
+ 16 FD000000
+ 17 40034 4437FFFF l4 BP \$55,l3 % Within reach\.
+ 18 40038 00000000 \.space 65533\*4,0
+ 18 00000000
+ 18 00000000
+ 18 00000000
+ 18 00000000
+ 18 00000000
+ 19 8002c F1FDFFF7 JMP l1 % Dummy\.
+ 20 80030 F1FDFFF5 l3 JMP l0 % Dummy\.
+ 21 80034 47580000 BOD \$88,l4 % Within reach\.
+ 22 80038 46580000 BOD \$88,l4 % Out of reach\.
+ 22 FD000000
+ 22 FD000000
+ 22 FD000000
+ 22 FD000000
+ 22 FD000000
+ 23 80050 F0000000 JMP l5 % Out of reach\.
+ 23 FD000000
+ 23 FD000000
+ 23 FD000000
+ 23 FD000000
+ 24 80064 F0FFFFFF l6 JMP l5 % Within reach\.
+ 25 80068 436FFFF2 BZ \$111,l3 % Dummy\.
+ 26 8006c 00000000 \.space \(256\*256\*256-3\)\*4,0
+ 26 00000000
+ 26 00000000
+ 26 00000000
+ 26 00000000
+ 26 00000000
+\fGAS for MMIX .*/relax1\.s page 2
+
+
+ 27 4080060 F000000D l5 JMP l8 % Dummy\.
+ 28 4080064 F1000000 JMP l6 % Within reach
+ 29 4080068 F0000000 JMP l6 % Out of reach\.
+ 29 FD000000
+ 29 FD000000
+ 29 FD000000
+ 29 FD000000
+ 30 408007c 482C0000 BNN \$44,l9 % Out of reach\.
+ 30 FD000000
+ 30 FD000000
+ 30 FD000000
+ 30 FD000000
+ 30 FD000000
+ 31 4080094 482CFFFF l8 BNN \$44,l9 % Within reach\.
+ 32 4080098 F1FFFFF2 JMP l5 % Dummy\.
+ 33 408009c F1FFFFF1 JMP l5 % Dummy\.
+ 34 40800a0 00000000 \.space 65531\*4,0
+ 34 00000000
+ 34 00000000
+ 34 00000000
+ 34 00000000
+ 34 00000000
+ 35 40c008c F1FEFFF5 l10 JMP l5 % Dummy\.
+ 36 40c0090 F0000007 l9 JMP l11 % Dummy
+ 37 40c0094 F3210000 l7 PUSHJ \$33,l8 % Within reach\.
+ 38 40c0098 F2210000 PUSHJ \$33,l8 % Out of reach\.
+ 38 FD000000
+ 38 FD000000
+ 38 FD000000
+ 38 FD000000
+ 39 40c00ac F1FEFFED l11 JMP l5 % Dummy\.
+ 40 40c00b0 F1FEFFF9 JMP l8 % Dummy\.
+ 41 40c00b4 00000000 \.space 65534\*4,0
+ 41 00000000
+ 41 00000000
+ 41 00000000
+ 41 00000000
+ 41 00000000
+ 42 41000ac F53D0000 GETA \$61,l11 % Within reach\.
+ 43 41000b0 F4480000 GETA \$72,l11 % Out of reach\.
+ 43 FD000000
+ 43 FD000000
+ 43 FD000000
+\fGAS for MMIX .*/relax1\.s page 3
+
+
+DEFINED SYMBOLS
+.*/relax1\.s:4 \.text:0000000000000000 Main
+.*/relax1\.s:24 \.text:0000000000080064 l6
+.*/relax1\.s:5 \.text:0000000000000004 l0
+.*/relax1\.s:6 \.text:0000000000000008 l1
+.*/relax1\.s:7 \.text:000000000000000c l01
+.*/relax1\.s:14 \.text:000000000004000c nearfar1
+.*/relax1\.s:15 \.text:0000000000040010 nearfar2
+.*/relax1\.s:10 \.text:0000000000000018 l2
+.*/relax1\.s:20 \.text:0000000000080030 l3
+.*/relax1\.s:17 \.text:0000000000040034 l4
+.*/relax1\.s:27 \.text:0000000004080060 l5
+.*/relax1\.s:31 \.text:0000000004080094 l8
+.*/relax1\.s:36 \.text:00000000040c0090 l9
+.*/relax1\.s:35 \.text:00000000040c008c l10
+.*/relax1\.s:39 \.text:00000000040c00ac l11
+.*/relax1\.s:37 \.text:00000000040c0094 l7
+
+NO UNDEFINED SYMBOLS
--- /dev/null
+# Relaxation border-cases: just-within reach, just-out-of-reach, forward
+# and backward. Have a few variable-length thingies in-between so it
+# doesn't get too easy.
+Main JMP l6
+l0 JMP l6
+l1 JMP l6
+l01 JMP l6
+ GETA $7,nearfar1 % Within reach.
+ PUSHJ $191,nearfar2 % Within reach.
+l2 JMP nearfar2 % Dummy.
+ .space 65530*4,0
+ BNP $72,l0 % Within reach
+ GETA $4,l1 % Within reach.
+nearfar1 PUSHJ 5,l01 % Within reach.
+nearfar2 GETA $9,l1 % Out of reach.
+ PUSHJ $11,l3 % Out of reach.
+l4 BP $55,l3 % Within reach.
+ .space 65533*4,0
+ JMP l1 % Dummy.
+l3 JMP l0 % Dummy.
+ BOD $88,l4 % Within reach.
+ BOD $88,l4 % Out of reach.
+ JMP l5 % Out of reach.
+l6 JMP l5 % Within reach.
+ BZ $111,l3 % Dummy.
+ .space (256*256*256-3)*4,0
+l5 JMP l8 % Dummy.
+ JMP l6 % Within reach
+ JMP l6 % Out of reach.
+ BNN $44,l9 % Out of reach.
+l8 BNN $44,l9 % Within reach.
+ JMP l5 % Dummy.
+ JMP l5 % Dummy.
+ .space 65531*4,0
+l10 JMP l5 % Dummy.
+l9 JMP l11 % Dummy
+l7 PUSHJ $33,l8 % Within reach.
+ PUSHJ $33,l8 % Out of reach.
+l11 JMP l5 % Dummy.
+ JMP l8 % Dummy.
+ .space 65534*4,0
+ GETA $61,l11 % Within reach.
+ GETA $72,l11 % Out of reach.
--- /dev/null
+# objdump: -dr
+# as: -no-expand
+# source: reloc16.s
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: e3040000 setl \$4,0x0
+ 2: R_MMIX_16 foo
+ 4: f82d0000 pop 45,0
+ 6: R_MMIX_16 bar\+0x2a
+ 8: fd2a0000 swym 42,0,0
+ a: R_MMIX_16 baz\+0xfffffffffffff6d7
--- /dev/null
+# objdump: -dr
+# as: -linkrelax
+# source: reloc16.s
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: e3040000 setl \$4,0x0
+ 2: R_MMIX_16 foo
+ 4: f82d0000 pop 45,0
+ 6: R_MMIX_16 bar\+0x2a
+ 8: fd2a0000 swym 42,0,0
+ a: R_MMIX_16 baz\+0xfffffffffffff6d7
--- /dev/null
+# objdump: -dr
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: e3040000 setl \$4,0x0
+ 2: R_MMIX_16 foo
+ 4: f82d0000 pop 45,0
+ 6: R_MMIX_16 bar\+0x2a
+ 8: fd2a0000 swym 42,0,0
+ a: R_MMIX_16 baz\+0xfffffffffffff6d7
--- /dev/null
+GAS for MMIX .*/reloc16\.s page 1
+
+
+ 1 #.*
+ 2 0000 E3040000 Main SETL \$4,foo
+ 3 0004 F82D0000 POP 45,bar\+42
+ 4 0008 FD2A0000 SWYM 42,baz-2345
+\fGAS for MMIX .*/reloc16\.s page 2
+
+
+DEFINED SYMBOLS
+.*/reloc16\.s:2 \.text:0000000000000000 Main
+
+UNDEFINED SYMBOLS
+foo
+bar
+baz
--- /dev/null
+# Simple relocations against 16-bit extern symbols.
+Main SETL $4,foo
+ POP 45,bar+42
+ SWYM 42,baz-2345
--- /dev/null
+# objdump: -dr
+# as: -linkrelax
+# source: reloc8.s
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: b9002dea syncd 0,\$45,234
+ 1: R_MMIX_8 foo
+ 4: 372f002a negu \$47,0,42
+ 6: R_MMIX_8 bar\+0x30
+ 8: fd00b26e swym 0,178,110
+ 9: R_MMIX_8 baz\+0xfffffffffffffffe
+ c: ff000000 trip 0,0,0
+ d: R_MMIX_8 fee\+0xffffffffffffffff
+ e: R_MMIX_8 fie\+0x1
+ f: R_MMIX_8 foe\+0x3
+ 10: f9000000 resume 0
+ 13: R_MMIX_8 foobar\+0x8
--- /dev/null
+# objdump: -dr
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: b9002dea syncd 0,\$45,234
+ 1: R_MMIX_8 foo
+ 4: 372f002a negu \$47,0,42
+ 6: R_MMIX_8 bar\+0x30
+ 8: fd00b26e swym 0,178,110
+ 9: R_MMIX_8 baz\+0xfffffffffffffffe
+ c: ff000000 trip 0,0,0
+ d: R_MMIX_8 fee\+0xffffffffffffffff
+ e: R_MMIX_8 fie\+0x1
+ f: R_MMIX_8 foe\+0x3
+ 10: f9000000 resume 0
+ 13: R_MMIX_8 foobar\+0x8
--- /dev/null
+GAS for MMIX .*/reloc8\.s page 1
+
+
+ 1 #.*
+ 2 0000 B9002DEA Main SYNCD foo,\$45,234
+ 3 0004 372F002A NEGU \$47,bar\+48,localsym
+ 4 0008 FD00B26E SWYM baz-2,45678
+ 5 000c FF000000 TRIP fee-1,fie\+1,foe\+3
+ 6 0010 F9000000 RESUME foobar\+8
+ 7 localsym IS 42
+ 8
+\fGAS for MMIX .*/reloc8\.s page 2
+
+
+DEFINED SYMBOLS
+.*/reloc8\.s:2 \.text:0000000000000000 Main
+ \*ABS\*:000000000000002a localsym
+
+UNDEFINED SYMBOLS
+foo
+bar
+baz
+fee
+fie
+foe
+foobar
--- /dev/null
+# Simple relocations against 8-bit extern symbols.
+Main SYNCD foo,$45,234
+ NEGU $47,bar+48,localsym
+ SWYM baz-2,45678
+ TRIP fee-1,fie+1,foe+3
+ RESUME foobar+8
+localsym IS 42
+
--- /dev/null
+#objdump: -dr
+#source: reloclab.s
+#as: -no-expand
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: f0000000 jmp 0 <Main>
+ 0: R_MMIX_ADDR27 foo\+0x8
+ 4: f0000004 jmp 14 <here>
+ 8: f4080003 geta \$8,14 <here>
+ c: 46630002 bod \$99,14 <here>
+ 10: fd000000 swym 0,0,0
+
+0000000000000014 <here>:
+ 14: 42de0000 bz \$222,14 <here>
+ 14: R_MMIX_ADDR19 bar\+0x10
+
+0000000000000018 <there>:
+ 18: f4040000 geta \$4,18 <there>
+ 18: R_MMIX_ADDR19 baz
+ 1c: f2070000 pushj \$7,1c <there\+0x4>
+ 1c: R_MMIX_ADDR19 foobar
+ 20: f1fffffe jmp 18 <there>
+ 24: f558fffd geta \$88,18 <there>
+ 28: 476ffffc bod \$111,18 <there>
--- /dev/null
+#objdump: -dr
+#as: -linkrelax -x
+#source: reloclab.s
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: f0000000 jmp 0 <Main>
+ 0: R_MMIX_JMP foo\+0x8
+ 4: fd000000 swym 0,0,0
+ 8: fd000000 swym 0,0,0
+ c: fd000000 swym 0,0,0
+ 10: fd000000 swym 0,0,0
+ 14: f0000004 jmp 24 <here>
+ 14: R_MMIX_ADDR27 \.text\+0x24
+ 18: f4080003 geta \$8,24 <here>
+ 18: R_MMIX_ADDR19 \.text\+0x24
+ 1c: 46630002 bod \$99,24 <here>
+ 1c: R_MMIX_ADDR19 \.text\+0x24
+ 20: fd000000 swym 0,0,0
+
+0000000000000024 <here>:
+ 24: 42de0000 bz \$222,24 <here>
+ 24: R_MMIX_CBRANCH bar\+0x10
+ 28: fd000000 swym 0,0,0
+ 2c: fd000000 swym 0,0,0
+ 30: fd000000 swym 0,0,0
+ 34: fd000000 swym 0,0,0
+ 38: fd000000 swym 0,0,0
+
+000000000000003c <there>:
+ 3c: f4040000 geta \$4,3c <there>
+ 3c: R_MMIX_GETA baz
+ 40: fd000000 swym 0,0,0
+ 44: fd000000 swym 0,0,0
+ 48: fd000000 swym 0,0,0
+ 4c: f2070000 pushj \$7,4c <there\+0x10>
+ 4c: R_MMIX_PUSHJ foobar
+ 50: fd000000 swym 0,0,0
+ 54: fd000000 swym 0,0,0
+ 58: fd000000 swym 0,0,0
+ 5c: fd000000 swym 0,0,0
+ 60: f1fffff7 jmp 3c <there>
+ 60: R_MMIX_ADDR27 \.text\+0x3c
+ 64: f558fff6 geta \$88,3c <there>
+ 64: R_MMIX_ADDR19 \.text\+0x3c
+ 68: 476ffff5 bod \$111,3c <there>
+ 68: R_MMIX_ADDR19 \.text\+0x3c
--- /dev/null
+#objdump: -dr
+#as: -x
+
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: f0000000 jmp 0 <Main>
+ 0: R_MMIX_JMP foo\+0x8
+ 4: fd000000 swym 0,0,0
+ 8: fd000000 swym 0,0,0
+ c: fd000000 swym 0,0,0
+ 10: fd000000 swym 0,0,0
+ 14: f0000004 jmp 24 <here>
+ 18: f4080003 geta \$8,24 <here>
+ 1c: 46630002 bod \$99,24 <here>
+ 20: fd000000 swym 0,0,0
+
+0000000000000024 <here>:
+ 24: 42de0000 bz \$222,24 <here>
+ 24: R_MMIX_CBRANCH bar\+0x10
+ 28: fd000000 swym 0,0,0
+ 2c: fd000000 swym 0,0,0
+ 30: fd000000 swym 0,0,0
+ 34: fd000000 swym 0,0,0
+ 38: fd000000 swym 0,0,0
+
+000000000000003c <there>:
+ 3c: f4040000 geta \$4,3c <there>
+ 3c: R_MMIX_GETA baz
+ 40: fd000000 swym 0,0,0
+ 44: fd000000 swym 0,0,0
+ 48: fd000000 swym 0,0,0
+ 4c: f2070000 pushj \$7,4c <there\+0x10>
+ 4c: R_MMIX_PUSHJ foobar
+ 50: fd000000 swym 0,0,0
+ 54: fd000000 swym 0,0,0
+ 58: fd000000 swym 0,0,0
+ 5c: fd000000 swym 0,0,0
+ 60: f1fffff7 jmp 3c <there>
+ 64: f558fff6 geta \$88,3c <there>
+ 68: 476ffff5 bod \$111,3c <there>
--- /dev/null
+GAS for MMIX .*/reloclab\.s page 1
+
+
+ 1 #.*
+ 2 #.*
+ 3 #.*
+ 4 0000 F0000000 Main JMP foo\+8
+ 4 FD000000
+ 4 FD000000
+ 4 FD000000
+ 4 FD000000
+ 5 0014 F0000004 JMP here
+ 6 0018 F4080003 GETA \$8,here
+ 7 001c 46630002 BOD \$99,here
+ 8 0020 FD000000 SWYM 0
+ 9 0024 42DE0000 here BZ \$222,bar\+16
+ 9 FD000000
+ 9 FD000000
+ 9 FD000000
+ 9 FD000000
+ 9 FD000000
+ 10 003c F4040000 there GETA \$4,baz
+ 10 FD000000
+ 10 FD000000
+ 10 FD000000
+ 11 004c F2070000 PUSHJ \$7,foobar
+ 11 FD000000
+ 11 FD000000
+ 11 FD000000
+ 11 FD000000
+ 12 0060 F1FFFFF7 JMP there
+ 13 0064 F558FFF6 GETA \$88,there
+ 14 0068 476FFFF5 BOD \$111,there
+\fGAS for MMIX .*/reloclab\.s page 2
+
+
+DEFINED SYMBOLS
+.*/reloclab\.s:4 \.text:0000000000000000 Main
+.*/reloclab\.s:9 \.text:0000000000000024 here
+.*/reloclab\.s:10 \.text:000000000000003c there
+
+UNDEFINED SYMBOLS
+foo
+bar
+baz
+foobar
--- /dev/null
+# Different relocations for extern labels: GETA, PUSHJ, Bcc, JMP.
+# Mix in different accesses to local labels to see that relaxing works for
+# this case.
+Main JMP foo+8
+ JMP here
+ GETA $8,here
+ BOD $99,here
+ SWYM 0
+here BZ $222,bar+16
+there GETA $4,baz
+ PUSHJ $7,foobar
+ JMP there
+ GETA $88,there
+ BOD $111,there
--- /dev/null
+# objdump: -dr
+# as: -linkrelax -no-expand
+# source: reloclab.s
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: f0000000 jmp 0 <Main>
+ 0: R_MMIX_ADDR27 foo\+0x8
+ 4: f0000000 jmp 4 <Main\+0x4>
+ 4: R_MMIX_ADDR27 \.text\+0x14
+ 8: f4080000 geta \$8,8 <Main\+0x8>
+ 8: R_MMIX_ADDR19 \.text\+0x14
+ c: 46630000 bod \$99,c <Main\+0xc>
+ c: R_MMIX_ADDR19 \.text\+0x14
+ 10: fd000000 swym 0,0,0
+
+0000000000000014 <here>:
+ 14: 42de0000 bz \$222,14 <here>
+ 14: R_MMIX_ADDR19 bar\+0x10
+
+0000000000000018 <there>:
+ 18: f4040000 geta \$4,18 <there>
+ 18: R_MMIX_ADDR19 baz
+ 1c: f2070000 pushj \$7,1c <there\+0x4>
+ 1c: R_MMIX_ADDR19 foobar
+ 20: f0000000 jmp 20 <there\+0x8>
+ 20: R_MMIX_ADDR27 \.text\+0x18
+ 24: f4580000 geta \$88,24 <there\+0xc>
+ 24: R_MMIX_ADDR19 \.text\+0x18
+ 28: 466f0000 bod \$111,28 <there\+0x10>
+ 28: R_MMIX_ADDR19 \.text\+0x18
--- /dev/null
+# objdump: -dr
+# as: -no-expand -linkrelax
+# source: reloc16.s
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: e3040000 setl \$4,0x0
+ 2: R_MMIX_16 foo
+ 4: f82d0000 pop 45,0
+ 6: R_MMIX_16 bar\+0x2a
+ 8: fd2a0000 swym 42,0,0
+ a: R_MMIX_16 baz\+0xfffffffffffff6d7
--- /dev/null
+# objdump: -dr
+# as: -linkrelax
+# source: resume-op.s
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: f9000001 resume 1
+ 4: f9000000 resume 0
+ 8: f9000001 resume 1
+ c: f9000000 resume 0
--- /dev/null
+# objdump: -dr
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: f9000001 resume 1
+ 4: f9000000 resume 0
+ 8: f9000001 resume 1
+ c: f9000000 resume 0
--- /dev/null
+GAS for MMIX .*/resume-op\.s page 1
+
+
+ 1 # Test the 'z'-type operand, RESUME\.
+ 2 0000 F9000001 Main RESUME X
+ 3 0004 F9000000 RESUME 0
+ 4 0008 F9000001 RESUME 1
+ 5 000c F9000000 RESUME XX
+ 6 X IS 1
+ 7 XX IS 0
+ 8
+\fGAS for MMIX .*/resume-op\.s page 2
+
+
+DEFINED SYMBOLS
+.*/resume-op\.s:2 \.text:0000000000000000 Main
+ \*ABS\*:0000000000000001 X
+ \*ABS\*:0000000000000000 XX
+
+NO UNDEFINED SYMBOLS
--- /dev/null
+# Test the 'z'-type operand, RESUME.
+Main RESUME X
+ RESUME 0
+ RESUME 1
+ RESUME XX
+X IS 1
+XX IS 0
+
--- /dev/null
+# objdump: -dr
+# as: -linkrelax
+# source: round2-op.s
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: 088700f4 flot \$135,\$244
+ 4: 0a8700e9 flotu \$135,\$233
+ 8: 0d85005b sflot \$133,91
+ c: 177b00f4 fint \$123,\$244
+ 10: 0c8500f4 sflot \$133,\$244
+ 14: 0987005b flot \$135,91
+ 18: 0f7b005b sflotu \$123,91
+ 1c: 05ad00e9 fix \$173,\$233
+ 20: 0bad00d5 flotu \$173,213
+ 24: 078700f4 fixu \$135,\$244
+ 28: 0b870077 flotu \$135,119
--- /dev/null
+# objdump: -dr
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: 088700f4 flot \$135,\$244
+ 4: 0a8700e9 flotu \$135,\$233
+ 8: 0d85005b sflot \$133,91
+ c: 177b00f4 fint \$123,\$244
+ 10: 0c8500f4 sflot \$133,\$244
+ 14: 0987005b flot \$135,91
+ 18: 0f7b005b sflotu \$123,91
+ 1c: 05ad00e9 fix \$173,\$233
+ 20: 0bad00d5 flotu \$173,213
+ 24: 078700f4 fixu \$135,\$244
+ 28: 0b870077 flotu \$135,119
--- /dev/null
+GAS for MMIX .*/round2-op\.s page 1
+
+
+ 1 #.*
+ 2 0000 088700F4 Main FLOT X,Z
+ 3 0004 0A8700E9 FLOTU X,\$233
+ 4 0008 0D85005B SFLOT \$133,Z0
+ 5 000c 177B00F4 FINT \$123,Z
+ 6 0010 0C8500F4 SFLOT \$133,Z
+ 7 0014 0987005B FLOT X,Z0
+ 8 0018 0F7B005B SFLOTU \$123,Z0
+ 9 001c 05AD00E9 FIX \$173,\$233
+ 10 0020 0BAD00D5 FLOTU \$173,213
+ 11 0024 078700F4 FIXU X,Z
+ 12 0028 0B870077 FLOTU X,119
+ 13 X IS \$135
+ 14 Z IS \$244
+ 15 Z0 IS 91
+\fGAS for MMIX .*/round2-op\.s page 2
+
+
+DEFINED SYMBOLS
+.*/round2-op\.s:2 \.text:0000000000000000 Main
+ \*REG\*:0000000000000087 X
+ \*REG\*:00000000000000f4 Z
+ \*ABS\*:000000000000005b Z0
+
+NO UNDEFINED SYMBOLS
--- /dev/null
+# Two-operand variants of "R" and "I".
+Main FLOT X,Z
+ FLOTU X,$233
+ SFLOT $133,Z0
+ FINT $123,Z
+ SFLOT $133,Z
+ FLOT X,Z0
+ SFLOTU $123,Z0
+ FIX $173,$233
+ FLOTU $173,213
+ FIXU X,Z
+ FLOTU X,119
+X IS $135
+Z IS $244
+Z0 IS 91
--- /dev/null
+# objdump: -dr
+# as: -linkrelax
+# source: roundi-op.s
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: 088701f4 flot \$135,ROUND_OFF,\$244
+ 4: 0a8702e9 flotu \$135,ROUND_UP,\$233
+ 8: 0d85005b sflot \$133,91
+ c: 0e7b04f4 sflotu \$123,ROUND_NEAR,\$244
+ 10: 0c8500f4 sflot \$133,\$244
+ 14: 0987005b flot \$135,91
+ 18: 0f7b045b sflotu \$123,ROUND_NEAR,91
+ 1c: 0987015b flot \$135,ROUND_OFF,91
+ 20: 0aad02e9 flotu \$173,ROUND_UP,\$233
+ 24: 0bad02d5 flotu \$173,ROUND_UP,213
+ 28: 0c8700f4 sflot \$135,\$244
+ 2c: 0b870277 flotu \$135,ROUND_UP,119
+ 30: 0d87005b sflot \$135,91
+ 34: 088700f4 flot \$135,\$244
--- /dev/null
+# objdump: -dr
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: 088701f4 flot \$135,ROUND_OFF,\$244
+ 4: 0a8702e9 flotu \$135,ROUND_UP,\$233
+ 8: 0d85005b sflot \$133,91
+ c: 0e7b04f4 sflotu \$123,ROUND_NEAR,\$244
+ 10: 0c8500f4 sflot \$133,\$244
+ 14: 0987005b flot \$135,91
+ 18: 0f7b045b sflotu \$123,ROUND_NEAR,91
+ 1c: 0987015b flot \$135,ROUND_OFF,91
+ 20: 0aad02e9 flotu \$173,ROUND_UP,\$233
+ 24: 0bad02d5 flotu \$173,ROUND_UP,213
+ 28: 0c8700f4 sflot \$135,\$244
+ 2c: 0b870277 flotu \$135,ROUND_UP,119
+ 30: 0d87005b sflot \$135,91
+ 34: 088700f4 flot \$135,\$244
--- /dev/null
+GAS for MMIX .*/roundi-op\.s page 1
+
+
+ 1 #.*
+ 2 0000 088701F4 Main FLOT X,ROUND_OFF,Z
+ 3 0004 0A8702E9 FLOTU X,2,\$233
+ 4 0008 0D85005B SFLOT \$133,0,Z0
+ 5 000c 0E7B04F4 SFLOTU \$123,ROUND_NEAR,Z
+ 6 0010 0C8500F4 SFLOT \$133,0,Z
+ 7 0014 0987005B FLOT X,ROUND_CURRENT,Z0
+ 8 0018 0F7B045B SFLOTU \$123,ROUND_NEAR,Z0
+ 9 001c 0987015B FLOT X,ROUND_OFF,Z0
+ 10 0020 0AAD02E9 FLOTU \$173,2,\$233
+ 11 0024 0BAD02D5 FLOTU \$173,2,213
+ 12 0028 0C8700F4 SFLOT X,0,Z
+ 13 002c 0B870277 FLOTU X,2,119
+ 14 0030 0D87005B SFLOT X,0,Z0
+ 15 0034 088700F4 FLOT X,ROUND_CURRENT,Z
+ 16 X IS \$135
+ 17 Z IS \$244
+ 18 Z0 IS 91
+\fGAS for MMIX .*/roundi-op\.s page 2
+
+
+DEFINED SYMBOLS
+.*/roundi-op\.s:2 \.text:0000000000000000 Main
+ \*REG\*:0000000000000087 X
+ \*REG\*:00000000000000f4 Z
+ \*ABS\*:000000000000005b Z0
+
+NO UNDEFINED SYMBOLS
--- /dev/null
+# Round-type "R".
+Main FLOT X,ROUND_OFF,Z
+ FLOTU X,2,$233
+ SFLOT $133,0,Z0
+ SFLOTU $123,ROUND_NEAR,Z
+ SFLOT $133,0,Z
+ FLOT X,ROUND_CURRENT,Z0
+ SFLOTU $123,ROUND_NEAR,Z0
+ FLOT X,ROUND_OFF,Z0
+ FLOTU $173,2,$233
+ FLOTU $173,2,213
+ SFLOT X,0,Z
+ FLOTU X,2,119
+ SFLOT X,0,Z0
+ FLOT X,ROUND_CURRENT,Z
+X IS $135
+Z IS $244
+Z0 IS 91
--- /dev/null
+# objdump: -dr
+# as: -linkrelax
+# source: roundr-op.s
+.*: file format elf64-mmix
+
+Disassembly of section .text:
+
+0000000000000000 <Main>:
+ 0: 178701f4 fint \$135,ROUND_OFF,\$244
+ 4: 058702e9 fix \$135,ROUND_UP,\$233
+ 8: 178500f4 fint \$133,\$244
+ c: 157b04f4 fsqrt \$123,ROUND_NEAR,\$244
+ 10: 17ad02e9 fint \$173,ROUND_UP,\$233
+ 14: 058700f4 fix \$135,\$244
+ 18: 078700f4 fixu \$135,\$244
--- /dev/null
+# objdump: -dr
+.*: file format elf64-mmix
+
+Disassembly of section .text:
+
+0000000000000000 <Main>:
+ 0: 178701f4 fint \$135,ROUND_OFF,\$244
+ 4: 058702e9 fix \$135,ROUND_UP,\$233
+ 8: 178500f4 fint \$133,\$244
+ c: 157b04f4 fsqrt \$123,ROUND_NEAR,\$244
+ 10: 17ad02e9 fint \$173,ROUND_UP,\$233
+ 14: 058700f4 fix \$135,\$244
+ 18: 078700f4 fixu \$135,\$244
--- /dev/null
+GAS for MMIX .*/roundr-op\.s page 1
+
+
+ 1 # Round-type "R"\.
+ 2 0000 178701F4 Main FINT X,ROUND_OFF,Z
+ 3 0004 058702E9 FIX X,2,\$233
+ 4 0008 178500F4 FINT \$133,0,Z
+ 5 000c 157B04F4 FSQRT \$123,ROUND_NEAR,Z
+ 6 0010 17AD02E9 FINT \$173,2,\$233
+ 7 0014 058700F4 FIX X,0,Z
+ 8 0018 078700F4 FIXU X,ROUND_CURRENT,Z
+ 9 X IS \$135
+ 10 Z IS \$244
+\fGAS for MMIX .*/roundr-op\.s page 2
+
+
+DEFINED SYMBOLS
+.*/roundr-op\.s:2 \.text:0000000000000000 Main
+ \*REG\*:0000000000000087 X
+ \*REG\*:00000000000000f4 Z
+
+NO UNDEFINED SYMBOLS
--- /dev/null
+# Round-type "R".
+Main FINT X,ROUND_OFF,Z
+ FIX X,2,$233
+ FINT $133,0,Z
+ FSQRT $123,ROUND_NEAR,Z
+ FINT $173,2,$233
+ FIX X,0,Z
+ FIXU X,ROUND_CURRENT,Z
+X IS $135
+Z IS $244
--- /dev/null
+# objdump: -dr
+# as: -linkrelax
+# source: save-op.s
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: fa2d0000 save \$45,0
+ 4: fa1f0000 save \$31,0
+ 8: fa000000 save \$0,0
--- /dev/null
+# objdump: -dr
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: fa2d0000 save \$45,0
+ 4: fa1f0000 save \$31,0
+ 8: fa000000 save \$0,0
--- /dev/null
+GAS for MMIX .*/save-op.s page 1
+
+
+ 1 #.*
+ 2 0000 FA2D0000 Main SAVE \$45,0
+ 3 0004 FA1F0000 SAVE X,0
+ 4 0008 FA000000 SAVE X0,0
+ 5 X IS \$31
+ 6 X0 IS \$0
+ 7
+\fGAS for MMIX .*/save-op.s page 2
+
+
+DEFINED SYMBOLS
+.*/save-op.s:2 .text:0000000000000000 Main
+ \*REG\*:000000000000001f X
+ \*REG\*:0000000000000000 X0
+
+NO UNDEFINED SYMBOLS
--- /dev/null
+# Test the 's'-type operand, SAVE.
+Main SAVE $45,0
+ SAVE X,0
+ SAVE X0,0
+X IS $31
+X0 IS $0
+
--- /dev/null
+# objdump: -dr
+# as: -linkrelax
+# source: set.s
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: e32d0463 setl \$45,0x463
+ 4: c1394300 set \$57,\$67
+ 8: c14e1f00 set \$78,\$31
+ c: e3750463 setl \$117,0x463
+ 10: c1754300 set \$117,\$67
+ 14: c1751f00 set \$117,\$31
--- /dev/null
+# objdump: -dr
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: e32d0463 setl \$45,0x463
+ 4: c1394300 set \$57,\$67
+ 8: c14e1f00 set \$78,\$31
+ c: e3750463 setl \$117,0x463
+ 10: c1754300 set \$117,\$67
+ 14: c1751f00 set \$117,\$31
--- /dev/null
+GAS for MMIX .*/set\.s page 1
+
+
+ 1 #.*
+ 2 0000 E32D0463 Main SET \$45,1123
+ 3 0004 C1394300 SET \$57,\$67
+ 4 0008 C14E1F00 SET \$78,X
+ 5 000c E3750463 SET Y,1123
+ 6 0010 C1754300 SET Y,\$67
+ 7 0014 C1751F00 SET Y,X
+ 8 X IS \$31
+ 9 Y IS \$117
+\fGAS for MMIX .*/set\.s page 2
+
+
+DEFINED SYMBOLS
+.*/set\.s:2 \.text:0000000000000000 Main
+ \*REG\*:000000000000001f X
+ \*REG\*:0000000000000075 Y
+
+NO UNDEFINED SYMBOLS
--- /dev/null
+# Test the 'r'-type operand and the mapping of SET to OR(I) and SETL.
+Main SET $45,1123
+ SET $57,$67
+ SET $78,X
+ SET Y,1123
+ SET Y,$67
+ SET Y,X
+X IS $31
+Y IS $117
--- /dev/null
+# objdump: -dr
+# as: -linkrelax
+# source: swym-op.s
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: fd840def swym 132,13,239
+ 4: ff840def trip 132,13,239
+ 8: 00845678 trap 132,86,120
+ c: 00170def trap 23,13,239
+ 10: 0023cace trap 35,202,206
+ 14: ff170c43 trip 23,12,67
+ 18: ff175678 trip 23,86,120
+ 1c: fd12d687 swym 18,214,135
--- /dev/null
+# objdump: -dr
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: fd840def swym 132,13,239
+ 4: ff840def trip 132,13,239
+ 8: 00845678 trap 132,86,120
+ c: 00170def trap 23,13,239
+ 10: 0023cace trap 35,202,206
+ 14: ff170c43 trip 23,12,67
+ 18: ff175678 trip 23,86,120
+ 1c: fd12d687 swym 18,214,135
--- /dev/null
+GAS for MMIX .*/swym-op\.s page 1
+
+
+ 1 #.*
+ 2 #.*
+ 3 0000 FD840DEF Main SWYM 132,3567
+ 4 0004 FF840DEF TRIP 132,3567
+ 5 0008 00845678 TRAP 132,YZ
+ 6 000c 00170DEF TRAP X,3567
+ 7 0010 0023CACE TRAP 2345678
+ 8 0014 FF170C43 TRIP X,Y,Z
+ 9 0018 FF175678 TRIP X,YZ
+ 10 001c FD12D687 SWYM XYZ
+ 11 X IS 23
+ 12 Y IS 12
+ 13 Z IS 67
+ 14 YZ IS #5678
+ 15 XYZ IS 1234567
+\fGAS for MMIX .*/swym-op\.s page 2
+
+
+DEFINED SYMBOLS
+.*/swym-op\.s:3 \.text:0000000000000000 Main
+ \*ABS\*:0000000000005678 YZ
+ \*ABS\*:0000000000000017 X
+ \*ABS\*:000000000000000c Y
+ \*ABS\*:0000000000000043 Z
+ \*ABS\*:000000000012d687 XYZ
+
+NO UNDEFINED SYMBOLS
--- /dev/null
+# Check different type of operands to SWYM etc.
+# No need to check the canonical three constants.
+Main SWYM 132,3567
+ TRIP 132,3567
+ TRAP 132,YZ
+ TRAP X,3567
+ TRAP 2345678
+ TRIP X,Y,Z
+ TRIP X,YZ
+ SWYM XYZ
+X IS 23
+Y IS 12
+Z IS 67
+YZ IS #5678
+XYZ IS 1234567
--- /dev/null
+#objdump: -dt
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+ l d .text 0+
+0+ l d .data 0+
+0+ l d .bss 0+
+0+10 l .text 0+ scl1
+0+14 l .text 0+ :scl2
+0+20 l .text 0+ endcl1
+0+24 l .text 0+ endcl2:
+0+ g F .text 0+ Main
+0+4 g .text 0+ scg1
+0+8 g .text 0+ scg2
+0+c g .text 0+ :scg3
+0+18 g .text 0+ endcg1
+0+1c g .text 0+ endcg2:
+
+
+Disassembly of section .text:
+
+0+ <Main>:
+ 0: fd000410 swym 0,4,16
+
+0+4 <scg1>:
+ 4: fd100400 swym 16,4,0
+
+0+8 <scg2>:
+ 8: fda12a1e swym 161,42,30
+
+0+c <:scg3>:
+ c: fda32a14 swym 163,42,20
+
+0+10 <scl1>:
+ 10: fd010203 swym 1,2,3
+
+0+14 <:scl2>:
+ 14: fd010204 swym 1,2,4
+
+0+18 <endcg1>:
+ 18: fd030201 swym 3,2,1
+
+0+1c <endcg2:>:
+ 1c: fd030201 swym 3,2,1
+
+0+20 <endcl1>:
+ 20: fd040302 swym 4,3,2
+
+0+24 <endcl2:>:
+ 24: fd040302 swym 4,3,2
--- /dev/null
+# Test beginning and starting with ":"; it should be stripped off, but
+# only one. A trailing ":" is stripped off at a label only.
+
+Main SWYM 0,4,16
+ .global :scg1
+ .global scg2
+ .global ::scg3
+ .global scg2
+:scg1 SWYM 16,4,0
+:scg2 SWYM 161,42,30
+::scg3 SWYM 163,42,20
+:scl1 SWYM 1,2,3
+::scl2 SWYM 1,2,4
+ .global endcg1
+ .global endcg2:
+endcg1: SWYM 3,2,1
+endcg2:: SWYM 3,2,1
+endcl1: SWYM 4,3,2
+endcl2:: SWYM 4,3,2
--- /dev/null
+# objdump: -dr
+# as: -linkrelax
+# source: sync-op.s
+.*: file format elf64-mmix
+
+Disassembly of section .text:
+
+0000000000000000 <Main>:
+ 0: fc6e6406 sync 7234566
+ 4: fc000000 sync 0
+ 8: fc000001 sync 1
+ c: fc000000 sync 0
+ 10: fc000001 sync 1
+ 14: fc7c2242 sync 8135234
--- /dev/null
+# objdump: -dr
+.*: file format elf64-mmix
+
+Disassembly of section .text:
+
+0000000000000000 <Main>:
+ 0: fc6e6406 sync 7234566
+ 4: fc000000 sync 0
+ 8: fc000001 sync 1
+ c: fc000000 sync 0
+ 10: fc000001 sync 1
+ 14: fc7c2242 sync 8135234
--- /dev/null
+GAS for MMIX .*/sync-op\.s page 1
+
+
+ 1 #.*
+ 2 0000 FC6E6406 Main SYNC 7234566
+ 3 0004 FC000000 SYNC 0
+ 4 0008 FC000001 SYNC 1
+ 5 000c FC000000 SYNC Zz
+ 6 0010 FC000001 SYNC Zo
+ 7 0014 FC7C2242 SYNC Z
+ 8 Zz IS 0
+ 9 Zo IS 1
+ 10 Z IS 8135234
+\fGAS for MMIX .*/sync-op\.s page 2
+
+
+DEFINED SYMBOLS
+.*/sync-op\.s:2 \.text:0000000000000000 Main
+ \*ABS\*:0000000000000000 Zz
+ \*ABS\*:0000000000000001 Zo
+ \*ABS\*:00000000007c2242 Z
+
+NO UNDEFINED SYMBOLS
--- /dev/null
+# Test operands for SYNC.
+Main SYNC 7234566
+ SYNC 0
+ SYNC 1
+ SYNC Zz
+ SYNC Zo
+ SYNC Z
+Zz IS 0
+Zo IS 1
+Z IS 8135234
--- /dev/null
+Main SWYM 0
+l1 GETA $5,foo
+ LDA $252,$34,127
+ SWYM 0,bar,baz
+ GETA $56,Main
+
--- /dev/null
+# objdump: -dr
+# as: -linkrelax
+# source: two-op.s
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: e0175840 seth \$23,0x5840
+ 4: e12d5840 setmh \$45,0x5840
+ 8: e8171ed4 orh \$23,0x1ed4
+ c: e92d3039 ormh \$45,0x3039
+ 10: e2175840 setml \$23,0x5840
+ 14: e32d5840 setl \$45,0x5840
+ 18: ea171ed4 orml \$23,0x1ed4
+ 1c: eb2d3039 orl \$45,0x3039
+ 20: e42d3039 inch \$45,0x3039
+ 24: e5171ed4 incmh \$23,0x1ed4
+ 28: ec2d5840 andnh \$45,0x5840
+ 2c: ed175840 andnmh \$23,0x5840
+ 30: e6175840 incml \$23,0x5840
+ 34: e72d5840 incl \$45,0x5840
+ 38: ee171ed4 andnml \$23,0x1ed4
+ 3c: ef2d3039 andnl \$45,0x3039
--- /dev/null
+# objdump: -dr
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: e0175840 seth \$23,0x5840
+ 4: e12d5840 setmh \$45,0x5840
+ 8: e8171ed4 orh \$23,0x1ed4
+ c: e92d3039 ormh \$45,0x3039
+ 10: e2175840 setml \$23,0x5840
+ 14: e32d5840 setl \$45,0x5840
+ 18: ea171ed4 orml \$23,0x1ed4
+ 1c: eb2d3039 orl \$45,0x3039
+ 20: e42d3039 inch \$45,0x3039
+ 24: e5171ed4 incmh \$23,0x1ed4
+ 28: ec2d5840 andnh \$45,0x5840
+ 2c: ed175840 andnmh \$23,0x5840
+ 30: e6175840 incml \$23,0x5840
+ 34: e72d5840 incl \$45,0x5840
+ 38: ee171ed4 andnml \$23,0x1ed4
+ 3c: ef2d3039 andnl \$45,0x3039
--- /dev/null
+GAS for MMIX .*/two-op\.s page 1
+
+
+ 1 #.*
+ 2 #.*
+ 3 0000 E0175840 Main SETH X,YZ
+ 4 0004 E12D5840 SETMH \$45,YZ
+ 5 0008 E8171ED4 ORH X,7892
+ 6 000c E92D3039 ORMH \$45,12345
+ 7
+ 8 0010 E2175840 SETML X,YZ
+ 9 0014 E32D5840 SETL \$45,YZ
+ 10 0018 EA171ED4 ORML X,7892
+ 11 001c EB2D3039 ORL \$45,12345
+ 12
+ 13 0020 E42D3039 INCH \$45,12345
+ 14 0024 E5171ED4 INCMH X,7892
+ 15 0028 EC2D5840 ANDNH \$45,YZ
+ 16 002c ED175840 ANDNMH X,YZ
+ 17
+ 18 0030 E6175840 INCML X,YZ
+ 19 0034 E72D5840 INCL \$45,YZ
+ 20 0038 EE171ED4 ANDNML X,7892
+ 21 003c EF2D3039 ANDNL \$45,12345
+ 22 X IS \$23
+ 23 YZ IS #5678\+456
+\fGAS for MMIX .*/two-op\.s page 2
+
+
+DEFINED SYMBOLS
+.*/two-op\.s:3 \.text:0000000000000000 Main
+ \*REG\*:0000000000000017 X
+ \*ABS\*:0000000000005840 YZ
+
+NO UNDEFINED SYMBOLS
--- /dev/null
+# Two-operand insns; 16-bit operand.
+#
+Main SETH X,YZ
+ SETMH $45,YZ
+ ORH X,7892
+ ORMH $45,12345
+
+ SETML X,YZ
+ SETL $45,YZ
+ ORML X,7892
+ ORL $45,12345
+
+ INCH $45,12345
+ INCMH X,7892
+ ANDNH $45,YZ
+ ANDNMH X,YZ
+
+ INCML X,YZ
+ INCL $45,YZ
+ ANDNML X,7892
+ ANDNL $45,12345
+X IS $23
+YZ IS #5678+456
--- /dev/null
+# objdump: -dr
+# as: -linkrelax
+# source: unsave-op.s
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: fb00002d unsave 0,\$45
+ 4: fb00001f unsave 0,\$31
+ 8: fb000000 unsave 0,\$0
--- /dev/null
+# objdump: -dr
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0000000000000000 <Main>:
+ 0: fb00002d unsave 0,\$45
+ 4: fb00001f unsave 0,\$31
+ 8: fb000000 unsave 0,\$0
--- /dev/null
+GAS for MMIX .*/unsave-op.s page 1
+
+
+ 1 #.*
+ 2 0000 FB00002D Main UNSAVE 0,\$45
+ 3 0004 FB00001F UNSAVE 0,X
+ 4 0008 FB000000 UNSAVE 0,X0
+ 5 X IS \$31
+ 6 X0 IS \$0
+ 7
+\fGAS for MMIX .*/unsave-op\.s page 2
+
+
+DEFINED SYMBOLS
+.*/unsave-op.s:2 \.text:0000000000000000 Main
+ \*REG\*:000000000000001f X
+ \*REG\*:0000000000000000 X0
+
+NO UNDEFINED SYMBOLS
--- /dev/null
+# Test the 'u'-type operand, UNSAVE.
+Main UNSAVE 0,$45
+ UNSAVE 0,X
+ UNSAVE 0,X0
+X IS $31
+X0 IS $0
+
--- /dev/null
+#objdump: -drt
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+ l d \.text 0+
+0+ l d \.data 0+
+0+ l d \.bss 0+
+0+ g F \.text 0+ Main
+
+
+Disassembly of section \.text:
+
+0+ <Main>:
+ 0: 00000000 trap 0,0,0
+ 4: fd000000 swym 0,0,0
+ 8: ff000000 trip 0,0,0
+ c: f0000000 jmp c <Main\+0xc>
+ 10: f801e240 pop 1,57920
+ 14: f8000000 pop 0,0
--- /dev/null
+# Check that we allow zero operands for some insns.
+# Naked comments aren't supported when no operands are supplied; this
+# matches mmixal behavior.
+Main TRAP
+ SWYM
+ TRIP
+ JMP
+ POP 123456
+ POP
+2001-10-30 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * dis-asm.h (print_insn_mmix): Add prototype.
+
2001-10-24 Neil Booth <neil@daikokuya.demon.co.uk>
* include/safe-ctype.h (_sch_isbasic, IS_ISOBASIC): New.
enum bfd_endian display_endian;
/* Number of octets per incremented target address
- Normally one, but some DSPs have byte sizes of 16 or 32 bits
- */
+ Normally one, but some DSPs have byte sizes of 16 or 32 bits. */
unsigned int octets_per_byte;
/* Results from instruction decoders. Not all decoders yet support
extern int print_insn_h8300s PARAMS ((bfd_vma, disassemble_info*));
extern int print_insn_h8500 PARAMS ((bfd_vma, disassemble_info*));
extern int print_insn_alpha PARAMS ((bfd_vma, disassemble_info*));
-extern disassembler_ftype arc_get_disassembler PARAMS ((void *));
extern int print_insn_big_arm PARAMS ((bfd_vma, disassemble_info*));
extern int print_insn_little_arm PARAMS ((bfd_vma, disassemble_info*));
extern int print_insn_sparc PARAMS ((bfd_vma, disassemble_info*));
extern int print_insn_big_a29k PARAMS ((bfd_vma, disassemble_info*));
extern int print_insn_little_a29k PARAMS ((bfd_vma, disassemble_info*));
+extern int print_insn_avr PARAMS ((bfd_vma, disassemble_info*));
+extern int print_insn_d10v PARAMS ((bfd_vma, disassemble_info*));
+extern int print_insn_d30v PARAMS ((bfd_vma, disassemble_info*));
+extern int print_insn_fr30 PARAMS ((bfd_vma, disassemble_info*));
+extern int print_insn_hppa PARAMS ((bfd_vma, disassemble_info*));
extern int print_insn_i860 PARAMS ((bfd_vma, disassemble_info*));
extern int print_insn_i960 PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_sh PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_shl PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_hppa PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_fr30 PARAMS ((bfd_vma, disassemble_info*));
extern int print_insn_m32r PARAMS ((bfd_vma, disassemble_info*));
extern int print_insn_m88k PARAMS ((bfd_vma, disassemble_info*));
extern int print_insn_mcore PARAMS ((bfd_vma, disassemble_info*));
+extern int print_insn_mmix PARAMS ((bfd_vma, disassemble_info*));
extern int print_insn_mn10200 PARAMS ((bfd_vma, disassemble_info*));
extern int print_insn_mn10300 PARAMS ((bfd_vma, disassemble_info*));
extern int print_insn_ns32k PARAMS ((bfd_vma, disassemble_info*));
extern int print_insn_openrisc PARAMS ((bfd_vma, disassemble_info*));
extern int print_insn_pdp11 PARAMS ((bfd_vma, disassemble_info*));
+extern int print_insn_pj PARAMS ((bfd_vma, disassemble_info*));
extern int print_insn_big_powerpc PARAMS ((bfd_vma, disassemble_info*));
extern int print_insn_little_powerpc PARAMS ((bfd_vma, disassemble_info*));
extern int print_insn_rs6000 PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_w65 PARAMS ((bfd_vma, disassemble_info*));
-extern disassembler_ftype cris_get_disassembler PARAMS ((bfd *));
-extern int print_insn_d10v PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_d30v PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_v850 PARAMS ((bfd_vma, disassemble_info*));
+extern int print_insn_s390 PARAMS ((bfd_vma, disassemble_info*));
+extern int print_insn_sh PARAMS ((bfd_vma, disassemble_info*));
+extern int print_insn_shl PARAMS ((bfd_vma, disassemble_info*));
extern int print_insn_tic30 PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_vax PARAMS ((bfd_vma, disassemble_info*));
extern int print_insn_tic54x PARAMS ((bfd_vma, disassemble_info*));
extern int print_insn_tic80 PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_pj PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_avr PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_s390 PARAMS ((bfd_vma, disassemble_info*));
+extern int print_insn_v850 PARAMS ((bfd_vma, disassemble_info*));
+extern int print_insn_vax PARAMS ((bfd_vma, disassemble_info*));
+extern int print_insn_w65 PARAMS ((bfd_vma, disassemble_info*));
+
+extern disassembler_ftype arc_get_disassembler PARAMS ((void *));
+extern disassembler_ftype cris_get_disassembler PARAMS ((bfd *));
extern void print_arm_disassembler_options PARAMS ((FILE *));
extern void parse_arm_disassembler_option PARAMS ((char *));
+2001-10-30 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * mmix.h: New file.
+
2001-10-23 Alan Modra <amodra@bigpond.net.au>
* internal.h: White space changes to keep lines under 80 chars.
--- /dev/null
+/* MMIX support for BFD.
+ Copyright (C) 2001 Free Software Foundation, Inc.
+
+This file is part of BFD, the Binary File Descriptor library.
+
+This program is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2 of the License, or
+(at your option) any later version.
+
+This program is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with this program; if not, write to the Free Software
+Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+
+/* This file holds definitions specific to the MMIX ELF ABI. */
+#ifndef ELF_MMIX_H
+#define ELF_MMIX_H
+
+#include "elf/reloc-macros.h"
+
+/* Relocations. */
+START_RELOC_NUMBERS (elf_mmix_reloc_type)
+ RELOC_NUMBER (R_MMIX_NONE, 0)
+
+ /* Standard absolute relocations. */
+ RELOC_NUMBER (R_MMIX_8, 1)
+ RELOC_NUMBER (R_MMIX_16, 2)
+ RELOC_NUMBER (R_MMIX_24, 3)
+ RELOC_NUMBER (R_MMIX_32, 4)
+ RELOC_NUMBER (R_MMIX_64, 5)
+
+ /* Standard relative relocations. */
+ RELOC_NUMBER (R_MMIX_PC_8, 6)
+ RELOC_NUMBER (R_MMIX_PC_16, 7)
+ RELOC_NUMBER (R_MMIX_PC_24, 8)
+ RELOC_NUMBER (R_MMIX_PC_32, 9)
+ RELOC_NUMBER (R_MMIX_PC_64, 10)
+
+ /* GNU extensions for C++ vtables. */
+ RELOC_NUMBER (R_MMIX_GNU_VTINHERIT, 11)
+ RELOC_NUMBER (R_MMIX_GNU_VTENTRY, 12)
+
+ /* A GETA instruction. */
+ RELOC_NUMBER (R_MMIX_GETA, 13)
+ RELOC_NUMBER (R_MMIX_GETA_1, 14)
+ RELOC_NUMBER (R_MMIX_GETA_2, 15)
+ RELOC_NUMBER (R_MMIX_GETA_3, 16)
+
+ /* A conditional branch instruction. */
+ RELOC_NUMBER (R_MMIX_CBRANCH, 17)
+ RELOC_NUMBER (R_MMIX_CBRANCH_J, 18)
+ RELOC_NUMBER (R_MMIX_CBRANCH_1, 19)
+ RELOC_NUMBER (R_MMIX_CBRANCH_2, 20)
+ RELOC_NUMBER (R_MMIX_CBRANCH_3, 21)
+
+ /* A PUSHJ instruction. */
+ RELOC_NUMBER (R_MMIX_PUSHJ, 22)
+ RELOC_NUMBER (R_MMIX_PUSHJ_1, 23)
+ RELOC_NUMBER (R_MMIX_PUSHJ_2, 24)
+ RELOC_NUMBER (R_MMIX_PUSHJ_3, 25)
+
+ /* A JMP instruction. */
+ RELOC_NUMBER (R_MMIX_JMP, 26)
+ RELOC_NUMBER (R_MMIX_JMP_1, 27)
+ RELOC_NUMBER (R_MMIX_JMP_2, 28)
+ RELOC_NUMBER (R_MMIX_JMP_3, 29)
+
+ /* A relative address such as in a GETA or a branch. */
+ RELOC_NUMBER (R_MMIX_ADDR19, 30)
+
+ /* A relative address such as in a JMP (only). */
+ RELOC_NUMBER (R_MMIX_ADDR27, 31)
+
+ /* A general register or a number 0..255. */
+ RELOC_NUMBER (R_MMIX_REG_OR_BYTE, 32)
+
+ /* A general register. */
+ RELOC_NUMBER (R_MMIX_REG, 33)
+
+ /* A global register and an offset, equivalent of the expression. */
+ RELOC_NUMBER (R_MMIX_BASE_PLUS_OFFSET, 34)
+
+ /* A LOCAL assertion. */
+ RELOC_NUMBER (R_MMIX_LOCAL, 35)
+END_RELOC_NUMBERS (R_MMIX_max)
+
+
+/* Section Attributes. */
+/* A section containing necessary information for relaxation. */
+#define SHF_MMIX_CANRELAX 0x80000000
+
+/* Symbol attributes. */
+/* A symbol with this section-index is a register. */
+#define SHN_REGISTER SHN_LOPROC
+
+/* This section holds contents for each initialized register, at VMA
+ regno*8. A symbol relative to this section will be transformed to an
+ absolute symbol with the value corresponding to the register number at
+ final link time. A symbol with a value outside the inclusive range
+ 32*8 .. 254*8 is an error. It is highly recommended to only use an
+ upper bound of 253*8 or lower as specified in the (currently
+ unspecified) ABI. */
+#define MMIX_REG_CONTENTS_SECTION_NAME ".MMIX.reg_contents"
+
+/* This is a faked section holding symbols with SHN_REGISTER. Don't
+ confuse it with MMIX_REG_CONTENTS_SECTION_NAME; this one has no
+ contents, just values. It is an error for a value in this section to
+ be outside the range 32..255 and it must never become an actual section
+ in an object file. */
+#define MMIX_REG_SECTION_NAME "*REG*"
+
+/* Appended with a number N=0..65535, this is a representation of the
+ mmixal "BSPEC N" ... "ESPEC" directive pair; the contents go into an
+ ELF section by name ".MMIX.spec_data.N". */
+#define MMIX_OTHER_SPEC_SECTION_PREFIX ".MMIX.spec_data."
+
+/* A section SECNAME is noted to start at "__.MMIX.start.SECNAME" by the
+ presence of this symbol. Currently only implemented for ".text"
+ through the symbol "__.MMIX.start..text". */
+#define MMIX_LOC_SECTION_START_SYMBOL_PREFIX "__.MMIX.start."
+
+/* This symbol is always a function. */
+#define MMIX_START_SYMBOL_NAME "Main"
+
+
+/* We smuggle in a few MMO specifics here. We don't make a specific MMO
+ file, since we can't reasonably support MMO without ELF; we have to
+ include this file anyway. */
+
+#define MMO_TEXT_SECTION_NAME ".text"
+#define MMO_DATA_SECTION_NAME ".data"
+
+/* A definition for the flags we put in spec data in files. A copy of our
+ own of some flags to keep immune to BFD flag changes. See section.c of
+ 2001-07-18 for flag documentation. */
+#define MMO_SEC_ALLOC 0x001
+#define MMO_SEC_LOAD 0x002
+#define MMO_SEC_RELOC 0x004
+#define MMO_SEC_READONLY 0x010
+#define MMO_SEC_CODE 0x020
+#define MMO_SEC_DATA 0x040
+#define MMO_SEC_NEVER_LOAD 0x400
+#define MMO_SEC_IS_COMMON 0x8000
+#define MMO_SEC_DEBUGGING 0x10000
+
+#endif /* ELF_MMIX_H */
+2001-10-30 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * mmix.h: New file.
+
2001-10-18 Chris Demetriou <cgd@broadcom.com>
* mips.h (OPCODE_IS_MEMBER): Add a no-op term to the end
--- /dev/null
+/* mmix.h -- Header file for MMIX opcode table
+ Copyright (C) 2001 Free Software Foundation, Inc.
+ Written by Hans-Peter Nilsson (hp@bitrange.com)
+
+This file is part of GDB, GAS, and the GNU binutils.
+
+GDB, GAS, and the GNU binutils are free software; you can redistribute
+them and/or modify them under the terms of the GNU General Public
+License as published by the Free Software Foundation; either version 2,
+or (at your option) any later version.
+
+GDB, GAS, and the GNU binutils are distributed in the hope that they
+will be useful, but WITHOUT ANY WARRANTY; without even the implied
+warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See
+the GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with this file; see the file COPYING. If not, write to the Free
+Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+
+/* We could have just a char*[] table indexed by the register number, but
+ that would not allow for synonyms. The table is terminated with an
+ entry with a NULL name. */
+struct mmix_spec_reg
+{
+ const char *name;
+ unsigned int number;
+};
+
+/* General indication of the type of instruction. */
+enum mmix_insn_type
+ {
+ mmix_type_pseudo,
+ mmix_type_normal,
+ mmix_type_branch,
+ mmix_type_condbranch,
+ mmix_type_memaccess_octa,
+ mmix_type_memaccess_tetra,
+ mmix_type_memaccess_wyde,
+ mmix_type_memaccess_byte,
+ mmix_type_memaccess_block,
+ mmix_type_jsr
+ };
+
+/* Type of operands an instruction takes. Use when parsing assembly code
+ and disassembling. */
+enum mmix_operands_type
+ {
+ mmix_operands_none = 0,
+
+ /* All operands are registers: "$X,$Y,$Z". */
+ mmix_operands_regs,
+
+ /* "$X,YZ", like SETH. */
+ mmix_operands_reg_yz,
+
+ /* The regular "$X,$Y,$Z|Z".
+ The Z is optional; if only "$X,$Y" is given, then "$X,$Y,0" is
+ assumed. */
+ mmix_operands_regs_z_opt,
+
+ /* The regular "$X,$Y,$Z|Z". */
+ mmix_operands_regs_z,
+
+ /* "Address"; only JMP. Zero operands allowed unless GNU syntax. */
+ mmix_operands_jmp,
+
+ /* "$X|X,$Y,$Z|Z": PUSHGO; like "3", but X can be expressed as an
+ integer. */
+ mmix_operands_pushgo,
+
+ /* Two registers or a register and a byte, like FLOT, possibly with
+ rounding: "$X,$Z|Z" or "$X,ROUND_MODE,$Z|Z". */
+ mmix_operands_roundregs_z,
+
+ /* "X,YZ", POP. Unless GNU syntax, zero or one operand is allowed. */
+ mmix_operands_pop,
+
+ /* Two registers, possibly with rounding: "$X,$Z" or
+ "$X,ROUND_MODE,$Z". */
+ mmix_operands_roundregs,
+
+ /* "XYZ", like SYNC. */
+ mmix_operands_sync,
+
+ /* "X,$Y,$Z|Z", like SYNCD. */
+ mmix_operands_x_regs_z,
+
+ /* "$X,Y,$Z|Z", like NEG and NEGU. The Y field is optional, default 0. */
+ mmix_operands_neg,
+
+ /* "$X,Address, like GETA or branches. */
+ mmix_operands_regaddr,
+
+ /* "$X|X,Address, like PUSHJ. */
+ mmix_operands_pushj,
+
+ /* "$X,spec_reg"; GET. */
+ mmix_operands_get,
+
+ /* "spec_reg,$Z|Z"; PUT. */
+ mmix_operands_put,
+
+ /* Two registers, "$X,$Y". */
+ mmix_operands_set,
+
+ /* "$X,0"; SAVE. */
+ mmix_operands_save,
+
+ /* "0,$Z"; UNSAVE. */
+ mmix_operands_unsave,
+
+ /* "X,Y,Z"; like SWYM or TRAP. Zero (or 1 if GNU syntax) to three
+ operands, interpreted as 0; XYZ; X, YZ and X, Y, Z. */
+ mmix_operands_xyz_opt,
+
+ /* Just "Z", like RESUME. Unless GNU syntax, the operand can be omitted
+ and will then be assumed zero. */
+ mmix_operands_resume,
+
+ /* These are specials to handle that pseudo-directives are specified
+ like ordinary insns when being mmixal-compatible. They signify the
+ specific pseudo-directive rather than the operands type. */
+
+ /* LOC. */
+ mmix_operands_loc,
+
+ /* PREFIX. */
+ mmix_operands_prefix,
+
+ /* BYTE. */
+ mmix_operands_byte,
+
+ /* WYDE. */
+ mmix_operands_wyde,
+
+ /* TETRA. */
+ mmix_operands_tetra,
+
+ /* OCTA. */
+ mmix_operands_octa,
+
+ /* LOCAL. */
+ mmix_operands_local,
+
+ /* BSPEC. */
+ mmix_operands_bspec,
+
+ /* ESPEC. */
+ mmix_operands_espec,
+ };
+
+struct mmix_opcode
+ {
+ const char *name;
+ unsigned long match;
+ unsigned long lose;
+ enum mmix_operands_type operands;
+
+ /* This is used by the disassembly function. */
+ enum mmix_insn_type type;
+ };
+
+/* Declare the actual tables. */
+extern const struct mmix_opcode mmix_opcodes[];
+
+/* This one is terminated with an entry with a NULL name. */
+extern const struct mmix_spec_reg mmix_spec_regs[];
+
+/* Some insn values we use when padding and synthesizing address loads. */
+#define IMM_OFFSET_BIT 1
+#define COND_INV_BIT 0x8
+#define PRED_INV_BIT 0x10
+
+#define PUSHGO_INSN_BYTE 0xbe
+#define GO_INSN_BYTE 0x9e
+#define SETL_INSN_BYTE 0xe3
+#define INCML_INSN_BYTE 0xe6
+#define INCMH_INSN_BYTE 0xe5
+#define INCH_INSN_BYTE 0xe4
+#define SWYM_INSN_BYTE 0xfd
+
+/* We can have 256 - 32 (local registers) - 1 ($255 is not allocatable)
+ global registers. */
+#define MAX_GREGS 223
+2001-10-30 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * configure.tgt (mmix-*-*): New target.
+ * Makefile.am (ALL_EMULATIONS): Add eelf64mmix.o and emmo.o.
+ Add dependencies to match.
+ * emulparams/mmo.sh, emulparams/elf64mmix.sh, emultempl/mmo.em,
+ emultempl/mmix-elfnmmo.em, emultempl/mmixelf.em,
+ scripttempl/mmo.sc: New files.
+ * gen-doc.texi: @set MMIX.
+ * ld.texinfo: Ditto.
+ [MMIX] Add MMIX node.
+ * Makefile.in: Regenerate.
+
2001-10-29 Kazu Hirata <kazu@hxi.com>
* ldlang.c: Fix a comment typo.
eelf64btsmip.o \
eelf64ltsmip.o \
eelf64hppa.o \
+ eelf64mmix.o \
+ emmo.o \
eelf64ppc.o \
eelf64lppc.o \
eaixppc64.o \
eelf64bmip.c: $(srcdir)/emulparams/elf64bmip.sh \
$(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
${GENSCRIPTS} elf64bmip "$(tdir_elf64bmip)"
+eelf64mmix.c: $(srcdir)/emulparams/elf64mmix.sh \
+ $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/mmix-elfnmmo.em \
+ $(srcdir)/emultempl/mmixelf.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
+ ${GENSCRIPTS} elf64mmix "$(tdir_elf64mmix)"
+emmo.c: $(srcdir)/emulparams/mmo.sh $(srcdir)/emultempl/mmix-elfnmmo.em \
+ $(srcdir)/emultempl/generic.em $(srcdir)/emultempl/mmo.em \
+ $(srcdir)/scripttempl/mmo.sc ${GEN_DEPENDS}
+ ${GENSCRIPTS} mmo "$(tdir_mmo)"
eelf64btsmip.c: $(srcdir)/emulparams/elf64btsmip.sh \
$(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
${GENSCRIPTS} elf64btsmip "$(tdir_elf64btsmip)"
-# Makefile.in generated automatically by automake 1.4 from Makefile.am
+# Makefile.in generated automatically by automake 1.4-p5 from Makefile.am
-# Copyright (C) 1994, 1995-8, 1999 Free Software Foundation, Inc.
+# Copyright (C) 1994, 1995-8, 1999, 2001 Free Software Foundation, Inc.
# This Makefile.in is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
# with or without modifications, as long as this notice is preserved.
eelf64btsmip.o \
eelf64ltsmip.o \
eelf64hppa.o \
+ eelf64mmix.o \
+ emmo.o \
eelf64ppc.o \
eelf64lppc.o \
eaixppc64.o \
DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) $(TEXINFOS) $(EXTRA_DIST)
-TAR = tar
+TAR = gtar
GZIP_ENV = --best
SOURCES = $(ld_new_SOURCES) $(EXTRA_ld_new_SOURCES)
OBJECTS = $(ld_new_OBJECTS)
else ii=; fi; \
list='$(INFO_DEPS)'; \
for file in $$list; do \
- test -z "$ii" \
+ test -z "$$ii" \
|| install-info --info-dir=$(DESTDIR)$(infodir) --remove $$file; \
done
@$(NORMAL_UNINSTALL)
dot_seen=no; \
rev=''; list='$(SUBDIRS)'; for subdir in $$list; do \
rev="$$subdir $$rev"; \
- test "$$subdir" = "." && dot_seen=yes; \
+ test "$$subdir" != "." || dot_seen=yes; \
done; \
test "$$dot_seen" = "no" && rev=". $$rev"; \
target=`echo $@ | sed s/-recursive//`; \
eelf64bmip.c: $(srcdir)/emulparams/elf64bmip.sh \
$(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
${GENSCRIPTS} elf64bmip "$(tdir_elf64bmip)"
+eelf64mmix.c: $(srcdir)/emulparams/elf64mmix.sh \
+ $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/mmix-elfnmmo.em \
+ $(srcdir)/emultempl/mmixelf.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
+ ${GENSCRIPTS} elf64mmix "$(tdir_elf64mmix)"
+emmo.c: $(srcdir)/emulparams/mmo.sh $(srcdir)/emultempl/mmix-elfnmmo.em \
+ $(srcdir)/emultempl/generic.em $(srcdir)/emultempl/mmo.em \
+ $(srcdir)/scripttempl/mmo.sc ${GEN_DEPENDS}
+ ${GENSCRIPTS} mmo "$(tdir_mmo)"
eelf64btsmip.c: $(srcdir)/emulparams/elf64btsmip.sh \
$(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
${GENSCRIPTS} elf64btsmip "$(tdir_elf64btsmip)"
program_transform_name=s,x,x,
silent=
site=
-sitefile=
srcdir=
target=NONE
verbose=
--help print this message
--no-create do not create output files
--quiet, --silent do not print \`checking...' messages
- --site-file=FILE use FILE as the site file
--version print the version of autoconf that created configure
Directory and file names:
--prefix=PREFIX install architecture-independent files in PREFIX
-site=* | --site=* | --sit=*)
site="$ac_optarg" ;;
- -site-file | --site-file | --site-fil | --site-fi | --site-f)
- ac_prev=sitefile ;;
- -site-file=* | --site-file=* | --site-fil=* | --site-fi=* | --site-f=*)
- sitefile="$ac_optarg" ;;
-
-srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
ac_prev=srcdir ;;
-srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
# Prefer explicitly selected file to automatically selected ones.
-if test -z "$sitefile"; then
- if test -z "$CONFIG_SITE"; then
- if test "x$prefix" != xNONE; then
- CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
- else
- CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
- fi
+if test -z "$CONFIG_SITE"; then
+ if test "x$prefix" != xNONE; then
+ CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
+ else
+ CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
fi
-else
- CONFIG_SITE="$sitefile"
fi
for ac_site_file in $CONFIG_SITE; do
if test -r "$ac_site_file"; then
fi
echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6
-echo "configure:561: checking for Cygwin environment" >&5
+echo "configure:550: checking for Cygwin environment" >&5
if eval "test \"`echo '$''{'ac_cv_cygwin'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 566 "configure"
+#line 555 "configure"
#include "confdefs.h"
int main() {
return __CYGWIN__;
; return 0; }
EOF
-if { (eval echo configure:577: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:566: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_cygwin=yes
else
CYGWIN=
test "$ac_cv_cygwin" = yes && CYGWIN=yes
echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6
-echo "configure:594: checking for mingw32 environment" >&5
+echo "configure:583: checking for mingw32 environment" >&5
if eval "test \"`echo '$''{'ac_cv_mingw32'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 599 "configure"
+#line 588 "configure"
#include "confdefs.h"
int main() {
return __MINGW32__;
; return 0; }
EOF
-if { (eval echo configure:606: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:595: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_mingw32=yes
else
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:671: checking host system type" >&5
+echo "configure:660: checking host system type" >&5
host_alias=$host
case "$host_alias" in
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:692: checking target system type" >&5
+echo "configure:681: checking target system type" >&5
target_alias=$target
case "$target_alias" in
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:710: checking build system type" >&5
+echo "configure:699: checking build system type" >&5
build_alias=$build
case "$build_alias" in
echo $ac_n "checking for strerror in -lcposix""... $ac_c" 1>&6
-echo "configure:734: checking for strerror in -lcposix" >&5
+echo "configure:723: checking for strerror in -lcposix" >&5
ac_lib_var=`echo cposix'_'strerror | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lcposix $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 742 "configure"
+#line 731 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
strerror()
; return 0; }
EOF
-if { (eval echo configure:753: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:742: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:789: checking for a BSD compatible install" >&5
+echo "configure:778: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
-echo "configure:842: checking whether build environment is sane" >&5
+echo "configure:831: checking whether build environment is sane" >&5
# Just in case
sleep 1
echo timestamp > conftestfile
test "$program_transform_name" = "" && program_transform_name="s,x,x,"
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:899: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:888: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
missing_dir=`cd $ac_aux_dir && pwd`
echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
-echo "configure:945: checking for working aclocal" >&5
+echo "configure:934: checking for working aclocal" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
fi
echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
-echo "configure:958: checking for working autoconf" >&5
+echo "configure:947: checking for working autoconf" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
fi
echo $ac_n "checking for working automake""... $ac_c" 1>&6
-echo "configure:971: checking for working automake" >&5
+echo "configure:960: checking for working automake" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
fi
echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
-echo "configure:984: checking for working autoheader" >&5
+echo "configure:973: checking for working autoheader" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
fi
echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
-echo "configure:997: checking for working makeinfo" >&5
+echo "configure:986: checking for working makeinfo" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
# Extract the first word of "gcc", so it can be a program name with args.
set dummy gcc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1083: checking for $ac_word" >&5
+echo "configure:1072: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "cc", so it can be a program name with args.
set dummy cc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1113: checking for $ac_word" >&5
+echo "configure:1102: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "cl", so it can be a program name with args.
set dummy cl; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1164: checking for $ac_word" >&5
+echo "configure:1153: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:1196: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:1185: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
cat > conftest.$ac_ext << EOF
-#line 1207 "configure"
+#line 1196 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:1212: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1201: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:1238: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:1227: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:1243: checking whether we are using GNU C" >&5
+echo "configure:1232: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1252: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1241: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:1271: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:1260: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
if test "$GCC" = yes; then
# Check if gcc -print-prog-name=ld gives a path.
echo $ac_n "checking for ld used by GCC""... $ac_c" 1>&6
-echo "configure:1314: checking for ld used by GCC" >&5
+echo "configure:1303: checking for ld used by GCC" >&5
case $host in
*-*-mingw*)
# gcc leaves a trailing carriage return which upsets mingw
esac
elif test "$with_gnu_ld" = yes; then
echo $ac_n "checking for GNU ld""... $ac_c" 1>&6
-echo "configure:1344: checking for GNU ld" >&5
+echo "configure:1333: checking for GNU ld" >&5
else
echo $ac_n "checking for non-GNU ld""... $ac_c" 1>&6
-echo "configure:1347: checking for non-GNU ld" >&5
+echo "configure:1336: checking for non-GNU ld" >&5
fi
if eval "test \"`echo '$''{'lt_cv_path_LD'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
fi
test -z "$LD" && { echo "configure: error: no acceptable ld found in \$PATH" 1>&2; exit 1; }
echo $ac_n "checking if the linker ($LD) is GNU ld""... $ac_c" 1>&6
-echo "configure:1382: checking if the linker ($LD) is GNU ld" >&5
+echo "configure:1371: checking if the linker ($LD) is GNU ld" >&5
if eval "test \"`echo '$''{'lt_cv_prog_gnu_ld'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
echo $ac_n "checking for $LD option to reload object files""... $ac_c" 1>&6
-echo "configure:1399: checking for $LD option to reload object files" >&5
+echo "configure:1388: checking for $LD option to reload object files" >&5
if eval "test \"`echo '$''{'lt_cv_ld_reload_flag'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
test -n "$reload_flag" && reload_flag=" $reload_flag"
echo $ac_n "checking for BSD-compatible nm""... $ac_c" 1>&6
-echo "configure:1411: checking for BSD-compatible nm" >&5
+echo "configure:1400: checking for BSD-compatible nm" >&5
if eval "test \"`echo '$''{'lt_cv_path_NM'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
echo "$ac_t""$NM" 1>&6
echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6
-echo "configure:1449: checking whether ln -s works" >&5
+echo "configure:1438: checking whether ln -s works" >&5
if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
fi
echo $ac_n "checking how to recognise dependant libraries""... $ac_c" 1>&6
-echo "configure:1470: checking how to recognise dependant libraries" >&5
+echo "configure:1459: checking how to recognise dependant libraries" >&5
if eval "test \"`echo '$''{'lt_cv_deplibs_check_method'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
deplibs_check_method=$lt_cv_deplibs_check_method
echo $ac_n "checking for object suffix""... $ac_c" 1>&6
-echo "configure:1634: checking for object suffix" >&5
+echo "configure:1623: checking for object suffix" >&5
if eval "test \"`echo '$''{'ac_cv_objext'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
rm -f conftest*
echo 'int i = 1;' > conftest.$ac_ext
-if { (eval echo configure:1640: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1629: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
for ac_file in conftest.*; do
case $ac_file in
*.c) ;;
echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
-echo "configure:1660: checking for executable suffix" >&5
+echo "configure:1649: checking for executable suffix" >&5
if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
rm -f conftest*
echo 'int main () { return 0; }' > conftest.$ac_ext
ac_cv_exeext=
- if { (eval echo configure:1670: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
+ if { (eval echo configure:1659: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
for file in conftest.*; do
case $file in
- *.c | *.o | *.obj | *.ilk | *.pdb) ;;
+ *.c | *.o | *.obj) ;;
*) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;;
esac
done
file_magic*)
if test "$file_magic_cmd" = '$MAGIC_CMD'; then
echo $ac_n "checking for ${ac_tool_prefix}file""... $ac_c" 1>&6
-echo "configure:1703: checking for ${ac_tool_prefix}file" >&5
+echo "configure:1692: checking for ${ac_tool_prefix}file" >&5
if eval "test \"`echo '$''{'lt_cv_path_MAGIC_CMD'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
if test -z "$lt_cv_path_MAGIC_CMD"; then
if test -n "$ac_tool_prefix"; then
echo $ac_n "checking for file""... $ac_c" 1>&6
-echo "configure:1765: checking for file" >&5
+echo "configure:1754: checking for file" >&5
if eval "test \"`echo '$''{'lt_cv_path_MAGIC_CMD'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
set dummy ${ac_tool_prefix}ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1836: checking for $ac_word" >&5
+echo "configure:1825: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "ranlib", so it can be a program name with args.
set dummy ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1868: checking for $ac_word" >&5
+echo "configure:1857: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
set dummy ${ac_tool_prefix}strip; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1903: checking for $ac_word" >&5
+echo "configure:1892: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_STRIP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "strip", so it can be a program name with args.
set dummy strip; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1935: checking for $ac_word" >&5
+echo "configure:1924: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_STRIP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
case $host in
*-*-irix6*)
# Find out which ABI we are using.
- echo '#line 2002 "configure"' > conftest.$ac_ext
- if { (eval echo configure:2003: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+ echo '#line 1991 "configure"' > conftest.$ac_ext
+ if { (eval echo configure:1992: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
case `/usr/bin/file conftest.$ac_objext` in
*32-bit*)
LD="${LD-ld} -32"
SAVE_CFLAGS="$CFLAGS"
CFLAGS="$CFLAGS -belf"
echo $ac_n "checking whether the C compiler needs -belf""... $ac_c" 1>&6
-echo "configure:2024: checking whether the C compiler needs -belf" >&5
+echo "configure:2013: checking whether the C compiler needs -belf" >&5
if eval "test \"`echo '$''{'lt_cv_cc_needs_belf'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext <<EOF
-#line 2037 "configure"
+#line 2026 "configure"
#include "confdefs.h"
int main() {
; return 0; }
EOF
-if { (eval echo configure:2044: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2033: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
lt_cv_cc_needs_belf=yes
else
# Extract the first word of "gcc", so it can be a program name with args.
set dummy gcc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2221: checking for $ac_word" >&5
+echo "configure:2210: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "cc", so it can be a program name with args.
set dummy cc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2251: checking for $ac_word" >&5
+echo "configure:2240: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "cl", so it can be a program name with args.
set dummy cl; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2302: checking for $ac_word" >&5
+echo "configure:2291: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:2334: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:2323: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
cat > conftest.$ac_ext << EOF
-#line 2345 "configure"
+#line 2334 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:2350: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2339: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:2376: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:2365: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:2381: checking whether we are using GNU C" >&5
+echo "configure:2370: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:2390: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:2379: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:2409: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:2398: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:2452: checking for a BSD compatible install" >&5
+echo "configure:2441: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ALL_LINGUAS=
echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
-echo "configure:2507: checking how to run the C preprocessor" >&5
+echo "configure:2496: checking how to run the C preprocessor" >&5
# On Suns, sometimes $CPP names a directory.
if test -n "$CPP" && test -d "$CPP"; then
CPP=
# On the NeXT, cc -E runs the code through the compiler's parser,
# not just through cpp.
cat > conftest.$ac_ext <<EOF
-#line 2522 "configure"
+#line 2511 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2528: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2517: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
rm -rf conftest*
CPP="${CC-cc} -E -traditional-cpp"
cat > conftest.$ac_ext <<EOF
-#line 2539 "configure"
+#line 2528 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2545: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2534: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
rm -rf conftest*
CPP="${CC-cc} -nologo -E"
cat > conftest.$ac_ext <<EOF
-#line 2556 "configure"
+#line 2545 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2562: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2551: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
# Extract the first word of "ranlib", so it can be a program name with args.
set dummy ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2589: checking for $ac_word" >&5
+echo "configure:2578: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
fi
echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
-echo "configure:2617: checking for ANSI C header files" >&5
+echo "configure:2606: checking for ANSI C header files" >&5
if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2622 "configure"
+#line 2611 "configure"
#include "confdefs.h"
#include <stdlib.h>
#include <stdarg.h>
#include <float.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2630: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2619: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
if test $ac_cv_header_stdc = yes; then
# SunOS 4.x string.h does not declare mem*, contrary to ANSI.
cat > conftest.$ac_ext <<EOF
-#line 2647 "configure"
+#line 2636 "configure"
#include "confdefs.h"
#include <string.h>
EOF
if test $ac_cv_header_stdc = yes; then
# ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
cat > conftest.$ac_ext <<EOF
-#line 2665 "configure"
+#line 2654 "configure"
#include "confdefs.h"
#include <stdlib.h>
EOF
:
else
cat > conftest.$ac_ext <<EOF
-#line 2686 "configure"
+#line 2675 "configure"
#include "confdefs.h"
#include <ctype.h>
#define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
exit (0); }
EOF
-if { (eval echo configure:2697: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:2686: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
:
else
fi
echo $ac_n "checking for working const""... $ac_c" 1>&6
-echo "configure:2721: checking for working const" >&5
+echo "configure:2710: checking for working const" >&5
if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2726 "configure"
+#line 2715 "configure"
#include "confdefs.h"
int main() {
; return 0; }
EOF
-if { (eval echo configure:2775: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:2764: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_c_const=yes
else
fi
echo $ac_n "checking for inline""... $ac_c" 1>&6
-echo "configure:2796: checking for inline" >&5
+echo "configure:2785: checking for inline" >&5
if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_cv_c_inline=no
for ac_kw in inline __inline__ __inline; do
cat > conftest.$ac_ext <<EOF
-#line 2803 "configure"
+#line 2792 "configure"
#include "confdefs.h"
int main() {
} $ac_kw foo() {
; return 0; }
EOF
-if { (eval echo configure:2810: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:2799: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_c_inline=$ac_kw; break
else
esac
echo $ac_n "checking for off_t""... $ac_c" 1>&6
-echo "configure:2836: checking for off_t" >&5
+echo "configure:2825: checking for off_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2841 "configure"
+#line 2830 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
fi
echo $ac_n "checking for size_t""... $ac_c" 1>&6
-echo "configure:2869: checking for size_t" >&5
+echo "configure:2858: checking for size_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2874 "configure"
+#line 2863 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
# for constant arguments. Useless!
echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6
-echo "configure:2904: checking for working alloca.h" >&5
+echo "configure:2893: checking for working alloca.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2909 "configure"
+#line 2898 "configure"
#include "confdefs.h"
#include <alloca.h>
int main() {
char *p = alloca(2 * sizeof(int));
; return 0; }
EOF
-if { (eval echo configure:2916: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2905: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
ac_cv_header_alloca_h=yes
else
fi
echo $ac_n "checking for alloca""... $ac_c" 1>&6
-echo "configure:2937: checking for alloca" >&5
+echo "configure:2926: checking for alloca" >&5
if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2942 "configure"
+#line 2931 "configure"
#include "confdefs.h"
#ifdef __GNUC__
char *p = (char *) alloca(1);
; return 0; }
EOF
-if { (eval echo configure:2970: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2959: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
ac_cv_func_alloca_works=yes
else
echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6
-echo "configure:3002: checking whether alloca needs Cray hooks" >&5
+echo "configure:2991: checking whether alloca needs Cray hooks" >&5
if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3007 "configure"
+#line 2996 "configure"
#include "confdefs.h"
#if defined(CRAY) && ! defined(CRAY2)
webecray
if test $ac_cv_os_cray = yes; then
for ac_func in _getb67 GETB67 getb67; do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3032: checking for $ac_func" >&5
+echo "configure:3021: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3037 "configure"
+#line 3026 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:3060: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3049: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
fi
echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6
-echo "configure:3087: checking stack direction for C alloca" >&5
+echo "configure:3076: checking stack direction for C alloca" >&5
if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_cv_c_stack_direction=0
else
cat > conftest.$ac_ext <<EOF
-#line 3095 "configure"
+#line 3084 "configure"
#include "confdefs.h"
find_stack_direction ()
{
exit (find_stack_direction() < 0);
}
EOF
-if { (eval echo configure:3114: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:3103: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_c_stack_direction=1
else
fi
-for ac_hdr in unistd.h
+for ac_hdr in stdlib.h unistd.h sys/stat.h sys/types.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:3139: checking for $ac_hdr" >&5
+echo "configure:3128: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3144 "configure"
+#line 3133 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3149: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3138: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
for ac_func in getpagesize
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3178: checking for $ac_func" >&5
+echo "configure:3167: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3183 "configure"
+#line 3172 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:3206: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3195: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
done
echo $ac_n "checking for working mmap""... $ac_c" 1>&6
-echo "configure:3231: checking for working mmap" >&5
+echo "configure:3220: checking for working mmap" >&5
if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_cv_func_mmap_fixed_mapped=no
else
cat > conftest.$ac_ext <<EOF
-#line 3239 "configure"
+#line 3228 "configure"
#include "confdefs.h"
/* Thanks to Mike Haertel and Jim Avera for this test.
#include <fcntl.h>
#include <sys/mman.h>
+#if HAVE_SYS_TYPES_H
+# include <sys/types.h>
+#endif
+
+#if HAVE_STDLIB_H
+# include <stdlib.h>
+#endif
+
+#if HAVE_SYS_STAT_H
+# include <sys/stat.h>
+#endif
+
+#if HAVE_UNISTD_H
+# include <unistd.h>
+#endif
+
/* This mess was copied from the GNU getpagesize.h. */
#ifndef HAVE_GETPAGESIZE
-# ifdef HAVE_UNISTD_H
-# include <unistd.h>
-# endif
/* Assume that all systems that can run configure have sys/param.h. */
# ifndef HAVE_SYS_PARAM_H
}
EOF
-if { (eval echo configure:3379: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:3381: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_func_mmap_fixed_mapped=yes
else
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:3407: checking for $ac_hdr" >&5
+echo "configure:3409: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3412 "configure"
+#line 3414 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3417: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3419: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
__argz_count __argz_stringify __argz_next
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3447: checking for $ac_func" >&5
+echo "configure:3449: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3452 "configure"
+#line 3454 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:3475: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3477: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
for ac_func in stpcpy
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3504: checking for $ac_func" >&5
+echo "configure:3506: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3509 "configure"
+#line 3511 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:3532: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3534: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
if test $ac_cv_header_locale_h = yes; then
echo $ac_n "checking for LC_MESSAGES""... $ac_c" 1>&6
-echo "configure:3566: checking for LC_MESSAGES" >&5
+echo "configure:3568: checking for LC_MESSAGES" >&5
if eval "test \"`echo '$''{'am_cv_val_LC_MESSAGES'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3571 "configure"
+#line 3573 "configure"
#include "confdefs.h"
#include <locale.h>
int main() {
return LC_MESSAGES
; return 0; }
EOF
-if { (eval echo configure:3578: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3580: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
am_cv_val_LC_MESSAGES=yes
else
fi
fi
echo $ac_n "checking whether NLS is requested""... $ac_c" 1>&6
-echo "configure:3599: checking whether NLS is requested" >&5
+echo "configure:3601: checking whether NLS is requested" >&5
# Check whether --enable-nls or --disable-nls was given.
if test "${enable_nls+set}" = set; then
enableval="$enable_nls"
EOF
echo $ac_n "checking whether included gettext is requested""... $ac_c" 1>&6
-echo "configure:3619: checking whether included gettext is requested" >&5
+echo "configure:3621: checking whether included gettext is requested" >&5
# Check whether --with-included-gettext or --without-included-gettext was given.
if test "${with_included_gettext+set}" = set; then
withval="$with_included_gettext"
ac_safe=`echo "libintl.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for libintl.h""... $ac_c" 1>&6
-echo "configure:3638: checking for libintl.h" >&5
+echo "configure:3640: checking for libintl.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3643 "configure"
+#line 3645 "configure"
#include "confdefs.h"
#include <libintl.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3648: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3650: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
echo "$ac_t""yes" 1>&6
echo $ac_n "checking for gettext in libc""... $ac_c" 1>&6
-echo "configure:3665: checking for gettext in libc" >&5
+echo "configure:3667: checking for gettext in libc" >&5
if eval "test \"`echo '$''{'gt_cv_func_gettext_libc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3670 "configure"
+#line 3672 "configure"
#include "confdefs.h"
#include <libintl.h>
int main() {
return (int) gettext ("")
; return 0; }
EOF
-if { (eval echo configure:3677: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3679: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
gt_cv_func_gettext_libc=yes
else
if test "$gt_cv_func_gettext_libc" != "yes"; then
echo $ac_n "checking for bindtextdomain in -lintl""... $ac_c" 1>&6
-echo "configure:3693: checking for bindtextdomain in -lintl" >&5
+echo "configure:3695: checking for bindtextdomain in -lintl" >&5
ac_lib_var=`echo intl'_'bindtextdomain | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lintl $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 3701 "configure"
+#line 3703 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
bindtextdomain()
; return 0; }
EOF
-if { (eval echo configure:3712: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3714: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
echo "$ac_t""yes" 1>&6
echo $ac_n "checking for gettext in libintl""... $ac_c" 1>&6
-echo "configure:3728: checking for gettext in libintl" >&5
+echo "configure:3730: checking for gettext in libintl" >&5
if eval "test \"`echo '$''{'gt_cv_func_gettext_libintl'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3733 "configure"
+#line 3735 "configure"
#include "confdefs.h"
int main() {
return (int) gettext ("")
; return 0; }
EOF
-if { (eval echo configure:3740: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3742: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
gt_cv_func_gettext_libintl=yes
else
# Extract the first word of "msgfmt", so it can be a program name with args.
set dummy msgfmt; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3768: checking for $ac_word" >&5
+echo "configure:3770: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
for ac_func in dcgettext
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3802: checking for $ac_func" >&5
+echo "configure:3804: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3807 "configure"
+#line 3809 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:3830: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3832: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
# Extract the first word of "gmsgfmt", so it can be a program name with args.
set dummy gmsgfmt; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3857: checking for $ac_word" >&5
+echo "configure:3859: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "xgettext", so it can be a program name with args.
set dummy xgettext; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3893: checking for $ac_word" >&5
+echo "configure:3895: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
fi
cat > conftest.$ac_ext <<EOF
-#line 3925 "configure"
+#line 3927 "configure"
#include "confdefs.h"
int main() {
return _nl_msg_cat_cntr
; return 0; }
EOF
-if { (eval echo configure:3933: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3935: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
CATOBJEXT=.gmo
DATADIRNAME=share
# Extract the first word of "msgfmt", so it can be a program name with args.
set dummy msgfmt; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3965: checking for $ac_word" >&5
+echo "configure:3967: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "gmsgfmt", so it can be a program name with args.
set dummy gmsgfmt; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3999: checking for $ac_word" >&5
+echo "configure:4001: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "xgettext", so it can be a program name with args.
set dummy xgettext; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4035: checking for $ac_word" >&5
+echo "configure:4037: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
LINGUAS=
else
echo $ac_n "checking for catalogs to be installed""... $ac_c" 1>&6
-echo "configure:4125: checking for catalogs to be installed" >&5
+echo "configure:4127: checking for catalogs to be installed" >&5
NEW_LINGUAS=
for lang in ${LINGUAS=$ALL_LINGUAS}; do
case "$ALL_LINGUAS" in
if test "$CATOBJEXT" = ".cat"; then
ac_safe=`echo "linux/version.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for linux/version.h""... $ac_c" 1>&6
-echo "configure:4153: checking for linux/version.h" >&5
+echo "configure:4155: checking for linux/version.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4158 "configure"
+#line 4160 "configure"
#include "confdefs.h"
#include <linux/version.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:4163: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:4165: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
-echo "configure:4228: checking for executable suffix" >&5
+echo "configure:4230: checking for executable suffix" >&5
if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
rm -f conftest*
echo 'int main () { return 0; }' > conftest.$ac_ext
ac_cv_exeext=
- if { (eval echo configure:4238: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
+ if { (eval echo configure:4240: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
for file in conftest.*; do
case $file in
- *.c | *.o | *.obj | *.ilk | *.pdb) ;;
+ *.c | *.o | *.obj) ;;
*) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;;
esac
done
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4264: checking for $ac_word" >&5
+echo "configure:4266: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_YACC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4300: checking for $ac_word" >&5
+echo "configure:4302: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_LEX'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "flex", so it can be a program name with args.
set dummy flex; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4333: checking for $ac_word" >&5
+echo "configure:4335: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_LEX'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
*) ac_lib=l ;;
esac
echo $ac_n "checking for yywrap in -l$ac_lib""... $ac_c" 1>&6
-echo "configure:4367: checking for yywrap in -l$ac_lib" >&5
+echo "configure:4369: checking for yywrap in -l$ac_lib" >&5
ac_lib_var=`echo $ac_lib'_'yywrap | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-l$ac_lib $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 4375 "configure"
+#line 4377 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
yywrap()
; return 0; }
EOF
-if { (eval echo configure:4386: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4388: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
fi
echo $ac_n "checking lex output file root""... $ac_c" 1>&6
-echo "configure:4409: checking lex output file root" >&5
+echo "configure:4411: checking lex output file root" >&5
if eval "test \"`echo '$''{'ac_cv_prog_lex_root'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
LEX_OUTPUT_ROOT=$ac_cv_prog_lex_root
echo $ac_n "checking whether yytext is a pointer""... $ac_c" 1>&6
-echo "configure:4430: checking whether yytext is a pointer" >&5
+echo "configure:4432: checking whether yytext is a pointer" >&5
if eval "test \"`echo '$''{'ac_cv_prog_lex_yytext_pointer'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_save_LIBS="$LIBS"
LIBS="$LIBS $LEXLIB"
cat > conftest.$ac_ext <<EOF
-#line 4442 "configure"
+#line 4444 "configure"
#include "confdefs.h"
`cat $LEX_OUTPUT_ROOT.c`
int main() {
; return 0; }
EOF
-if { (eval echo configure:4449: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4451: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
ac_cv_prog_lex_yytext_pointer=yes
else
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:4472: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:4474: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:4506: checking for $ac_hdr" >&5
+echo "configure:4508: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4511 "configure"
+#line 4513 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:4516: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:4518: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
for ac_func in sbrk
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:4545: checking for $ac_func" >&5
+echo "configure:4547: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4550 "configure"
+#line 4552 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:4573: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4575: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr that defines DIR""... $ac_c" 1>&6
-echo "configure:4602: checking for $ac_hdr that defines DIR" >&5
+echo "configure:4604: checking for $ac_hdr that defines DIR" >&5
if eval "test \"`echo '$''{'ac_cv_header_dirent_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4607 "configure"
+#line 4609 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <$ac_hdr>
DIR *dirp = 0;
; return 0; }
EOF
-if { (eval echo configure:4615: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4617: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
eval "ac_cv_header_dirent_$ac_safe=yes"
else
# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
if test $ac_header_dirent = dirent.h; then
echo $ac_n "checking for opendir in -ldir""... $ac_c" 1>&6
-echo "configure:4640: checking for opendir in -ldir" >&5
+echo "configure:4642: checking for opendir in -ldir" >&5
ac_lib_var=`echo dir'_'opendir | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-ldir $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 4648 "configure"
+#line 4650 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
opendir()
; return 0; }
EOF
-if { (eval echo configure:4659: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4661: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
else
echo $ac_n "checking for opendir in -lx""... $ac_c" 1>&6
-echo "configure:4681: checking for opendir in -lx" >&5
+echo "configure:4683: checking for opendir in -lx" >&5
ac_lib_var=`echo x'_'opendir | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lx $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 4689 "configure"
+#line 4691 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
opendir()
; return 0; }
EOF
-if { (eval echo configure:4700: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4702: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
esac
echo $ac_n "checking whether strstr must be declared""... $ac_c" 1>&6
-echo "configure:4733: checking whether strstr must be declared" >&5
+echo "configure:4735: checking whether strstr must be declared" >&5
if eval "test \"`echo '$''{'bfd_cv_decl_needed_strstr'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4738 "configure"
+#line 4740 "configure"
#include "confdefs.h"
#include <stdio.h>
char *(*pfn) = (char *(*)) strstr
; return 0; }
EOF
-if { (eval echo configure:4759: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4761: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_decl_needed_strstr=no
else
fi
echo $ac_n "checking whether free must be declared""... $ac_c" 1>&6
-echo "configure:4780: checking whether free must be declared" >&5
+echo "configure:4782: checking whether free must be declared" >&5
if eval "test \"`echo '$''{'bfd_cv_decl_needed_free'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4785 "configure"
+#line 4787 "configure"
#include "confdefs.h"
#include <stdio.h>
char *(*pfn) = (char *(*)) free
; return 0; }
EOF
-if { (eval echo configure:4806: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4808: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_decl_needed_free=no
else
fi
echo $ac_n "checking whether sbrk must be declared""... $ac_c" 1>&6
-echo "configure:4827: checking whether sbrk must be declared" >&5
+echo "configure:4829: checking whether sbrk must be declared" >&5
if eval "test \"`echo '$''{'bfd_cv_decl_needed_sbrk'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4832 "configure"
+#line 4834 "configure"
#include "confdefs.h"
#include <stdio.h>
char *(*pfn) = (char *(*)) sbrk
; return 0; }
EOF
-if { (eval echo configure:4853: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4855: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_decl_needed_sbrk=no
else
fi
echo $ac_n "checking whether getenv must be declared""... $ac_c" 1>&6
-echo "configure:4874: checking whether getenv must be declared" >&5
+echo "configure:4876: checking whether getenv must be declared" >&5
if eval "test \"`echo '$''{'bfd_cv_decl_needed_getenv'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4879 "configure"
+#line 4881 "configure"
#include "confdefs.h"
#include <stdio.h>
char *(*pfn) = (char *(*)) getenv
; return 0; }
EOF
-if { (eval echo configure:4900: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4902: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_decl_needed_getenv=no
else
fi
echo $ac_n "checking whether environ must be declared""... $ac_c" 1>&6
-echo "configure:4921: checking whether environ must be declared" >&5
+echo "configure:4923: checking whether environ must be declared" >&5
if eval "test \"`echo '$''{'bfd_cv_decl_needed_environ'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4926 "configure"
+#line 4928 "configure"
#include "confdefs.h"
#include <stdio.h>
char *(*pfn) = (char *(*)) environ
; return 0; }
EOF
-if { (eval echo configure:4947: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4949: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_decl_needed_environ=no
else
# constants, while still supporting pre-ANSI compilers which do not
# support string concatenation.
echo $ac_n "checking whether ANSI C string concatenation works""... $ac_c" 1>&6
-echo "configure:4975: checking whether ANSI C string concatenation works" >&5
+echo "configure:4977: checking whether ANSI C string concatenation works" >&5
if eval "test \"`echo '$''{'ld_cv_string_concatenation'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4980 "configure"
+#line 4982 "configure"
#include "confdefs.h"
int main() {
char *a = "a" "a";
; return 0; }
EOF
-if { (eval echo configure:4987: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4989: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ld_cv_string_concatenation=yes
else
;;
mips*-*-lnews*) targ_emul=mipslnews ;;
mips*-*-sysv4*) targ_emul=elf32btsmip ;;
+mmix-*-*) targ_emul=mmo
+ targ_extra_emuls=elf64mmix
+ ;;
mn10200-*-*) targ_emul=mn10200 ;;
mn10300-*-*) targ_emul=mn10300 ;;
alpha*-*-freebsd*) targ_emul=elf64alpha
--- /dev/null
+TEMPLATE_NAME=elf32
+GENERATE_SHLIB_SCRIPT=yes
+ELFSIZE=64
+SCRIPT_NAME=elf
+OUTPUT_FORMAT="elf64-mmix"
+ENTRY=_start.
+
+# Default to 0 as mmixal does.
+TEXT_START_ADDR='DEFINED (__.MMIX.start..text) ? __.MMIX.start..text : 0'
+# Don't add SIZEOF_HEADERS.
+# Don't set EMBEDDED, that would be misleading; it's not that kind of system.
+TEXT_BASE_ADDRESS=$TEXT_START_ADDR
+DATA_ADDR='DEFINED (__.MMIX.start..data) ? __.MMIX.start..data : 0x2000000000000000'
+
+# Setting this anywhere near the quite reasonable value of 0x10000
+# causes the binary to bloat to reach page alignment between segments.
+# Let's just have a 256-byte default page alignment. Having some
+# alignment at all gives a warm feeling but not much more.
+MAXPAGESIZE=256
+ARCH=mmix
+MACHINE=
+COMPILE_IN=yes
+EXTRA_EM_FILE=mmixelf
+
+# The existence of a symbol __start (or _start) should overrule Main, so
+# it can be a user symbol without the associated mmixal magic. We
+# also want to provide Main as a synonym for _start, if Main wasn't
+# defined but is referred to, and _start was defined.
+#
+# The reason we use a symbol "_start." as a mediator is to avoid
+# causing ld to force the type of _start to object rather than no
+# type, which confuses disassembly; we also make it alphanumerically
+# a successor of _start for similar reasons. Perhaps it's a linker
+# bug that linker-defined symbols set the symbol-type.
+#
+# Note that we smuggle this into OTHER_TEXT_SECTIONS (at the end
+# of .text) rather than TEXT_START_SYMBOLS. This is necessary, as
+# DEFINED wouldn't find the symbol if it was at the top; presumably
+# before the definition, if the definition is not in the first file.
+# FIXME: Arguably a linker bug.
+OTHER_TEXT_SECTIONS='
+ _start. = (DEFINED (_start) ? _start
+ : (DEFINED (Main) ? Main : (DEFINED (.text) ? .text : 0)));
+ PROVIDE (Main = DEFINED (Main) ? Main : (DEFINED (_start) ? _start : _start.));
+'
+
+OTHER_RELOCATING_SECTIONS='
+ .MMIX.reg_contents :
+ {
+ /* Note that this section always has a fixed VMA - that of its
+ first register * 8. */
+ *(.MMIX.reg_contents);
+ }
+'
+
+# FIXME: Also bit by the PROVIDE bug? If not, this could be
+# EXECUTABLE_SYMBOLS.
+# By default, put the high end of the stack where the register stack
+# begins. They grow in opposite directions. */
+OTHER_SECTIONS='PROVIDE (__Stack_start = 0x6000000000000000);'
--- /dev/null
+SCRIPT_NAME=mmo
+TARGET_PAGE_SIZE=256
+
+# Default to 0 as mmixal does.
+TEXT_START_ADDR='DEFINED (__.MMIX.start..text) ? __.MMIX.start..text : 0'
+DATA_ADDR='DEFINED (__.MMIX.start..data) ? __.MMIX.start..data : 0x2000000000000000'
+OUTPUT_FORMAT=mmo
+ARCH=mmix
+COMPILE_IN=yes
+EXTRA_EM_FILE=mmo
--- /dev/null
+# This shell script emits a C file. -*- C -*-
+# Copyright 2001 Free Software Foundation, Inc.
+#
+# This file is part of GLD, the Gnu Linker.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+#
+
+# This file is sourced from elf32.em and mmo.em, used to define
+# MMIX-specific things common to ELF and MMO.
+
+cat >>e${EMULATION_NAME}.c <<EOF
+#include "elf/mmix.h"
+
+static void mmix_set_reg_section_vma PARAMS ((void));
+
+/* We need to set the VMA of the .MMIX.reg_contents section when it has
+ been allocated. */
+
+static void
+mmix_set_reg_section_vma ()
+{
+ asection *sec
+ = bfd_get_section_by_name (output_bfd, MMIX_REG_CONTENTS_SECTION_NAME);
+ bfd_vma regvma;
+
+ /* If there's no register section, we don't need to do anything. */
+ if (sec == NULL)
+ return;
+
+ regvma = 256 * 8 - sec->_raw_size - 8;
+
+ /* If we start on a local register, we have too many global registers. */
+ if (regvma < 32 * 8)
+ einfo ("%X%P: Too many global registers: %u, max 223\n",
+ (unsigned) sec->_raw_size / 8);
+
+ /* Set vma to correspond to first such register number * 8. */
+ bfd_set_section_vma (output_bfd, sec, regvma);
+
+ /* ??? Why isn't the section size (_cooked_size) set? Doesn't it get
+ set regardless of presence of relocations? */
+ if (sec->_cooked_size == 0
+ && ! bfd_set_section_size (output_bfd, sec, sec->_raw_size))
+ {
+ einfo ("%X%P: Can't set section %s size to %u\n",
+ MMIX_REG_CONTENTS_SECTION_NAME, (unsigned) sec->_raw_size);
+ return;
+ }
+
+ /* Simplify symbol output for the register section (without contents;
+ created for register symbols) by setting the output offset to 0. */
+ sec = bfd_get_section_by_name (output_bfd, MMIX_REG_SECTION_NAME);
+ if (sec == NULL)
+ return;
+
+ bfd_set_section_vma (abfd, sec, 0);
+
+}
+EOF
+
+LDEMUL_AFTER_ALLOCATION=mmix_set_reg_section_vma
--- /dev/null
+# This shell script emits a C file. -*- C -*-
+# Copyright 2001 Free Software Foundation, Inc.
+#
+# This file is part of GLD, the Gnu Linker.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+#
+
+# This file is sourced from elf32.em and used to define MMIX and ELF
+# specific things. First include what we have in common with mmo.
+
+. ${srcdir}/emultempl/mmix-elfnmmo.em
+
+cat >>e${EMULATION_NAME}.c <<EOF
+#line 29 "${srcdir}/emultempl/elfmmix.em"
+
+static void elfmmix_before_parse PARAMS ((void));
+
+static void
+elfmmix_before_parse ()
+{
+ gld${EMULATION_NAME}_before_parse ();
+
+ /* Make sure we don't create a demand-paged executable. Unfortunately
+ this isn't changeable with a command-line option. It makes no
+ difference to mmo, but the sections in elf64mmix will be aligned to a
+ page in the linked file, which is non-intuitive. If there's ever a
+ full system with shared libraries and demand paging, you will want to
+ exclude this file. */
+ config.magic_demand_paged = false;
+}
+EOF
+
+LDEMUL_BEFORE_PARSE=elfmmix_before_parse
--- /dev/null
+# This shell script emits a C file. -*- C -*-
+# Copyright 2001 Free Software Foundation, Inc.
+#
+# This file is part of GLD, the Gnu Linker.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+#
+
+# This file is sourced from elf32.em and mmo.em, used to define
+# linker MMIX-specifics common to ELF and MMO.
+
+. ${srcdir}/emultempl/mmix-elfnmmo.em
+
+cat >>e${EMULATION_NAME}.c <<EOF
+
+static boolean mmo_place_orphan
+ PARAMS ((lang_input_statement_type *, asection *));
+static asection *output_prev_sec_find
+ PARAMS ((lang_output_section_statement_type *));
+static void mmo_finish PARAMS ((void));
+static void mmo_wipe_sec_reloc_flag PARAMS ((bfd *, asection *, PTR));
+
+/* Find the last output section before given output statement.
+ Used by place_orphan. */
+
+static asection *
+output_prev_sec_find (os)
+ lang_output_section_statement_type *os;
+{
+ asection *s = (asection *) NULL;
+ lang_statement_union_type *u;
+ lang_output_section_statement_type *lookup;
+
+ for (u = lang_output_section_statement.head;
+ u != (lang_statement_union_type *) NULL;
+ u = lookup->next)
+ {
+ lookup = &u->output_section_statement;
+ if (lookup == os)
+ break;
+ if (lookup->bfd_section != NULL
+ && lookup->bfd_section != bfd_abs_section_ptr
+ && lookup->bfd_section != bfd_com_section_ptr
+ && lookup->bfd_section != bfd_und_section_ptr)
+ s = lookup->bfd_section;
+ }
+
+ if (u == NULL)
+ return NULL;
+
+ return s;
+}
+
+struct orphan_save {
+ lang_output_section_statement_type *os;
+ asection **section;
+ lang_statement_union_type **stmt;
+};
+
+#define HAVE_SECTION(hold, name) \
+(hold.os != NULL || (hold.os = lang_output_section_find (name)) != NULL)
+
+/* Place an orphan section. We use this to put random SEC_CODE or
+ SEC_READONLY sections right after MMO_TEXT_SECTION_NAME. Much borrowed
+ from elf32.em. */
+
+static boolean
+mmo_place_orphan (file, s)
+ lang_input_statement_type *file;
+ asection *s;
+{
+ static struct orphan_save hold_text;
+ struct orphan_save *place;
+ lang_output_section_statement_type *os;
+ lang_statement_list_type *old;
+ lang_statement_list_type add;
+ asection *snew, **pps, *bfd_section;
+
+ /* We have nothing to say for anything other than a final link. */
+ if (link_info.relocateable
+ || (bfd_get_section_flags (s->owner, s)
+ & (SEC_EXCLUDE | SEC_LOAD)) != SEC_LOAD)
+ return false;
+
+ /* Only care for sections we're going to load. */
+ os = lang_output_section_find (bfd_get_section_name (s->owner, s));
+
+ /* We have an output section by this name. Place the section inside it
+ (regardless of whether the linker script lists it as input). */
+ if (os != NULL)
+ {
+ lang_add_section (&os->children, s, os, file);
+ return true;
+ }
+
+ /* If this section does not have .text-type section flags or there's no
+ MMO_TEXT_SECTION_NAME, we don't have anything to say. */
+ if ((bfd_get_section_flags (s->owner, s) & (SEC_CODE | SEC_READONLY)) == 0)
+ return false;
+
+ if (hold_text.os == NULL)
+ hold_text.os = lang_output_section_find (MMO_TEXT_SECTION_NAME);
+
+ place = &hold_text;
+
+ /* If there's an output section by this name, we'll use it, regardless
+ of section flags, in contrast to what's done in elf32.em. */
+
+ /* Start building a list of statements for this section.
+ First save the current statement pointer. */
+ old = stat_ptr;
+
+ /* Add the output section statements for this orphan to our own private
+ list, inserting them later into the global statement list. */
+ stat_ptr = &add;
+ lang_list_init (stat_ptr);
+
+ os = lang_enter_output_section_statement (bfd_get_section_name (s->owner,
+ s),
+ NULL, 0,
+ (bfd_vma) 0,
+ (etree_type *) NULL,
+ (etree_type *) NULL,
+ (etree_type *) NULL);
+
+ lang_add_section (&os->children, s, os, file);
+
+ lang_leave_output_section_statement
+ ((bfd_vma) 0, "*default*",
+ (struct lang_output_section_phdr_list *) NULL, "*default*");
+
+ /* Restore the global list pointer. */
+ stat_ptr = old;
+
+ snew = os->bfd_section;
+ bfd_section = place->os->bfd_section;
+ if (place->section == NULL && bfd_section == NULL)
+ bfd_section = output_prev_sec_find (place->os);
+
+ if (place->section != NULL
+ || (bfd_section != NULL
+ && bfd_section != snew))
+ {
+ /* Shuffle the section to make the output file look neater. This is
+ really only cosmetic. */
+ if (place->section == NULL)
+ /* Put orphans after the first section on the list. */
+ place->section = &bfd_section->next;
+
+ /* Unlink the section. */
+ for (pps = &output_bfd->sections; *pps != snew; pps = &(*pps)->next)
+ ;
+ *pps = snew->next;
+
+ /* Now tack it on to the "place->os" section list. */
+ snew->next = *place->section;
+ *place->section = snew;
+ }
+ place->section = &snew->next; /* Save the end of this list. */
+
+ if (add.head != NULL)
+ {
+ /* We try to put the output statements in some sort of reasonable
+ order here, because they determine the final load addresses of
+ the orphan sections. */
+ if (place->stmt == NULL)
+ {
+ /* Put the new statement list right at the head. */
+ *add.tail = place->os->header.next;
+ place->os->header.next = add.head;
+ }
+ else
+ {
+ /* Put it after the last orphan statement we added. */
+ *add.tail = *place->stmt;
+ *place->stmt = add.head;
+ }
+
+ /* Fix the global list pointer if we happened to tack our new list
+ at the tail. */
+ if (*old->tail == add.head)
+ old->tail = add.tail;
+
+ /* Save the end of this list. */
+ place->stmt = add.tail;
+ }
+
+ return true;
+}
+
+/* Remove the spurious settings of SEC_RELOC that make it to the output at
+ link time. We are as confused as elflink.h:elf_bfd_final_link, and
+ paper over the bug similarly. */
+
+static void
+mmo_wipe_sec_reloc_flag (abfd, sec, ptr)
+ bfd *abfd;
+ asection *sec;
+ PTR ptr ATTRIBUTE_UNUSED;
+{
+ bfd_set_section_flags (abfd, sec,
+ bfd_get_section_flags (abfd, sec) & ~SEC_RELOC);
+}
+
+/* Iterate with bfd_map_over_sections over mmo_wipe_sec_reloc_flag... */
+
+static void
+mmo_finish ()
+{
+ bfd_map_over_sections (output_bfd, mmo_wipe_sec_reloc_flag, NULL);
+}
+
+EOF
+
+LDEMUL_PLACE_ORPHAN=mmo_place_orphan
+LDEMUL_FINISH=mmo_finish
@c 2. Specific target machines
@set H8300
@set I960
+@set MMIX
@set TICOFF
@c 3. Properties of this configuration
@set M680X0
@set MCORE
@set MIPS
+@set MMIX
@set PDP11
@set PJ
@set SH
* i960:: @code{ld} and the Intel 960 family
* ARM:: @code{ld} and the ARM family
* HPPA ELF32:: @code{ld} and HPPA 32-bit ELF
+@ifset MMIX
+* MMIX:: @code{ld} and MMIX
+@end ifset
@ifset TICOFF
* TI COFF:: @code{ld} and TI COFF
@end ifset
create a larger group (of one section). If input sections are too
large, it may not be possible for a branch to reach its stub.
+@ifset MMIX
+@node MMIX
+@section @code{ld} and MMIX
+For MMIX, there is choice of generating @code{ELF} object files or
+@code{mmo} object files when linking. The simulator @code{mmix}
+understands the @code{mmo} format. The binutils @code{objcopy} utility
+can translate between the two formats.
+
+There is one special section, the @samp{.MMIX.reg_contents} section.
+Contents in this section is assumed to correspond to that of global
+registers, and symbols referring to it are translated to special symbols,
+equal to registers. In a final link, the start address of the
+@samp{.MMIX.reg_contents} section corresponds to the first allocated
+global register multiplied by 8. Register @code{$255} is not included in
+this section; it is always set to the program entry, which is at the
+symbol @code{Main} for @code{mmo} files.
+
+Symbols with the prefix @code{__.MMIX.start.}, for example
+@code{__.MMIX.start..text} and @code{__.MMIX.start..data} are special;
+there must be only one each, even if they are local. The default linker
+script uses these to set the default start address of a section.
+
+Initial and trailing multiples of zero-valued 32-bit words in a section,
+are left out from an mmo file.
+@end ifset
+
@ifset TICOFF
@node TI COFF
@section @code{ld}'s support for various TI COFF versions
--- /dev/null
+cat <<EOF
+OUTPUT_FORMAT("mmo")
+OUTPUT_ARCH(mmix)
+ENTRY(Main)
+SECTIONS
+{
+ .text ${RELOCATING+ ${TEXT_START_ADDR}}:
+ {
+ *(.text)
+ ${RELOCATING+*(.text.*)}
+ ${RELOCATING+*(.gnu.linkonce.t*)}
+ ${RELOCATING+*(.rodata)}
+ ${RELOCATING+*(.rodata.*)}
+ ${RELOCATING+*(.gnu.linkonce.r*)}
+
+ /* FIXME: Move .init, .fini, .ctors and .dtors to their own sections. */
+ ${RELOCATING+ PROVIDE (_init_start = .);}
+ ${RELOCATING+ PROVIDE (_init = .);}
+ ${RELOCATING+ *(.init)}
+ ${RELOCATING+ PROVIDE (_init_end = .);}
+
+ ${RELOCATING+ PROVIDE (_fini_start = .);}
+ ${RELOCATING+ PROVIDE (_fini = .);}
+ ${RELOCATING+ *(.fini)}
+ ${RELOCATING+ PROVIDE (_fini_end = .);}
+
+ /* FIXME: Align ctors, dtors, ehframe. */
+ ${RELOCATING+ PROVIDE (_ctors_start = .);}
+ ${RELOCATING+ PROVIDE (__ctors_start = .);}
+ ${RELOCATING+ PROVIDE (_ctors = .);}
+ ${RELOCATING+ PROVIDE (__ctors = .);}
+ ${RELOCATING+ KEEP (*crtbegin.o(.ctors))}
+ ${RELOCATING+ KEEP (*(EXCLUDE_FILE (*crtend.o) .ctors))}
+ ${RELOCATING+ KEEP (*(SORT(.ctors.*)))}
+ ${RELOCATING+ KEEP (*(.ctors))}
+ ${RELOCATING+ PROVIDE (_ctors_end = .);}
+ ${RELOCATING+ PROVIDE (__ctors_end = .);}
+
+ ${RELOCATING+ PROVIDE (_dtors_start = .);}
+ ${RELOCATING+ PROVIDE (__dtors_start = .);}
+ ${RELOCATING+ PROVIDE (_dtors = .);}
+ ${RELOCATING+ PROVIDE (__dtors = .);}
+ ${RELOCATING+ KEEP (*crtbegin.o(.dtors))}
+ ${RELOCATING+ KEEP (*(EXCLUDE_FILE (*crtend.o) .dtors))}
+ ${RELOCATING+ KEEP (*(SORT(.dtors.*)))}
+ ${RELOCATING+ KEEP (*(.dtors))}
+ ${RELOCATING+ PROVIDE (_dtors_end = .);}
+ ${RELOCATING+ PROVIDE (__dtors_end = .);}
+
+ ${RELOCATING+KEEP (*(.jcr))}
+ ${RELOCATING+KEEP (*(.eh_frame))}
+ ${RELOCATING+*(.gcc_except_table)}
+
+ ${RELOCATING+ PROVIDE(etext = .);}
+ ${RELOCATING+ PROVIDE(_etext = .);}
+ ${RELOCATING+ PROVIDE(__etext = .);}
+ }
+ ${RELOCATING+Main = DEFINED (Main) ? Main : (DEFINED (_start) ? _start : . - SIZEOF (.text));}
+
+ .stab 0 : { *(.stab) }
+ .stabstr 0 : { *(.stabstr) }
+ .stab.excl 0 : { *(.stab.excl) }
+ .stab.exclstr 0 : { *(.stab.exclstr) }
+ .stab.index 0 : { *(.stab.index) }
+ .stab.indexstr 0 : { *(.stab.indexstr) }
+ .debug_aranges 0 : { *(.debug_aranges) }
+ .debug_pubnames 0 : { *(.debug_pubnames) }
+ .debug_info 0 : { *(.debug_info) *(.gnu.linkonce.wi.*) }
+ .debug_abbrev 0 : { *(.debug_abbrev) }
+ .debug_line 0 : { *(.debug_line) }
+ .debug_frame 0 : { *(.debug_frame) }
+ .debug_str 0 : { *(.debug_str) }
+ .debug_loc 0 : { *(.debug_loc) }
+ .debug_macinfo 0 : { *(.debug_macinfo) }
+
+ .data ${RELOCATING+ ${DATA_ADDR}}:
+ {
+ ${RELOCATING+ PROVIDE(__Sdata = .);}
+
+ *(.data);
+ ${RELOCATING+*(.data.*)}
+ ${RELOCATING+*(.gnu.linkonce.d*)}
+
+ ${RELOCATING+ PROVIDE(__Edata = .);}
+
+ /* Deprecated, use __Edata. */
+ ${RELOCATING+ PROVIDE(edata = .);}
+ ${RELOCATING+ PROVIDE(_edata = .);}
+ ${RELOCATING+ PROVIDE(__edata = .);}
+ }
+
+ /* At the moment, although perhaps we should, we can't map sections
+ without contents to sections *with* contents due to FIXME: a BFD bug.
+ Anyway, the mmo back-end ignores sections without contents when
+ writing out sections, so this works fine. */
+ .bss :
+ {
+ ${RELOCATING+ PROVIDE(__Sbss = .);}
+ ${RELOCATING+ PROVIDE(__bss_start = .);}
+ ${RELOCATING+ *(.sbss);}
+ ${RELOCATING+ *(.bss);}
+ ${RELOCATING+*(.bss.*)}
+ ${RELOCATING+ *(COMMON);}
+ ${RELOCATING+ PROVIDE(__Ebss = .);}
+ }
+
+ /* Deprecated, use __Ebss or __Eall as appropriate. */
+ ${RELOCATING+ PROVIDE(end = .);}
+ ${RELOCATING+ PROVIDE(_end = .);}
+ ${RELOCATING+ PROVIDE(__end = .);}
+ ${RELOCATING+ PROVIDE(__Eall = .);}
+
+ .MMIX.reg_contents :
+ {
+ /* Note that this section always has a fixed VMA - that of its
+ first register * 8. */
+ *(.MMIX.reg_contents);
+ }
+
+ /* By default, put the high end of the stack where the register stack
+ begins. They grow in opposite directions. */
+ PROVIDE (__Stack_start = 0x6000000000000000);
+
+ /* Unfortunately, stabs are not mappable from ELF to MMO.
+ It can probably be fixed with some amount of work. */
+ /DISCARD/ :
+ { *(.gnu.warning.*); }
+}
+EOF
+2001-10-30 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * ld-mmix: New testsuite directory.
+
2001-10-14 Hans-Peter Nilsson <hp@bitrange.com>
* ld-sh/sub2l-1.d, ld-sh/shared-1.d, ld-sh/weak1.d: Only run on
--- /dev/null
+* The symbol "a" is found here.
+ .text
+ .global a
+a:
+ SET $253,4
--- /dev/null
+ .global areg
+areg IS $255+1
--- /dev/null
+ .text
+ .global areg
+areg SWYM 4,8,16
--- /dev/null
+ .global areg
+areg GREG Main+4
+ LDOU $3,areg,16
+ LDOU $3,$7,areg
+ LDOU $5,Main+8
--- /dev/null
+#source: b-twoinsn.s
+#source: b-badfil1.s
+#source: b-post1.s
+#source: b-goodmain.s
+#ld: --oformat binary
+#objcopy_linked_file:
+#error: invalid mmo file: file number 42 `bar.s', was already entered as `foo.s'
--- /dev/null
+% The .text contents is supposed to be linked --oformat binary with
+% b-twoinsn.s and b-goodmain.s, and will provide two LOP_FILEs, but
+% specifying the same file number.
+ .text
+ .byte 0x98,06,42,2
+ .ascii "foo.s"
+ .byte 0,0,0
+ .byte 0x98,06,42,2
+ .ascii "bar.s"
+ .byte 0,0,0
--- /dev/null
+#source: b-twoinsn.s
+#source: b-badfil2.s
+#source: b-post1.s
+#source: b-goodmain.s
+#ld: --oformat binary
+#objcopy_linked_file:
+#error: invalid mmo file: file name for number 42 was not specified before use
--- /dev/null
+% The .text contents is supposed to be linked --oformat binary with
+% b-twoinsn.s and b-goodmain.s, and will provide a LOP_FILE for file
+% number 42, without specifying the file name, which an earlier LOP_FILE
+% for the same file number was supposed to have filled in
+ .text
+ .byte 0x98,06,42,0
--- /dev/null
+#source: b-twoinsn.s
+#source: b-badfixo.s
+#source: b-post1.s
+#source: b-goodmain.s
+#ld: --oformat binary
+#objcopy_linked_file:
+#error: invalid mmo file: .* lop_fixo
--- /dev/null
+% The .text contents is supposed to be linked --oformat binary with
+% b-twoinsn.s and b-goodmain.s, and will provide a LOP_FIXO with invalid;
+% (!= 1, != 2), YZ field.
+ .text
+ .byte 0x98,3,0,3
--- /dev/null
+#source: b-twoinsn.s
+#source: b-badloc.s
+#source: b-post1.s
+#source: b-goodmain.s
+#ld: --oformat binary
+#objcopy_linked_file:
+#error: invalid mmo file: .* lop_loc
--- /dev/null
+% The .text contents is supposed to be linked --oformat binary with
+% b-twoinsn.s and b-goodmain.s, and will provide a LOP_LOC with invalid;
+% (!= 1, != 2), YZ field.
+ .text
+ .byte 0x98,1,0,0
--- /dev/null
+#source: b-twoinsn.s
+#source: b-badlop.s
+#source: b-post1.s
+#source: b-goodmain.s
+#ld: --oformat binary
+#objcopy_linked_file:
+#error: invalid mmo file: unsupported lopcode
--- /dev/null
+% The .text contents is supposed to be linked --oformat binary with
+% b-twoinsn.s and b-goodmain.s, and will provide an invalid lopcode.
+ .text
+ .byte 0x98,0xff,0,0
--- /dev/null
+#source: b-twoinsn.s
+#source: b-post1.s
+#source: b-badmain.s
+#ld: --oformat binary
+#objcopy_linked_file:
+#error: invalid mmo file: initialization value for .255 is not `Main'
--- /dev/null
+% The .text contents is supposed to be linked --oformat binary with
+% b-twoinsn.s. It will provide an incorrect LOP_END; its YZ field is not
+% the number of tetras to the preceding LOP_STAB.
+ .text
+ .byte 0x98,0x0b,0x00,0x00,0x20,0x3a,0x30,0x4d,0x20,0x61,0x20,0x69
+ .byte 0x01,0x6e,0x04,0x81,0x01,0x61,0x04,0x82,0x98,0x0c,0x00,0x03
--- /dev/null
+% The .text contents is supposed to be linked --oformat binary with
+% b-twoinsn.s, and will provide the end of a mmo file with a value of
+% :Main that does not correspond to the address in the initialization of
+% $255 - the start address.
+ .text
+ .byte 0x98,0x0b,0,0,0x20,0x3a,0x30,0x4d,0x20,0x61,0x20,0x69
+ .byte 1,0x6e,0,0x81,1,0x61,4,0x82,0x98,0x0c,0,4
--- /dev/null
+#source: b-twoinsn.s
+#source: b-badquot.s
+#source: b-post1.s
+#source: b-goodmain.s
+#ld: --oformat binary
+#objcopy_linked_file:
+#error: invalid mmo file: .* lop_quote
--- /dev/null
+% The .text contents is supposed to be linked --oformat binary with
+% b-twoinsn.s and b-goodmain.s, and will provide a LOP_QUOTE with invalid;
+% non-zero, YZ field.
+ .text
+ .byte 0x98,0,0xff,0
--- /dev/null
+#source: b-twoinsn.s
+#source: b-badrx1.s
+#source: b-post1.s
+#source: b-goodmain.s
+#ld: --oformat binary
+#objcopy_linked_file:
+#error: invalid mmo file: expected y = 0, .* lop_fixrx
--- /dev/null
+% The .text contents is supposed to be linked --oformat binary with
+% b-twoinsn.s and b-goodmain.s, and will provide a LOP_FIXRX with invalid
+% (non-zero), Y field.
+ .text
+ .byte 0x98,5,1,0
+ .4byte 0
--- /dev/null
+#source: b-twoinsn.s
+#source: b-badrx2.s
+#source: b-post1.s
+#source: b-goodmain.s
+#ld: --oformat binary
+#objcopy_linked_file:
+#error: invalid mmo file: expected z .* lop_fixrx
--- /dev/null
+% The .text contents is supposed to be linked --oformat binary with
+% b-twoinsn.s and b-goodmain.s, and will provide a LOP_FIXRX with invalid
+% (!= 16, != 24), Z field.
+ .text
+ .byte 0x98,5,0,8
+ .4byte 0
--- /dev/null
+#source: b-twoinsn.s
+#source: b-badrx3.s
+#source: b-post1.s
+#source: b-goodmain.s
+#ld: --oformat binary
+#objcopy_linked_file:
+#error: invalid mmo file: leading byte of operand word .* lop_fixrx
--- /dev/null
+% The .text contents is supposed to be linked --oformat binary with
+% b-twoinsn.s and b-goodmain.s, and will provide a LOP_FIXRX with invalid
+% (!= 0, != 1), first byte of the operand word.
+ .text
+ .byte 0x98,5,0,24
+ .byte 2,0,0,0
--- /dev/null
+% The .text contents is supposed to be linked --oformat binary with
+% b-twoinsn.s and b-goodmain.s, and will provide an invalid LOP_END; one
+% not at the end of a file. It also does not in YZ specify a correct
+% number of bytes between it and a preceding lop_stab.
+ .text
+ .byte 0x98,12,0,0
--- /dev/null
+#source: b-twoinsn.s
+#source: b-bend.s
+#source: b-post1.s
+#source: b-goodmain.s
+#ld: --oformat binary
+#objcopy_linked_file:
+#error: invalid mmo file: lop_end not last item in file
+
+# This test depend on that the non-at-end condition is tested before
+# not-correct-YZ-field and might need tweaking if the implementation
+# changes.
--- /dev/null
+#source: b-twoinsn.s
+#source: b-post1.s
+#source: b-goodmain.s
+#source: b-bend.s
+#ld: --oformat binary
+#objcopy_linked_file:
+#error: invalid mmo file: lop_end not last item in file
+
+# We use the b-bend.s file just to make the correct lop_end in
+# b-goodmain.s not the last one.
--- /dev/null
+#source: b-twoinsn.s
+#source: b-post1.s
+#source: b-badm2.s
+#ld: --oformat binary
+#objcopy_linked_file:
+#error: invalid mmo file: YZ of lop_end .* not equal to the number of tetras to the preceding lop_stab
--- /dev/null
+#source: b-twoinsn.s
+#source: b-bstab1.s
+#source: b-post1.s
+#source: b-goodmain.s
+#ld: --oformat binary
+#objcopy_linked_file:
+#error: invalid mmo file: fields y and z of lop_stab non-zero, y: 1, z: 2
--- /dev/null
+% The .text contents is supposed to be linked --oformat binary with
+% b-twoinsn.s and b-goodmain.s, and will provide an invalid LOP_STAB, one
+% with non-zero y and/or z.
+ .text
+ .byte 0x98,11,1,2
--- /dev/null
+#source: b-twoinsn.s
+#source: b-fixo2.s
+#source: b-post1.s
+#source: b-goodmain.s
+#ld: --oformat binary
+#objcopy_linked_file:
+#objdump: -sht
+
+# Note that we "optimize" out the high tetrabyte of 0 written to
+# 2068098510aa5560, hence only the low part is left.
+
+.*: file format mmo
+
+Sections:
+Idx Name Size VMA LMA File off Algn
+ 0 \.text 0+8 0+ 0+ 0+ 2\*\*2
+ CONTENTS, ALLOC, LOAD, CODE
+ 1 \.data 0+4 2068098510aa5564 2068098510aa5564 0+ 2\*\*2
+ CONTENTS, ALLOC, LOAD
+SYMBOL TABLE:
+0+4 g \.text Main
+0+4 g \.text a
+
+
+Contents of section \.text:
+ 0000 e3fd0001 e3fd0004 .*
+Contents of section \.data:
+ 10aa5564 00000008 .*
--- /dev/null
+% The .text contents is supposed to be linked --oformat binary with
+% b-twoinsn.s and b-goodmain.s, and will provide a LOP_FIXO storing the
+% current address at address 0x2068098510aa5560.
+ .text
+ .byte 0x98,3,0x20,2
+ .8byte 0x68098510aa5560
--- /dev/null
+% The .text contents is supposed to be linked --oformat binary with
+% b-twoinsn.s, and will provide a valid end of a mmo file.
+ .text
+ .byte 0x98,0x0b,0x00,0x00,0x20,0x3a,0x30,0x4d,0x20,0x61,0x20,0x69
+ .byte 0x01,0x6e,0x04,0x81,0x01,0x61,0x04,0x82,0x98,0x0c,0x00,0x04
--- /dev/null
+#source: b-loc64k.s
+#source: b-goodmain.s
+#ld: --oformat binary
+#objcopy_linked_file:
+#objdump: -dht
+
+.*: file format mmo
+
+Sections:
+Idx Name Size VMA LMA File off Algn
+ 0 \.text 0+10004 0+ 0+ 0+ 2\*\*2
+ CONTENTS, ALLOC, LOAD, CODE
+SYMBOL TABLE:
+0+4 g \.text Main
+0+4 g \.text a
+
+
+Disassembly of section \.text:
+
+0+ <Main-0x4>:
+ 0: e3fd0001 setl \$253,0x1
+
+0+4 <Main>:
+ \.\.\.
+ 10000: e3fd0004 setl \$253,0x4
--- /dev/null
+% The .text contents is supposed to be linked --oformat binary, and will
+% correspond to the start of a mmo file with two instructions, 64k apart.
+% This file ends before the LOP_STAB.
+ .text
+ .byte 0x98,9,1,1,0x3b,0x7f,0x9c,0xe3,0x98,1,0,2,0,0,0,0
+ .byte 0,0,0,0,0xe3,0xfd,0,1,0x98,1,0,2,0,0,0,0
+ .byte 0,1,0,0,0xe3,0xfd,0,4,0x98,0x0a,0,0xff,0,0,0,0
+ .byte 0,0,0,4
--- /dev/null
+#source: b-twoinsn.s
+#source: b-post1.s
+#source: b-nosym.s
+#ld: --oformat binary
+#objcopy_linked_file:
+#objdump: -st
+
+.*: file format mmo
+
+SYMBOL TABLE:
+0+4 g \.text Main
+
+
+Contents of section \.text:
+ 0000 e3fd0001 e3fd0004 .*
--- /dev/null
+% The .text contents is supposed to be linked --oformat binary with
+% b-twoinsn.s, and will provide a valid end of a mmo file but with no
+% symbols (if that is actually valid).
+ .text
+ .byte 0x98,0x0b,0x00,0x00,0x98,0x0c,0x00,0x00
+
--- /dev/null
+% The .text contents is supposed to be linked --oformat binary, and will
+% correspond to a LOP_POST for an initialization of $255 with 4. A
+% LOP_STAB, such as in b-goodmain.s should follow.
+ .text
+ .byte 0x98,0x0a,0,0xff,0,0,0,0,0,0,0,4
--- /dev/null
+% The .text contents is supposed to be linked --oformat binary, and will
+% correspond to the start of a mmo file with two instructions. This file
+% ends before the LOP_STAB.
+ .text
+ .byte 0x98,9,1,1,0x3b,0x7f,0x9c,0xe3,0x98,1,0,2,0,0,0,0
+ .byte 0,0,0,0,0xe3,0xfd,0,1,0x98,1,0,2,0,0,0,0
+ .byte 0,0,0,4,0xe3,0xfd,0,4
--- /dev/null
+% The .text contents is supposed to be linked --oformat binary with
+% b-twoinsn.s, and will provide a valid end of a mmo file, but with the
+% "n" in :Main in wide character format; the widening is with a nil, so it
+% is treated like a normal "n".
+ .text
+ .byte 0x98,0x0b,0x00,0x00,0x20,0x3a,0x30,0x4d,0x20,0x61,0x20,0x69
+ .byte 0x81,0,0x6e,0x04,0x81,0x01,0x61,0x04,0x82,0,0,0,0x98,0x0c,0x00,0x05
--- /dev/null
+#source: b-twoinsn.s
+#source: b-post1.s
+#source: b-widec.s
+#ld: --oformat binary
+#objcopy_linked_file:
+#objdump: -t
+
+.*: file format mmo
+
+SYMBOL TABLE:
+0+4 g \.text Main
+0+4 g \.text a
--- /dev/null
+#source: b-twoinsn.s
+#source: b-post1.s
+#source: b-widec2.s
+#ld: --oformat binary
+#objcopy_linked_file:
+#error: unsupported wide character sequence 0xFF 0x6E
--- /dev/null
+% The .text contents is supposed to be linked --oformat binary with
+% b-twoinsn.s, and will provide a valid end of a mmo file, but with the
+% "n" in :Main in wide character format; the widening is with a 0xff, so it
+% isn't supported, and the file is rejected.
+ .text
+ .byte 0x98,0x0b,0x00,0x00,0x20,0x3a,0x30,0x4d,0x20,0x61,0x20,0x69
+ .byte 0x81,0xff,0x6e,0x04,0x81,0x01,0x61,0x04,0x82,0,0,0,0x98,0x0c,0x00,0x05
--- /dev/null
+#source: b-twoinsn.s
+#source: b-post1.s
+#source: b-widec3.s
+#ld: --oformat binary
+#objcopy_linked_file:
+#error: invalid symbol table: duplicate symbol `Main'
--- /dev/null
+% The .text contents is supposed to be linked --oformat binary with
+% b-twoinsn.s, and will provide a valid end of a mmo file, but with the
+% "n" in :Main in wide character format; the widening is with a nil, so it
+% is treated like a normal "n". Also, it provides a normal "n", so the
+% two symbols collide.
+ .text
+ .byte 0x98,0x0b,0x00,0x00,0x20,0x3a,0x30,0x4d,0x20,0x61,0x20,0x69
+ .byte 0x91,0,0x6e,0x04,0x81,0x01,0x6e,0x04,0x83,1,0x01,0x61,0x04,0x82,0,0,0x98,0x0c,0,0x06
+
--- /dev/null
+#source: bspec1.s
+#source: start.s
+#ld: -m elf64mmix
+#readelf: -Ssr -x1 -x5
+
+There are 9 section headers, starting at offset 0x100:
+
+Section Headers:
+ \[Nr\] Name Type Address Offset
+ Size EntSize Flags Link Info Align
+ \[ 0\] NULL 0+ 0+
+ 0+ 0+ 0 0 0
+ \[ 1\] \.text PROGBITS 0+ 0+b0
+ 0+4 0+ AX 0 0 4
+ \[ 2\] \.data PROGBITS 2000000000000000 0+b4
+ 0+ 0+ WA 0 0 1
+ \[ 3\] \.sbss PROGBITS 2000000000000000 0+b4
+ 0+ 0+ W 0 0 1
+ \[ 4\] \.bss NOBITS 2000000000000000 0+b4
+ 0+ 0+ WA 0 0 1
+ \[ 5\] \.MMIX\.spec_data\.2 PROGBITS 0+ 0+b4
+ 0+4 0+ 0 0 4
+ \[ 6\] \.shstrtab STRTAB 0+ 0+b8
+ 0+44 0+ 0 0 1
+ \[ 7\] \.symtab SYMTAB 0+ 0+340
+ 0+168 0+18 8 9 8
+ \[ 8\] \.strtab STRTAB 0+ 0+4a8
+ 0+2d 0+ 0 0 1
+Key to Flags:
+ W \(write\), A \(alloc\), X \(execute\), M \(merge\), S \(strings\)
+ I \(info\), L \(link order\), G \(group\), x \(unknown\)
+ O \(extra OS processing required\) o \(OS specific\), p \(processor specific\)
+
+There are no relocations in this file\.
+
+Symbol table '\.symtab' contains 15 entries:
+ Num: Value Size Type Bind Vis Ndx Name
+ 0: 0+ 0 NOTYPE LOCAL DEFAULT UND
+ 1: 0+ 0 SECTION LOCAL DEFAULT 1
+ 2: 2000000000000000 0 SECTION LOCAL DEFAULT 2
+ 3: 2000000000000000 0 SECTION LOCAL DEFAULT 3
+ 4: 2000000000000000 0 SECTION LOCAL DEFAULT 4
+ 5: 0+ 0 SECTION LOCAL DEFAULT 5
+ 6: 0+ 0 SECTION LOCAL DEFAULT 6
+ 7: 0+ 0 SECTION LOCAL DEFAULT 7
+ 8: 0+ 0 SECTION LOCAL DEFAULT 8
+ 9: 0+ 0 FUNC GLOBAL DEFAULT 1 Main
+ 10: 0+ 0 NOTYPE GLOBAL DEFAULT 1 _start
+ 11: 2000000000000000 0 OBJECT GLOBAL DEFAULT ABS __bss_start
+ 12: 2000000000000000 0 OBJECT GLOBAL DEFAULT ABS _edata
+ 13: 2000000000000000 0 OBJECT GLOBAL DEFAULT ABS _end
+ 14: 0+ 0 OBJECT GLOBAL DEFAULT 1 _start\.
+
+Hex dump of section '\.text':
+ 0x0+ e3fd0001 .*
+
+Hex dump of section '\.MMIX\.spec_data\.2':
+ 0x0+ 0000002a .*
--- /dev/null
+ BSPEC 2
+ TETRA :Main+42
+ ESPEC
--- /dev/null
+#source: bspec1.s
+#source: start.s
+#ld: -m mmo
+#objdump: -str
+
+.*: file format mmo
+
+SYMBOL TABLE:
+0+ g \.text Main
+0+ g \.text _start
+
+
+Contents of section \.text:
+ 0+ e3fd0001 .*
+Contents of section \.MMIX\.spec_data\.2:
+ 0000 0000002a .*
--- /dev/null
+#source: bspec1.s
+#source: bspec2.s
+#source: bspec1.s
+#source: start.s
+#source: ext1.s
+#ld: -m elf64mmix
+#readelf: -Ssr -x1 -x5 -x6
+
+There are 10 section headers, starting at offset 0x118:
+
+Section Headers:
+ \[Nr\] Name Type Address Offset
+ Size EntSize Flags Link Info Align
+ \[ 0\] NULL 0+ 0+
+ 0+ 0+ 0 0 0
+ \[ 1\] \.text PROGBITS 0+ 0+b0
+ 0+4 0+ AX 0 0 4
+ \[ 2\] \.data PROGBITS 2000000000000000 0+b4
+ 0+ 0+ WA 0 0 1
+ \[ 3\] \.sbss PROGBITS 2000000000000000 0+b4
+ 0+ 0+ W 0 0 1
+ \[ 4\] \.bss NOBITS 2000000000000000 0+b4
+ 0+ 0+ WA 0 0 1
+ \[ 5\] \.MMIX\.spec_data\.2 PROGBITS 0+ 0+b4
+ 0+8 0+ 0 0 4
+ \[ 6\] \.MMIX\.spec_data\.3 PROGBITS 0+ 0+bc
+ 0+4 0+ 0 0 4
+ \[ 7\] \.shstrtab STRTAB 0+ 0+c0
+ 0+56 0+ 0 0 1
+ \[ 8\] \.symtab SYMTAB 0+ 0+398
+ 0+198 0+18 9 a 8
+ \[ 9\] \.strtab STRTAB 0+ 0+530
+ 0+32 0+ 0 0 1
+Key to Flags:
+ W \(write\), A \(alloc\), X \(execute\), M \(merge\), S \(strings\)
+ I \(info\), L \(link order\), G \(group\), x \(unknown\)
+ O \(extra OS processing required\) o \(OS specific\), p \(processor specific\)
+
+There are no relocations in this file\.
+
+Symbol table '\.symtab' contains 17 entries:
+ Num: Value Size Type Bind Vis Ndx Name
+ 0: 0+ 0 NOTYPE LOCAL DEFAULT UND
+ 1: 0+ 0 SECTION LOCAL DEFAULT 1
+ 2: 2000000000000000 0 SECTION LOCAL DEFAULT 2
+ 3: 2000000000000000 0 SECTION LOCAL DEFAULT 3
+ 4: 2000000000000000 0 SECTION LOCAL DEFAULT 4
+ 5: 0+ 0 SECTION LOCAL DEFAULT 5
+ 6: 0+ 0 SECTION LOCAL DEFAULT 6
+ 7: 0+ 0 SECTION LOCAL DEFAULT 7
+ 8: 0+ 0 SECTION LOCAL DEFAULT 8
+ 9: 0+ 0 SECTION LOCAL DEFAULT 9
+ 10: 0+ 0 FUNC GLOBAL DEFAULT 1 Main
+ 11: 0+fc 0 NOTYPE GLOBAL DEFAULT ABS ext1
+ 12: 0+ 0 NOTYPE GLOBAL DEFAULT 1 _start
+ 13: 2000000000000000 0 OBJECT GLOBAL DEFAULT ABS __bss_start
+ 14: 2000000000000000 0 OBJECT GLOBAL DEFAULT ABS _edata
+ 15: 2000000000000000 0 OBJECT GLOBAL DEFAULT ABS _end
+ 16: 0+ 0 OBJECT GLOBAL DEFAULT 1 _start\.
+
+Hex dump of section '\.text':
+ 0x0+ e3fd0001 .*
+
+Hex dump of section '\.MMIX\.spec_data\.2':
+ 0x0+ 0000002a 0000002a .*
+
+Hex dump of section '\.MMIX\.spec_data\.3':
+ 0x0+ 000000fc .*
--- /dev/null
+ BSPEC 3
+ TETRA ext1
+ ESPEC
--- /dev/null
+#source: bspec1.s
+#source: bspec2.s
+#source: bspec1.s
+#source: start.s
+#source: ext1.s
+#ld: -m mmo
+#objdump: -str
+
+.*: file format mmo
+
+SYMBOL TABLE:
+0+ g \.text Main
+0+fc g \*ABS\* ext1
+0+ g \.text _start
+
+
+Contents of section \.text:
+ 0+ e3fd0001 .*
+Contents of section \.MMIX\.spec_data\.2:
+ 0000 0000002a 0000002a .*
+Contents of section \.MMIX\.spec_data\.3:
+ 0000 000000fc .*
--- /dev/null
+ BSPEC 80
+ TETRA 0x98000001
+ ESPEC
--- /dev/null
+ BSPEC 80
+ TETRA 4 % Decent section length name (in 32-bit words). However...
+ ESPEC % Everything ends here. The next thing is a LOP_LOC for .data, or
+ % an ending LOP-something, hence a non-LOP_QUOTE in the name.
+
+ .data
+ TETRA 0x112233
--- /dev/null
+ BSPEC 80
+ TETRA 2 % Decent section length name (in 32-bit words). However...
+ BYTE "aaaa"
+ BYTE 0x98,"aaa" # A LOP_QUOTEd part here. And also...
+ ESPEC % Everything ends here. The next thing is a LOP_LOC for .data, or
+ % an ending LOP-something, hence a non-LOP_QUOTE in the section flags.
+
+ .data
+ TETRA 0x112233
--- /dev/null
+ BSPEC 80
+ TETRA 2 % Decent section length name (in 32-bit words).
+ BYTE "aaaaaaaa"
+ TETRA 0x11 % Flags. However...
+ ESPEC % Everything ends here. The next thing is a LOP_LOC for .data, or
+ % an ending LOP-something, hence a non-LOP_QUOTE in the section
+ % length, high part.
+ .data
+ TETRA 0x112233
--- /dev/null
+ BSPEC 80
+ TETRA 2 % Decent section length name (in 32-bit words).
+ BYTE "aaaaaaaa"
+ TETRA 0x11 % Flags.
+ TETRA 0 % Decent high-part of section length. However...
+ ESPEC % Everything ends here. The next thing is a LOP_LOC for .data, or
+ % an ending LOP-something, hence a non-LOP_QUOTE in the section
+ % length, high part.
+ .data
+ TETRA 0x112233
--- /dev/null
+ BSPEC 80
+ TETRA 2 % Decent section length name (in 32-bit words).
+ BYTE "aaaaaaaa"
+ TETRA 0x11 % Flags.
+ OCTA 12 % Decent section length. However...
+ ESPEC % Everything ends here. The next thing is a LOP_LOC for .data, or
+ % an ending LOP-something, hence a non-LOP_QUOTE in the section
+ % length, high part.
+ .data
+ TETRA 0x112233
--- /dev/null
+ BSPEC 80
+ TETRA 2 % Decent section length name (in 32-bit words).
+ BYTE "aaaaaaaa"
+ TETRA 0x11 % Flags.
+ TETRA 0,12 % Decent section length. However...
+ TETRA 0 % Things end stops after the high part of the VMA.
+ ESPEC
+ .data
+ TETRA 0x112233
--- /dev/null
+ BSPEC 80
+ TETRA 2 % Decent section length name (in 32-bit words).
+ BYTE "aaaaaaaa"
+ TETRA 0x11 % Flags.
+ TETRA 0xff00,0 % Indecent section length
+ TETRA 0xff,0 % Decent vma.
+ ESPEC
+ .data
+ TETRA 0x112233
--- /dev/null
+#source: start.s
+#source: a.s
+#source: bza.s
+#as: -x
+#ld: -m elf64mmix
+#objdump: -dr
+
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0+ <_start>:
+ 0+: e3fd0001 setl \$253,0x1
+
+0+4 <a>:
+ 4: e3fd0004 setl \$253,0x4
+
+0+8 <bza>:
+ 8: e3fd0002 setl \$253,0x2
+ c: 5aea0006 pbnz \$234,24 <bza\+0x1c>
+ 10: e3ff0004 setl \$255,0x4
+ 14: e6ff0000 incml \$255,0x0
+ 18: e5ff0000 incmh \$255,0x0
+ 1c: e4ff0000 inch \$255,0x0
+ 20: 9fffff00 go \$255,\$255,0
+ 24: e3fd0003 setl \$253,0x3
--- /dev/null
+#source: start.s
+#source: bza.s
+#source: a.s
+#as: -x
+#ld: -m elf64mmix
+#objdump: -dr
+
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0+ <_start>:
+ 0+: e3fd0001 setl \$253,0x1
+
+0+4 <bza>:
+ 4: e3fd0002 setl \$253,0x2
+ 8: 5aea0006 pbnz \$234,20 <bza\+0x1c>
+ c: e3ff0024 setl \$255,0x24
+ 10: e6ff0000 incml \$255,0x0
+ 14: e5ff0000 incmh \$255,0x0
+ 18: e4ff0000 inch \$255,0x0
+ 1c: 9fffff00 go \$255,\$255,0
+ 20: e3fd0003 setl \$253,0x3
+
+0+24 <a>:
+ 24: e3fd0004 setl \$253,0x4
--- /dev/null
+#source: start.s
+#source: a.s
+#source: bza.s
+#as: -no-expand
+#ld: -m elf64mmix
+#objdump: -dr
+
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0+ <_start>:
+ 0+: e3fd0001 setl \$253,0x1
+
+0+4 <a>:
+ 4: e3fd0004 setl \$253,0x4
+
+0+8 <bza>:
+ 8: e3fd0002 setl \$253,0x2
+ c: 43eafffe bz \$234,4 <a>
+ 10: e3fd0003 setl \$253,0x3
--- /dev/null
+#source: start.s
+#source: bza.s
+#source: a.s
+#as: -no-expand
+#ld: -m elf64mmix
+#objdump: -dr
+
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0+ <_start>:
+ 0: e3fd0001 setl \$253,0x1
+
+0+4 <bza>:
+ 4: e3fd0002 setl \$253,0x2
+ 8: 42ea0002 bz \$234,10 <a>
+ c: e3fd0003 setl \$253,0x3
+
+0+10 <a>:
+ 10: e3fd0004 setl \$253,0x4
--- /dev/null
+#source: start.s
+#source: a.s
+#source: bza.s
+#as: -x
+#ld: -m mmo
+#objdump: -dr
+
+.*: file format mmo
+
+Disassembly of section \.text:
+
+0+ <(Main|_start)>:
+ 0+: e3fd0001 setl \$253,0x1
+
+0+4 <a>:
+ 4: e3fd0004 setl \$253,0x4
+
+0+8 <bza>:
+ 8: e3fd0002 setl \$253,0x2
+ c: 5aea0006 pbnz \$234,24 <bza\+0x1c>
+ 10: e3ff0004 setl \$255,0x4
+ 14: e6ff0000 incml \$255,0x0
+ 18: e5ff0000 incmh \$255,0x0
+ 1c: e4ff0000 inch \$255,0x0
+ 20: 9fffff00 go \$255,\$255,0
+ 24: e3fd0003 setl \$253,0x3
--- /dev/null
+#source: start.s
+#source: bza.s
+#source: a.s
+#as: -x
+#ld: -m mmo
+#objdump: -dr
+
+.*: file format mmo
+
+Disassembly of section \.text:
+
+0+ <(Main|_start)>:
+ 0+: e3fd0001 setl \$253,0x1
+
+0+4 <bza>:
+ 4: e3fd0002 setl \$253,0x2
+ 8: 5aea0006 pbnz \$234,20 <bza\+0x1c>
+ c: e3ff0024 setl \$255,0x24
+ 10: e6ff0000 incml \$255,0x0
+ 14: e5ff0000 incmh \$255,0x0
+ 18: e4ff0000 inch \$255,0x0
+ 1c: 9fffff00 go \$255,\$255,0
+ 20: e3fd0003 setl \$253,0x3
+
+0+24 <a>:
+ 24: e3fd0004 setl \$253,0x4
--- /dev/null
+#source: start.s
+#source: a.s
+#source: bza.s
+#as: -no-expand
+#ld: -m mmo
+#objdump: -dr
+
+.*: file format mmo
+
+Disassembly of section \.text:
+
+0+ <(Main|_start)>:
+ 0+: e3fd0001 setl \$253,0x1
+
+0+4 <a>:
+ 4: e3fd0004 setl \$253,0x4
+
+0+8 <bza>:
+ 8: e3fd0002 setl \$253,0x2
+ c: 43eafffe bz \$234,4 <a>
+ 10: e3fd0003 setl \$253,0x3
--- /dev/null
+#source: start.s
+#source: bza.s
+#source: a.s
+#as: -no-expand
+#ld: -m mmo
+#objdump: -dr
+
+.*: file format mmo
+
+Disassembly of section \.text:
+
+0+ <(Main|_start)>:
+ 0+: e3fd0001 setl \$253,0x1
+
+0+4 <bza>:
+ 4: e3fd0002 setl \$253,0x2
+ 8: 42ea0002 bz \$234,10 <a>
+ c: e3fd0003 setl \$253,0x3
+
+0+10 <a>:
+ 10: e3fd0004 setl \$253,0x4
--- /dev/null
+* Just BEQs to an external symbol, with some padding.
+ .text
+ .global bza
+bza:
+ SET $253,2
+ BZ $234,a
+ SET $253,3
--- /dev/null
+ LOC #20 << 56
+xx OCTA Main+44
--- /dev/null
+ LOC #20 << 56 + #200
+dloc1 TETRA 4,5,6
+ .global dloc1
+
--- /dev/null
+ LOC #20 << 56 + #200
+dloc2 TETRA 7,8,9
+ .global dloc2
--- /dev/null
+ .global ext1
+ext1 IS 254
--- /dev/null
+ .global ext1
+ext1 IS 252
--- /dev/null
+ .global ext1
+ext1 GREG
--- /dev/null
+ .global ext1
+ext1 SWYM 4,8,16
--- /dev/null
+#source: start.s
+#source: a.s
+#source: getaa.s
+#as: -x
+#ld: -m elf64mmix
+#objdump: -dr
+
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0+ <_start>:
+ 0+: e3fd0001 setl \$253,0x1
+
+0+4 <a>:
+ 4: e3fd0004 setl \$253,0x4
+
+0+8 <getaa>:
+ 8: e3fd0002 setl \$253,0x2
+ c: e37b0004 setl \$123,0x4
+ 10: e67b0000 incml \$123,0x0
+ 14: e57b0000 incmh \$123,0x0
+ 18: e47b0000 inch \$123,0x0
+ 1c: e3fd0003 setl \$253,0x3
--- /dev/null
+#source: start.s
+#source: getaa.s
+#source: a.s
+#as: -x
+#ld: -m elf64mmix
+#objdump: -dr
+
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0+ <_start>:
+ 0+: e3fd0001 setl \$253,0x1
+
+0+4 <getaa>:
+ 4: e3fd0002 setl \$253,0x2
+ 8: e37b001c setl \$123,0x1c
+ c: e67b0000 incml \$123,0x0
+ 10: e57b0000 incmh \$123,0x0
+ 14: e47b0000 inch \$123,0x0
+ 18: e3fd0003 setl \$253,0x3
+
+0+1c <a>:
+ 1c: e3fd0004 setl \$253,0x4
--- /dev/null
+#source: start.s
+#source: a.s
+#source: getaa.s
+#as: -no-expand
+#ld: -m elf64mmix
+#objdump: -dr
+
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0+ <_start>:
+ 0+: e3fd0001 setl \$253,0x1
+
+0+4 <a>:
+ 4: e3fd0004 setl \$253,0x4
+
+0+8 <getaa>:
+ 8: e3fd0002 setl \$253,0x2
+ c: f57bfffe geta \$123,4 <a>
+ 10: e3fd0003 setl \$253,0x3
--- /dev/null
+#source: start.s
+#source: getaa.s
+#source: a.s
+#as: -no-expand
+#ld: -m elf64mmix
+#objdump: -dr
+
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0+ <_start>:
+ 0+: e3fd0001 setl \$253,0x1
+
+0+4 <getaa>:
+ 4: e3fd0002 setl \$253,0x2
+ 8: f47b0002 geta \$123,10 <a>
+ c: e3fd0003 setl \$253,0x3
+
+0+10 <a>:
+ 10: e3fd0004 setl \$253,0x4
--- /dev/null
+#source: start.s
+#source: a.s
+#source: pad2p18m32.s
+#source: pad16.s
+#source: pad4.s
+#source: pad4.s
+#source: getaa.s
+#as: -no-expand
+#ld: -m elf64mmix
+#objdump: -dr
+
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0+ <_start>:
+ 0: e3fd0001 setl \$253,0x1
+
+0+4 <a>:
+ 4: e3fd0004 setl \$253,0x4
+ \.\.\.
+
+0+40000 <getaa>:
+ 40000: e3fd0002 setl \$253,0x2
+ 40004: f57b0000 geta \$123,4 <a>
+ 40008: e3fd0003 setl \$253,0x3
--- /dev/null
+#source: start.s
+#source: getaa.s
+#source: pad2p18m32.s
+#source: pad16.s
+#source: pad4.s
+#source: a.s
+#as: -no-expand
+#ld: -m elf64mmix
+#objdump: -dr
+
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0+ <_start>:
+ 0: e3fd0001 setl \$253,0x1
+
+0+4 <getaa>:
+ 4: e3fd0002 setl \$253,0x2
+ 8: f47bffff geta \$123,40004 <a>
+ c: e3fd0003 setl \$253,0x3
+ \.\.\.
+
+0+40004 <a>:
+ 40004: e3fd0004 setl \$253,0x4
--- /dev/null
+#source: start.s
+#source: a.s
+#source: pad2p18m32.s
+#source: pad16.s
+#source: pad4.s
+#source: pad4.s
+#source: pad4.s
+#source: getaa.s
+#as: -no-expand
+#ld: -m elf64mmix
+#error: relocation truncated to fit: R_MMIX_ADDR19 a$
--- /dev/null
+#source: start.s
+#source: getaa.s
+#source: pad2p18m32.s
+#source: pad16.s
+#source: pad4.s
+#source: pad4.s
+#source: a.s
+#as: -no-expand
+#ld: -m elf64mmix
+#error: relocation truncated to fit: R_MMIX_ADDR19 a$
--- /dev/null
+#source: start.s
+#source: a.s
+#source: getaa.s
+#as: -x
+#ld: -m mmo
+#objdump: -dr
+
+.*: file format mmo
+
+Disassembly of section .text:
+
+0+ <(Main|_start)>:
+ 0+: e3fd0001 setl \$253,0x1
+
+0+4 <a>:
+ 4: e3fd0004 setl \$253,0x4
+
+0+8 <getaa>:
+ 8: e3fd0002 setl \$253,0x2
+ c: e37b0004 setl \$123,0x4
+ 10: e67b0000 incml \$123,0x0
+ 14: e57b0000 incmh \$123,0x0
+ 18: e47b0000 inch \$123,0x0
+ 1c: e3fd0003 setl \$253,0x3
--- /dev/null
+#source: start.s
+#source: getaa.s
+#source: a.s
+#as: -x
+#ld: -m mmo
+#objdump: -dr
+
+.*: file format mmo
+
+Disassembly of section \.text:
+
+0+ <(Main|_start)>:
+ 0+: e3fd0001 setl \$253,0x1
+
+0+4 <getaa>:
+ 4: e3fd0002 setl \$253,0x2
+ 8: e37b001c setl \$123,0x1c
+ c: e67b0000 incml \$123,0x0
+ 10: e57b0000 incmh \$123,0x0
+ 14: e47b0000 inch \$123,0x0
+ 18: e3fd0003 setl \$253,0x3
+
+0+1c <a>:
+ 1c: e3fd0004 setl \$253,0x4
--- /dev/null
+#source: start.s
+#source: a.s
+#source: getaa.s
+#as: -no-expand
+#ld: -m mmo
+#objdump: -dr
+
+.*: file format mmo
+
+Disassembly of section \.text:
+
+0+ <(Main|_start)>:
+ 0+: e3fd0001 setl \$253,0x1
+
+0+4 <a>:
+ 4: e3fd0004 setl \$253,0x4
+
+0+8 <getaa>:
+ 8: e3fd0002 setl \$253,0x2
+ c: f57bfffe geta \$123,4 <a>
+ 10: e3fd0003 setl \$253,0x3
--- /dev/null
+#source: start.s
+#source: getaa.s
+#source: a.s
+#as: -no-expand
+#ld: -m mmo
+#objdump: -dr
+
+.*: file format mmo
+
+Disassembly of section \.text:
+
+0+ <(Main|_start)>:
+ 0+: e3fd0001 setl \$253,0x1
+
+0+4 <getaa>:
+ 4: e3fd0002 setl \$253,0x2
+ 8: f47b0002 geta \$123,10 <a>
+ c: e3fd0003 setl \$253,0x3
+
+0+10 <a>:
+ 10: e3fd0004 setl \$253,0x4
--- /dev/null
+* Just geta an external symbol, with some padding.
+ .text
+ .global getaa
+getaa:
+ SET $253,2
+ GETA $123,a
+ SET $253,3
--- /dev/null
+#source: start.s
+#source: a.s
+#source: pad2p18m32.s
+#source: pad16.s
+#source: pad4.s
+#source: pad4.s
+#source: getaa.s
+#as: -no-expand
+#ld: -m mmo
+#objdump: -dr
+
+.*: file format mmo
+
+Disassembly of section \.text:
+
+0+ <(Main|_start)>:
+ 0: e3fd0001 setl \$253,0x1
+
+0+4 <a>:
+ 4: e3fd0004 setl \$253,0x4
+ \.\.\.
+
+0+40000 <getaa>:
+ 40000: e3fd0002 setl \$253,0x2
+ 40004: f57b0000 geta \$123,4 <a>
+ 40008: e3fd0003 setl \$253,0x3
--- /dev/null
+#source: start.s
+#source: getaa.s
+#source: pad2p18m32.s
+#source: pad16.s
+#source: pad4.s
+#source: a.s
+#as: -no-expand
+#ld: -m mmo
+#objdump: -dr
+
+.*: file format mmo
+
+Disassembly of section \.text:
+
+0+ <(Main|_start)>:
+ 0: e3fd0001 setl \$253,0x1
+
+0+4 <getaa>:
+ 4: e3fd0002 setl \$253,0x2
+ 8: f47bffff geta \$123,40004 <a>
+ c: e3fd0003 setl \$253,0x3
+ \.\.\.
+
+0+40004 <a>:
+ 40004: e3fd0004 setl \$253,0x4
--- /dev/null
+#source: start.s
+#source: a.s
+#source: pad2p18m32.s
+#source: pad16.s
+#source: pad4.s
+#source: pad4.s
+#source: pad4.s
+#source: getaa.s
+#as: -no-expand
+#ld: -m mmo
+#error: relocation truncated to fit: R_MMIX_ADDR19 a$
--- /dev/null
+#source: start.s
+#source: getaa.s
+#source: pad2p18m32.s
+#source: pad16.s
+#source: pad4.s
+#source: pad4.s
+#source: a.s
+#as: -no-expand
+#ld: -m mmo
+#error: relocation truncated to fit: R_MMIX_ADDR19 a$
--- /dev/null
+#source: greg-1.s
+#source: gregldo1.s
+#source: start.s
+#ld: -m elf64mmix
+#objdump: -dt
+
+# Most simple greg usage: relocate to each possible location within an
+# insn.
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+ l d .text 0+
+2000000000000000 l d .data 0+
+2000000000000000 l d .sbss 0+
+2000000000000000 l d .bss 0+
+0+7f0 l d \.MMIX\.reg_contents 0+
+0+ l d \*ABS\* 0+
+0+ l d \*ABS\* 0+
+0+ l d \*ABS\* 0+
+0+c g \.text 0+ _start
+0+fe g \*REG\* 0+ areg
+2000000000000000 g O \*ABS\* 0+ __bss_start
+2000000000000000 g O \*ABS\* 0+ _edata
+2000000000000000 g O \*ABS\* 0+ _end
+0+c g O \.text 0+ _start\.
+
+Disassembly of section \.text:
+
+0+ <_start-0xc>:
+ 0: 8c0c20fe ldo \$12,\$32,\$254
+ 4: 8d7bfe22 ldo \$123,\$254,34
+ 8: 8dfeea38 ldo \$254,\$234,56
+
+0+c <_start>:
+ c: e3fd0001 setl \$253,0x1
--- /dev/null
+# Have a single GREG register allocation.
+ .global areg
+areg GREG 123456789101112
--- /dev/null
+#source: greg-1.s
+#source: gregldo1.s
+#source: start.s
+#ld: -m mmo
+#objdump: -dt
+
+# Most simple greg usage: relocate to each possible location within an
+# insn; mmo.
+
+.*: file format mmo
+
+SYMBOL TABLE:
+0+c g \.text Main
+0+c g \.text _start
+0+fe g \*REG\* areg
+
+Disassembly of section \.text:
+
+0+ <Main-0xc>:
+ 0: 8c0c20fe ldo \$12,\$32,areg
+ 4: 8d7bfe22 ldo \$123,areg,34
+ 8: 8dfeea38 ldo areg,\$234,56
+
+0+c <(Main|_start)>:
+ c: e3fd0001 setl \$253,0x1
--- /dev/null
+#source: greg-1.s
+#source: gregldo1.s
+#source: gregget2.s
+#source: a.s
+#source: greg-3.s
+#source: start.s
+#source: greg-2.s
+#as: -x
+#ld: -m mmo
+#objdump: -dt
+
+# Have two used gregs and one unused, mmo.
+
+.*: file format mmo
+
+SYMBOL TABLE:
+0+20 g \.text Main
+0+fe g \*REG\* b
+0+20 g \.text _start
+0+fc g \*REG\* areg
+0+fd g \*REG\* c
+0+1c g \.text a
+
+Disassembly of section \.text:
+
+0+ <a-0x1c>:
+ 0: 8c0c20fc ldo \$12,\$32,areg
+ 4: 8d7bfc22 ldo \$123,areg,34
+ 8: 8dfcea38 ldo areg,\$234,56
+ c: e3fe001c setl b,0x1c
+ 10: e6fe0000 incml b,0x0
+ 14: e5fe0000 incmh b,0x0
+ 18: e4fe0000 inch b,0x0
+
+0+1c <a>:
+ 1c: e3fd0004 setl c,0x4
+
+0+20 <(Main|_start)>:
+ 20: e3fd0001 setl c,0x1
--- /dev/null
+#source: greg-1.s
+#source: gregldo1.s
+#source: gregget2.s
+#source: a.s
+#source: greg-3.s
+#source: start.s
+#source: greg-2.s
+#as: -x
+#ld: -m mmo
+#objdump: -str
+
+# Have two used gregs and one unused, mmo; display contents to visualize
+# mmo bug with register contents.
+
+.*: file format mmo
+
+SYMBOL TABLE:
+0+20 g \.text Main
+0+fe g \*REG\* b
+0+20 g \.text _start
+0+fc g \*REG\* areg
+0+fd g \*REG\* c
+0+1c g \.text a
+
+
+Contents of section \.text:
+ 0+ 8c0c20fc 8d7bfc22 8dfcea38 e3fe001c .*
+ 0+10 e6fe0000 e5fe0000 e4fe0000 e3fd0004 .*
+ 0+20 e3fd0001 .*
+Contents of section \.MMIX\.reg_contents:
+ 07e0 00007048 860f3a38 00000000 00000042 .*
+ 07f0 007acf50 505a30a2 .*
--- /dev/null
+#source: greg-1.s
+#source: gregget1.s
+#source: start.s
+#source: a.s
+#as: -x
+#ld: -m mmo
+#objdump: -dt
+
+# A greg usage with an expanding insn. The register reloc must be
+# evaluated before the expanding reloc. Here, it doesn't appear in the
+# wrong order, and it doesn't seem like they would naturally appear in the
+# wrong order, but anyway; mmo.
+
+.*: file format mmo
+
+SYMBOL TABLE:
+0+10 g \.text Main
+0+10 g \.text _start
+0+fe g \*REG\* areg
+0+14 g \.text a
+
+Disassembly of section \.text:
+
+0+ <(Main|_start)-0x10>:
+ 0: e3fe0014 setl areg,0x14
+ 4: e6fe0000 incml areg,0x0
+ 8: e5fe0000 incmh areg,0x0
+ c: e4fe0000 inch areg,0x0
+
+0+10 <(Main|_start)>:
+ 10: e3fd0001 setl \$253,0x1
+
+0+14 <a>:
+ 14: e3fd0004 setl \$253,0x4
--- /dev/null
+#source: greg-1.s
+#source: gregbza1.s
+#source: start.s
+#source: a.s
+#as: -x
+#ld: -m mmo
+#objdump: -dt
+
+# Like greg-3, but a different expanding insn, mmo.
+
+.*: file format mmo
+
+SYMBOL TABLE:
+0+18 g \.text Main
+0+18 g \.text _start
+0+fe g \*REG\* areg
+0+1c g \.text a
+
+Disassembly of section \.text:
+
+0+ <(Main|_start)-0x18>:
+ 0: 5afe0006 pbnz areg,18 <(Main|_start)>
+ 4: e3ff001c setl \$255,0x1c
+ 8: e6ff0000 incml \$255,0x0
+ c: e5ff0000 incmh \$255,0x0
+ 10: e4ff0000 inch \$255,0x0
+ 14: 9fffff00 go \$255,\$255,0
+
+0+18 <(Main|_start)>:
+ 18: e3fd0001 setl \$253,0x1
+
+0+1c <a>:
+ 1c: e3fd0004 setl \$253,0x4
--- /dev/null
+#source: greg-1.s
+#source: gregpsj1.s
+#source: start.s
+#source: a.s
+#as: -x
+#ld: -m mmo
+#objdump: -dt
+
+# Like greg-3, but a different expanding insn.
+
+.*: file format mmo
+
+SYMBOL TABLE:
+0+14 g \.text Main
+0+14 g \.text _start
+0+fe g \*REG\* areg
+0+18 g \.text a
+
+Disassembly of section \.text:
+
+0+ <(Main|_start)-0x14>:
+ 0: e3ff0018 setl \$255,0x18
+ 4: e6ff0000 incml \$255,0x0
+ 8: e5ff0000 incmh \$255,0x0
+ c: e4ff0000 inch \$255,0x0
+ 10: bffeff00 pushgo areg,\$255,0
+
+0+14 <(Main|_start)>:
+ 14: e3fd0001 setl \$253,0x1
+
+0+18 <a>:
+ 18: e3fd0004 setl \$253,0x4
--- /dev/null
+#source: gregget1.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-1.s
+#source: a.s
+#source: start.s
+#as: -x
+#ld: -m mmo
+#objdump: -dt
+
+# Allocating the maximum number of gregs and referring to one at the end
+# still works, mmo.
+
+.*: file format mmo
+
+SYMBOL TABLE:
+0+14 g \.text Main
+0+14 g \.text _start
+0+fe g \*REG\* areg
+0+10 g \.text a
+
+Disassembly of section \.text:
+
+0+ <a-0x10>:
+ 0: e3fe0010 setl areg,0x10
+ 4: e6fe0000 incml areg,0x0
+ 8: e5fe0000 incmh areg,0x0
+ c: e4fe0000 inch areg,0x0
+
+0+10 <a>:
+ 10: e3fd0004 setl \$253,0x4
+
+0+14 <(Main|_start)>:
+ 14: e3fd0001 setl \$253,0x1
--- /dev/null
+#source: gregget1.s
+#source: greg-1.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: a.s
+#source: start.s
+#as: -x
+#ld: -m mmo
+#objdump: -dt
+
+# Allocating the maximum number of gregs and referring to one at the
+# *other* end still works, mmo.
+
+.*: file format mmo
+
+SYMBOL TABLE:
+0+14 g \.text Main
+0+14 g \.text _start
+0+20 g \*REG\* areg
+0+10 g \.text a
+
+Disassembly of section \.text:
+
+0+ <a-0x10>:
+ 0: e3200010 setl areg,0x10
+ 4: e6200000 incml areg,0x0
+ 8: e5200000 incmh areg,0x0
+ c: e4200000 inch areg,0x0
+
+0+10 <a>:
+ 10: e3fd0004 setl \$253,0x4
+
+0+14 <(Main|_start)>:
+ 14: e3fd0001 setl \$253,0x1
--- /dev/null
+#source: gregget1.s
+#source: greg-1.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: a.s
+#source: start.s
+#as: -x
+#ld: -m mmo
+#error: Too many global registers: 224, max 223
+
+# Allocating the maximum number of gregs *plus one* is an error, mmo.
--- /dev/null
+#source: gregget1.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-1.s
+#source: a.s
+#source: start.s
+#as: -x
+#ld: -m mmo
+#objdump: -dt
+#error: Too many global registers: 224, max 223
+
+# Allocating the maximum number of gregs *plus one* is an error; other end
+# of the stick, mmo.
--- /dev/null
+#source: start.s
+#source: aregm.s
+#source: gregldo1.s
+#ld: -m elf64mmix
+#objdump: -str
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+ l d \.text 0+
+2000000000000000 l d \.data 0+
+2000000000000000 l d \.sbss 0+
+2000000000000000 l d \.bss 0+
+0+7f0 l d \.MMIX\.reg_contents 0+
+0+ l d \*ABS\* 0+
+0+ l d \*ABS\* 0+
+0+ l d \*ABS\* 0+
+0+ g F \.text 0+ Main
+0+ g \.text 0+ _start
+0+fe g \*REG\* 0+ areg
+2000000000000000 g O \*ABS\* 0+ __bss_start
+2000000000000000 g O \*ABS\* 0+ _edata
+2000000000000000 g O \*ABS\* 0+ _end
+0+ g O \.text 0+ _start\.
+
+Contents of section \.text:
+ 0+ e3fd0001 8f03fe10 8e0307fe 8f05fe04 .*
+ 0+10 8c0c20fe 8d7bfe22 8dfeea38 .*
+Contents of section \.data:
+Contents of section \.sbss:
+Contents of section \.MMIX\.reg_contents:
+ 07f0 00000000 00000004 .*
--- /dev/null
+#source: greg-1.s
+#source: gregldo1.s
+#source: gregget2.s
+#source: a.s
+#source: greg-3.s
+#source: start.s
+#source: greg-2.s
+#as: -x
+#ld: -m elf64mmix
+#objdump: -dt
+
+# Have two used gregs and one unused.
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+ l d .text 0+
+2000000000000000 l d .data 0+
+2000000000000000 l d .sbss 0+
+2000000000000000 l d .bss 0+
+0+7e0 l d \.MMIX\.reg_contents 0+
+0+ l d \*ABS\* 0+
+0+ l d \*ABS\* 0+
+0+ l d \*ABS\* 0+
+0+fe g \*REG\* 0+ b
+0+20 g \.text 0+ _start
+0+fc g \*REG\* 0+ areg
+0+fd g \*REG\* 0+ c
+2000000000000000 g O \*ABS\* 0+ __bss_start
+2000000000000000 g O \*ABS\* 0+ _edata
+2000000000000000 g O \*ABS\* 0+ _end
+0+20 g O \.text 0+ _start\.
+0+1c g \.text 0+ a
+
+Disassembly of section \.text:
+
+0+ <a-0x1c>:
+ 0: 8c0c20fc ldo \$12,\$32,\$252
+ 4: 8d7bfc22 ldo \$123,\$252,34
+ 8: 8dfcea38 ldo \$252,\$234,56
+ c: e3fe001c setl \$254,0x1c
+ 10: e6fe0000 incml \$254,0x0
+ 14: e5fe0000 incmh \$254,0x0
+ 18: e4fe0000 inch \$254,0x0
+
+0+1c <a>:
+ 1c: e3fd0004 setl \$253,0x4
+
+0+20 <_start>:
+ 20: e3fd0001 setl \$253,0x1
--- /dev/null
+# Have another GREG register allocation.
+ .global b
+b GREG 34567891011121314
--- /dev/null
+#source: start.s
+#source: aregm.s
+#source: gregldo1.s
+#ld: -m mmo
+#objdump: -str
+
+.*: file format mmo
+
+SYMBOL TABLE:
+0+ g \.text Main
+0+ g \.text _start
+0+fe g \*REG\* areg
+
+Contents of section \.text:
+ 0+ e3fd0001 8f03fe10 8e0307fe 8f05fe04 .*
+ 0+10 8c0c20fe 8d7bfe22 8dfeea38 .*
+Contents of section \.MMIX\.reg_contents:
+ 07f0 00000000 00000004 .*
--- /dev/null
+#source: greg-1.s
+#source: gregget1.s
+#source: start.s
+#source: a.s
+#as: -x
+#ld: -m elf64mmix
+#objdump: -dt
+
+# A greg usage with an expanding insn. The register reloc must be
+# evaluated before the expanding reloc. Here, it doesn't appear in the
+# wrong order, and it doesn't seem like they would naturally appear in the
+# wrong order, but anyway.
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+ l d .text 0+
+2000000000000000 l d .data 0+
+2000000000000000 l d .sbss 0+
+2000000000000000 l d .bss 0+
+0+7f0 l d \.MMIX\.reg_contents 0+
+0+ l d \*ABS\* 0+
+0+ l d \*ABS\* 0+
+0+ l d \*ABS\* 0+
+0+10 g \.text 0+ _start
+0+fe g \*REG\* 0+ areg
+2000000000000000 g O \*ABS\* 0+ __bss_start
+2000000000000000 g O \*ABS\* 0+ _edata
+2000000000000000 g O \*ABS\* 0+ _end
+0+10 g O \.text 0+ _start\.
+0+14 g \.text 0+ a
+
+Disassembly of section \.text:
+
+0+ <_start-0x10>:
+ 0: e3fe0014 setl \$254,0x14
+ 4: e6fe0000 incml \$254,0x0
+ 8: e5fe0000 incmh \$254,0x0
+ c: e4fe0000 inch \$254,0x0
+
+0+10 <_start>:
+ 10: e3fd0001 setl \$253,0x1
+
+0+14 <a>:
+ 14: e3fd0004 setl \$253,0x4
--- /dev/null
+# Have yet another GREG register allocation.
+ .global c
+c GREG #42
--- /dev/null
+#source: greg-1.s
+#source: gregbza1.s
+#source: start.s
+#source: a.s
+#as: -x
+#ld: -m elf64mmix
+#objdump: -dt
+
+# Like greg-3, but a different expanding insn.
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+ l d .text 0+
+2000000000000000 l d .data 0+
+2000000000000000 l d .sbss 0+
+2000000000000000 l d .bss 0+
+0+7f0 l d \.MMIX\.reg_contents 0+
+0+ l d \*ABS\* 0+
+0+ l d \*ABS\* 0+
+0+ l d \*ABS\* 0+
+0+18 g \.text 0+ _start
+0+fe g \*REG\* 0+ areg
+2000000000000000 g O \*ABS\* 0+ __bss_start
+2000000000000000 g O \*ABS\* 0+ _edata
+2000000000000000 g O \*ABS\* 0+ _end
+0+18 g O \.text 0+ _start\.
+0+1c g \.text 0+ a
+
+Disassembly of section \.text:
+
+0+ <_start-0x18>:
+ 0: 5afe0006 pbnz \$254,18 <_start>
+ 4: e3ff001c setl \$255,0x1c
+ 8: e6ff0000 incml \$255,0x0
+ c: e5ff0000 incmh \$255,0x0
+ 10: e4ff0000 inch \$255,0x0
+ 14: 9fffff00 go \$255,\$255,0
+
+0+18 <_start>:
+ 18: e3fd0001 setl \$253,0x1
+
+0+1c <a>:
+ 1c: e3fd0004 setl \$253,0x4
--- /dev/null
+# A single local greg.
+lsym GREG 78
--- /dev/null
+#source: greg-1.s
+#source: gregpsj1.s
+#source: start.s
+#source: a.s
+#as: -x
+#ld: -m elf64mmix
+#objdump: -dt
+
+# Like greg-3, but a different expanding insn.
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+ l d .text 0+
+2000000000000000 l d .data 0+
+2000000000000000 l d .sbss 0+
+2000000000000000 l d .bss 0+
+0+7f0 l d \.MMIX\.reg_contents 0+
+0+ l d \*ABS\* 0+
+0+ l d \*ABS\* 0+
+0+ l d \*ABS\* 0+
+0+14 g \.text 0+ _start
+0+fe g \*REG\* 0+ areg
+2000000000000000 g O \*ABS\* 0+ __bss_start
+2000000000000000 g O \*ABS\* 0+ _edata
+2000000000000000 g O \*ABS\* 0+ _end
+0+14 g O \.text 0+ _start\.
+0+18 g \.text 0+ a
+
+Disassembly of section \.text:
+
+0+ <_start-0x14>:
+ 0: e3ff0018 setl \$255,0x18
+ 4: e6ff0000 incml \$255,0x0
+ 8: e5ff0000 incmh \$255,0x0
+ c: e4ff0000 inch \$255,0x0
+ 10: bffeff00 pushgo \$254,\$255,0
+
+0+14 <_start>:
+ 14: e3fd0001 setl \$253,0x1
+
+0+18 <a>:
+ 18: e3fd0004 setl \$253,0x4
--- /dev/null
+# 16 local gregs.
+A GREG
+B GREG
+C GREG
+D GREG
+
+E GREG
+F GREG
+G GREG
+H GREG
+
+I GREG
+J GREG
+K GREG
+L GREG
+
+M GREG
+N GREG
+O GREG
+P GREG
--- /dev/null
+#source: gregget1.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-1.s
+#source: a.s
+#source: start.s
+#as: -x
+#ld: -m elf64mmix
+#objdump: -dt
+
+# Allocating the maximum number of gregs and referring to one at the end
+# still works.
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+0 l d \.text 0+
+2000000000000000 l d \.data 0+
+2000000000000000 l d \.sbss 0+
+2000000000000000 l d \.bss 0+
+0+100 l d \.MMIX\.reg_contents 0+
+0+ l d \*ABS\* 0+
+0+ l d \*ABS\* 0+
+0+ l d \*ABS\* 0+
+0+20 l \*REG\* 0+ P
+0+21 l \*REG\* 0+ O
+0+22 l \*REG\* 0+ N
+0+23 l \*REG\* 0+ M
+0+24 l \*REG\* 0+ L
+0+25 l \*REG\* 0+ K
+0+26 l \*REG\* 0+ J
+0+27 l \*REG\* 0+ I
+0+28 l \*REG\* 0+ H
+0+29 l \*REG\* 0+ G
+0+2a l \*REG\* 0+ F
+0+2b l \*REG\* 0+ E
+0+2c l \*REG\* 0+ D
+0+2d l \*REG\* 0+ C
+0+2e l \*REG\* 0+ B
+0+2f l \*REG\* 0+ A
+0+30 l \*REG\* 0+ P
+0+31 l \*REG\* 0+ O
+0+32 l \*REG\* 0+ N
+0+33 l \*REG\* 0+ M
+0+34 l \*REG\* 0+ L
+0+35 l \*REG\* 0+ K
+0+36 l \*REG\* 0+ J
+0+37 l \*REG\* 0+ I
+0+38 l \*REG\* 0+ H
+0+39 l \*REG\* 0+ G
+0+3a l \*REG\* 0+ F
+0+3b l \*REG\* 0+ E
+0+3c l \*REG\* 0+ D
+0+3d l \*REG\* 0+ C
+0+3e l \*REG\* 0+ B
+0+3f l \*REG\* 0+ A
+0+40 l \*REG\* 0+ P
+0+41 l \*REG\* 0+ O
+0+42 l \*REG\* 0+ N
+0+43 l \*REG\* 0+ M
+0+44 l \*REG\* 0+ L
+0+45 l \*REG\* 0+ K
+0+46 l \*REG\* 0+ J
+0+47 l \*REG\* 0+ I
+0+48 l \*REG\* 0+ H
+0+49 l \*REG\* 0+ G
+0+4a l \*REG\* 0+ F
+0+4b l \*REG\* 0+ E
+0+4c l \*REG\* 0+ D
+0+4d l \*REG\* 0+ C
+0+4e l \*REG\* 0+ B
+0+4f l \*REG\* 0+ A
+0+50 l \*REG\* 0+ P
+0+51 l \*REG\* 0+ O
+0+52 l \*REG\* 0+ N
+0+53 l \*REG\* 0+ M
+0+54 l \*REG\* 0+ L
+0+55 l \*REG\* 0+ K
+0+56 l \*REG\* 0+ J
+0+57 l \*REG\* 0+ I
+0+58 l \*REG\* 0+ H
+0+59 l \*REG\* 0+ G
+0+5a l \*REG\* 0+ F
+0+5b l \*REG\* 0+ E
+0+5c l \*REG\* 0+ D
+0+5d l \*REG\* 0+ C
+0+5e l \*REG\* 0+ B
+0+5f l \*REG\* 0+ A
+0+60 l \*REG\* 0+ P
+0+61 l \*REG\* 0+ O
+0+62 l \*REG\* 0+ N
+0+63 l \*REG\* 0+ M
+0+64 l \*REG\* 0+ L
+0+65 l \*REG\* 0+ K
+0+66 l \*REG\* 0+ J
+0+67 l \*REG\* 0+ I
+0+68 l \*REG\* 0+ H
+0+69 l \*REG\* 0+ G
+0+6a l \*REG\* 0+ F
+0+6b l \*REG\* 0+ E
+0+6c l \*REG\* 0+ D
+0+6d l \*REG\* 0+ C
+0+6e l \*REG\* 0+ B
+0+6f l \*REG\* 0+ A
+0+70 l \*REG\* 0+ P
+0+71 l \*REG\* 0+ O
+0+72 l \*REG\* 0+ N
+0+73 l \*REG\* 0+ M
+0+74 l \*REG\* 0+ L
+0+75 l \*REG\* 0+ K
+0+76 l \*REG\* 0+ J
+0+77 l \*REG\* 0+ I
+0+78 l \*REG\* 0+ H
+0+79 l \*REG\* 0+ G
+0+7a l \*REG\* 0+ F
+0+7b l \*REG\* 0+ E
+0+7c l \*REG\* 0+ D
+0+7d l \*REG\* 0+ C
+0+7e l \*REG\* 0+ B
+0+7f l \*REG\* 0+ A
+0+80 l \*REG\* 0+ P
+0+81 l \*REG\* 0+ O
+0+82 l \*REG\* 0+ N
+0+83 l \*REG\* 0+ M
+0+84 l \*REG\* 0+ L
+0+85 l \*REG\* 0+ K
+0+86 l \*REG\* 0+ J
+0+87 l \*REG\* 0+ I
+0+88 l \*REG\* 0+ H
+0+89 l \*REG\* 0+ G
+0+8a l \*REG\* 0+ F
+0+8b l \*REG\* 0+ E
+0+8c l \*REG\* 0+ D
+0+8d l \*REG\* 0+ C
+0+8e l \*REG\* 0+ B
+0+8f l \*REG\* 0+ A
+0+90 l \*REG\* 0+ P
+0+91 l \*REG\* 0+ O
+0+92 l \*REG\* 0+ N
+0+93 l \*REG\* 0+ M
+0+94 l \*REG\* 0+ L
+0+95 l \*REG\* 0+ K
+0+96 l \*REG\* 0+ J
+0+97 l \*REG\* 0+ I
+0+98 l \*REG\* 0+ H
+0+99 l \*REG\* 0+ G
+0+9a l \*REG\* 0+ F
+0+9b l \*REG\* 0+ E
+0+9c l \*REG\* 0+ D
+0+9d l \*REG\* 0+ C
+0+9e l \*REG\* 0+ B
+0+9f l \*REG\* 0+ A
+0+a0 l \*REG\* 0+ P
+0+a1 l \*REG\* 0+ O
+0+a2 l \*REG\* 0+ N
+0+a3 l \*REG\* 0+ M
+0+a4 l \*REG\* 0+ L
+0+a5 l \*REG\* 0+ K
+0+a6 l \*REG\* 0+ J
+0+a7 l \*REG\* 0+ I
+0+a8 l \*REG\* 0+ H
+0+a9 l \*REG\* 0+ G
+0+aa l \*REG\* 0+ F
+0+ab l \*REG\* 0+ E
+0+ac l \*REG\* 0+ D
+0+ad l \*REG\* 0+ C
+0+ae l \*REG\* 0+ B
+0+af l \*REG\* 0+ A
+0+b0 l \*REG\* 0+ P
+0+b1 l \*REG\* 0+ O
+0+b2 l \*REG\* 0+ N
+0+b3 l \*REG\* 0+ M
+0+b4 l \*REG\* 0+ L
+0+b5 l \*REG\* 0+ K
+0+b6 l \*REG\* 0+ J
+0+b7 l \*REG\* 0+ I
+0+b8 l \*REG\* 0+ H
+0+b9 l \*REG\* 0+ G
+0+ba l \*REG\* 0+ F
+0+bb l \*REG\* 0+ E
+0+bc l \*REG\* 0+ D
+0+bd l \*REG\* 0+ C
+0+be l \*REG\* 0+ B
+0+bf l \*REG\* 0+ A
+0+c0 l \*REG\* 0+ P
+0+c1 l \*REG\* 0+ O
+0+c2 l \*REG\* 0+ N
+0+c3 l \*REG\* 0+ M
+0+c4 l \*REG\* 0+ L
+0+c5 l \*REG\* 0+ K
+0+c6 l \*REG\* 0+ J
+0+c7 l \*REG\* 0+ I
+0+c8 l \*REG\* 0+ H
+0+c9 l \*REG\* 0+ G
+0+ca l \*REG\* 0+ F
+0+cb l \*REG\* 0+ E
+0+cc l \*REG\* 0+ D
+0+cd l \*REG\* 0+ C
+0+ce l \*REG\* 0+ B
+0+cf l \*REG\* 0+ A
+0+d0 l \*REG\* 0+ P
+0+d1 l \*REG\* 0+ O
+0+d2 l \*REG\* 0+ N
+0+d3 l \*REG\* 0+ M
+0+d4 l \*REG\* 0+ L
+0+d5 l \*REG\* 0+ K
+0+d6 l \*REG\* 0+ J
+0+d7 l \*REG\* 0+ I
+0+d8 l \*REG\* 0+ H
+0+d9 l \*REG\* 0+ G
+0+da l \*REG\* 0+ F
+0+db l \*REG\* 0+ E
+0+dc l \*REG\* 0+ D
+0+dd l \*REG\* 0+ C
+0+de l \*REG\* 0+ B
+0+df l \*REG\* 0+ A
+0+e0 l \*REG\* 0+ P
+0+e1 l \*REG\* 0+ O
+0+e2 l \*REG\* 0+ N
+0+e3 l \*REG\* 0+ M
+0+e4 l \*REG\* 0+ L
+0+e5 l \*REG\* 0+ K
+0+e6 l \*REG\* 0+ J
+0+e7 l \*REG\* 0+ I
+0+e8 l \*REG\* 0+ H
+0+e9 l \*REG\* 0+ G
+0+ea l \*REG\* 0+ F
+0+eb l \*REG\* 0+ E
+0+ec l \*REG\* 0+ D
+0+ed l \*REG\* 0+ C
+0+ee l \*REG\* 0+ B
+0+ef l \*REG\* 0+ A
+0+f0 l \*REG\* 0+ lsym
+0+f1 l \*REG\* 0+ lsym
+0+f2 l \*REG\* 0+ lsym
+0+f3 l \*REG\* 0+ lsym
+0+f4 l \*REG\* 0+ lsym
+0+f5 l \*REG\* 0+ lsym
+0+f6 l \*REG\* 0+ lsym
+0+f7 l \*REG\* 0+ lsym
+0+f8 l \*REG\* 0+ lsym
+0+f9 l \*REG\* 0+ lsym
+0+fa l \*REG\* 0+ lsym
+0+fb l \*REG\* 0+ lsym
+0+fc l \*REG\* 0+ lsym
+0+fd l \*REG\* 0+ lsym
+0+14 g \.text 0+ _start
+0+fe g \*REG\* 0+ areg
+2000000000000000 g O \*ABS\* 0+ __bss_start
+2000000000000000 g O \*ABS\* 0+ _edata
+2000000000000000 g O \*ABS\* 0+ _end
+0+14 g O \.text 0+ _start\.
+0+10 g \.text 0+ a
+
+Disassembly of section \.text:
+
+0+ <a-0x10>:
+ 0: e3fe0010 setl \$254,0x10
+ 4: e6fe0000 incml \$254,0x0
+ 8: e5fe0000 incmh \$254,0x0
+ c: e4fe0000 inch \$254,0x0
+
+0+10 <a>:
+ 10: e3fd0004 setl \$253,0x4
+
+0+14 <_start>:
+ 14: e3fd0001 setl \$253,0x1
--- /dev/null
+#source: gregget1.s
+#source: greg-1.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: a.s
+#source: start.s
+#as: -x
+#ld: -m elf64mmix
+#objdump: -dt
+
+# Allocating the maximum number of gregs and referring to one at the
+# *other* end still works.
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+ l d \.text 0+
+2000000000000000 l d \.data 0+
+2000000000000000 l d \.sbss 0+
+2000000000000000 l d \.bss 0+
+0+100 l d \.MMIX\.reg_contents 0+
+0+ l d \*ABS\* 0+
+0+ l d \*ABS\* 0+
+0+ l d \*ABS\* 0+
+0+21 l \*REG\* 0+ P
+0+22 l \*REG\* 0+ O
+0+23 l \*REG\* 0+ N
+0+24 l \*REG\* 0+ M
+0+25 l \*REG\* 0+ L
+0+26 l \*REG\* 0+ K
+0+27 l \*REG\* 0+ J
+0+28 l \*REG\* 0+ I
+0+29 l \*REG\* 0+ H
+0+2a l \*REG\* 0+ G
+0+2b l \*REG\* 0+ F
+0+2c l \*REG\* 0+ E
+0+2d l \*REG\* 0+ D
+0+2e l \*REG\* 0+ C
+0+2f l \*REG\* 0+ B
+0+30 l \*REG\* 0+ A
+0+31 l \*REG\* 0+ P
+0+32 l \*REG\* 0+ O
+0+33 l \*REG\* 0+ N
+0+34 l \*REG\* 0+ M
+0+35 l \*REG\* 0+ L
+0+36 l \*REG\* 0+ K
+0+37 l \*REG\* 0+ J
+0+38 l \*REG\* 0+ I
+0+39 l \*REG\* 0+ H
+0+3a l \*REG\* 0+ G
+0+3b l \*REG\* 0+ F
+0+3c l \*REG\* 0+ E
+0+3d l \*REG\* 0+ D
+0+3e l \*REG\* 0+ C
+0+3f l \*REG\* 0+ B
+0+40 l \*REG\* 0+ A
+0+41 l \*REG\* 0+ P
+0+42 l \*REG\* 0+ O
+0+43 l \*REG\* 0+ N
+0+44 l \*REG\* 0+ M
+0+45 l \*REG\* 0+ L
+0+46 l \*REG\* 0+ K
+0+47 l \*REG\* 0+ J
+0+48 l \*REG\* 0+ I
+0+49 l \*REG\* 0+ H
+0+4a l \*REG\* 0+ G
+0+4b l \*REG\* 0+ F
+0+4c l \*REG\* 0+ E
+0+4d l \*REG\* 0+ D
+0+4e l \*REG\* 0+ C
+0+4f l \*REG\* 0+ B
+0+50 l \*REG\* 0+ A
+0+51 l \*REG\* 0+ P
+0+52 l \*REG\* 0+ O
+0+53 l \*REG\* 0+ N
+0+54 l \*REG\* 0+ M
+0+55 l \*REG\* 0+ L
+0+56 l \*REG\* 0+ K
+0+57 l \*REG\* 0+ J
+0+58 l \*REG\* 0+ I
+0+59 l \*REG\* 0+ H
+0+5a l \*REG\* 0+ G
+0+5b l \*REG\* 0+ F
+0+5c l \*REG\* 0+ E
+0+5d l \*REG\* 0+ D
+0+5e l \*REG\* 0+ C
+0+5f l \*REG\* 0+ B
+0+60 l \*REG\* 0+ A
+0+61 l \*REG\* 0+ P
+0+62 l \*REG\* 0+ O
+0+63 l \*REG\* 0+ N
+0+64 l \*REG\* 0+ M
+0+65 l \*REG\* 0+ L
+0+66 l \*REG\* 0+ K
+0+67 l \*REG\* 0+ J
+0+68 l \*REG\* 0+ I
+0+69 l \*REG\* 0+ H
+0+6a l \*REG\* 0+ G
+0+6b l \*REG\* 0+ F
+0+6c l \*REG\* 0+ E
+0+6d l \*REG\* 0+ D
+0+6e l \*REG\* 0+ C
+0+6f l \*REG\* 0+ B
+0+70 l \*REG\* 0+ A
+0+71 l \*REG\* 0+ P
+0+72 l \*REG\* 0+ O
+0+73 l \*REG\* 0+ N
+0+74 l \*REG\* 0+ M
+0+75 l \*REG\* 0+ L
+0+76 l \*REG\* 0+ K
+0+77 l \*REG\* 0+ J
+0+78 l \*REG\* 0+ I
+0+79 l \*REG\* 0+ H
+0+7a l \*REG\* 0+ G
+0+7b l \*REG\* 0+ F
+0+7c l \*REG\* 0+ E
+0+7d l \*REG\* 0+ D
+0+7e l \*REG\* 0+ C
+0+7f l \*REG\* 0+ B
+0+80 l \*REG\* 0+ A
+0+81 l \*REG\* 0+ P
+0+82 l \*REG\* 0+ O
+0+83 l \*REG\* 0+ N
+0+84 l \*REG\* 0+ M
+0+85 l \*REG\* 0+ L
+0+86 l \*REG\* 0+ K
+0+87 l \*REG\* 0+ J
+0+88 l \*REG\* 0+ I
+0+89 l \*REG\* 0+ H
+0+8a l \*REG\* 0+ G
+0+8b l \*REG\* 0+ F
+0+8c l \*REG\* 0+ E
+0+8d l \*REG\* 0+ D
+0+8e l \*REG\* 0+ C
+0+8f l \*REG\* 0+ B
+0+90 l \*REG\* 0+ A
+0+91 l \*REG\* 0+ P
+0+92 l \*REG\* 0+ O
+0+93 l \*REG\* 0+ N
+0+94 l \*REG\* 0+ M
+0+95 l \*REG\* 0+ L
+0+96 l \*REG\* 0+ K
+0+97 l \*REG\* 0+ J
+0+98 l \*REG\* 0+ I
+0+99 l \*REG\* 0+ H
+0+9a l \*REG\* 0+ G
+0+9b l \*REG\* 0+ F
+0+9c l \*REG\* 0+ E
+0+9d l \*REG\* 0+ D
+0+9e l \*REG\* 0+ C
+0+9f l \*REG\* 0+ B
+0+a0 l \*REG\* 0+ A
+0+a1 l \*REG\* 0+ P
+0+a2 l \*REG\* 0+ O
+0+a3 l \*REG\* 0+ N
+0+a4 l \*REG\* 0+ M
+0+a5 l \*REG\* 0+ L
+0+a6 l \*REG\* 0+ K
+0+a7 l \*REG\* 0+ J
+0+a8 l \*REG\* 0+ I
+0+a9 l \*REG\* 0+ H
+0+aa l \*REG\* 0+ G
+0+ab l \*REG\* 0+ F
+0+ac l \*REG\* 0+ E
+0+ad l \*REG\* 0+ D
+0+ae l \*REG\* 0+ C
+0+af l \*REG\* 0+ B
+0+b0 l \*REG\* 0+ A
+0+b1 l \*REG\* 0+ P
+0+b2 l \*REG\* 0+ O
+0+b3 l \*REG\* 0+ N
+0+b4 l \*REG\* 0+ M
+0+b5 l \*REG\* 0+ L
+0+b6 l \*REG\* 0+ K
+0+b7 l \*REG\* 0+ J
+0+b8 l \*REG\* 0+ I
+0+b9 l \*REG\* 0+ H
+0+ba l \*REG\* 0+ G
+0+bb l \*REG\* 0+ F
+0+bc l \*REG\* 0+ E
+0+bd l \*REG\* 0+ D
+0+be l \*REG\* 0+ C
+0+bf l \*REG\* 0+ B
+0+c0 l \*REG\* 0+ A
+0+c1 l \*REG\* 0+ P
+0+c2 l \*REG\* 0+ O
+0+c3 l \*REG\* 0+ N
+0+c4 l \*REG\* 0+ M
+0+c5 l \*REG\* 0+ L
+0+c6 l \*REG\* 0+ K
+0+c7 l \*REG\* 0+ J
+0+c8 l \*REG\* 0+ I
+0+c9 l \*REG\* 0+ H
+0+ca l \*REG\* 0+ G
+0+cb l \*REG\* 0+ F
+0+cc l \*REG\* 0+ E
+0+cd l \*REG\* 0+ D
+0+ce l \*REG\* 0+ C
+0+cf l \*REG\* 0+ B
+0+d0 l \*REG\* 0+ A
+0+d1 l \*REG\* 0+ P
+0+d2 l \*REG\* 0+ O
+0+d3 l \*REG\* 0+ N
+0+d4 l \*REG\* 0+ M
+0+d5 l \*REG\* 0+ L
+0+d6 l \*REG\* 0+ K
+0+d7 l \*REG\* 0+ J
+0+d8 l \*REG\* 0+ I
+0+d9 l \*REG\* 0+ H
+0+da l \*REG\* 0+ G
+0+db l \*REG\* 0+ F
+0+dc l \*REG\* 0+ E
+0+dd l \*REG\* 0+ D
+0+de l \*REG\* 0+ C
+0+df l \*REG\* 0+ B
+0+e0 l \*REG\* 0+ A
+0+e1 l \*REG\* 0+ P
+0+e2 l \*REG\* 0+ O
+0+e3 l \*REG\* 0+ N
+0+e4 l \*REG\* 0+ M
+0+e5 l \*REG\* 0+ L
+0+e6 l \*REG\* 0+ K
+0+e7 l \*REG\* 0+ J
+0+e8 l \*REG\* 0+ I
+0+e9 l \*REG\* 0+ H
+0+ea l \*REG\* 0+ G
+0+eb l \*REG\* 0+ F
+0+ec l \*REG\* 0+ E
+0+ed l \*REG\* 0+ D
+0+ee l \*REG\* 0+ C
+0+ef l \*REG\* 0+ B
+0+f0 l \*REG\* 0+ A
+0+f1 l \*REG\* 0+ lsym
+0+f2 l \*REG\* 0+ lsym
+0+f3 l \*REG\* 0+ lsym
+0+f4 l \*REG\* 0+ lsym
+0+f5 l \*REG\* 0+ lsym
+0+f6 l \*REG\* 0+ lsym
+0+f7 l \*REG\* 0+ lsym
+0+f8 l \*REG\* 0+ lsym
+0+f9 l \*REG\* 0+ lsym
+0+fa l \*REG\* 0+ lsym
+0+fb l \*REG\* 0+ lsym
+0+fc l \*REG\* 0+ lsym
+0+fd l \*REG\* 0+ lsym
+0+fe l \*REG\* 0+ lsym
+0+14 g \.text 0+ _start
+0+20 g \*REG\* 0+ areg
+2000000000000000 g O \*ABS\* 0+ __bss_start
+2000000000000000 g O \*ABS\* 0+ _edata
+2000000000000000 g O \*ABS\* 0+ _end
+0+14 g O \.text 0+ _start\.
+0+10 g \.text 0+ a
+
+Disassembly of section \.text:
+
+0+ <a-0x10>:
+ 0: e3200010 setl \$32,0x10
+ 4: e6200000 incml \$32,0x0
+ 8: e5200000 incmh \$32,0x0
+ c: e4200000 inch \$32,0x0
+
+0+10 <a>:
+ 10: e3fd0004 setl \$253,0x4
+
+0+14 <_start>:
+ 14: e3fd0001 setl \$253,0x1
--- /dev/null
+#source: gregget1.s
+#source: greg-1.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: a.s
+#source: start.s
+#as: -x
+#ld: -m elf64mmix
+#error: Too many global registers: 224, max 223
+
+# Allocating the maximum number of gregs *plus one* is an error.
--- /dev/null
+#source: gregget1.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-1.s
+#source: a.s
+#source: start.s
+#as: -x
+#ld: -m elf64mmix
+#objdump: -dt
+#error: Too many global registers: 224, max 223
+
+# Allocating the maximum number of gregs *plus one* is an error; other end
+# of the stick.
--- /dev/null
+# Use a symbolic register areg, presumably allocated by greg in another file.
+# The "BZ" will be expanded, and the reloc for areg must be resolved
+# before the other relocs for that insn.
+ BZ areg,a
--- /dev/null
+# Use a symbolic register areg, presumably allocated by greg in another file.
+# The "GETA" will be expanded, and the reloc for areg must be resolved
+# before the other relocs for that insn.
+ GETA areg,a
--- /dev/null
+# Use a symbolic register b, presumably allocated by greg in another file.
+# The "GETA" will be expanded, and the reloc for b must be resolved before
+# the other relocs for that insn.
+ GETA b,a
--- /dev/null
+# Use a symbolic register areg, presumably allocated by greg in another file.
+ LDO $12,$32,areg
+ LDO $123,areg,34
+ LDO areg,$234,56
+
+
--- /dev/null
+# Use a symbolic register areg, presumably allocated by greg in another file.
+# The "PUSHJ" will be expanded, and the reloc for areg must be resolved
+# before the other relocs for that insn.
+ PUSHJ areg,a
--- /dev/null
+#source: start.s
+#source: a.s
+#ld: -T $srcdir/$subdir/mmohdr1.ld
+#objdump: -sht
+
+.*: file format mmo
+
+Sections:
+Idx Name Size VMA LMA File off Algn
+ 0 \.text 0+8 0+100 0+100 0+ 2\*\*2
+ CONTENTS, ALLOC, LOAD, CODE
+SYMBOL TABLE:
+0+100 g \.text Main
+0+100 g \.text _start
+0+104 g \.text a
+
+
+Contents of section \.text:
+ 0100 e3fd0001 e3fd0004 .*
--- /dev/null
+#source: start.s
+#source: a.s
+#source: jumpa.s
+#as: -x
+#ld: -m elf64mmix
+#objdump: -dr
+
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0+ <_start>:
+ 0: e3fd0001 setl \$253,0x1
+
+0+4 <a>:
+ 4: e3fd0004 setl \$253,0x4
+
+0+8 <jumpa>:
+ 8: e3fd0002 setl \$253,0x2
+ c: f1fffffe jmp 4 <a>
+ 10: fd000000 swym 0,0,0
+ 14: fd000000 swym 0,0,0
+ 18: fd000000 swym 0,0,0
+ 1c: fd000000 swym 0,0,0
+ 20: e3fd0003 setl \$253,0x3
--- /dev/null
+#source: start.s
+#source: jumpa.s
+#source: a.s
+#as: -x
+#ld: -m elf64mmix
+#objdump: -dr
+
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0+ <_start>:
+ 0: e3fd0001 setl \$253,0x1
+
+0+4 <jumpa>:
+ 4: e3fd0002 setl \$253,0x2
+ 8: f0000006 jmp 20 <a>
+ c: fd000000 swym 0,0,0
+ 10: fd000000 swym 0,0,0
+ 14: fd000000 swym 0,0,0
+ 18: fd000000 swym 0,0,0
+ 1c: e3fd0003 setl \$253,0x3
+
+0+20 <a>:
+ 20: e3fd0004 setl \$253,0x4
--- /dev/null
+#source: start.s
+#source: a.s
+#source: jumpa.s
+#as: -no-expand
+#ld: -m elf64mmix
+#objdump: -dr
+
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0+ <_start>:
+ 0: e3fd0001 setl \$253,0x1
+
+0+4 <a>:
+ 4: e3fd0004 setl \$253,0x4
+
+0+8 <jumpa>:
+ 8: e3fd0002 setl \$253,0x2
+ c: f1fffffe jmp 4 <a>
+ 10: e3fd0003 setl \$253,0x3
--- /dev/null
+#source: start.s
+#source: jumpa.s
+#source: a.s
+#as: -no-expand
+#ld: -m elf64mmix
+#objdump: -dr
+
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0+ <_start>:
+ 0: e3fd0001 setl \$253,0x1
+
+0+4 <jumpa>:
+ 4: e3fd0002 setl \$253,0x2
+ 8: f0000002 jmp 10 <a>
+ c: e3fd0003 setl \$253,0x3
+
+0+10 <a>:
+ 10: e3fd0004 setl \$253,0x4
--- /dev/null
+#source: start.s
+#source: a.s
+#source: pad2p26m32.s
+#source: pad16.s
+#source: pad4.s
+#source: pad4.s
+#source: jumpa.s
+#as: -x
+#ld: -m elf64mmix
+#objdump: -dr
+
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0+ <_start>:
+ 0: e3fd0001 setl \$253,0x1
+
+0+4 <a>:
+ 4: e3fd0004 setl \$253,0x4
+ \.\.\.
+
+0+4000000 <jumpa>:
+ 4000000: e3fd0002 setl \$253,0x2
+ 4000004: f1000000 jmp 4 <a>
+ 4000008: fd000000 swym 0,0,0
+ 400000c: fd000000 swym 0,0,0
+ 4000010: fd000000 swym 0,0,0
+ 4000014: fd000000 swym 0,0,0
+ 4000018: e3fd0003 setl \$253,0x3
--- /dev/null
+#source: start.s
+#source: jumpa.s
+#source: pad2p26m32.s
+#source: pad4.s
+#source: a.s
+#as: -x
+#ld: -m elf64mmix
+#objdump: -dr
+
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0+ <_start>:
+ 0: e3fd0001 setl \$253,0x1
+
+0+4 <jumpa>:
+ 4: e3fd0002 setl \$253,0x2
+ 8: f0ffffff jmp 4000004 <a>
+ c: fd000000 swym 0,0,0
+ 10: fd000000 swym 0,0,0
+ 14: fd000000 swym 0,0,0
+ 18: fd000000 swym 0,0,0
+ 1c: e3fd0003 setl \$253,0x3
+ \.\.\.
+
+0+4000004 <a>:
+ 4000004: e3fd0004 setl \$253,0x4
--- /dev/null
+#source: start.s
+#source: a.s
+#source: pad2p26m32.s
+#source: pad16.s
+#source: pad4.s
+#source: pad4.s
+#source: jumpa.s
+#as: -no-expand
+#ld: -m elf64mmix
+#objdump: -dr
+
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0+ <_start>:
+ 0: e3fd0001 setl \$253,0x1
+
+0+4 <a>:
+ 4: e3fd0004 setl \$253,0x4
+ \.\.\.
+
+0+4000000 <jumpa>:
+ 4000000: e3fd0002 setl \$253,0x2
+ 4000004: f1000000 jmp 4 <a>
+ 4000008: e3fd0003 setl \$253,0x3
--- /dev/null
+#source: start.s
+#source: jumpa.s
+#source: pad2p26m32.s
+#source: pad16.s
+#source: pad4.s
+#source: a.s
+#as: -no-expand
+#ld: -m elf64mmix
+#objdump: -dr
+
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0+ <_start>:
+ 0: e3fd0001 setl \$253,0x1
+
+0+4 <jumpa>:
+ 4: e3fd0002 setl \$253,0x2
+ 8: f0ffffff jmp 4000004 <a>
+ c: e3fd0003 setl \$253,0x3
+ \.\.\.
+
+0+4000004 <a>:
+ 4000004: e3fd0004 setl \$253,0x4
--- /dev/null
+#source: start.s
+#source: a.s
+#source: pad2p26m32.s
+#source: pad16.s
+#source: pad4.s
+#source: pad4.s
+#source: pad4.s
+#source: jumpa.s
+#as: -x
+#ld: -m elf64mmix
+#objdump: -dr
+
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0+ <_start>:
+ 0: e3fd0001 setl \$253,0x1
+
+0+4 <a>:
+ 4: e3fd0004 setl \$253,0x4
+ \.\.\.
+
+0+4000004 <jumpa>:
+ 4000004: e3fd0002 setl \$253,0x2
+ 4000008: e3ff0004 setl \$255,0x4
+ 400000c: e6ff0000 incml \$255,0x0
+ 4000010: e5ff0000 incmh \$255,0x0
+ 4000014: e4ff0000 inch \$255,0x0
+ 4000018: 9fffff00 go \$255,\$255,0
+ 400001c: e3fd0003 setl \$253,0x3
--- /dev/null
+#source: start.s
+#source: jumpa.s
+#source: pad2p26m32.s
+#source: pad4.s
+#source: pad4.s
+#source: a.s
+#as: -x
+#ld: -m elf64mmix
+#objdump: -dr
+
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0+ <_start>:
+ 0: e3fd0001 setl \$253,0x1
+
+0+4 <jumpa>:
+ 4: e3fd0002 setl \$253,0x2
+ 8: e3ff0008 setl \$255,0x8
+ c: e6ff0400 incml \$255,0x400
+ 10: e5ff0000 incmh \$255,0x0
+ 14: e4ff0000 inch \$255,0x0
+ 18: 9fffff00 go \$255,\$255,0
+ 1c: e3fd0003 setl \$253,0x3
+ \.\.\.
+
+0+4000008 <a>:
+ 4000008: e3fd0004 setl \$253,0x4
--- /dev/null
+#source: start.s
+#source: a.s
+#source: pad2p26m32.s
+#source: pad16.s
+#source: pad4.s
+#source: pad4.s
+#source: pad4.s
+#source: jumpa.s
+#as: -no-expand
+#ld: -m elf64mmix
+#error: relocation truncated to fit: R_MMIX_ADDR27 a$
--- /dev/null
+#source: start.s
+#source: jumpa.s
+#source: pad2p26m32.s
+#source: pad16.s
+#source: pad4.s
+#source: pad4.s
+#source: a.s
+#as: -no-expand
+#ld: -m elf64mmix
+#error: relocation truncated to fit: R_MMIX_ADDR27 a$
--- /dev/null
+#source: start.s
+#source: a.s
+#source: jumpa.s
+#as: -x
+#ld: -m mmo
+#objdump: -dr
+
+.*: file format mmo
+
+Disassembly of section \.text:
+
+0+ <(Main|_start)>:
+ 0: e3fd0001 setl \$253,0x1
+
+0+4 <a>:
+ 4: e3fd0004 setl \$253,0x4
+
+0+8 <jumpa>:
+ 8: e3fd0002 setl \$253,0x2
+ c: f1fffffe jmp 4 <a>
+ 10: fd000000 swym 0,0,0
+ 14: fd000000 swym 0,0,0
+ 18: fd000000 swym 0,0,0
+ 1c: fd000000 swym 0,0,0
+ 20: e3fd0003 setl \$253,0x3
--- /dev/null
+#source: start.s
+#source: jumpa.s
+#source: a.s
+#as: -x
+#ld: -m mmo
+#objdump: -dr
+
+.*: file format mmo
+
+Disassembly of section \.text:
+
+0+ <(Main|_start)>:
+ 0: e3fd0001 setl \$253,0x1
+
+0+4 <jumpa>:
+ 4: e3fd0002 setl \$253,0x2
+ 8: f0000006 jmp 20 <a>
+ c: fd000000 swym 0,0,0
+ 10: fd000000 swym 0,0,0
+ 14: fd000000 swym 0,0,0
+ 18: fd000000 swym 0,0,0
+ 1c: e3fd0003 setl \$253,0x3
+
+0+20 <a>:
+ 20: e3fd0004 setl \$253,0x4
--- /dev/null
+#source: start.s
+#source: a.s
+#source: jumpa.s
+#as: -no-expand
+#ld: -m mmo
+#objdump: -dr
+
+.*: file format mmo
+
+Disassembly of section \.text:
+
+0+ <(Main|_start)>:
+ 0: e3fd0001 setl \$253,0x1
+
+0+4 <a>:
+ 4: e3fd0004 setl \$253,0x4
+
+0+8 <jumpa>:
+ 8: e3fd0002 setl \$253,0x2
+ c: f1fffffe jmp 4 <a>
+ 10: e3fd0003 setl \$253,0x3
--- /dev/null
+#source: start.s
+#source: jumpa.s
+#source: a.s
+#as: -no-expand
+#ld: -m mmo
+#objdump: -dr
+
+.*: file format mmo
+
+Disassembly of section \.text:
+
+0+ <(Main|_start)>:
+ 0: e3fd0001 setl \$253,0x1
+
+0+4 <jumpa>:
+ 4: e3fd0002 setl \$253,0x2
+ 8: f0000002 jmp 10 <a>
+ c: e3fd0003 setl \$253,0x3
+
+0+10 <a>:
+ 10: e3fd0004 setl \$253,0x4
--- /dev/null
+#source: start.s
+#source: a.s
+#source: pad2p26m32.s
+#source: pad16.s
+#source: pad4.s
+#source: pad4.s
+#source: jumpa.s
+#as: -x
+#ld: -m mmo
+#objdump: -dr
+
+.*: file format mmo
+
+Disassembly of section \.text:
+
+0+ <(Main|_start)>:
+ 0: e3fd0001 setl \$253,0x1
+
+0+4 <a>:
+ 4: e3fd0004 setl \$253,0x4
+ \.\.\.
+
+0+4000000 <jumpa>:
+ 4000000: e3fd0002 setl \$253,0x2
+ 4000004: f1000000 jmp 4 <a>
+ 4000008: fd000000 swym 0,0,0
+ 400000c: fd000000 swym 0,0,0
+ 4000010: fd000000 swym 0,0,0
+ 4000014: fd000000 swym 0,0,0
+ 4000018: e3fd0003 setl \$253,0x3
--- /dev/null
+#source: start.s
+#source: jumpa.s
+#source: pad2p26m32.s
+#source: pad4.s
+#source: a.s
+#as: -x
+#ld: -m mmo
+#objdump: -dr
+
+.*: file format mmo
+
+Disassembly of section \.text:
+
+0+ <(Main|_start)>:
+ 0: e3fd0001 setl \$253,0x1
+
+0+4 <jumpa>:
+ 4: e3fd0002 setl \$253,0x2
+ 8: f0ffffff jmp 4000004 <a>
+ c: fd000000 swym 0,0,0
+ 10: fd000000 swym 0,0,0
+ 14: fd000000 swym 0,0,0
+ 18: fd000000 swym 0,0,0
+ 1c: e3fd0003 setl \$253,0x3
+ \.\.\.
+
+0+4000004 <a>:
+ 4000004: e3fd0004 setl \$253,0x4
--- /dev/null
+* Just jump to an external symbol, with some padding.
+ .text
+ .global jumpa
+jumpa:
+ SET $253,2
+ JMP a
+ SET $253,3
--- /dev/null
+#source: start.s
+#source: a.s
+#source: pad2p26m32.s
+#source: pad16.s
+#source: pad4.s
+#source: pad4.s
+#source: jumpa.s
+#as: -no-expand
+#ld: -m mmo
+#objdump: -dr
+
+.*: file format mmo
+
+Disassembly of section \.text:
+
+0+ <(Main|_start)>:
+ 0: e3fd0001 setl \$253,0x1
+
+0+4 <a>:
+ 4: e3fd0004 setl \$253,0x4
+ \.\.\.
+
+0+4000000 <jumpa>:
+ 4000000: e3fd0002 setl \$253,0x2
+ 4000004: f1000000 jmp 4 <a>
+ 4000008: e3fd0003 setl \$253,0x3
--- /dev/null
+#source: start.s
+#source: jumpa.s
+#source: pad2p26m32.s
+#source: pad16.s
+#source: pad4.s
+#source: a.s
+#as: -no-expand
+#ld: -m mmo
+#objdump: -dr
+
+.*: file format mmo
+
+Disassembly of section \.text:
+
+0+ <(Main|_start)>:
+ 0: e3fd0001 setl \$253,0x1
+
+0+4 <jumpa>:
+ 4: e3fd0002 setl \$253,0x2
+ 8: f0ffffff jmp 4000004 <a>
+ c: e3fd0003 setl \$253,0x3
+ \.\.\.
+
+0+4000004 <a>:
+ 4000004: e3fd0004 setl \$253,0x4
--- /dev/null
+#source: start.s
+#source: a.s
+#source: pad2p26m32.s
+#source: pad16.s
+#source: pad4.s
+#source: pad4.s
+#source: pad4.s
+#source: jumpa.s
+#as: -x
+#ld: -m mmo
+#objdump: -dr
+
+.*: file format mmo
+
+Disassembly of section \.text:
+
+0+ <(Main|_start)>:
+ 0: e3fd0001 setl \$253,0x1
+
+0+4 <a>:
+ 4: e3fd0004 setl \$253,0x4
+ \.\.\.
+
+0+4000004 <jumpa>:
+ 4000004: e3fd0002 setl \$253,0x2
+ 4000008: e3ff0004 setl \$255,0x4
+ 400000c: e6ff0000 incml \$255,0x0
+ 4000010: e5ff0000 incmh \$255,0x0
+ 4000014: e4ff0000 inch \$255,0x0
+ 4000018: 9fffff00 go \$255,\$255,0
+ 400001c: e3fd0003 setl \$253,0x3
--- /dev/null
+#source: start.s
+#source: jumpa.s
+#source: pad2p26m32.s
+#source: pad4.s
+#source: pad4.s
+#source: a.s
+#as: -x
+#ld: -m mmo
+#objdump: -dr
+
+.*: file format mmo
+
+Disassembly of section \.text:
+
+0+ <(Main|_start)>:
+ 0: e3fd0001 setl \$253,0x1
+
+0+4 <jumpa>:
+ 4: e3fd0002 setl \$253,0x2
+ 8: e3ff0008 setl \$255,0x8
+ c: e6ff0400 incml \$255,0x400
+ 10: e5ff0000 incmh \$255,0x0
+ 14: e4ff0000 inch \$255,0x0
+ 18: 9fffff00 go \$255,\$255,0
+ 1c: e3fd0003 setl \$253,0x3
+ \.\.\.
+
+0+4000008 <a>:
+ 4000008: e3fd0004 setl \$253,0x4
--- /dev/null
+#source: start.s
+#source: a.s
+#source: pad2p26m32.s
+#source: pad16.s
+#source: pad4.s
+#source: pad4.s
+#source: pad4.s
+#source: jumpa.s
+#as: -no-expand
+#ld: -m mmo
+#error: relocation truncated to fit: R_MMIX_ADDR27 a$
--- /dev/null
+#source: start.s
+#source: jumpa.s
+#source: pad2p26m32.s
+#source: pad16.s
+#source: pad4.s
+#source: pad4.s
+#source: a.s
+#as: -no-expand
+#ld: -m mmo
+#error: relocation truncated to fit: R_MMIX_ADDR27 a$
--- /dev/null
+#source: loc1.s
+#ld: -e loc1 -m elf64mmix
+#objdump: -str
+
+# Single text file.
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+1000 l d \.text 0+
+2000000000000000 l d \.data 0+
+2000000000000000 l d \.sbss 0+
+2000000000000000 l d \.bss 0+
+0+ l d \*ABS\* 0+
+0+ l d \*ABS\* 0+
+0+ l d \*ABS\* 0+
+0+1000 g \.text 0+ loc1
+0+1000 g \*ABS\* 0+ __\.MMIX\.start\.\.text
+2000000000000000 g O \*ABS\* 0+ __bss_start
+2000000000000000 g O \*ABS\* 0+ _edata
+2000000000000000 g O \*ABS\* 0+ _end
+0+1000 g O \.text 0+ _start\.
+
+
+Contents of section \.text:
+ 1000 fd030303 .*
+Contents of section \.data:
+Contents of section \.sbss:
--- /dev/null
+ LOC #1000
+loc1 SWYM 3,3,3
+ .global loc1
+
--- /dev/null
+#source: loc1.s
+#ld: -m mmo -e loc1
+#objdump: -str
+
+# err: two locs.
+
+.*: file format mmo
+
+SYMBOL TABLE:
+0+1000 g \.text Main
+0+1000 g \.text loc1
+
+Contents of section \.text:
+ 1000 fd030303 .*
--- /dev/null
+#source: loc1.s
+#source: start.s
+#ld: -m elf64mmix
+#objdump: -str
+
+# Two text files.
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+1000 l d \.text 0+
+2000000000000000 l d \.data 0+
+2000000000000000 l d \.sbss 0+
+2000000000000000 l d \.bss 0+
+0+ l d \*ABS\* 0+
+0+ l d \*ABS\* 0+
+0+ l d \*ABS\* 0+
+0+1004 g \.text 0+ _start
+0+1000 g \.text 0+ loc1
+0+1000 g \*ABS\* 0+ __\.MMIX\.start\.\.text
+2000000000000000 g O \*ABS\* 0+ __bss_start
+2000000000000000 g O \*ABS\* 0+ _edata
+2000000000000000 g O \*ABS\* 0+ _end
+0+1004 g O \.text 0+ _start\.
+
+Contents of section \.text:
+ 1000 fd030303 e3fd0001 .*
+Contents of section \.data:
+Contents of section .sbss:
--- /dev/null
+ LOC #2000
+loc2 SWYM 3,2,3
+ .global loc2
+
--- /dev/null
+#source: loc1.s
+#source: start.s
+#ld: -m mmo
+#objdump: -str
+
+.*: file format mmo
+
+SYMBOL TABLE:
+0+1004 g \.text Main
+0+1004 g \.text _start
+0+1000 g \.text loc1
+
+Contents of section \.text:
+ 1000 fd030303 e3fd0001 .*
--- /dev/null
+#source: start.s
+#source: loc1.s
+#ld: -m elf64mmix
+#objdump: -str
+
+# Two text files in opposite order.
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+1000 l d \.text 0+
+2000000000000000 l d \.data 0+
+2000000000000000 l d \.sbss 0+
+2000000000000000 l d \.bss 0+
+0+ l d \*ABS\* 0+
+0+ l d \*ABS\* 0+
+0+ l d \*ABS\* 0+
+0+1000 g \.text 0+ _start
+0+1004 g \.text 0+ loc1
+0+1000 g \*ABS\* 0+ __\.MMIX\.start\.\.text
+2000000000000000 g O \*ABS\* 0+ __bss_start
+2000000000000000 g O \*ABS\* 0+ _edata
+2000000000000000 g O \*ABS\* 0+ _end
+0+1000 g O \.text 0+ _start\.
+
+Contents of section \.text:
+ 1000 e3fd0001 fd030303 .*
+Contents of section \.data:
+Contents of section \.sbss:
--- /dev/null
+#source: start.s
+#source: loc1.s
+#ld: -m mmo
+#objdump: -str
+
+.*: file format mmo
+
+SYMBOL TABLE:
+0+1000 g \.text Main
+0+1000 g \.text _start
+0+1004 g \.text loc1
+
+Contents of section \.text:
+ 1000 e3fd0001 fd030303 .*
--- /dev/null
+#source: loc1.s
+#source: data1.s
+#source: start.s
+#ld: -m elf64mmix
+#objdump: -str
+
+# Two text files and one data.
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+1000 l d \.text 0+
+2000000000000000 l d \.data 0+
+2000000000000008 l d \.sbss 0+
+2000000000000008 l d \.bss 0+
+0+ l d \*ABS\* 0+
+0+ l d \*ABS\* 0+
+0+ l d \*ABS\* 0+
+2000000000000000 l \.data 0+ xx
+0+1004 g F \.text 0+ Main
+2000000000000000 g \*ABS\* 0+ __\.MMIX\.start\.\.data
+0+1004 g \.text 0+ _start
+0+1000 g \.text 0+ loc1
+0+1000 g \*ABS\* 0+ __\.MMIX\.start\.\.text
+2000000000000008 g O \*ABS\* 0+ __bss_start
+2000000000000008 g O \*ABS\* 0+ _edata
+2000000000000008 g O \*ABS\* 0+ _end
+0+1004 g O \.text 0+ _start\.
+
+
+Contents of section \.text:
+ 1000 fd030303 e3fd0001 .*
+Contents of section \.data:
+ 0000 00000000 00001030 .*
+Contents of section \.sbss:
--- /dev/null
+#source: loc1.s
+#source: data1.s
+#source: start.s
+#ld: -m mmo
+#objdump: -str
+
+.*: file format mmo
+
+SYMBOL TABLE:
+0+1004 g \.text Main
+0+1004 g \.text _start
+0+1000 g \.text loc1
+
+Contents of section \.text:
+ 1000 fd030303 e3fd0001 .*
+Contents of section \.data:
+ 0004 00001030 .*
+
--- /dev/null
+#source: loc1.s
+#source: start.s
+#source: loc2.s
+#ld: -m elf64mmix
+#objdump: -str
+#error: multiple definition of `__\.MMIX\.start\.\.text'
--- /dev/null
+#source: loc1.s
+#source: start.s
+#source: loc2.s
+#ld: -m mmo
+#objdump: -str
+#error: multiple definition of `__\.MMIX\.start\.\.text'
--- /dev/null
+#source: dloc1.s
+#source: start.s
+#ld: -m elf64mmix
+#objdump: -str
+
+# Text files and one loc:ed data at offset.
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+ l d \.text 0+
+2000000000000200 l d \.data 0+
+200000000000020c l d \.sbss 0+
+200000000000020c l d \.bss 0+
+0+ l d \*ABS\* 0+
+0+ l d \*ABS\* 0+
+0+ l d \*ABS\* 0+
+2000000000000200 g \.data 0+ dloc1
+2000000000000200 g \*ABS\* 0+ __\.MMIX\.start\.\.data
+0+ g \.text 0+ _start
+200000000000020c g O \*ABS\* 0+ __bss_start
+200000000000020c g O \*ABS\* 0+ _edata
+2000000000000210 g O \*ABS\* 0+ _end
+0+ g O \.text 0+ _start\.
+
+Contents of section \.text:
+ 0000 e3fd0001 .*
+Contents of section \.data:
+ 0200 00000004 00000005 00000006 .*
+Contents of section \.sbss:
--- /dev/null
+#source: dloc1.s
+#source: start.s
+#ld: -m mmo
+#objdump: -str
+
+# Text files and one loc:ed data at offset.
+
+.*: file format mmo
+
+SYMBOL TABLE:
+0+ g \.text Main
+2000000000000200 g \.data dloc1
+0+ g \.text _start
+
+Contents of section \.text:
+ 0000 e3fd0001 .*
+Contents of section \.data:
+ 0200 00000004 00000005 00000006 .*
+
--- /dev/null
+#source: dloc1.s
+#source: start.s
+#source: dloc2.s
+#ld: -m elf64mmix
+#objdump: -str
+#error: multiple definition of `__\.MMIX\.start\.\.data'
--- /dev/null
+#source: dloc1.s
+#source: start.s
+#source: dloc2.s
+#ld: -m mmo
+#objdump: -str
+#error: multiple definition of `__\.MMIX\.start\.\.data'
--- /dev/null
+#source: greg-4.s
+#source: greg-4.s
+#source: local1.s
+#source: regext1.s
+#source: start.s
+#ld: -m elf64mmix
+#readelf: -Ssx1 -x5
+
+# We check that the externally visible symbol ext1 is a local register
+# (different meaning of "local" than for symbol), which can be seen as
+# somewhat twisted.
+
+There are 9 section headers, starting at offset 0x110:
+
+Section Headers:
+ \[Nr\] Name Type Address Offset
+ Size EntSize Flags Link Info Align
+ \[ 0\] NULL 0+ 0+
+ 0+ 0+ 0 0 0
+ \[ 1\] \.text PROGBITS 0+ 0+b0
+ 0+8 0+ AX 0 0 4
+ \[ 2\] \.data PROGBITS 2000000000000000 0+b8
+ 0+ 0+ WA 0 0 1
+ \[ 3\] \.sbss PROGBITS 2000000000000000 0+b8
+ 0+ 0+ W 0 0 1
+ \[ 4\] \.bss NOBITS 2000000000000000 0+b8
+ 0+ 0+ WA 0 0 1
+ \[ 5\] \.MMIX\.reg_content PROGBITS 0+7e8 0+b8
+ 0+10 0+ W 0 0 1
+ \[ 6\] \.shstrtab STRTAB 0+ 0+c8
+ 0+45 0+ 0 0 1
+ \[ 7\] \.symtab SYMTAB 0+ 0+350
+ 0+198 0+18 8 b 8
+ \[ 8\] \.strtab STRTAB 0+ 0+4e8
+ 0+32 0+ 0 0 1
+Key to Flags:
+ W \(write\), A \(alloc\), X \(execute\), M \(merge\), S \(strings\)
+ I \(info\), L \(link order\), G \(group\), x \(unknown\)
+ O \(extra OS processing required\) o \(OS specific\), p \(processor specific\)
+
+Symbol table '\.symtab' contains 17 entries:
+ Num: Value Size Type Bind Vis Ndx Name
+ 0: 0+ 0 NOTYPE LOCAL DEFAULT UND
+ 1: 0+ 0 SECTION LOCAL DEFAULT 1
+ 2: 20+ 0 SECTION LOCAL DEFAULT 2
+ 3: 2000000000000000 0 SECTION LOCAL DEFAULT 3
+ 4: 2000000000000000 0 SECTION LOCAL DEFAULT 4
+ 5: 0+7e8 0 SECTION LOCAL DEFAULT 5
+ 6: 0+ 0 SECTION LOCAL DEFAULT 6
+ 7: 0+ 0 SECTION LOCAL DEFAULT 7
+ 8: 0+ 0 SECTION LOCAL DEFAULT 8
+ 9: 0+fd 0 NOTYPE LOCAL DEFAULT PRC lsym
+ 10: 0+fe 0 NOTYPE LOCAL DEFAULT PRC lsym
+ 11: 0+fc 0 NOTYPE GLOBAL DEFAULT PRC ext1
+ 12: 0+4 0 NOTYPE GLOBAL DEFAULT 1 _start
+ 13: 2000000000000000 0 OBJECT GLOBAL DEFAULT ABS __bss_start
+ 14: 2000000000000000 0 OBJECT GLOBAL DEFAULT ABS _edata
+ 15: 2000000000000000 0 OBJECT GLOBAL DEFAULT ABS _end
+ 16: 0+4 0 OBJECT GLOBAL DEFAULT 1 _start\.
+
+Hex dump of section '\.text':
+ 0x0+ fd030201 e3fd0001 .*
+
+Hex dump of section '\.MMIX\.reg_contents':
+ 0x0+7e8 00000000 0000004e 00000000 0000004e .*
--- /dev/null
+ LOCAL ext1
+ SWYM 3,2,1
--- /dev/null
+#source: local1.s
+#source: ext1g.s
+#source: start.s
+#ld: -m elf64mmix
+#error: 254 is not a local register
--- /dev/null
+#source: local1.s
+#source: ext1g.s
+#source: start.s
+#ld: -m mmo
+#error: 254 is not a local register
--- /dev/null
+#source: local1.s
+#source: greg-1.s
+#source: ext1l.s
+#source: start.s
+#ld: -m elf64mmix
+#error: valid only with a register or absolute value
--- /dev/null
+#source: local1.s
+#source: greg-1.s
+#source: ext1l.s
+#source: start.s
+#ld: -m mmo
+#error: valid only with a register or absolute value
--- /dev/null
+#source: local1.s
+#source: ext1-254.s
+#source: start.s
+#ld: -m elf64mmix
+#objdump: -shr
+
+# Check that 254 is local when we don't have any registers.
+
+.*: file format elf64-mmix
+
+Sections:
+Idx Name Size VMA LMA File off Algn
+ 0 \.text 0+8 0+ 0+ 0+b0 2\*\*2
+ CONTENTS, ALLOC, LOAD, READONLY, CODE
+ 1 \.data 0+ 2000000000000000 2000000000000000 0+b8 2\*\*0
+ CONTENTS, ALLOC, LOAD, DATA
+ 2 \.sbss 0+ 2000000000000000 2000000000000000 0+b8 2\*\*0
+ CONTENTS
+ 3 \.bss 0+ 2000000000000000 2000000000000000 0+b8 2\*\*0
+ ALLOC
+Contents of section \.text:
+ 0000 fd030201 e3fd0001 .*
+Contents of section \.data:
+Contents of section \.sbss:
--- /dev/null
+#source: local1.s
+#source: ext1-254.s
+#source: start.s
+#ld: -m mmo
+#objdump: -shr
+
+# Check that 254 is local when we don't have any registers.
+
+.*: file format mmo
+
+Sections:
+Idx Name Size VMA LMA File off Algn
+ 0 \.text 0+8 0+ 0+ 0+ 2\*\*2
+ CONTENTS, ALLOC, LOAD, CODE
+Contents of section \.text:
+ 0000 fd030201 e3fd0001 .*
--- /dev/null
+#source: greg-4.s
+#source: greg-4.s
+#source: local1.s
+#source: regext1.s
+#source: start.s
+#ld: -m mmo
+#objdump: -str
+
+.*: file format mmo
+
+SYMBOL TABLE:
+0+4 g \.text Main
+0+fc g \*REG\* ext1
+0+4 g \.text _start
+
+
+Contents of section \.text:
+ 0000 fd030201 e3fd0001 .*
+Contents of section \.MMIX\.reg_contents:
+ 07e8 00000000 0000004e 00000000 0000004e .*
+
--- /dev/null
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: local1.s
+#source: regext1.s
+#source: start.s
+#ld: -m elf64mmix
+#error: not a local register
--- /dev/null
+ LOCAL 128
+ SWYM 2,2,2
--- /dev/null
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: local1.s
+#source: regext1.s
+#source: start.s
+#ld: -m mmo
+#error: not a local register
--- /dev/null
+#source: greg-4.s
+#source: greg-4.s
+#source: local1.s
+#source: ext1.s
+#source: start.s
+#ld: -m elf64mmix
+#readelf: -Ssx1 -x5
+
+# Like local1, but ext1 is here a constant, not a global register.
+
+There are 9 section headers, starting at offset 0x110:
+
+Section Headers:
+ \[Nr\] Name Type Address Offset
+ Size EntSize Flags Link Info Align
+ \[ 0\] NULL 0+ 0+
+ 0+ 0+ 0 0 0
+ \[ 1\] \.text PROGBITS 0+ 0+b0
+ 0+8 0+ AX 0 0 4
+ \[ 2\] \.data PROGBITS 2000000000000000 0+b8
+ 0+ 0+ WA 0 0 1
+ \[ 3\] \.sbss PROGBITS 2000000000000000 0+b8
+ 0+ 0+ W 0 0 1
+ \[ 4\] \.bss NOBITS 2000000000000000 0+b8
+ 0+ 0+ WA 0 0 1
+ \[ 5\] \.MMIX\.reg_content PROGBITS 0+7e8 0+b8
+ 0+10 0+ W 0 0 1
+ \[ 6\] \.shstrtab STRTAB 0+ 0+c8
+ 0+45 0+ 0 0 1
+ \[ 7\] \.symtab SYMTAB 0+ 0+350
+ 0+198 0+18 8 b 8
+ \[ 8\] \.strtab STRTAB 0+ 0+4e8
+ 0+32 0+ 0 0 1
+Key to Flags:
+ W \(write\), A \(alloc\), X \(execute\), M \(merge\), S \(strings\)
+ I \(info\), L \(link order\), G \(group\), x \(unknown\)
+ O \(extra OS processing required\) o \(OS specific\), p \(processor specific\)
+
+Symbol table '\.symtab' contains 17 entries:
+ Num: Value Size Type Bind Vis Ndx Name
+ 0: 0+ 0 NOTYPE LOCAL DEFAULT UND
+ 1: 0+ 0 SECTION LOCAL DEFAULT 1
+ 2: 2000000000000000 0 SECTION LOCAL DEFAULT 2
+ 3: 2000000000000000 0 SECTION LOCAL DEFAULT 3
+ 4: 2000000000000000 0 SECTION LOCAL DEFAULT 4
+ 5: 0+7e8 0 SECTION LOCAL DEFAULT 5
+ 6: 0+ 0 SECTION LOCAL DEFAULT 6
+ 7: 0+ 0 SECTION LOCAL DEFAULT 7
+ 8: 0+ 0 SECTION LOCAL DEFAULT 8
+ 9: 0+fd 0 NOTYPE LOCAL DEFAULT PRC lsym
+ 10: 0+fe 0 NOTYPE LOCAL DEFAULT PRC lsym
+ 11: 0+fc 0 NOTYPE GLOBAL DEFAULT ABS ext1
+ 12: 0+4 0 NOTYPE GLOBAL DEFAULT 1 _start
+ 13: 2000000000000000 0 OBJECT GLOBAL DEFAULT ABS __bss_start
+ 14: 2000000000000000 0 OBJECT GLOBAL DEFAULT ABS _edata
+ 15: 2000000000000000 0 OBJECT GLOBAL DEFAULT ABS _end
+ 16: 0+4 0 OBJECT GLOBAL DEFAULT 1 _start\.
+
+Hex dump of section '\.text':
+ 0x0+ fd030201 e3fd0001 .*
+
+Hex dump of section '\.MMIX\.reg_contents':
+ 0x0+7e8 00000000 0000004e 00000000 0000004e .*
--- /dev/null
+#source: greg-4.s
+#source: greg-4.s
+#source: local1.s
+#source: ext1.s
+#source: start.s
+#ld: -m mmo
+#objdump: -str
+
+.*: file format mmo
+
+SYMBOL TABLE:
+0+4 g \.text Main
+0+fc g \*ABS\* ext1
+0+4 g \.text _start
+
+
+Contents of section \.text:
+ 0000 fd030201 e3fd0001 .*
+Contents of section \.MMIX\.reg_contents:
+ 07e8 00000000 0000004e 00000000 0000004e .*
+
--- /dev/null
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: local1.s
+#source: ext1.s
+#source: start.s
+#ld: -m elf64mmix
+#error: not a local register
--- /dev/null
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: local1.s
+#source: ext1.s
+#source: start.s
+#ld: -m mmo
+#error: is not a local register
--- /dev/null
+#source: greg-4.s
+#source: greg-4.s
+#source: local2.s
+#source: local1.s
+#source: regext1.s
+#source: start.s
+#ld: -m elf64mmix
+#readelf: -Ssx1 -x5
+
+# Like local1, but with two checks for a local register.
+
+There are 9 section headers, starting at offset 0x118:
+
+Section Headers:
+ \[Nr\] Name Type Address Offset
+ Size EntSize Flags Link Info Align
+ \[ 0\] NULL 0+ 0+
+ 0+ 0+ 0 0 0
+ \[ 1\] \.text PROGBITS 0+ 0+b0
+ 0+c 0+ AX 0 0 4
+ \[ 2\] \.data PROGBITS 2000000000000000 0+bc
+ 0+ 0+ WA 0 0 1
+ \[ 3\] \.sbss PROGBITS 2000000000000000 0+bc
+ 0+ 0+ W 0 0 1
+ \[ 4\] \.bss NOBITS 2000000000000000 0+bc
+ 0+ 0+ WA 0 0 1
+ \[ 5\] \.MMIX\.reg_content PROGBITS 0+7e8 0+bc
+ 0+10 0+ W 0 0 1
+ \[ 6\] \.shstrtab STRTAB 0+ 0+cc
+ 0+45 0+ 0 0 1
+ \[ 7\] \.symtab SYMTAB 0+ 0+358
+ 0+198 0+18 8 b 8
+ \[ 8\] \.strtab STRTAB 0+ 0+4f0
+ 0+32 0+ 0 0 1
+Key to Flags:
+ W \(write\), A \(alloc\), X \(execute\), M \(merge\), S \(strings\)
+ I \(info\), L \(link order\), G \(group\), x \(unknown\)
+ O \(extra OS processing required\) o \(OS specific\), p \(processor specific\)
+
+Symbol table '\.symtab' contains 17 entries:
+ Num: Value Size Type Bind Vis Ndx Name
+ 0: 0+ 0 NOTYPE LOCAL DEFAULT UND
+ 1: 0+ 0 SECTION LOCAL DEFAULT 1
+ 2: 2000000000000000 0 SECTION LOCAL DEFAULT 2
+ 3: 2000000000000000 0 SECTION LOCAL DEFAULT 3
+ 4: 2000000000000000 0 SECTION LOCAL DEFAULT 4
+ 5: 0+7e8 0 SECTION LOCAL DEFAULT 5
+ 6: 0+ 0 SECTION LOCAL DEFAULT 6
+ 7: 0+ 0 SECTION LOCAL DEFAULT 7
+ 8: 0+ 0 SECTION LOCAL DEFAULT 8
+ 9: 0+fd 0 NOTYPE LOCAL DEFAULT PRC lsym
+ 10: 0+fe 0 NOTYPE LOCAL DEFAULT PRC lsym
+ 11: 0+fc 0 NOTYPE GLOBAL DEFAULT PRC ext1
+ 12: 0+8 0 NOTYPE GLOBAL DEFAULT 1 _start
+ 13: 2000000000000000 0 OBJECT GLOBAL DEFAULT ABS __bss_start
+ 14: 2000000000000000 0 OBJECT GLOBAL DEFAULT ABS _edata
+ 15: 2000000000000000 0 OBJECT GLOBAL DEFAULT ABS _end
+ 16: 0+8 0 OBJECT GLOBAL DEFAULT 1 _start\.
+
+Hex dump of section '\.text':
+ 0x0+ fd020202 fd030201 e3fd0001 .*
+
+Hex dump of section '\.MMIX\.reg_contents':
+ 0x0+7e8 00000000 0000004e 00000000 0000004e .*
--- /dev/null
+#source: greg-4.s
+#source: greg-4.s
+#source: local2.s
+#source: local1.s
+#source: regext1.s
+#source: start.s
+#ld: -m mmo
+#objdump: -str
+
+.*: file format mmo
+
+SYMBOL TABLE:
+0+8 g \.text Main
+0+fc g \*REG\* ext1
+0+8 g \.text _start
+
+
+Contents of section \.text:
+ 0000 fd020202 fd030201 e3fd0001 .*
+Contents of section \.MMIX\.reg_contents:
+ 07e8 00000000 0000004e 00000000 0000004e .*
--- /dev/null
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: local1.s
+#source: local2.s
+#source: ext1.s
+#source: start.s
+#ld: -m elf64mmix
+#error: not a local register
--- /dev/null
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: local1.s
+#source: local2.s
+#source: ext1.s
+#source: start.s
+#ld: -m mmo
+#error: not a local register
--- /dev/null
+#source: greg-4.s
+#source: greg-4.s
+#source: local1.s
+#source: local2.s
+#source: ext1.s
+#source: start.s
+#ld: -m elf64mmix
+#readelf: -Ssx1 -x5
+
+# Like local1, but ext1 is here a constant, not a global register and two
+# local-register checks.
+
+There are 9 section headers, starting at offset 0x118:
+
+Section Headers:
+ \[Nr\] Name Type Address Offset
+ Size EntSize Flags Link Info Align
+ \[ 0\] NULL 0+ 0+
+ 0+ 0+ 0 0 0
+ \[ 1\] \.text PROGBITS 0+ 0+b0
+ 0+c 0+ AX 0 0 4
+ \[ 2\] \.data PROGBITS 2000000000000000 0+bc
+ 0+ 0+ WA 0 0 1
+ \[ 3\] \.sbss PROGBITS 2000000000000000 0+bc
+ 0+ 0+ W 0 0 1
+ \[ 4\] \.bss NOBITS 2000000000000000 0+bc
+ 0+ 0+ WA 0 0 1
+ \[ 5\] \.MMIX\.reg_content PROGBITS 0+7e8 0+bc
+ 0+10 0+ W 0 0 1
+ \[ 6\] \.shstrtab STRTAB 0+ 0+cc
+ 0+45 0+ 0 0 1
+ \[ 7\] \.symtab SYMTAB 0+ 0+358
+ 0+198 0+18 8 b 8
+ \[ 8\] \.strtab STRTAB 0+ 0+4f0
+ 0+32 0+ 0 0 1
+Key to Flags:
+ W \(write\), A \(alloc\), X \(execute\), M \(merge\), S \(strings\)
+ I \(info\), L \(link order\), G \(group\), x \(unknown\)
+ O \(extra OS processing required\) o \(OS specific\), p \(processor specific\)
+
+Symbol table '\.symtab' contains 17 entries:
+ Num: Value Size Type Bind Vis Ndx Name
+ 0: 0+ 0 NOTYPE LOCAL DEFAULT UND
+ 1: 0+ 0 SECTION LOCAL DEFAULT 1
+ 2: 2000000000000000 0 SECTION LOCAL DEFAULT 2
+ 3: 2000000000000000 0 SECTION LOCAL DEFAULT 3
+ 4: 2000000000000000 0 SECTION LOCAL DEFAULT 4
+ 5: 0+7e8 0 SECTION LOCAL DEFAULT 5
+ 6: 0+ 0 SECTION LOCAL DEFAULT 6
+ 7: 0+ 0 SECTION LOCAL DEFAULT 7
+ 8: 0+ 0 SECTION LOCAL DEFAULT 8
+ 9: 0+fd 0 NOTYPE LOCAL DEFAULT PRC lsym
+ 10: 0+fe 0 NOTYPE LOCAL DEFAULT PRC lsym
+ 11: 0+fc 0 NOTYPE GLOBAL DEFAULT ABS ext1
+ 12: 0+8 0 NOTYPE GLOBAL DEFAULT 1 _start
+ 13: 2000000000000000 0 OBJECT GLOBAL DEFAULT ABS __bss_start
+ 14: 2000000000000000 0 OBJECT GLOBAL DEFAULT ABS _edata
+ 15: 2000000000000000 0 OBJECT GLOBAL DEFAULT ABS _end
+ 16: 0+8 0 OBJECT GLOBAL DEFAULT 1 _start\.
+
+Hex dump of section '\.text':
+ 0x0+ fd030201 fd020202 e3fd0001 .*
+
+Hex dump of section '\.MMIX\.reg_contents':
+ 0x0+7e8 00000000 0000004e 00000000 0000004e .*
--- /dev/null
+#source: greg-4.s
+#source: greg-4.s
+#source: local1.s
+#source: local2.s
+#source: ext1.s
+#source: start.s
+#ld: -m mmo
+#objdump: -str
+
+.*: file format mmo
+
+SYMBOL TABLE:
+0+8 g \.text Main
+0+fc g \*ABS\* ext1
+0+8 g \.text _start
+
+
+Contents of section \.text:
+ 0000 fd030201 fd020202 e3fd0001 .*
+Contents of section \.MMIX\.reg_contents:
+ 07e8 00000000 0000004e 00000000 0000004e .*
--- /dev/null
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: local2.s
+#source: local1.s
+#source: ext1.s
+#source: start.s
+#ld: -m elf64mmix
+#error: 128 is not a local register
--- /dev/null
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-5.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: greg-4.s
+#source: local2.s
+#source: local1.s
+#source: ext1.s
+#source: start.s
+#ld: -m mmo
+#error: 128 is not a local register
--- /dev/null
+#source: local1.s
+#source: ext1l.s
+#source: start.s
+#ld: -m elf64mmix
+#error: valid only with a register or absolute value
--- /dev/null
+#source: local1.s
+#source: ext1l.s
+#source: start.s
+#ld: -m mmo
+#error: valid only with a register or absolute value
--- /dev/null
+#source: locdo.s -globalize-symbols
+#source: start.s
+#ld: -m elf64mmix
+#objdump: -str
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+ l d \.text 0+
+2000000000000008 l d \.data 0+
+2000000000000010 l d \.sbss 0+
+2000000000000010 l d \.bss 0+
+0+ l d \*ABS\* 0+
+0+ l d \*ABS\* 0+
+0+ l d \*ABS\* 0+
+2000000000000008 g \*ABS\* 0+ __\.MMIX\.start\.\.data
+2000000000000008 g \.data 0+ od
+0+ g \.text 0+ _start
+2000000000000010 g O \*ABS\* 0+ __bss_start
+2000000000000000 g \*ABS\* 0+ Data_Segment
+2000000000000010 g O \*ABS\* 0+ _edata
+2000000000000010 g O \*ABS\* 0+ _end
+0+ g O \.text 0+ _start\.
+
+Contents of section \.text:
+ 0000 e3fd0001 \.\.\.\.
+Contents of section \.data:
+ 0008 20000000 00000008 \.\.\.\.\.\.\.
+Contents of section \.sbss:
--- /dev/null
+ LOC Data_Segment+2
+od OCTA od
--- /dev/null
+#source: loct.s
+#source: start.s
+#ld: -m elf64mmix
+#objdump: -str
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+1004 l d \.text 0+
+2000000000000000 l d \.data 0+
+2000000000000000 l d \.sbss 0+
+2000000000000000 l d \.bss 0+
+0+ l d \*ABS\* 0+
+0+ l d \*ABS\* 0+
+0+ l d \*ABS\* 0+
+0+1004 l \.text 0+ t
+0+100c g \.text 0+ _start
+0+1004 g \*ABS\* 0+ __\.MMIX\.start\.\.text
+2000000000000000 g O \*ABS\* 0+ __bss_start
+2000000000000000 g O \*ABS\* 0+ _edata
+2000000000000000 g O \*ABS\* 0+ _end
+0+100c g O \.text 0+ _start\.
+
+Contents of section \.text:
+ 1004 fd000000 00001004 e3fd0001 .*
+Contents of section \.data:
+Contents of section \.sbss:
--- /dev/null
+ LOC #1002
+t SWYM
+ TETRA t
+
--- /dev/null
+#source: locto.s -globalize-symbols
+#source: start.s
+#ld: -m elf64mmix
+#objdump: -str
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+1008 l d \.text 0+
+2000000000000000 l d \.data 0+
+2000000000000000 l d \.sbss 0+
+2000000000000000 l d \.bss 0+
+0+ l d \*ABS\* 0+
+0+ l d \*ABS\* 0+
+0+ l d \*ABS\* 0+
+0+1008 g \.text 0+ od
+0+1010 g \.text 0+ _start
+0+1008 g \*ABS\* 0+ __\.MMIX\.start\.\.text
+2000000000000000 g O \*ABS\* 0+ __bss_start
+2000000000000000 g O \*ABS\* 0+ _edata
+2000000000000000 g O \*ABS\* 0+ _end
+0+1010 g O \.text 0+ _start\.
+
+Contents of section \.text:
+ 1008 00000000 00001008 e3fd0001 .*
+Contents of section \.data:
+Contents of section \.sbss:
--- /dev/null
+ LOC #1002
+od OCTA od
+
--- /dev/null
+% For tests regarding the Main symbol and mmo. Most tests use start.s as
+% a base file.
+ .text
+Main:
+ SET $253,1
--- /dev/null
+# Expect script for ld-mmix tests
+# Copyright 2001 Free Software Foundation, Inc.
+#
+# This file is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+#
+# Written by Hans-Peter Nilsson (hp@bitrange.com)
+#
+
+# Test MMIX and mmo object format handling.
+
+if ![istarget mmix-*-*] {
+ return
+}
+
+set rd_test_list [lsort [glob -nocomplain $srcdir/$subdir/*.d]]
+foreach mmixtest $rd_test_list {
+ # We need to strip the ".d", but can leave the dirname.
+ verbose [file rootname $mmixtest]
+ run_dump_test [file rootname $mmixtest]
+}
--- /dev/null
+OUTPUT_ARCH(mmix)
+OUTPUT_FORMAT("mmo")
+ENTRY(Main)
+SECTIONS
+{
+ .text 0x100 + sizeof_headers :
+ { *(.text); Main = _start; }
+
+ .MMIX.reg_contents :
+ { *(.MMIX.reg_contents); }
+}
--- /dev/null
+OUTPUT_ARCH(mmix)
+ENTRY(Main)
+SECTIONS
+{
+ .text 0x100 :
+ { *(.text); Main = _start; }
+
+ .other 0x1000000000000000 :
+ { *(secname); *(anothersec); *(thirdsec); *(.a.fourth.section); }
+
+ .data 0x2000000000000000 :
+ { *(.data); }
+
+ .MMIX.reg_contents :
+ { *(.MMIX.reg_contents); }
+}
--- /dev/null
+OUTPUT_ARCH(mmix)
+ENTRY(Main)
+SECTIONS
+{
+ .text 0x1000000000000000 :
+ { *(.text); Main = _start; }
+
+ .data 0x2000000000000000 :
+ { *(.data); }
+
+ .MMIX.reg_contents :
+ { *(.MMIX.reg_contents); }
+}
--- /dev/null
+# A nop to pad with an explicit insn.
+ .text
+ SWYM 1,2,3
--- /dev/null
+* Padding 16 bytes, suitable for testing relocs together with the larger
+* padding files.
+ .text
+ .space 16,0
--- /dev/null
+* Padding (1 << 19)/2 - 32 bytes; that is, suitable for testing the
+* short-range relocs.
+ .text
+ .space (1 << 19)/2 - 32,0
--- /dev/null
+* Padding (1 << 27)/2 - 32 bytes; that is, suitable for testing the
+* long-range relocs.
+ .text
+ .space (1 << 27)/2 - 32,0
--- /dev/null
+* Padding 16 bytes, suitable for testing relocs together with the larger
+* padding files.
+ .text
+ .space 4,0
--- /dev/null
+* Just PUSHJs to an external symbol, with some padding.
+ .text
+ .global pushja
+pushja:
+ SET $253,2
+ PUSHJ $12,a
+ SET $253,3
--- /dev/null
+#source: start.s
+#source: a.s
+#source: pushja.s
+#as: -x
+#ld: -m elf64mmix
+#objdump: -dr
+
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0+ <_start>:
+ 0: e3fd0001 setl \$253,0x1
+
+0+4 <a>:
+ 4: e3fd0004 setl \$253,0x4
+
+0+8 <pushja>:
+ 8: e3fd0002 setl \$253,0x2
+ c: e3ff0004 setl \$255,0x4
+ 10: e6ff0000 incml \$255,0x0
+ 14: e5ff0000 incmh \$255,0x0
+ 18: e4ff0000 inch \$255,0x0
+ 1c: bf0cff00 pushgo \$12,\$255,0
+ 20: e3fd0003 setl \$253,0x3
--- /dev/null
+#source: start.s
+#source: pushja.s
+#source: a.s
+#as: -x
+#ld: -m elf64mmix
+#objdump: -dr
+
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0+ <_start>:
+ 0: e3fd0001 setl \$253,0x1
+
+0+4 <pushja>:
+ 4: e3fd0002 setl \$253,0x2
+ 8: e3ff0020 setl \$255,0x20
+ c: e6ff0000 incml \$255,0x0
+ 10: e5ff0000 incmh \$255,0x0
+ 14: e4ff0000 inch \$255,0x0
+ 18: bf0cff00 pushgo \$12,\$255,0
+ 1c: e3fd0003 setl \$253,0x3
+
+0+20 <a>:
+ 20: e3fd0004 setl \$253,0x4
--- /dev/null
+#source: start.s
+#source: a.s
+#source: pushja.s
+#as: -no-expand
+#ld: -m elf64mmix
+#objdump: -dr
+
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0+ <_start>:
+ 0: e3fd0001 setl \$253,0x1
+
+0+4 <a>:
+ 4: e3fd0004 setl \$253,0x4
+
+0+8 <pushja>:
+ 8: e3fd0002 setl \$253,0x2
+ c: f30cfffe pushj \$12,4 <a>
+ 10: e3fd0003 setl \$253,0x3
--- /dev/null
+#source: start.s
+#source: pushja.s
+#source: a.s
+#as: -no-expand
+#ld: -m elf64mmix
+#objdump: -dr
+
+.*: file format elf64-mmix
+
+Disassembly of section \.text:
+
+0+ <_start>:
+ 0: e3fd0001 setl \$253,0x1
+
+0+4 <pushja>:
+ 4: e3fd0002 setl \$253,0x2
+ 8: f20c0002 pushj \$12,10 <a>
+ c: e3fd0003 setl \$253,0x3
+
+0+10 <a>:
+ 10: e3fd0004 setl \$253,0x4
--- /dev/null
+#source: start.s
+#source: a.s
+#source: pushja.s
+#as: -x
+#ld: -m mmo
+#objdump: -dr
+
+.*: file format mmo
+
+Disassembly of section \.text:
+
+0+ <(Main|_start)>:
+ 0: e3fd0001 setl \$253,0x1
+
+0+4 <a>:
+ 4: e3fd0004 setl \$253,0x4
+
+0+8 <pushja>:
+ 8: e3fd0002 setl \$253,0x2
+ c: e3ff0004 setl \$255,0x4
+ 10: e6ff0000 incml \$255,0x0
+ 14: e5ff0000 incmh \$255,0x0
+ 18: e4ff0000 inch \$255,0x0
+ 1c: bf0cff00 pushgo \$12,\$255,0
+ 20: e3fd0003 setl \$253,0x3
--- /dev/null
+#source: start.s
+#source: pushja.s
+#source: a.s
+#as: -x
+#ld: -m mmo
+#objdump: -dr
+
+.*: file format mmo
+
+Disassembly of section \.text:
+
+0+ <(Main|_start)>:
+ 0: e3fd0001 setl \$253,0x1
+
+0+4 <pushja>:
+ 4: e3fd0002 setl \$253,0x2
+ 8: e3ff0020 setl \$255,0x20
+ c: e6ff0000 incml \$255,0x0
+ 10: e5ff0000 incmh \$255,0x0
+ 14: e4ff0000 inch \$255,0x0
+ 18: bf0cff00 pushgo \$12,\$255,0
+ 1c: e3fd0003 setl \$253,0x3
+
+0+20 <a>:
+ 20: e3fd0004 setl \$253,0x4
--- /dev/null
+#source: start.s
+#source: a.s
+#source: pushja.s
+#as: -no-expand
+#ld: -m mmo
+#objdump: -dr
+
+.*: file format mmo
+
+Disassembly of section \.text:
+
+0+ <(Main|_start)>:
+ 0: e3fd0001 setl \$253,0x1
+
+0+4 <a>:
+ 4: e3fd0004 setl \$253,0x4
+
+0+8 <pushja>:
+ 8: e3fd0002 setl \$253,0x2
+ c: f30cfffe pushj \$12,4 <a>
+ 10: e3fd0003 setl \$253,0x3
--- /dev/null
+#source: start.s
+#source: pushja.s
+#source: a.s
+#as: -no-expand
+#ld: -m mmo
+#objdump: -dr
+
+.*: file format mmo
+
+Disassembly of section \.text:
+
+0+ <(Main|_start)>:
+ 0: e3fd0001 setl \$253,0x1
+
+0+4 <pushja>:
+ 4: e3fd0002 setl \$253,0x2
+ 8: f20c0002 pushj \$12,10 <a>
+ c: e3fd0003 setl \$253,0x3
+
+0+10 <a>:
+ 10: e3fd0004 setl \$253,0x4
--- /dev/null
+#source: areg-256.s
+#source: gregget1.s
+#source: start.s
+#source: a.s
+#as: -x
+#ld: -m elf64mmix
+#error: relocation truncated to fit: R_MMIX_REG areg$
--- /dev/null
+#source: areg-256.s
+#source: gregget1.s
+#source: start.s
+#source: a.s
+#as: -x
+#ld: -m mmo
+#error: relocation truncated to fit: R_MMIX_REG areg$
--- /dev/null
+#source: areg-t.s
+#source: gregget1.s
+#source: start.s
+#source: a.s
+#as: -x
+#ld: -m elf64mmix
+#error: register relocation against non-register symbol: areg in \.text
--- /dev/null
+#source: areg-t.s
+#source: gregget1.s
+#source: start.s
+#source: a.s
+#as: -x
+#ld: -m mmo
+#error: register relocation against non-register symbol: areg in \.text
--- /dev/null
+ .global ext1
+ext1 IS $252
--- /dev/null
+#source: sec-1.s
+#source: start.s
+#ld: -m elf64mmix
+#objcopy_linked_file: -O mmo
+#objdump: -sh
+
+.*: file format mmo
+
+Sections:
+Idx Name Size VMA LMA File off Algn
+ 0 \.text 0+4 0+ 0+ 0+ 2\*\*2
+ CONTENTS, ALLOC, LOAD, CODE
+ 1 \.a\.fourth\.section 0+10 0+20 0+20 0+ 2\*\*2
+ CONTENTS, ALLOC, LOAD, READONLY, DATA
+ 2 secname 0+1c 0+4 0+4 0+ 2\*\*2
+ CONTENTS, ALLOC, LOAD, READONLY, CODE
+ 3 anothersec 0+14 2000000000000000 2000000000000000 0+ 2\*\*2
+ CONTENTS, ALLOC, LOAD, DATA
+ 4 thirdsec 0+c 0+ 0+ 0+ 2\*\*2
+ CONTENTS, READONLY
+Contents of section \.text:
+ 0000 e3fd0001 .*
+Contents of section \.a\.fourth\.section:
+ 0020 00000000 0087a238 00000000 302a55a8 .*
+Contents of section secname:
+ 0004 00000001 00000002 00000003 00000004 .*
+ 0014 ffffffff fffff827 50000000 .*
+Contents of section anothersec:
+ 0000 0000000a 00000009 00000008 00000007 .*
+ 0010 25272900 .*
+Contents of section thirdsec:
+ 0000 00030d41 000186a2 26280000 .*
--- /dev/null
+ .section secname,"ax"
+ TETRA 1,2,3,4,-1,-2009
+ BYTE 80
+
+ .section anothersec,"aw"
+ TETRA 10,9,8,7
+ BYTE 37,39,41
+
+ .section thirdsec
+ TETRA 200001,100002
+ BYTE 38,40
+
+ .section .a.fourth.section,"a"
+ OCTA 8888888,808080808
--- /dev/null
+#source: sec-1.s
+#source: start.s
+#source: data1.s
+#ld: -m mmo -T $srcdir/$subdir/mmosec1.ld
+#objdump: -sh
+
+.*: file format mmo
+
+Sections:
+Idx Name Size VMA LMA File off Algn
+ 0 \.text 0+4 0+100 0+100 0+ 2\*\*2
+ CONTENTS, ALLOC, LOAD, CODE
+ 1 \.other 0+50 1000000000000000 1000000000000000 0+ 2\*\*2
+ CONTENTS, ALLOC, LOAD, CODE, DATA
+ 2 \.data 0+4 2000000000000004 2000000000000004 0+ 2\*\*2
+ CONTENTS, ALLOC, LOAD
+Contents of section \.text:
+ 0100 e3fd0001 .*
+Contents of section \.other:
+ 0000 00000001 00000002 00000003 00000004 .*
+ 0010 ffffffff fffff827 50000000 0000000a .*
+ 0020 00000009 00000008 00000007 25272900 .*
+ 0030 00030d41 000186a2 26280000 00000000 .*
+ 0040 00000000 0087a238 00000000 302a55a8 .*
+Contents of section \.data:
+ 0004 0000012c .*
--- /dev/null
+ .section .other,"ax"
+ TETRA 12,34,1
--- /dev/null
+#source: sec-1.s
+#source: start.s
+#source: data1.s
+#ld: -m mmo
+#objdump: -sh
+
+.*: file format mmo
+
+Sections:
+Idx Name Size VMA LMA File off Algn
+ 0 \.text 0+4 0+ 0+ 0+ 2\*\*2
+ CONTENTS, ALLOC, LOAD, CODE
+ 1 secname 0+1c 0+4 0+4 0+ 2\*\*2
+ CONTENTS, ALLOC, LOAD, READONLY, CODE
+ 2 \.a\.fourth\.section 0+10 0+20 0+20 0+ 2\*\*2
+ CONTENTS, ALLOC, LOAD, READONLY, DATA
+ 3 \.data 0+4 2000000000000004 2000000000000004 0+ 2\*\*2
+ CONTENTS, ALLOC, LOAD
+ 4 anothersec 0+14 2000000000000008 2000000000000008 0+ 2\*\*2
+ CONTENTS, ALLOC, LOAD, DATA
+ 5 thirdsec 0+c 200000000000001c 200000000000001c 0+ 2\*\*2
+ CONTENTS, READONLY
+Contents of section \.text:
+ 0000 e3fd0001 .*
+Contents of section secname:
+ 0004 00000001 00000002 00000003 00000004 .*
+ 0014 ffffffff fffff827 50000000 .*
+Contents of section \.a\.fourth\.section:
+ 0020 00000000 0087a238 00000000 302a55a8 .*
+Contents of section \.data:
+ 0004 0000002c .*
+Contents of section anothersec:
+ 0008 0000000a 00000009 00000008 00000007 .*
+ 0018 25272900 .*
+Contents of section thirdsec:
+ 001c 00030d41 000186a2 26280000 .*
--- /dev/null
+#source: sec-2.s
+#source: start.s
+#source: data1.s
+#ld: -m mmo -T $srcdir/$subdir/mmosec1.ld
+#objdump: -sh
+
+.*: file format mmo
+
+Sections:
+Idx Name Size VMA LMA File off Algn
+ 0 \.text 0+4 0+100 0+100 0+ 2\*\*2
+ CONTENTS, ALLOC, LOAD, CODE
+ 1 \.data 0+4 2000000000000004 2000000000000004 0+ 2\*\*2
+ CONTENTS, ALLOC, LOAD
+ 2 \.other 0+c 1000000000000000 1000000000000000 0+ 2\*\*2
+ CONTENTS, ALLOC, LOAD, READONLY, CODE
+Contents of section \.text:
+ 0100 e3fd0001 .*
+Contents of section \.data:
+ 0004 0000012c .*
+Contents of section \.other:
+ 0000 0000000c 00000022 00000001 .*
--- /dev/null
+#source: start.s
+#ld: -m mmo -T $srcdir/$subdir/mmosec2.ld
+#objdump: -sh
+
+# Check that sections are automatically created to cope with contents at
+# unexpected addresses. We do this by linking .text at an unexpected
+# address. As .text (like .data) does not get a section descriptor, the
+# output gets a LOP_LOC at an unexpected address, and a unique section is
+# created. This test will have to be changed if .text gets a section
+# descriptor if linked to an unexpected address.
+
+.*: file format mmo
+
+Sections:
+Idx Name Size VMA LMA File off Algn
+ 0 \.text 0+ 0+ 0+ 0+ 2\*\*2
+
+ 1 \.MMIX\.sec\.0 0+4 1000000000000000 1000000000000000 0+ 2\*\*2
+ CONTENTS, ALLOC, LOAD
+Contents of section \.MMIX\.sec\.0:
+ 0000 e3fd0001 .*
--- /dev/null
+#source: start.s
+#source: sec-6.s
+#source: a.s
+#as: -x
+#ld: -m elf64mmix
+#objcopy_linked_file: -O mmo
+#objdump: -xs
+
+# A non-loaded section with relocs would have the SEC_RELOC bit set in the
+# output if we didn't clear it. For reference, here's the ELF copied to
+# mmo, so we make sure no spurious flags are introduced.
+
+.*: file format mmo
+.*
+architecture: mmix, flags 0x0+10:
+HAS_SYMS
+start address 0x0+
+
+Sections:
+Idx Name Size VMA LMA File off Algn
+ 0 \.text 0+8 0+ 0+ 0+ 2\*\*2
+ CONTENTS, ALLOC, LOAD, CODE
+ 1 \.debug_frame 0+10 0+ 0+ 0+ 2\*\*2
+ CONTENTS, READONLY, DEBUGGING
+SYMBOL TABLE:
+0+ g \.text _start
+0+8 g \.text debugb
+2000000000000000 g \*ABS\* __bss_start
+2000000000000000 g \*ABS\* _edata
+2000000000000000 g \*ABS\* _end
+0+4 g \.text a
+
+Contents of section \.text:
+ 0000 e3fd0001 e3fd0004 .*
+Contents of section \.debug_frame:
+ 0000 00000000 00000004 00000000 00000008 .*
--- /dev/null
+ .global debugb
+ .section .debug_frame,"",@progbits
+ .8byte a
+debugb:
+ .8byte debugb
--- /dev/null
+#source: start.s
+#source: sec-6.s
+#source: a.s
+#as: -x
+#ld: -m mmo
+#objdump: -xs
+
+# A non-loaded section with relocs would have the SEC_RELOC bit set in the
+# output if we didn't clear it.
+
+.*: file format mmo
+.*
+architecture: mmix, flags 0x0+10:
+HAS_SYMS
+start address 0x0+
+
+Sections:
+Idx Name Size VMA LMA File off Algn
+ 0 \.text 0+8 0+ 0+ 0+ 2\*\*2
+ CONTENTS, ALLOC, LOAD, CODE
+ 1 \.debug_frame 0+10 0+ 0+ 0+ 2\*\*2
+ CONTENTS, READONLY, DEBUGGING
+SYMBOL TABLE:
+0+ g \.text Main
+0+ g \.text _start
+0+8 g \.text debugb
+0+4 g \.text a
+
+Contents of section \.text:
+ 0000 e3fd0001 e3fd0004 .*
+Contents of section \.debug_frame:
+ 0000 00000000 00000004 00000000 00000008 .*
--- /dev/null
+#source: bspec801.s
+#source: start.s
+#ld: -m mmo
+#objdump: -sh
+
+# Check exceptional cases for LOP_SPEC 80, which we parse according to a
+# specific format: see documentation and mmo.c
+# #1: name length has LOP_QUOTE.
+
+.*: file format mmo
+
+Sections:
+Idx Name Size VMA LMA File off Algn
+ 0 \.text 00000004 0000000000000000 0000000000000000 00000000 2\*\*2
+ CONTENTS, ALLOC, LOAD, CODE
+ 1 \.MMIX\.spec_data\.80 00000004 0000000000000000 0000000000000000 00000000 2\*\*2
+ CONTENTS
+Contents of section \.text:
+ 0000 e3fd0001 .*
+Contents of section \.MMIX\.spec_data\.80:
+ 0000 98000001 .*
--- /dev/null
+#source: bspec802.s
+#source: start.s
+#ld: -m mmo
+#objdump: -sh
+
+# See spec801.d.
+# #2: non-quote LOP in name.
+
+.*: file format mmo
+
+Sections:
+Idx Name Size VMA LMA File off Algn
+ 0 \.text 0+4 0+ 0+ 0+ 2\*\*2
+ CONTENTS, ALLOC, LOAD, CODE
+ 1 \.data 0+4 2000000000000000 2000000000000000 0+ 2\*\*2
+ CONTENTS, ALLOC, LOAD
+ 2 \.MMIX\.spec_data\.80 0+4 0+ 0+ 0+ 2\*\*2
+ CONTENTS
+Contents of section \.text:
+ 0000 e3fd0001 .*
+Contents of section \.data:
+ 0000 00112233 .*
+Contents of section \.MMIX\.spec_data\.80:
+ 0000 00000004 .*
--- /dev/null
+#source: bspec803.s
+#source: start.s
+#ld: -m mmo
+#objdump: -sh
+
+# See spec801.d.
+# #3: LOP_QUOTE in name and non-quote LOP in section flags.
+
+.*: file format mmo
+
+Sections:
+Idx Name Size VMA LMA File off Algn
+ 0 \.text 0+4 0+ 0+ 0+ 2\*\*2
+ CONTENTS, ALLOC, LOAD, CODE
+ 1 \.data 0+4 2000000000000000 2000000000000000 0+ 2\*\*2
+ CONTENTS, ALLOC, LOAD
+ 2 \.MMIX\.spec_data\.80 0+c 0+ 0+ 0+ 2\*\*2
+ CONTENTS
+Contents of section \.text:
+ 0000 e3fd0001 .*
+Contents of section \.data:
+ 0000 00112233 .*
+Contents of section \.MMIX\.spec_data\.80:
+ 0000 00000002 61616161 98616161 .*
--- /dev/null
+#source: bspec804.s
+#source: start.s
+#ld: -m mmo
+#objdump: -sh
+
+# See spec801.d.
+# #4: non-quote LOP in section length, high part.
+
+.*: file format mmo
+
+Sections:
+Idx Name Size VMA LMA File off Algn
+ 0 \.text 0+4 0+ 0+ 0+ 2\*\*2
+ CONTENTS, ALLOC, LOAD, CODE
+ 1 \.data 0+4 2000000000000000 2000000000000000 0+ 2\*\*2
+ CONTENTS, ALLOC, LOAD
+ 2 \.MMIX\.spec_data\.80 0+10 0+ 0+ 0+ 2\*\*2
+ CONTENTS
+Contents of section \.text:
+ 0000 e3fd0001 .*
+Contents of section \.data:
+ 0000 00112233 .*
+Contents of section \.MMIX\.spec_data\.80:
+ 0000 00000002 61616161 61616161 00000011 .*
--- /dev/null
+#source: bspec805.s
+#source: start.s
+#ld: -m mmo
+#objdump: -sh
+
+# See spec801.d.
+# #5: non-quote LOP in section length, low part.
+
+.*: file format mmo
+
+Sections:
+Idx Name Size VMA LMA File off Algn
+ 0 \.text 0+4 0+ 0+ 0+ 2\*\*2
+ CONTENTS, ALLOC, LOAD, CODE
+ 1 \.data 0+4 2000000000000000 2000000000000000 0+ 2\*\*2
+ CONTENTS, ALLOC, LOAD
+ 2 \.MMIX\.spec_data\.80 0+14 0+ 0+ 0+ 2\*\*2
+ CONTENTS
+Contents of section \.text:
+ 0000 e3fd0001 .*
+Contents of section \.data:
+ 0000 00112233 .*
+Contents of section \.MMIX\.spec_data\.80:
+ 0000 00000002 61616161 61616161 00000011 .*
+ 0010 00000000 .*
--- /dev/null
+#source: bspec806.s
+#source: start.s
+#ld: -m mmo
+#objdump: -sh
+
+# See spec801.d.
+# #6: non-quote LOP in section vma, high part.
+
+.*: file format mmo
+
+Sections:
+Idx Name Size VMA LMA File off Algn
+ 0 \.text 0+4 0+ 0+ 0+ 2\*\*2
+ CONTENTS, ALLOC, LOAD, CODE
+ 1 \.data 0+4 2000000000000000 2000000000000000 0+ 2\*\*2
+ CONTENTS, ALLOC, LOAD
+ 2 \.MMIX\.spec_data\.80 0+18 0+ 0+ 0+ 2\*\*2
+ CONTENTS
+Contents of section \.text:
+ 0000 e3fd0001 .*
+Contents of section \.data:
+ 0000 00112233 .*
+Contents of section \.MMIX\.spec_data\.80:
+ 0000 00000002 61616161 61616161 00000011 .*
+ 0010 00000000 0000000c .*
--- /dev/null
+#source: bspec807.s
+#source: start.s
+#ld: -m mmo
+#objdump: -sh
+
+# See spec801.d.
+# #7: non-quote LOP in section vma, low part.
+
+.*: file format mmo
+
+Sections:
+Idx Name Size VMA LMA File off Algn
+ 0 \.text 0+4 0+ 0+ 0+ 2\*\*2
+ CONTENTS, ALLOC, LOAD, CODE
+ 1 \.data 0+4 2000000000000000 2000000000000000 0+ 2\*\*2
+ CONTENTS, ALLOC, LOAD
+ 2 \.MMIX\.spec_data\.80 0+1c 0+ 0+ 0+ 2\*\*2
+ CONTENTS
+Contents of section \.text:
+ 0000 e3fd0001 .*
+Contents of section \.data:
+ 0000 00112233 .*
+Contents of section \.MMIX\.spec_data\.80:
+ 0000 00000002 61616161 61616161 00000011 .*
+ 0010 00000000 0000000c 00000000 .*
--- /dev/null
+#source: bspec808.s
+#source: start.s
+#ld: -m mmo
+#objdump: -sh
+
+# See spec801.d.
+# #8: Indecent section length.
+
+.*: file format mmo
+
+Sections:
+Idx Name Size VMA LMA File off Algn
+ 0 \.text 0+4 0+ 0+ 0+ 2\*\*2
+ CONTENTS, ALLOC, LOAD, CODE
+ 1 \.data 0+4 2000000000000000 2000000000000000 0+ 2\*\*2
+ CONTENTS, ALLOC, LOAD
+ 2 \.MMIX\.spec_data\.80 0+20 0+ 0+ 0+ 2\*\*2
+ CONTENTS
+Contents of section \.text:
+ 0000 e3fd0001 .*
+Contents of section \.data:
+ 0000 00112233 .*
+Contents of section \.MMIX\.spec_data\.80:
+ 0000 00000002 61616161 61616161 00000011 .*
+ 0010 0000ff00 00000000 000000ff 00000000 .*
--- /dev/null
+#source: start2.s
+#ld: -m elf64mmix
+#objdump: -td
+
+.*: file format elf64-mmix
+
+SYMBOL TABLE:
+0+ l d \.text 0+
+2000000000000000 l d \.data 0+
+2000000000000000 l d \.sbss 0+
+2000000000000000 l d \.bss 0+
+0+ l d \*ABS\* 0+
+0+ l d \*ABS\* 0+
+0+ l d \*ABS\* 0+
+0+4 g \.text 0+ _start
+2000000000000000 g O \*ABS\* 0+ __bss_start
+2000000000000000 g O \*ABS\* 0+ _edata
+2000000000000000 g O \*ABS\* 0+ _end
+0+4 g O \.text 0+ _start\.
+
+Disassembly of section \.text:
+
+0+ <_start-0x4>:
+ 0: fd000001 swym 0,0,1
+
+0+4 <_start>:
+ 4: fd000002 swym 0,0,2
--- /dev/null
+#source: main1.s
+#source: a.s
+#ld: -m mmo -e a
+#error: Bad symbol definition: `Main' set to
--- /dev/null
+* Just a start symbol and some non-NOP padding.
+ .text
+ .global _start
+_start:
+ SET $253,1
--- /dev/null
+ .text
+ SWYM 1
+ .global _start
+_start:
+ SWYM 2
--- /dev/null
+#source: start.s
+#source: a.s
+#ld: -m mmo
+#nm: -n
+
+# Test that nm can grok a simple mmo symbol table (or that mmo lets nm
+# grok it).
+
+0+ T Main
+0+ T _start
+0+4 T a
--- /dev/null
+#source: start.s
+#source: sym-2.s
+#source: a.s
+#as: -globalize-symbols
+#ld: -m mmo
+#objcopy_linked_file:
+#objdump: -t
+
+.*: file format mmo
+
+SYMBOL TABLE:
+0+ g[ ]+\.text Main
+0+4 g[ ]+\.text a40
+0+4 g[ ]+\.text a33
+0+4 g[ ]+\.text a45
+0+4 g[ ]+\.text a21
+0+4 g[ ]+\.text a99
+0+4 g[ ]+\.text a114
+0+4 g[ ]+\.text a122
+0+4 g[ ]+\.text a73
+0+4 g[ ]+\.text a111
+0+4 g[ ]+\.text a109
+0+4 g[ ]+\.text a65
+0+4 g[ ]+\.text a28
+0+4 g[ ]+\.text a30
+0+4 g[ ]+\.text a10
+0+4 g[ ]+\.text a103
+0+4 g[ ]+\.text a42
+0+4 g[ ]+\.text a62
+0+4 g[ ]+\.text a25
+0+4 g[ ]+\.text a128
+0+4 g[ ]+\.text a9
+0+4 g[ ]+\.text a11
+0+4 g[ ]+\.text a81
+0+4 g[ ]+\.text a55
+0+4 g[ ]+\.text a88
+0+4 g[ ]+\.text a100
+0+4 g[ ]+\.text a104
+0+4 g[ ]+\.text a8
+0+4 g[ ]+\.text a86
+0+4 g[ ]+\.text a91
+0+4 g[ ]+\.text a1
+0+4 g[ ]+\.text a49
+0+4 g[ ]+\.text a43
+0+4 g[ ]+\.text a56
+0+4 g[ ]+\.text a116
+0+4 g[ ]+\.text a124
+0+4 g[ ]+\.text a98
+0+4 g[ ]+\.text a117
+0+4 g[ ]+\.text a80
+0+4 g[ ]+\.text a121
+0+4 g[ ]+\.text a36
+0+4 g[ ]+\.text a75
+0+4 g[ ]+\.text a48
+0+4 g[ ]+\.text a3
+0+4 g[ ]+\.text a63
+0+4 g[ ]+\.text a26
+0+4 g[ ]+\.text a78
+0+4 g[ ]+\.text a61
+0+4 g[ ]+\.text a24
+0+4 g[ ]+\.text a64
+0+4 g[ ]+\.text a27
+0+4 g[ ]+\.text a83
+0+4 g[ ]+\.text a57
+0+4 g[ ]+\.text a123
+0+4 g[ ]+\.text a34
+0+4 g[ ]+\.text a12
+0+4 g[ ]+\.text a14
+0+4 g[ ]+\.text a70
+0+4 g[ ]+\.text a39
+0+4 g[ ]+\.text a82
+0+4 g[ ]+\.text a102
+0+4 g[ ]+\.text a106
+0+4 g[ ]+\.text a110
+0+ g[ ]+\.text _start
+0+4 g[ ]+\.text a41
+0+4 g[ ]+\.text a85
+0+4 g[ ]+\.text a58
+0+4 g[ ]+\.text a89
+0+4 g[ ]+\.text a54
+0+4 g[ ]+\.text a19
+0+4 g[ ]+\.text a93
+0+4 g[ ]+\.text a126
+0+4 g[ ]+\.text a22
+0+4 g[ ]+\.text a96
+0+4 g[ ]+\.text a7
+0+4 g[ ]+\.text a35
+0+4 g[ ]+\.text a31
+0+4 g[ ]+\.text a5
+0+4 g[ ]+\.text a44
+0+4 g[ ]+\.text a105
+0+4 g[ ]+\.text a90
+0+4 g[ ]+\.text a97
+0+4 g[ ]+\.text a92
+0+4 g[ ]+\.text a2
+0+4 g[ ]+\.text a120
+0+4 g[ ]+\.text a113
+0+4 g[ ]+\.text a77
+0+4 g[ ]+\.text a125
+0+4 g[ ]+\.text a118
+0+4 g[ ]+\.text a32
+0+4 g[ ]+\.text a108
+0+4 g[ ]+\.text a47
+0+4 g[ ]+\.text a112
+0+4 g[ ]+\.text a59
+0+4 g[ ]+\.text a87
+0+4 g[ ]+\.text a94
+0+4 g[ ]+\.text a20
+0+4 g[ ]+\.text a51
+0+4 g[ ]+\.text a16
+0+4 g[ ]+\.text a53
+0+4 g[ ]+\.text a18
+0+4 g[ ]+\.text a66
+0+4 g[ ]+\.text a29
+0+4 g[ ]+\.text a72
+0+4 g[ ]+\.text a79
+0+4 g[ ]+\.text a74
+0+4 g[ ]+\.text a68
+0+4 g[ ]+\.text a95
+0+4 g[ ]+\.text a60
+0+4 g[ ]+\.text a23
+0+4 g[ ]+\.text a67
+0+4 g[ ]+\.text a
+0+4 g[ ]+\.text a38
+0+4 g[ ]+\.text a107
+0+4 g[ ]+\.text a127
+0+4 g[ ]+\.text a101
+0+4 g[ ]+\.text a115
+0+4 g[ ]+\.text a71
+0+4 g[ ]+\.text a84
+0+4 g[ ]+\.text a69
+0+4 g[ ]+\.text a37
+0+4 g[ ]+\.text a76
+0+4 g[ ]+\.text a52
+0+4 g[ ]+\.text a17
+0+4 g[ ]+\.text a13
+0+4 g[ ]+\.text a50
+0+4 g[ ]+\.text a15
+0+4 g[ ]+\.text a119
+0+4 g[ ]+\.text a6
+0+4 g[ ]+\.text a46
+0+4 g[ ]+\.text a4
--- /dev/null
+% Just 128 symbols to test that we can handle it in mmo. Assemble it with
+% -globalize-symbols.
+a1:
+a2:
+a3:
+a4:
+a5:
+a6:
+a7:
+a8:
+a9:
+a10:
+a11:
+a12:
+a13:
+a14:
+a15:
+a16:
+a17:
+a18:
+a19:
+a20:
+a21:
+a22:
+a23:
+a24:
+a25:
+a26:
+a27:
+a28:
+a29:
+a30:
+a31:
+a32:
+a33:
+a34:
+a35:
+a36:
+a37:
+a38:
+a39:
+a40:
+a41:
+a42:
+a43:
+a44:
+a45:
+a46:
+a47:
+a48:
+a49:
+a50:
+a51:
+a52:
+a53:
+a54:
+a55:
+a56:
+a57:
+a58:
+a59:
+a60:
+a61:
+a62:
+a63:
+a64:
+a65:
+a66:
+a67:
+a68:
+a69:
+a70:
+a71:
+a72:
+a73:
+a74:
+a75:
+a76:
+a77:
+a78:
+a79:
+a80:
+a81:
+a82:
+a83:
+a84:
+a85:
+a86:
+a87:
+a88:
+a89:
+a90:
+a91:
+a92:
+a93:
+a94:
+a95:
+a96:
+a97:
+a98:
+a99:
+a100:
+a101:
+a102:
+a103:
+a104:
+a105:
+a106:
+a107:
+a108:
+a109:
+a110:
+a111:
+a112:
+a113:
+a114:
+a115:
+a116:
+a117:
+a118:
+a119:
+a120:
+a121:
+a122:
+a123:
+a124:
+a125:
+a126:
+a127:
+a128:
--- /dev/null
+#source: undef-1.s
+#source: start.s
+#ld: -m elf64mmix
+#error: undefined reference to `regvar'
--- /dev/null
+ ADDU regvar,$8,$9
--- /dev/null
+#source: undef-1.s
+#source: start.s
+#ld: -m mmo
+#error: undefined reference to `regvar'
--- /dev/null
+#source: undef-2.s
+#source: start.s
+#as: -x
+#ld: -m elf64mmix
+#error: undefined reference to `undefd'
--- /dev/null
+ PUSHJ $5,undefd
--- /dev/null
+#source: undef-2.s
+#source: start.s
+#as: -x
+#ld: -m mmo
+#error: undefined reference to `undefd'
--- /dev/null
+#source: start.s
+#ld: -u undefd -m elf64mmix
+#readelf: -S -s
+
+There are 8 section headers, starting at offset 0xe8:
+
+Section Headers:
+ \[Nr\] Name Type Address Offset
+ Size EntSize Flags Link Info Align
+ \[ 0\] NULL 0+ 0+
+ 0+ 0+ 0 0 0
+ \[ 1\] \.text PROGBITS 0+ 0+b0
+ 0+4 0+ AX 0 0 4
+ \[ 2\] \.data PROGBITS 20+ 0+b4
+ 0+ 0+ WA 0 0 1
+ \[ 3\] \.sbss PROGBITS 2000000000000000 0+b4
+ 0+ 0+ W 0 0 1
+ \[ 4\] \.bss NOBITS 2000000000000000 0+b4
+ 0+ 0+ WA 0 0 1
+ \[ 5\] \.shstrtab STRTAB 0+ 0+b4
+ 0+32 0+ 0 0 1
+ \[ 6\] \.symtab SYMTAB 0+ 0+2e8
+ 0+150 0+18 7 8 8
+ \[ 7\] \.strtab STRTAB 0+ 0+438
+ 0+2f 0+ 0 0 1
+Key to Flags:
+ W \(write\), A \(alloc\), X \(execute\), M \(merge\), S \(strings\)
+ I \(info\), L \(link order\), G \(group\), x \(unknown\)
+ O \(extra OS processing required\) o \(OS specific\), p \(processor specific\)
+
+Symbol table '\.symtab' contains 14 entries:
+ Num: Value Size Type Bind Vis Ndx Name
+ 0: 0+ 0 NOTYPE LOCAL DEFAULT UND
+ 1: 0+ 0 SECTION LOCAL DEFAULT 1
+ 2: 2000000000000000 0 SECTION LOCAL DEFAULT 2
+ 3: 2000000000000000 0 SECTION LOCAL DEFAULT 3
+ 4: 2000000000000000 0 SECTION LOCAL DEFAULT 4
+ 5: 0+ 0 SECTION LOCAL DEFAULT 5
+ 6: 0+ 0 SECTION LOCAL DEFAULT 6
+ 7: 0+ 0 SECTION LOCAL DEFAULT 7
+ 8: 0+ 0 NOTYPE GLOBAL DEFAULT UND undefd
+ 9: 0+ 0 NOTYPE GLOBAL DEFAULT 1 _start
+ 10: 2000000000000000 0 OBJECT GLOBAL DEFAULT ABS __bss_start
+ 11: 2000000000000000 0 OBJECT GLOBAL DEFAULT ABS _edata
+ 12: 2000000000000000 0 OBJECT GLOBAL DEFAULT ABS _end
+ 13: 0+ 0 OBJECT GLOBAL DEFAULT 1 _start\.
--- /dev/null
+#source: start.s
+#ld: -m mmo -u undefd
+#objdump: -x
+
+.*: file format mmo
+.*
+architecture: mmix, flags 0x0+10:
+HAS_SYMS
+start address 0x0+
+
+Sections:
+Idx Name Size VMA LMA File off Algn
+ 0 \.text 0+4 0+ 0+ 0+ 2\*\*2
+ CONTENTS, ALLOC, LOAD, CODE
+SYMBOL TABLE:
+0+ g \.text Main
+0+ g \*UND\* undefd
+0+ g \.text _start
+
+
--- /dev/null
+;# Main file, x.s, with the program (_start) referring to two
+;# linkonce functions fn and fn2. The functions fn and fn2 are
+;# supposed to be equivalent of C++ template instantiations; the
+;# main file instantiates fn. There's the equivalent of an FDE
+;# entry in .eh_frame, referring to fn via a local label.
+
+ .text
+ .global _start
+_start:
+ .long fn
+ .long fn2
+
+ .section .gnu.linkonce.t.fn,"ax",@progbits
+ .weak fn
+ .type fn,@function
+fn:
+L:a:
+ .long 1
+ .long 2
+L:b:
+ .size fn,L:b-L:a
+
+ .section .eh_frame,"aw",@progbits
+ .long 2
+ .long L:a
+ .long L:b-L:a
--- /dev/null
+;# Library file y.s has linkonce entries for fn and fn2. Note
+;# that this version of fn has different code, as if compiled
+;# with different optimization flags than the one in x.s (not
+;# important for this test, though). The reference from
+;# .eh_frame to the linkonce-excluded fn2 must be zero, or g++
+;# EH will not work.
+
+ .section .gnu.linkonce.t.fn2,"ax",@progbits
+ .weak fn2
+ .type fn2,@function
+fn2:
+L:c:
+ .long 3
+L:d:
+ .size fn2,L:d-L:c
+
+ .section .gnu.linkonce.t.fn,"ax",@progbits
+ .weak fn
+ .type fn,@function
+fn:
+L:e:
+ .long 4
+L:f:
+ .size fn,L:f-L:e
+
+ .section .eh_frame,"aw",@progbits
+ .long 7
+ .long L:c
+ .long L:d-L:c
+
+ .long 0x6066
+ .long L:e
+ .long L:f-L:e
--- /dev/null
+SECTIONS {
+ .text 0xa00 : { *(.text); *(.gnu.linkonce.t.*) }
+ .eh_frame 0x2000 : { *(.eh_frame) }
+}
--- /dev/null
+#source: x.s
+#source: y.s
+#ld: -m elf64mmix -Ttext 0xa00 -T $srcdir/$subdir/zeroeh.ld
+#objdump: -s
+
+# The word at address 201c, for the linkonce-excluded section, must be zero.
+
+.*: file format elf64-mmix
+
+Contents of section \.text:
+ 0a00 00000a08 00000a10 00000001 00000002 .*
+ 0a10 00000003 .*
+Contents of section \.eh_frame:
+ 2000 00000002 00000a08 00000008 00000007 .*
+ 2010 00000a10 00000004 00006066 00000000 .*
+ 2020 00000004 .*
+#pass
--- /dev/null
+#source: x.s
+#source: y.s
+#ld: -m mmo -Ttext 0xa00 -T $srcdir/$subdir/zeroeh.ld
+#objdump: -s
+
+# The word at address 201c, for the linkonce-excluded section, must be zero.
+
+.*: file format mmo
+
+Contents of section \.text:
+ 0a00 00000a08 00000a10 00000001 00000002 .*
+ 0a10 00000003 .*
+Contents of section \.eh_frame:
+ 2000 00000002 00000a08 00000008 00000007 .*
+ 2010 00000a10 00000004 00006066 00000000 .*
+ 2020 00000004 .*
+2001-10-30 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * Makefile.am (CFILES): Add mmix-dis.c and mmix-opc.c. Regenerate
+ dependencies.
+ * Makefile.in: Regenerate.
+ * mmix-dis.c, mmix-opc.c: New files.
+
2001-10-29 Kazu Hirata <kazu@hxi.com>
* d30v-dis.c: Fix a comment typo.
m10200-opc.c \
m10300-dis.c \
m10300-opc.c \
+ mmix-dis.c \
+ mmix-opc.c \
ns32k-dis.c \
openrisc-asm.c \
openrisc-desc.c \
mips-dis.lo \
mips-opc.lo \
mips16-opc.lo \
+ mmix-dis.lo \
+ mmix-opc.lo \
ns32k-dis.lo \
openrisc-asm.lo \
openrisc-desc.lo \
$(INCDIR)/symcat.h opintl.h
m10300-opc.lo: m10300-opc.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(INCDIR)/opcode/mn10300.h
+mmix-dis.lo: mmix-dis.c $(INCDIR)/opcode/mmix.h $(INCDIR)/dis-asm.h \
+ $(BFD_H) $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h \
+ opintl.h
+mmix-opc.lo: mmix-opc.c $(INCDIR)/opcode/mmix.h $(INCDIR)/symcat.h
ns32k-dis.lo: ns32k-dis.c $(BFD_H) $(INCDIR)/ansidecl.h \
$(INCDIR)/symcat.h sysdep.h config.h $(INCDIR)/dis-asm.h \
$(INCDIR)/opcode/ns32k.h opintl.h
-# Makefile.in generated automatically by automake 1.4 from Makefile.am
+# Makefile.in generated automatically by automake 1.4-p5 from Makefile.am
-# Copyright (C) 1994, 1995-8, 1999 Free Software Foundation, Inc.
+# Copyright (C) 1994, 1995-8, 1999, 2001 Free Software Foundation, Inc.
# This Makefile.in is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
# with or without modifications, as long as this notice is preserved.
m10200-opc.c \
m10300-dis.c \
m10300-opc.c \
+ mmix-dis.c \
+ mmix-opc.c \
ns32k-dis.c \
openrisc-asm.c \
openrisc-desc.c \
mips-dis.lo \
mips-opc.lo \
mips16-opc.lo \
+ mmix-dis.lo \
+ mmix-opc.lo \
ns32k-dis.lo \
openrisc-asm.lo \
openrisc-desc.lo \
dot_seen=no; \
rev=''; list='$(SUBDIRS)'; for subdir in $$list; do \
rev="$$subdir $$rev"; \
- test "$$subdir" = "." && dot_seen=yes; \
+ test "$$subdir" != "." || dot_seen=yes; \
done; \
test "$$dot_seen" = "no" && rev=". $$rev"; \
target=`echo $@ | sed s/-recursive//`; \
$(INCDIR)/symcat.h opintl.h
m10300-opc.lo: m10300-opc.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(INCDIR)/opcode/mn10300.h
+mmix-dis.lo: mmix-dis.c $(INCDIR)/opcode/mmix.h $(INCDIR)/dis-asm.h \
+ $(BFD_H) $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h \
+ opintl.h
+mmix-opc.lo: mmix-opc.c $(INCDIR)/opcode/mmix.h $(INCDIR)/symcat.h
ns32k-dis.lo: ns32k-dis.c $(BFD_H) $(INCDIR)/ansidecl.h \
$(INCDIR)/symcat.h sysdep.h config.h $(INCDIR)/dis-asm.h \
$(INCDIR)/opcode/ns32k.h opintl.h
program_transform_name=s,x,x,
silent=
site=
-sitefile=
srcdir=
target=NONE
verbose=
--help print this message
--no-create do not create output files
--quiet, --silent do not print \`checking...' messages
- --site-file=FILE use FILE as the site file
--version print the version of autoconf that created configure
Directory and file names:
--prefix=PREFIX install architecture-independent files in PREFIX
-site=* | --site=* | --sit=*)
site="$ac_optarg" ;;
- -site-file | --site-file | --site-fil | --site-fi | --site-f)
- ac_prev=sitefile ;;
- -site-file=* | --site-file=* | --site-fil=* | --site-fi=* | --site-f=*)
- sitefile="$ac_optarg" ;;
-
-srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
ac_prev=srcdir ;;
-srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
# Prefer explicitly selected file to automatically selected ones.
-if test -z "$sitefile"; then
- if test -z "$CONFIG_SITE"; then
- if test "x$prefix" != xNONE; then
- CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
- else
- CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
- fi
+if test -z "$CONFIG_SITE"; then
+ if test "x$prefix" != xNONE; then
+ CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
+ else
+ CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
fi
-else
- CONFIG_SITE="$sitefile"
fi
for ac_site_file in $CONFIG_SITE; do
if test -r "$ac_site_file"; then
fi
echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6
-echo "configure:563: checking for Cygwin environment" >&5
+echo "configure:552: checking for Cygwin environment" >&5
if eval "test \"`echo '$''{'ac_cv_cygwin'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 568 "configure"
+#line 557 "configure"
#include "confdefs.h"
int main() {
return __CYGWIN__;
; return 0; }
EOF
-if { (eval echo configure:579: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:568: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_cygwin=yes
else
CYGWIN=
test "$ac_cv_cygwin" = yes && CYGWIN=yes
echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6
-echo "configure:596: checking for mingw32 environment" >&5
+echo "configure:585: checking for mingw32 environment" >&5
if eval "test \"`echo '$''{'ac_cv_mingw32'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 601 "configure"
+#line 590 "configure"
#include "confdefs.h"
int main() {
return __MINGW32__;
; return 0; }
EOF
-if { (eval echo configure:608: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:597: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_mingw32=yes
else
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:673: checking host system type" >&5
+echo "configure:662: checking host system type" >&5
host_alias=$host
case "$host_alias" in
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:694: checking target system type" >&5
+echo "configure:683: checking target system type" >&5
target_alias=$target
case "$target_alias" in
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:712: checking build system type" >&5
+echo "configure:701: checking build system type" >&5
build_alias=$build
case "$build_alias" in
echo $ac_n "checking for strerror in -lcposix""... $ac_c" 1>&6
-echo "configure:736: checking for strerror in -lcposix" >&5
+echo "configure:725: checking for strerror in -lcposix" >&5
ac_lib_var=`echo cposix'_'strerror | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lcposix $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 744 "configure"
+#line 733 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
strerror()
; return 0; }
EOF
-if { (eval echo configure:755: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:744: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:795: checking for a BSD compatible install" >&5
+echo "configure:784: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
-echo "configure:848: checking whether build environment is sane" >&5
+echo "configure:837: checking whether build environment is sane" >&5
# Just in case
sleep 1
echo timestamp > conftestfile
test "$program_transform_name" = "" && program_transform_name="s,x,x,"
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:905: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:894: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
missing_dir=`cd $ac_aux_dir && pwd`
echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
-echo "configure:951: checking for working aclocal" >&5
+echo "configure:940: checking for working aclocal" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
fi
echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
-echo "configure:964: checking for working autoconf" >&5
+echo "configure:953: checking for working autoconf" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
fi
echo $ac_n "checking for working automake""... $ac_c" 1>&6
-echo "configure:977: checking for working automake" >&5
+echo "configure:966: checking for working automake" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
fi
echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
-echo "configure:990: checking for working autoheader" >&5
+echo "configure:979: checking for working autoheader" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
fi
echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
-echo "configure:1003: checking for working makeinfo" >&5
+echo "configure:992: checking for working makeinfo" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
# Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
set dummy ${ac_tool_prefix}ar; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1026: checking for $ac_word" >&5
+echo "configure:1015: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
set dummy ${ac_tool_prefix}ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1058: checking for $ac_word" >&5
+echo "configure:1047: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "ranlib", so it can be a program name with args.
set dummy ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1090: checking for $ac_word" >&5
+echo "configure:1079: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "gcc", so it can be a program name with args.
set dummy gcc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1196: checking for $ac_word" >&5
+echo "configure:1185: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "cc", so it can be a program name with args.
set dummy cc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1226: checking for $ac_word" >&5
+echo "configure:1215: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "cl", so it can be a program name with args.
set dummy cl; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1277: checking for $ac_word" >&5
+echo "configure:1266: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:1309: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:1298: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
cat > conftest.$ac_ext << EOF
-#line 1320 "configure"
+#line 1309 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:1325: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1314: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:1351: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:1340: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:1356: checking whether we are using GNU C" >&5
+echo "configure:1345: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1365: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1354: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:1384: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:1373: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
if test "$GCC" = yes; then
# Check if gcc -print-prog-name=ld gives a path.
echo $ac_n "checking for ld used by GCC""... $ac_c" 1>&6
-echo "configure:1427: checking for ld used by GCC" >&5
+echo "configure:1416: checking for ld used by GCC" >&5
case $host in
*-*-mingw*)
# gcc leaves a trailing carriage return which upsets mingw
esac
elif test "$with_gnu_ld" = yes; then
echo $ac_n "checking for GNU ld""... $ac_c" 1>&6
-echo "configure:1457: checking for GNU ld" >&5
+echo "configure:1446: checking for GNU ld" >&5
else
echo $ac_n "checking for non-GNU ld""... $ac_c" 1>&6
-echo "configure:1460: checking for non-GNU ld" >&5
+echo "configure:1449: checking for non-GNU ld" >&5
fi
if eval "test \"`echo '$''{'lt_cv_path_LD'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
fi
test -z "$LD" && { echo "configure: error: no acceptable ld found in \$PATH" 1>&2; exit 1; }
echo $ac_n "checking if the linker ($LD) is GNU ld""... $ac_c" 1>&6
-echo "configure:1495: checking if the linker ($LD) is GNU ld" >&5
+echo "configure:1484: checking if the linker ($LD) is GNU ld" >&5
if eval "test \"`echo '$''{'lt_cv_prog_gnu_ld'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
echo $ac_n "checking for $LD option to reload object files""... $ac_c" 1>&6
-echo "configure:1512: checking for $LD option to reload object files" >&5
+echo "configure:1501: checking for $LD option to reload object files" >&5
if eval "test \"`echo '$''{'lt_cv_ld_reload_flag'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
test -n "$reload_flag" && reload_flag=" $reload_flag"
echo $ac_n "checking for BSD-compatible nm""... $ac_c" 1>&6
-echo "configure:1524: checking for BSD-compatible nm" >&5
+echo "configure:1513: checking for BSD-compatible nm" >&5
if eval "test \"`echo '$''{'lt_cv_path_NM'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
echo "$ac_t""$NM" 1>&6
echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6
-echo "configure:1562: checking whether ln -s works" >&5
+echo "configure:1551: checking whether ln -s works" >&5
if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
fi
echo $ac_n "checking how to recognise dependant libraries""... $ac_c" 1>&6
-echo "configure:1583: checking how to recognise dependant libraries" >&5
+echo "configure:1572: checking how to recognise dependant libraries" >&5
if eval "test \"`echo '$''{'lt_cv_deplibs_check_method'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
deplibs_check_method=$lt_cv_deplibs_check_method
echo $ac_n "checking for object suffix""... $ac_c" 1>&6
-echo "configure:1747: checking for object suffix" >&5
+echo "configure:1736: checking for object suffix" >&5
if eval "test \"`echo '$''{'ac_cv_objext'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
rm -f conftest*
echo 'int i = 1;' > conftest.$ac_ext
-if { (eval echo configure:1753: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1742: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
for ac_file in conftest.*; do
case $ac_file in
*.c) ;;
echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
-echo "configure:1773: checking for executable suffix" >&5
+echo "configure:1762: checking for executable suffix" >&5
if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
rm -f conftest*
echo 'int main () { return 0; }' > conftest.$ac_ext
ac_cv_exeext=
- if { (eval echo configure:1783: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
+ if { (eval echo configure:1772: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
for file in conftest.*; do
case $file in
- *.c | *.o | *.obj | *.ilk | *.pdb) ;;
+ *.c | *.o | *.obj) ;;
*) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;;
esac
done
file_magic*)
if test "$file_magic_cmd" = '$MAGIC_CMD'; then
echo $ac_n "checking for ${ac_tool_prefix}file""... $ac_c" 1>&6
-echo "configure:1810: checking for ${ac_tool_prefix}file" >&5
+echo "configure:1799: checking for ${ac_tool_prefix}file" >&5
if eval "test \"`echo '$''{'lt_cv_path_MAGIC_CMD'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
if test -z "$lt_cv_path_MAGIC_CMD"; then
if test -n "$ac_tool_prefix"; then
echo $ac_n "checking for file""... $ac_c" 1>&6
-echo "configure:1872: checking for file" >&5
+echo "configure:1861: checking for file" >&5
if eval "test \"`echo '$''{'lt_cv_path_MAGIC_CMD'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
set dummy ${ac_tool_prefix}ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1943: checking for $ac_word" >&5
+echo "configure:1932: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "ranlib", so it can be a program name with args.
set dummy ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1975: checking for $ac_word" >&5
+echo "configure:1964: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
set dummy ${ac_tool_prefix}strip; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2010: checking for $ac_word" >&5
+echo "configure:1999: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_STRIP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "strip", so it can be a program name with args.
set dummy strip; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2042: checking for $ac_word" >&5
+echo "configure:2031: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_STRIP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
case $host in
*-*-irix6*)
# Find out which ABI we are using.
- echo '#line 2109 "configure"' > conftest.$ac_ext
- if { (eval echo configure:2110: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+ echo '#line 2098 "configure"' > conftest.$ac_ext
+ if { (eval echo configure:2099: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
case `/usr/bin/file conftest.$ac_objext` in
*32-bit*)
LD="${LD-ld} -32"
SAVE_CFLAGS="$CFLAGS"
CFLAGS="$CFLAGS -belf"
echo $ac_n "checking whether the C compiler needs -belf""... $ac_c" 1>&6
-echo "configure:2131: checking whether the C compiler needs -belf" >&5
+echo "configure:2120: checking whether the C compiler needs -belf" >&5
if eval "test \"`echo '$''{'lt_cv_cc_needs_belf'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext <<EOF
-#line 2144 "configure"
+#line 2133 "configure"
#include "confdefs.h"
int main() {
; return 0; }
EOF
-if { (eval echo configure:2151: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2140: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
lt_cv_cc_needs_belf=yes
else
fi
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:2319: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:2308: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
-echo "configure:2344: checking for executable suffix" >&5
+echo "configure:2333: checking for executable suffix" >&5
if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
rm -f conftest*
echo 'int main () { return 0; }' > conftest.$ac_ext
ac_cv_exeext=
- if { (eval echo configure:2354: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
+ if { (eval echo configure:2343: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
for file in conftest.*; do
case $file in
- *.c | *.o | *.obj | *.ilk | *.pdb) ;;
+ *.c | *.o | *.obj) ;;
*) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;;
esac
done
# Extract the first word of "gcc", so it can be a program name with args.
set dummy gcc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2380: checking for $ac_word" >&5
+echo "configure:2369: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "cc", so it can be a program name with args.
set dummy cc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2410: checking for $ac_word" >&5
+echo "configure:2399: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "cl", so it can be a program name with args.
set dummy cl; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2461: checking for $ac_word" >&5
+echo "configure:2450: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:2493: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:2482: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
cat > conftest.$ac_ext << EOF
-#line 2504 "configure"
+#line 2493 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:2509: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2498: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:2535: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:2524: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:2540: checking whether we are using GNU C" >&5
+echo "configure:2529: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:2549: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:2538: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:2568: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:2557: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ALL_LINGUAS=
echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
-echo "configure:2602: checking how to run the C preprocessor" >&5
+echo "configure:2591: checking how to run the C preprocessor" >&5
# On Suns, sometimes $CPP names a directory.
if test -n "$CPP" && test -d "$CPP"; then
CPP=
# On the NeXT, cc -E runs the code through the compiler's parser,
# not just through cpp.
cat > conftest.$ac_ext <<EOF
-#line 2617 "configure"
+#line 2606 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2623: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2612: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
rm -rf conftest*
CPP="${CC-cc} -E -traditional-cpp"
cat > conftest.$ac_ext <<EOF
-#line 2634 "configure"
+#line 2623 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2640: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2629: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
rm -rf conftest*
CPP="${CC-cc} -nologo -E"
cat > conftest.$ac_ext <<EOF
-#line 2651 "configure"
+#line 2640 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2657: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2646: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
# Extract the first word of "ranlib", so it can be a program name with args.
set dummy ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2684: checking for $ac_word" >&5
+echo "configure:2673: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
fi
echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
-echo "configure:2712: checking for ANSI C header files" >&5
+echo "configure:2701: checking for ANSI C header files" >&5
if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2717 "configure"
+#line 2706 "configure"
#include "confdefs.h"
#include <stdlib.h>
#include <stdarg.h>
#include <float.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2725: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2714: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
if test $ac_cv_header_stdc = yes; then
# SunOS 4.x string.h does not declare mem*, contrary to ANSI.
cat > conftest.$ac_ext <<EOF
-#line 2742 "configure"
+#line 2731 "configure"
#include "confdefs.h"
#include <string.h>
EOF
if test $ac_cv_header_stdc = yes; then
# ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
cat > conftest.$ac_ext <<EOF
-#line 2760 "configure"
+#line 2749 "configure"
#include "confdefs.h"
#include <stdlib.h>
EOF
:
else
cat > conftest.$ac_ext <<EOF
-#line 2781 "configure"
+#line 2770 "configure"
#include "confdefs.h"
#include <ctype.h>
#define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
exit (0); }
EOF
-if { (eval echo configure:2792: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:2781: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
:
else
fi
echo $ac_n "checking for working const""... $ac_c" 1>&6
-echo "configure:2816: checking for working const" >&5
+echo "configure:2805: checking for working const" >&5
if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2821 "configure"
+#line 2810 "configure"
#include "confdefs.h"
int main() {
; return 0; }
EOF
-if { (eval echo configure:2870: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:2859: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_c_const=yes
else
fi
echo $ac_n "checking for inline""... $ac_c" 1>&6
-echo "configure:2891: checking for inline" >&5
+echo "configure:2880: checking for inline" >&5
if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_cv_c_inline=no
for ac_kw in inline __inline__ __inline; do
cat > conftest.$ac_ext <<EOF
-#line 2898 "configure"
+#line 2887 "configure"
#include "confdefs.h"
int main() {
} $ac_kw foo() {
; return 0; }
EOF
-if { (eval echo configure:2905: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:2894: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_c_inline=$ac_kw; break
else
esac
echo $ac_n "checking for off_t""... $ac_c" 1>&6
-echo "configure:2931: checking for off_t" >&5
+echo "configure:2920: checking for off_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2936 "configure"
+#line 2925 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
fi
echo $ac_n "checking for size_t""... $ac_c" 1>&6
-echo "configure:2964: checking for size_t" >&5
+echo "configure:2953: checking for size_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2969 "configure"
+#line 2958 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
# for constant arguments. Useless!
echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6
-echo "configure:2999: checking for working alloca.h" >&5
+echo "configure:2988: checking for working alloca.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3004 "configure"
+#line 2993 "configure"
#include "confdefs.h"
#include <alloca.h>
int main() {
char *p = alloca(2 * sizeof(int));
; return 0; }
EOF
-if { (eval echo configure:3011: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3000: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
ac_cv_header_alloca_h=yes
else
fi
echo $ac_n "checking for alloca""... $ac_c" 1>&6
-echo "configure:3032: checking for alloca" >&5
+echo "configure:3021: checking for alloca" >&5
if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3037 "configure"
+#line 3026 "configure"
#include "confdefs.h"
#ifdef __GNUC__
char *p = (char *) alloca(1);
; return 0; }
EOF
-if { (eval echo configure:3065: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3054: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
ac_cv_func_alloca_works=yes
else
echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6
-echo "configure:3097: checking whether alloca needs Cray hooks" >&5
+echo "configure:3086: checking whether alloca needs Cray hooks" >&5
if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3102 "configure"
+#line 3091 "configure"
#include "confdefs.h"
#if defined(CRAY) && ! defined(CRAY2)
webecray
if test $ac_cv_os_cray = yes; then
for ac_func in _getb67 GETB67 getb67; do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3127: checking for $ac_func" >&5
+echo "configure:3116: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3132 "configure"
+#line 3121 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:3155: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3144: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
fi
echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6
-echo "configure:3182: checking stack direction for C alloca" >&5
+echo "configure:3171: checking stack direction for C alloca" >&5
if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_cv_c_stack_direction=0
else
cat > conftest.$ac_ext <<EOF
-#line 3190 "configure"
+#line 3179 "configure"
#include "confdefs.h"
find_stack_direction ()
{
exit (find_stack_direction() < 0);
}
EOF
-if { (eval echo configure:3209: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:3198: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_c_stack_direction=1
else
fi
-for ac_hdr in unistd.h
+for ac_hdr in stdlib.h unistd.h sys/stat.h sys/types.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:3234: checking for $ac_hdr" >&5
+echo "configure:3223: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3239 "configure"
+#line 3228 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3244: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3233: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
for ac_func in getpagesize
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3273: checking for $ac_func" >&5
+echo "configure:3262: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3278 "configure"
+#line 3267 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:3301: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3290: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
done
echo $ac_n "checking for working mmap""... $ac_c" 1>&6
-echo "configure:3326: checking for working mmap" >&5
+echo "configure:3315: checking for working mmap" >&5
if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_cv_func_mmap_fixed_mapped=no
else
cat > conftest.$ac_ext <<EOF
-#line 3334 "configure"
+#line 3323 "configure"
#include "confdefs.h"
/* Thanks to Mike Haertel and Jim Avera for this test.
#include <fcntl.h>
#include <sys/mman.h>
+#if HAVE_SYS_TYPES_H
+# include <sys/types.h>
+#endif
+
+#if HAVE_STDLIB_H
+# include <stdlib.h>
+#endif
+
+#if HAVE_SYS_STAT_H
+# include <sys/stat.h>
+#endif
+
+#if HAVE_UNISTD_H
+# include <unistd.h>
+#endif
+
/* This mess was copied from the GNU getpagesize.h. */
#ifndef HAVE_GETPAGESIZE
-# ifdef HAVE_UNISTD_H
-# include <unistd.h>
-# endif
/* Assume that all systems that can run configure have sys/param.h. */
# ifndef HAVE_SYS_PARAM_H
}
EOF
-if { (eval echo configure:3474: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:3476: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_func_mmap_fixed_mapped=yes
else
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:3502: checking for $ac_hdr" >&5
+echo "configure:3504: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3507 "configure"
+#line 3509 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3512: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3514: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
__argz_count __argz_stringify __argz_next
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3542: checking for $ac_func" >&5
+echo "configure:3544: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3547 "configure"
+#line 3549 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:3570: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3572: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
for ac_func in stpcpy
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3599: checking for $ac_func" >&5
+echo "configure:3601: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3604 "configure"
+#line 3606 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:3627: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3629: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
if test $ac_cv_header_locale_h = yes; then
echo $ac_n "checking for LC_MESSAGES""... $ac_c" 1>&6
-echo "configure:3661: checking for LC_MESSAGES" >&5
+echo "configure:3663: checking for LC_MESSAGES" >&5
if eval "test \"`echo '$''{'am_cv_val_LC_MESSAGES'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3666 "configure"
+#line 3668 "configure"
#include "confdefs.h"
#include <locale.h>
int main() {
return LC_MESSAGES
; return 0; }
EOF
-if { (eval echo configure:3673: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3675: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
am_cv_val_LC_MESSAGES=yes
else
fi
fi
echo $ac_n "checking whether NLS is requested""... $ac_c" 1>&6
-echo "configure:3694: checking whether NLS is requested" >&5
+echo "configure:3696: checking whether NLS is requested" >&5
# Check whether --enable-nls or --disable-nls was given.
if test "${enable_nls+set}" = set; then
enableval="$enable_nls"
EOF
echo $ac_n "checking whether included gettext is requested""... $ac_c" 1>&6
-echo "configure:3714: checking whether included gettext is requested" >&5
+echo "configure:3716: checking whether included gettext is requested" >&5
# Check whether --with-included-gettext or --without-included-gettext was given.
if test "${with_included_gettext+set}" = set; then
withval="$with_included_gettext"
ac_safe=`echo "libintl.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for libintl.h""... $ac_c" 1>&6
-echo "configure:3733: checking for libintl.h" >&5
+echo "configure:3735: checking for libintl.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3738 "configure"
+#line 3740 "configure"
#include "confdefs.h"
#include <libintl.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3743: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3745: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
echo "$ac_t""yes" 1>&6
echo $ac_n "checking for gettext in libc""... $ac_c" 1>&6
-echo "configure:3760: checking for gettext in libc" >&5
+echo "configure:3762: checking for gettext in libc" >&5
if eval "test \"`echo '$''{'gt_cv_func_gettext_libc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3765 "configure"
+#line 3767 "configure"
#include "confdefs.h"
#include <libintl.h>
int main() {
return (int) gettext ("")
; return 0; }
EOF
-if { (eval echo configure:3772: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3774: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
gt_cv_func_gettext_libc=yes
else
if test "$gt_cv_func_gettext_libc" != "yes"; then
echo $ac_n "checking for bindtextdomain in -lintl""... $ac_c" 1>&6
-echo "configure:3788: checking for bindtextdomain in -lintl" >&5
+echo "configure:3790: checking for bindtextdomain in -lintl" >&5
ac_lib_var=`echo intl'_'bindtextdomain | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lintl $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 3796 "configure"
+#line 3798 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
bindtextdomain()
; return 0; }
EOF
-if { (eval echo configure:3807: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3809: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
echo "$ac_t""yes" 1>&6
echo $ac_n "checking for gettext in libintl""... $ac_c" 1>&6
-echo "configure:3823: checking for gettext in libintl" >&5
+echo "configure:3825: checking for gettext in libintl" >&5
if eval "test \"`echo '$''{'gt_cv_func_gettext_libintl'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3828 "configure"
+#line 3830 "configure"
#include "confdefs.h"
int main() {
return (int) gettext ("")
; return 0; }
EOF
-if { (eval echo configure:3835: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3837: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
gt_cv_func_gettext_libintl=yes
else
# Extract the first word of "msgfmt", so it can be a program name with args.
set dummy msgfmt; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3863: checking for $ac_word" >&5
+echo "configure:3865: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
for ac_func in dcgettext
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3897: checking for $ac_func" >&5
+echo "configure:3899: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3902 "configure"
+#line 3904 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:3925: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3927: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
# Extract the first word of "gmsgfmt", so it can be a program name with args.
set dummy gmsgfmt; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3952: checking for $ac_word" >&5
+echo "configure:3954: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "xgettext", so it can be a program name with args.
set dummy xgettext; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3988: checking for $ac_word" >&5
+echo "configure:3990: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
fi
cat > conftest.$ac_ext <<EOF
-#line 4020 "configure"
+#line 4022 "configure"
#include "confdefs.h"
int main() {
return _nl_msg_cat_cntr
; return 0; }
EOF
-if { (eval echo configure:4028: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4030: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
CATOBJEXT=.gmo
DATADIRNAME=share
# Extract the first word of "msgfmt", so it can be a program name with args.
set dummy msgfmt; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4060: checking for $ac_word" >&5
+echo "configure:4062: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "gmsgfmt", so it can be a program name with args.
set dummy gmsgfmt; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4094: checking for $ac_word" >&5
+echo "configure:4096: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "xgettext", so it can be a program name with args.
set dummy xgettext; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4130: checking for $ac_word" >&5
+echo "configure:4132: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
LINGUAS=
else
echo $ac_n "checking for catalogs to be installed""... $ac_c" 1>&6
-echo "configure:4220: checking for catalogs to be installed" >&5
+echo "configure:4222: checking for catalogs to be installed" >&5
NEW_LINGUAS=
for lang in ${LINGUAS=$ALL_LINGUAS}; do
case "$ALL_LINGUAS" in
if test "$CATOBJEXT" = ".cat"; then
ac_safe=`echo "linux/version.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for linux/version.h""... $ac_c" 1>&6
-echo "configure:4248: checking for linux/version.h" >&5
+echo "configure:4250: checking for linux/version.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4253 "configure"
+#line 4255 "configure"
#include "confdefs.h"
#include <linux/version.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:4258: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:4260: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
EXEEXT_FOR_BUILD='$(EXEEXT)'
else
echo $ac_n "checking for build system executable suffix""... $ac_c" 1>&6
-echo "configure:4336: checking for build system executable suffix" >&5
+echo "configure:4338: checking for build system executable suffix" >&5
if eval "test \"`echo '$''{'bfd_cv_build_exeext'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:4373: checking for a BSD compatible install" >&5
+echo "configure:4375: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:4430: checking for $ac_hdr" >&5
+echo "configure:4432: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4435 "configure"
+#line 4437 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:4440: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:4442: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
bfd_m88k_arch) ta="$ta m88k-dis.lo" ;;
bfd_mcore_arch) ta="$ta mcore-dis.lo" ;;
bfd_mips_arch) ta="$ta mips-dis.lo mips-opc.lo mips16-opc.lo" ;;
+ bfd_mmix_arch) ta="$ta mmix-dis.lo mmix-opc.lo" ;;
bfd_mn10200_arch) ta="$ta m10200-dis.lo m10200-opc.lo" ;;
bfd_mn10300_arch) ta="$ta m10300-dis.lo m10300-opc.lo" ;;
bfd_ns32k_arch) ta="$ta ns32k-dis.lo" ;;
bfd_m88k_arch) ta="$ta m88k-dis.lo" ;;
bfd_mcore_arch) ta="$ta mcore-dis.lo" ;;
bfd_mips_arch) ta="$ta mips-dis.lo mips-opc.lo mips16-opc.lo" ;;
+ bfd_mmix_arch) ta="$ta mmix-dis.lo mmix-opc.lo" ;;
bfd_mn10200_arch) ta="$ta m10200-dis.lo m10200-opc.lo" ;;
bfd_mn10300_arch) ta="$ta m10300-dis.lo m10300-opc.lo" ;;
bfd_ns32k_arch) ta="$ta ns32k-dis.lo" ;;
#define ARCH_m88k
#define ARCH_mcore
#define ARCH_mips
+#define ARCH_mmix
#define ARCH_mn10200
#define ARCH_mn10300
#define ARCH_ns32k
disassemble = print_insn_little_mips;
break;
#endif
+#ifdef ARCH_mmix
+ case bfd_arch_mmix:
+ disassemble = print_insn_mmix;
+ break;
+#endif
#ifdef ARCH_mn10200
case bfd_arch_mn10200:
disassemble = print_insn_mn10200;
CGEN_INSN_INT insn_value;
const CGEN_INSN_LIST *insn_list;
CGEN_EXTRACT_INFO ex_info;
+ int basesize;
/* Extract base part of instruction, just in case CGEN_DIS_* uses it. */
- insn_value = cgen_get_insn_value (cd, buf, buflen * 8);
+ basesize = cd->base_insn_bitsize < buflen * 8 ?
+ cd->base_insn_bitsize : buflen * 8;
+ insn_value = cgen_get_insn_value (cd, buf, basesize);
+
/* Fill in ex_info fields like read_insn would. Don't actually call
read_insn, since the incoming buffer is already read (and possibly