[all-commits] [llvm/llvm-project] c142c0: Place the BlockAddress type in the address space o...

Alexander Richardson via All-commits all-commits at lists.llvm.org
Fri Jul 2 04:19:13 PDT 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: c142c06c19b3725f26f33652db098a2302586f22
      https://github.com/llvm/llvm-project/commit/c142c06c19b3725f26f33652db098a2302586f22
  Author: Alex Richardson <Alexander.Richardson at cl.cam.ac.uk>
  Date:   2021-07-02 (Fri, 02 Jul 2021)

  Changed paths:
    M llvm/docs/LangRef.rst
    M llvm/include/llvm/AsmParser/LLParser.h
    M llvm/lib/AsmParser/LLParser.cpp
    M llvm/lib/IR/Constants.cpp
    A llvm/test/Bitcode/blockaddress-addrspace.ll
    A llvm/test/CodeGen/AVR/block-address-is-in-progmem-space.ll
    M llvm/test/CodeGen/AVR/brind.ll

  Log Message:
  -----------
  Place the BlockAddress type in the address space of the containing function

While this should not matter for most architectures (where the program
address space is 0), it is important for CHERI (and therefore Arm Morello).
We use address space 200 for all of our code pointers and without this
change we assert in the SelectionDAG handling of BlockAddress nodes.

It is also useful for AVR: previously programs targeting
AVR that attempt to read their own machine code
via a pointer to a label would instead read from RAM
using a pointer relative to the the start of program flash.

Reviewed By: dylanmckay, theraven
Differential Revision: https://reviews.llvm.org/D48803




More information about the All-commits mailing list