aboutsummaryrefslogtreecommitdiff
path: root/gas/symbols.h
diff options
context:
space:
mode:
authorAlan Modra <amodra@gmail.com>2022-07-07 08:40:26 +0930
committerAlan Modra <amodra@gmail.com>2022-07-09 21:15:30 +0930
commitc30081c1f955a9fea2da8988bab96191e3d2171e (patch)
treeb8ecf3a18a6dcbf012f432928e46daabf0e1826c /gas/symbols.h
parentd3be5dab558ab91789800a03fc2c1dc3c529eaf5 (diff)
downloadgdb-c30081c1f955a9fea2da8988bab96191e3d2171e.zip
gdb-c30081c1f955a9fea2da8988bab96191e3d2171e.tar.gz
gdb-c30081c1f955a9fea2da8988bab96191e3d2171e.tar.bz2
gas: utility notes memory alloc functions
Makes it a little easier to use the notes obstack for persistent storage. * as.h (gas_mul_overflow): Define. * symbols.h (notes_alloc, notes_calloc, notes_memdup), (notes_strdup, notes_concat, notes_free): Declare. * symbols.c (notes_alloc, notes_calloc, notes_memdup), (notes_strdup, notes_concat, notes_free): New functions. (save_symbol_name): Use notes_strdup. (symbol_create, local_symbol_make, local_symbol_convert), (symbol_clone, decode_local_label_name): Use notes_alloc.
Diffstat (limited to 'gas/symbols.h')
-rw-r--r--gas/symbols.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/gas/symbols.h b/gas/symbols.h
index 19eb658..240e08f 100644
--- a/gas/symbols.h
+++ b/gas/symbols.h
@@ -35,6 +35,13 @@ extern int symbol_table_frozen;
default. */
extern int symbols_case_sensitive;
+extern void *notes_alloc (size_t);
+extern void *notes_calloc (size_t, size_t);
+extern void *notes_memdup (const void *, size_t, size_t);
+extern char *notes_strdup (const char *);
+extern char *notes_concat (const char *, ...);
+extern void notes_free (void *);
+
char * symbol_relc_make_expr (expressionS *);
char * symbol_relc_make_sym (symbolS *);
char * symbol_relc_make_value (offsetT);