15ba6b03cSchristos /* tc-visium.h -- Header file for tc-visium.c.
25ba6b03cSchristos 
3*f22f0ef4Schristos    Copyright (C) 2005-2022 Free Software Foundation, Inc.
45ba6b03cSchristos 
55ba6b03cSchristos    This file is part of GAS, the GNU Assembler.
65ba6b03cSchristos 
75ba6b03cSchristos    GAS is free software; you can redistribute it and/or modify
85ba6b03cSchristos    it under the terms of the GNU General Public License as published by
95ba6b03cSchristos    the Free Software Foundation; either version 2, or (at your option)
105ba6b03cSchristos    any later version.
115ba6b03cSchristos 
125ba6b03cSchristos    GAS is distributed in the hope that it will be useful,
135ba6b03cSchristos    but WITHOUT ANY WARRANTY; without even the implied warranty of
145ba6b03cSchristos    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
155ba6b03cSchristos    GNU General Public License for more details.
165ba6b03cSchristos 
175ba6b03cSchristos    You should have received a copy of the GNU General Public License
1898f124a6Schristos    along with this program; if not, write to the Free Software
1998f124a6Schristos    Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston,
2098f124a6Schristos    MA 02110-1301, USA.  */
215ba6b03cSchristos 
225ba6b03cSchristos #define TC_VISIUM
235ba6b03cSchristos 
245ba6b03cSchristos #define LISTING_HEADER "VISIUM GAS "
255ba6b03cSchristos 
265ba6b03cSchristos /* The target BFD architecture.  */
275ba6b03cSchristos #define TARGET_ARCH bfd_arch_visium
285ba6b03cSchristos 
295ba6b03cSchristos #define TARGET_BYTES_BIG_ENDIAN 1
305ba6b03cSchristos 
315ba6b03cSchristos #define TARGET_FORMAT "elf32-visium"
325ba6b03cSchristos 
335ba6b03cSchristos /* Permit temporary numeric labels.  */
345ba6b03cSchristos #define LOCAL_LABELS_FB 1
355ba6b03cSchristos 
365ba6b03cSchristos /* .-foo gets turned into PC relative relocs.  */
375ba6b03cSchristos #define DIFF_EXPR_OK
385ba6b03cSchristos 
395ba6b03cSchristos /* We don't support external symbols overriding.  */
405ba6b03cSchristos #define EXTERN_FORCE_RELOC 0
415ba6b03cSchristos 
425ba6b03cSchristos /* We don't need to handle .word strangely.  */
435ba6b03cSchristos #define WORKING_DOT_WORD
445ba6b03cSchristos 
455ba6b03cSchristos #define tc_fix_adjustable(FIXP) visium_fix_adjustable (FIXP)
46*f22f0ef4Schristos extern bool visium_fix_adjustable (struct fix *);
475ba6b03cSchristos 
485ba6b03cSchristos #define HANDLE_ALIGN(FRAGP)		 \
495ba6b03cSchristos   if ((FRAGP)->fr_type == rs_align_code) \
505ba6b03cSchristos     visium_handle_align (FRAGP);
515ba6b03cSchristos extern void visium_handle_align (struct frag *);
525ba6b03cSchristos 
535ba6b03cSchristos #define md_relax_frag(segment, fragp, stretch) \
545ba6b03cSchristos   visium_relax_frag (segment, fragp, stretch)
555ba6b03cSchristos extern int visium_relax_frag (asection *, struct frag *, long);
565ba6b03cSchristos 
575ba6b03cSchristos /* Call md_pcrel_from_section, not md_pcrel_from.  */
585ba6b03cSchristos #define MD_PCREL_FROM_SECTION(FIXP, SEC) visium_pcrel_from_section (FIXP, SEC)
595ba6b03cSchristos extern long visium_pcrel_from_section (struct fix *, segT);
605ba6b03cSchristos 
615ba6b03cSchristos /* Values passed to md_apply_fix3 don't include the symbol value.  */
625ba6b03cSchristos #define MD_APPLY_SYM_VALUE(FIX) 0
635ba6b03cSchristos 
645ba6b03cSchristos #define md_operand(x)
655ba6b03cSchristos 
665ba6b03cSchristos #define tc_comment_chars visium_comment_chars
675ba6b03cSchristos extern const char *visium_comment_chars;
685ba6b03cSchristos 
695ba6b03cSchristos #define TARGET_USE_CFIPOP 1
705ba6b03cSchristos 
715ba6b03cSchristos #define tc_cfi_frame_initial_instructions visium_cfi_frame_initial_instructions
725ba6b03cSchristos extern void visium_cfi_frame_initial_instructions (void);
735ba6b03cSchristos 
745ba6b03cSchristos #define tc_regname_to_dw2regnum visium_regname_to_dw2regnum
755ba6b03cSchristos extern int visium_regname_to_dw2regnum (char *regname);
765ba6b03cSchristos 
775ba6b03cSchristos #define DWARF2_LINE_MIN_INSN_LENGTH     4
785ba6b03cSchristos #define DWARF2_DEFAULT_RETURN_COLUMN    21
795ba6b03cSchristos #define DWARF2_CIE_DATA_ALIGNMENT       (-4)
80