[llvm-bugs] [Bug 52230] New: Assertion failure when inline assembly referencing floating point registers is used on soft-float targets

via llvm-bugs llvm-bugs at lists.llvm.org
Wed Oct 20 00:38:04 PDT 2021


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

            Bug ID: 52230
           Summary: Assertion failure when inline assembly referencing
                    floating point registers is used on soft-float targets
           Product: libraries
           Version: trunk
          Hardware: All
                OS: All
            Status: NEW
          Severity: normal
          Priority: P
         Component: Backend: ARM
          Assignee: unassignedbugs at nondot.org
          Reporter: kosov.pavel at huawei.com
                CC: llvm-bugs at lists.llvm.org, smithp352 at googlemail.com,
                    Ties.Stuij at arm.com

We have a problem which triggers assertion failure (or UB) when inline assembly
referencing floating point registers is used on soft-float targets
(arm-linux-gnueabi, arm-linux-android). Asserion is triggered in backend which
tries to lower FP register access without FP registers available (target
feature “-fpregs” is passed to backend by clang).

Steps to reproduce:

Given code sample `f.c`

```
float f(float x) { __asm__("vsqrt.f32 %0, %1": "=w"(x) : "t"(x)); return x; }
```

Compile it to arm-linux-gnueabi target with

`clang  -target arm-linux-gnueabi  -c f.c`

-- 
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/20211020/9a33a174/attachment.html>


More information about the llvm-bugs mailing list