summaryrefslogtreecommitdiffstats
path: root/binutils-2.25/gas/config/tc-hppa.c
diff options
context:
space:
mode:
Diffstat (limited to 'binutils-2.25/gas/config/tc-hppa.c')
-rw-r--r--binutils-2.25/gas/config/tc-hppa.c18
1 files changed, 6 insertions, 12 deletions
diff --git a/binutils-2.25/gas/config/tc-hppa.c b/binutils-2.25/gas/config/tc-hppa.c
index 6e2debe9..5ee7f726 100644
--- a/binutils-2.25/gas/config/tc-hppa.c
+++ b/binutils-2.25/gas/config/tc-hppa.c
@@ -1,7 +1,5 @@
/* tc-hppa.c -- Assemble for the PA
- Copyright 1989, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
- 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2012
- Free Software Foundation, Inc.
+ Copyright (C) 1989-2014 Free Software Foundation, Inc.
This file is part of GAS, the GNU Assembler.
@@ -608,9 +606,6 @@ static int within_procedure;
seen in each subspace. */
static label_symbol_struct *label_symbols_rootp = NULL;
-/* Holds the last field selector. */
-static int hppa_field_selector;
-
/* Nonzero when strict matching is enabled. Zero otherwise.
Each opcode in the table has a flag which indicates whether or
@@ -1265,7 +1260,8 @@ fix_new_hppa (fragS *frag,
hppa_field_selector is set by the parse_cons_expression_hppa. */
void
-cons_fix_new_hppa (fragS *frag, int where, int size, expressionS *exp)
+cons_fix_new_hppa (fragS *frag, int where, int size, expressionS *exp,
+ int hppa_field_selector)
{
unsigned int rel_type;
@@ -1302,9 +1298,6 @@ cons_fix_new_hppa (fragS *frag, int where, int size, expressionS *exp)
fix_new_hppa (frag, where, size,
(symbolS *) NULL, (offsetT) 0, exp, 0, rel_type,
hppa_field_selector, size * 8, 0, 0);
-
- /* Reset field selector to its default state. */
- hppa_field_selector = 0;
}
/* Mark (via expr_end) the end of an expression (I think). FIXME. */
@@ -2519,11 +2512,12 @@ pa_chk_field_selector (char **str)
/* Parse a .byte, .word, .long expression for the HPPA. Called by
cons via the TC_PARSE_CONS_EXPRESSION macro. */
-void
+int
parse_cons_expression_hppa (expressionS *exp)
{
- hppa_field_selector = pa_chk_field_selector (&input_line_pointer);
+ int hppa_field_selector = pa_chk_field_selector (&input_line_pointer);
expression (exp);
+ return hppa_field_selector;
}
/* Evaluate an absolute expression EXP which may be modified by