[all-commits] [llvm/llvm-project] 131cdd: [AVR] Fix broken bitcast for aliases in non-zero a...

Ayke via All-commits all-commits at lists.llvm.org
Sun Nov 27 06:31:39 PST 2022


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 131cddcba2c4c953a8a49d7adbf656cab9e9f1c7
      https://github.com/llvm/llvm-project/commit/131cddcba2c4c953a8a49d7adbf656cab9e9f1c7
  Author: Ayke van Laethem <aykevanlaethem at gmail.com>
  Date:   2022-11-27 (Sun, 27 Nov 2022)

  Changed paths:
    M clang/lib/CodeGen/CodeGenModule.cpp
    M clang/test/CodeGen/avr/alias-avr.c

  Log Message:
  -----------
  [AVR] Fix broken bitcast for aliases in non-zero address space

This was triggered by some code in picolibc. The minimal version looks
like this:

    double infinity(void) {
       return 5;
    }

    extern long double infinityl() __attribute__((__alias__("infinity")));

These two declarations have a different type (not because of the 'long
double', which is also 'double' in IR, but because infinityl has
variadic parameters). This led to a crash in the bitcast which assumed
address space 0.

Differential Revision: https://reviews.llvm.org/D138681


  Commit: 3b2b83ce2f6bb32fc73dbd303c791cabf16c8218
      https://github.com/llvm/llvm-project/commit/3b2b83ce2f6bb32fc73dbd303c791cabf16c8218
  Author: Ayke van Laethem <aykevanlaethem at gmail.com>
  Date:   2022-11-27 (Sun, 27 Nov 2022)

  Changed paths:
    M llvm/lib/Target/AVR/MCTargetDesc/AVRMCAsmInfo.cpp
    A llvm/test/MC/AVR/separator.s

  Log Message:
  -----------
  [AVR] Add $ separator string (like avr-gcc)

avr-gcc uses the $ symbol as an assembly separator instead of the more
common %% syntax. We need it in LLVM too to be compatible.

Differential Revision: https://reviews.llvm.org/D138535


  Commit: 91ae1afd3cb9d9a583490ee9eef219287603a18a
      https://github.com/llvm/llvm-project/commit/91ae1afd3cb9d9a583490ee9eef219287603a18a
  Author: Ayke van Laethem <aykevanlaethem at gmail.com>
  Date:   2022-11-27 (Sun, 27 Nov 2022)

  Changed paths:
    M llvm/lib/Target/AVR/AVRExpandPseudoInsts.cpp
    M llvm/lib/Target/AVR/AVRInstrInfo.td
    M llvm/test/CodeGen/AVR/elpm.ll
    A llvm/test/CodeGen/AVR/pseudo/ELPMWRdZ.mir

  Log Message:
  -----------
  [AVR] Remove unused register scavenger

The LPMW/ELPMW instruction can be modified to use an earlyclobber, which
prevents it from using the Z register as an output register.

Also see: https://reviews.llvm.org/D131844

Differential Revision: https://reviews.llvm.org/D117957


Compare: https://github.com/llvm/llvm-project/compare/6a353c7756f2...91ae1afd3cb9


More information about the All-commits mailing list