[llvm-bugs] [Bug 44828] New: Warning: index register overlaps transfer register after 60e0120c913dd

via llvm-bugs llvm-bugs at lists.llvm.org
Fri Feb 7 09:05:00 PST 2020


https://bugs.llvm.org/show_bug.cgi?id=44828

            Bug ID: 44828
           Summary: Warning: index register overlaps transfer register
                    after 60e0120c913dd
           Product: libraries
           Version: trunk
          Hardware: Other
                OS: All
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: Backend: ARM
          Assignee: unassignedbugs at nondot.org
          Reporter: natechancellor at gmail.com
                CC: llvm-bugs at lists.llvm.org, peter.smith at linaro.org,
                    Ties.Stuij at arm.com

When building an ARM Linux kernel, we see assembler warnings after
60e0120c913dd1d4bfe33769e1f000a076249a42.

$ make -j$(nproc) -s ARCH=arm CC=clang CROSS_COMPILE=arm-linux-gnueabi-
O=out.arm32 distclean defconfig kernel/sched/fair.o
/tmp/fair-f01157.s: Assembler messages:
/tmp/fair-f01157.s:1048: Warning: index register overlaps transfer register

I was able to creduce a problematic translation unit to

struct g {
  long h;
  struct g *i;
  struct g *j
};
struct k {
  struct k *b
};
struct l {
  long m;
  int n
};
struct o {
} __attribute__((__aligned__(1 << 6)));
struct a {
  struct a *b, *c
} aj(ak) {
  *(volatile long long *)ak;
}
struct p {
  struct l a;
  long q;
  struct g r;
  struct a s;
  int t;
  long long u;
  long v;
  long long b;
  long w;
  struct o aa
};
struct {
  long d;
  void *e;
  int f;
  int b;
  int c;
  struct k x;
  int y;
  int z;
  long ab;
  int ac;
  int a;
  int ad;
  int t;
  int ae;
  int af;
  int ag;
  int ah;
  struct p ai
} a;
al() { aj(&a.ai.aa); }

See https://github.com/ClangBuiltLinux/linux/issues/838 for more details.

This is going to be a regression in clang-10, it would be nice to either revert
that commit or come up with a fix quickly, since this was reported on
Phabricator three weeks ago and there has been no movement.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20200207/63ef316e/attachment.html>


More information about the llvm-bugs mailing list