From b82b0773d7cd311372e29da6add0d0c48d15d1b3 Mon Sep 17 00:00:00 2001 From: Michael Meissner Date: Tue, 6 Apr 1993 16:09:50 +0000 Subject: More mips gas changes, allow -gdwarf on OSF/1 From-SVN: r4027 --- gcc/config/i386/osfrose.h | 7 +++++++ gcc/config/mips/mips.c | 6 +----- gcc/config/mips/mips.h | 18 +++++++++++++----- gcc/config/mips/osfrose.h | 15 +++++++-------- 4 files changed, 28 insertions(+), 18 deletions(-) (limited to 'gcc') diff --git a/gcc/config/i386/osfrose.h b/gcc/config/i386/osfrose.h index 1cc4c8c..736824f4 100644 --- a/gcc/config/i386/osfrose.h +++ b/gcc/config/i386/osfrose.h @@ -49,6 +49,13 @@ the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */ { "no-half-pic", -MASK_HALF_PIC}, \ { "debugb", MASK_HALF_PIC_DEBUG}, +/* OSF/rose uses stabs, not dwarf. */ +#define PREFERRED_DEBUGGING_TYPE DBX_DEBUG + +#ifndef DWARF_DEBUGGING_INFO +#define DWARF_DEBUGGING_INFO /* enable dwarf debugging for testing */ +#endif + /* Prefix that appears before all global/static identifiers, except for temporary labels. */ diff --git a/gcc/config/mips/mips.c b/gcc/config/mips/mips.c index 47b0000..1bf3d2d 100644 --- a/gcc/config/mips/mips.c +++ b/gcc/config/mips/mips.c @@ -2764,11 +2764,7 @@ override_options () register int regno; register enum machine_mode mode; - if (g_switch_set) - mips_section_threshold = g_switch_value; - - else - mips_section_threshold = (TARGET_MIPS_AS) ? 8 : 0; + mips_section_threshold = (g_switch_set) ? g_switch_value : MIPS_DEFAULT_GVALUE; /* Identify the processor type */ if (mips_cpu_string == (char *)0 diff --git a/gcc/config/mips/mips.h b/gcc/config/mips/mips.h index a888803..07ecb22 100644 --- a/gcc/config/mips/mips.h +++ b/gcc/config/mips/mips.h @@ -645,7 +645,7 @@ while (0) /* Print subsidiary information on the compiler version in use. */ -#define MIPS_VERSION "[AL 1.1, MM 37]" +#define MIPS_VERSION "[AL 1.1, MM 38]" #ifndef MACHINE_TYPE #define MACHINE_TYPE "BSD Mips" @@ -720,7 +720,8 @@ do { \ #define PUT_SDB_DEF(a) \ do { \ extern FILE *asm_out_text_file; \ - fprintf (asm_out_text_file, "\t#.def\t"); \ + fprintf (asm_out_text_file, "\t%s.def\t", \ + (TARGET_GAS) ? "" : "#"); \ ASM_OUTPUT_LABELREF (asm_out_text_file, a); \ fputc (';', asm_out_text_file); \ } while (0) @@ -728,7 +729,8 @@ do { \ #define PUT_SDB_PLAIN_DEF(a) \ do { \ extern FILE *asm_out_text_file; \ - fprintf (asm_out_text_file, "\t#.def\t.%s;", (a)); \ + fprintf (asm_out_text_file, "\t%s.def\t.%s;", \ + (TARGET_GAS) ? "" : "#", (a)); \ } while (0) #define PUT_SDB_ENDEF \ @@ -796,8 +798,9 @@ do { \ do { \ extern FILE *asm_out_text_file; \ fprintf (asm_out_text_file, \ - "$Lb%d:\n\t#.begin\t$Lb%d\t%d\n", \ + "$Lb%d:\n\t%s.begin\t$Lb%d\t%d\n", \ sdb_label_count, \ + (TARGET_GAS) ? "" : "#", \ sdb_label_count, \ (LINE)); \ sdb_label_count++; \ @@ -807,8 +810,9 @@ do { \ do { \ extern FILE *asm_out_text_file; \ fprintf (asm_out_text_file, \ - "$Le%d:\n\t#.bend\t$Le%d\t%d\n", \ + "$Le%d:\n\t%s.bend\t$Le%d\t%d\n", \ sdb_label_count, \ + (TARGET_GAS) ? "" : "#", \ sdb_label_count, \ (LINE)); \ sdb_label_count++; \ @@ -3368,6 +3372,10 @@ do { \ assemble_string (p, size); \ } +/* Default to -G 8 */ +#ifndef MIPS_DEFAULT_GVALUE +#define MIPS_DEFAULT_GVALUE 8 +#endif /* Define the strings to put out for each section in the object file. */ #define TEXT_SECTION_ASM_OP "\t.text" /* instructions */ diff --git a/gcc/config/mips/osfrose.h b/gcc/config/mips/osfrose.h index 518f2e1..f2afd62 100644 --- a/gcc/config/mips/osfrose.h +++ b/gcc/config/mips/osfrose.h @@ -126,19 +126,15 @@ the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */ #define WCHAR_TYPE "unsigned int" #define WCHAR_TYPE_SIZE BITS_PER_WORD -#if 0 -#define WCHAR_TYPE ((TARGET_WC8) \ - ? "unsigned char" \ - : ((TARGET_WC16) \ - ? "short unsigned int" \ - : "long unsigned int")) -#endif - +/* OSF/1 uses gas, not the mips assembler. */ #define TARGET_DEFAULT MASK_GAS /* OSF/rose uses stabs, not ECOFF. */ #define PREFERRED_DEBUGGING_TYPE DBX_DEBUG +/* enable dwarf debugging for testing */ +#define DWARF_DEBUGGING_INFO + /* Tell collect that the object format is OSF/rose. */ #define OBJECT_FORMAT_ROSE @@ -147,6 +143,9 @@ the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */ #define REAL_NM_FILE_NAME "/usr/ccs/bin/nm" #define REAL_STRIP_FILE_NAME "/usr/ccs/bin/strip" +/* Default to -G 0 unless doing ecoff work. */ +#define MIPS_DEFAULT_GVALUE ((TARGET_MIPS_AS) ? 8 : 0) + /* Use atexit for static constructors/destructors, instead of defining our own exit function. */ #define HAVE_ATEXIT -- cgit v1.1