[PATCH] D22740: Move Dot variable from LinkerScript to ScriptConfig.

Rafael Espíndola via llvm-commits llvm-commits at lists.llvm.org
Fri Jul 29 07:58:51 PDT 2016


On 29 July 2016 at 10:55, Rafael Ávila de Espíndola
<llvm-commits at lists.llvm.org> wrote:
> rafael added a subscriber: rafael.
> rafael added a comment.
>
> I am not sure how complex linker scripts expression will get, so it is hard to have an opinion on this.
>
> In general when interpreting an expression, the interpretation is made in an Environment, which maps names to values. It would be another way of doing this, but tt is not clear if that generality is needed for linker scripts. Is Dot the only variable that can have different values in different contexts?


Oh, and having Expr take a generic environment or no argument would be
an improvement for cases where "." is not available.

For example, we noticed that BFD supports "FLAGS(1|2)" for example. We
just changed that linker script locally for now, but there may be
other cases where we have expressions where it is invalid to use ".".

Cheers,
Rafael


More information about the llvm-commits mailing list