[PATCH] D22916: [ELF] - Linkerscript: implemented += operator.

George Rimar via llvm-commits llvm-commits at lists.llvm.org
Thu Jul 28 07:56:34 PDT 2016


grimar created this revision.
grimar added reviewers: ruiu, rafael.
grimar added subscribers: llvm-commits, grimar, davide, evgeny777.

Sometimes += is used to move the location counter.
Example from the wild is:

  .dbg_excpt _DBG_EXCPT_ADDR (NOLOAD) :
  {
    . += (DEFINED (_DEBUGGER) ? 0x8 : 0x0);

https://github.com/chipKIT32/pic32-Arduino-USB-Bootloader-original/blob/master/boot-linkerscript.ld

Patch implements it and opens way for others type of assignments (-= *= etc), though I think only += is
actual to support.

https://reviews.llvm.org/D22916

Files:
  ELF/LinkerScript.cpp
  test/ELF/linkerscript/linkerscript-locationcounter.s

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D22916.65936.patch
Type: text/x-patch
Size: 4209 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20160728/61de7993/attachment.bin>


More information about the llvm-commits mailing list