[PATCH 0/5] gas: dot handling

Jan Beulich jbeulich@suse.com
Fri Nov 22 12:38:21 GMT 2024


The fallout from dealing with PR gas/27217 has kept bothering me, so I
finally took the time to see whether we can't get things into better
shape. Before it goes in, especially the naming and defaulting aspects
(see the last patches for a respective remark) may want sorting, as in:
potentially doing a little differently. Input appreciated.

1: gas: streamline expr_build_dot()
2: MMIX: use current_location() directly
3: gas: partly restore how current_location() had worked
4: gas: introduce deferred expression evaluation mode latching dot
5: aarch64: re-work PR gas/27217 fix again

Further observations:

Shouldn't dot_symbol and dot_frag/dot_value remain in sync, i.e. be updated at
the same time? The fragment dot_symbol references typically is different at all
times when listings are enabled.

Do we really need both define_sym_at_dot() and symbol_set_value_now()? Their
sole differences being that the latter
- also works for local symbols,
- uses symbol_set_frag() and thus S_CLEAR_WEAKREFR() (where it's unclear to me
  why such a symbol would need weakrefr cleared, but one passed to
  define_sym_at_dot() wouldn't).

Jan


More information about the Binutils mailing list