diff options
author | Alan Modra <amodra@gmail.com> | 2001-03-30 02:19:36 +0000 |
---|---|---|
committer | Alan Modra <amodra@gmail.com> | 2001-03-30 02:19:36 +0000 |
commit | e46d99eb07bc0e366152fe2e69c613a15496e347 (patch) | |
tree | 55c79a36f0269e43402893bb90316d29a865e26f /gas/symbols.c | |
parent | bee723322c56ee34f9f511e901171e8ebfe5d22e (diff) | |
download | gdb-e46d99eb07bc0e366152fe2e69c613a15496e347.zip gdb-e46d99eb07bc0e366152fe2e69c613a15496e347.tar.gz gdb-e46d99eb07bc0e366152fe2e69c613a15496e347.tar.bz2 |
Multi-pass relaxation machinery.
Diffstat (limited to 'gas/symbols.c')
-rw-r--r-- | gas/symbols.c | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/gas/symbols.c b/gas/symbols.c index b983ddb..913686c 100644 --- a/gas/symbols.c +++ b/gas/symbols.c @@ -866,6 +866,10 @@ resolve_symbol_value (symp, finalize) resolved = 0; final_seg = S_GET_SEGMENT (symp); + /* Expressions aren't really symbols, so don't finalize their values + until relaxation is complete. */ + if (final_seg == expr_section && finalize != 2) + finalize = 0; if (symp->sy_resolving) { @@ -1182,7 +1186,7 @@ resolve_local_symbol (key, value) PTR value; { if (value != NULL) - resolve_symbol_value (value, 1); + resolve_symbol_value (value, finalize_syms); } #endif @@ -1574,7 +1578,11 @@ S_GET_VALUE (s) #endif if (!s->sy_resolved && s->sy_value.X_op != O_constant) - resolve_symbol_value (s, 1); + { + valueT val = resolve_symbol_value (s, finalize_syms); + if (finalize_syms != 2 && S_GET_SEGMENT (s) == expr_section) + return val; + } if (s->sy_value.X_op != O_constant) { static symbolS *recur; |