Thu Jan 2 13:37:29 1997 Ian Lance Taylor <ian@cygnus.com>
+ Based on patch from Ronald F. Guilmette <rfg@monkeys.com>:
+ * read.c (read_a_source_file): Check for conditional operators
+ before doing an MRI pending alignment.
+ * config/tc-m68k.h (m68k_conditional_pseudoop): Declare.
+ (tc_conditional_pseudop): Define.
+ * config/tc-m68k.c (m68k_conditional_pseudop): New function.
+ * doc/internals.texi (CPU backend): Describe
+ tc_conditional_pseudoop.
+
Based on patch from Ronald F. Guilmette <rfg@monkeys.com>:
* config/tc-m68k.c (m68k_rel32_from_cmdline): New static
variable.
/* This file is tc-m68k.h
- Copyright (C) 1987, 89, 90, 91, 92, 93, 94, 95, 1996
+ Copyright (C) 1987, 89, 90, 91, 92, 93, 94, 95, 96, 1997
Free Software Foundation, Inc.
This file is part of GAS, the GNU Assembler.
#ifdef OBJ_AOUT
#ifdef TE_SUN3
#define TARGET_FORMAT "a.out-sunos-big"
-#else
+#endif
#ifdef TE_NetBSD
#define TARGET_FORMAT "a.out-m68k-netbsd"
-#else
-#define TARGET_FORMAT "a.out-zero-big"
#endif
+#ifdef TE_LINUX
+#define TARGET_FORMAT "a.out-m68k-linux"
+#endif
+#ifndef TARGET_FORMAT
+#define TARGET_FORMAT "a.out-zero-big"
#endif
#endif
extern int m68k_aout_machtype;
#endif
+#define tc_comment_chars m68k_comment_chars
+extern const char *m68k_comment_chars;
+
#define tc_crawl_symbol_chain(a) {;} /* not used */
#define tc_headers_hook(a) {;} /* not used */
#define tc_aout_pre_write_hook(x) {;} /* not used */
#define LISTING_LHS_CONT_LINES 4/* And 4 lines max */
#define LISTING_HEADER "68K GAS "
-/* Copied from write.c */
-#define M68K_AIM_KLUDGE(aim, this_state,this_type) \
- if (aim==0 && this_state== 4) { /* hard encoded from tc-m68k.c */ \
- aim=this_type->rlx_forward+1; /* Force relaxation into word mode */ \
- }
-
#ifndef REGISTER_PREFIX
#define REGISTER_PREFIX '%'
#endif
extern void m68k_mri_mode_change PARAMS ((int));
#define MRI_MODE_CHANGE(i) m68k_mri_mode_change (i)
+extern int m68k_conditional_pseudoop PARAMS ((pseudo_typeS *));
+#define tc_conditional_pseudoop(pop) m68k_conditional_pseudoop (pop)
+
#ifdef BFD_ASSEMBLER
#define tc_frob_symbol(sym,punt) \
extern struct relax_type md_relax_table[];
#define TC_GENERIC_RELAX_TABLE md_relax_table
+/* Copied from write.c */
+/* This was formerly called M68K_AIM_KLUDGE. */
+#define md_prepare_relax_scan(fragP, address, aim, this_state, this_type) \
+ if (aim==0 && this_state== 4) { /* hard encoded from tc-m68k.c */ \
+ aim=this_type->rlx_forward+1; /* Force relaxation into word mode */ \
+ }
+
/* end of tc-m68k.h */
/* read.c - read a source file -
- Copyright (C) 1986, 87, 90, 91, 92, 93, 94, 95, 1996
+ Copyright (C) 1986, 87, 90, 91, 92, 93, 94, 95, 96, 1997
Free Software Foundation, Inc.
This file is part of GAS, the GNU Assembler.
|| ! ((pop->poc_handler == cons
&& pop->poc_val == 1)
|| (pop->poc_handler == s_space
- && pop->poc_val == 1))))
+ && pop->poc_val == 1)
+#ifdef tc_conditional_pseudoop
+ || tc_conditional_pseudoop (pop)
+#endif
+ || pop->poc_handler == s_if
+ || pop->poc_handler == s_ifdef
+ || pop->poc_handler == s_ifc
+ || pop->poc_handler == s_ifeqs
+ || pop->poc_handler == s_else
+ || pop->poc_handler == s_endif)))
{
do_align (1, (char *) NULL, 0);
mri_pending_align = 0;