[llvm-bugs] [Bug 42582] New: Assembly instructions "adrl, cpy, vmrs, vmsr" doesn't supported by Clang

via llvm-bugs llvm-bugs at lists.llvm.org
Thu Jul 11 04:16:18 PDT 2019


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

            Bug ID: 42582
           Summary: Assembly instructions "adrl, cpy, vmrs, vmsr" doesn't
                    supported by Clang
           Product: clang
           Version: 8.0
          Hardware: Other
                OS: Linux
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: -New Bugs
          Assignee: unassignedclangbugs at nondot.org
          Reporter: qwertytmp1 at gmail.com
                CC: htmldeveloper at gmail.com, llvm-bugs at lists.llvm.org,
                    neeilans at live.com, richard-llvm at metafoo.co.uk

Created attachment 22224
  --> https://bugs.llvm.org/attachment.cgi?id=22224&action=edit
Test to reproduce situation

Assembly instructions "adrl, cpy, vmrs, vmsr" don't supported by Clang.
At the same time, they are supported by GCC.

Environment information:
OS:    Ubuntu 16.04.5 LTS
GCC:   arm-linux-gnueabihf-gcc (Linaro GCC 6.2-2016.11) 6.2.1 20161016
CLANG: clang version 8.0.0 (tags/RELEASE_800/final)


Usecase is attached to this report. Also it is duplicated below in this text:




adrl_cpy_vmrs_vmsr.s
```
add:
adrl r0, add
cpy r0, r1
VMRS r2,FPEXC
VMSR FPEXC,r2
```




adrl_cpy_vmrs_vmsr.sh
```
#!/bin/bash

COMPILER_GCC=/opt/toolchains/aarch32/bin/arm-linux-gnueabihf-gcc
COMPILER_CLANG=opt/clang+llvm-8.0.0-x86_64-linux-gnu-ubuntu-16.04/bin/arm-funnyos-gnueabi-clang

i=adrl_cpy_vmrs_vmsr;

echo "======================================================================"
echo "Building by GCC";
echo "======================================================================"
${COMPILER_GCC} -c $i.s;
RESULT=$?
echo "----------------------------------------------------------------------"
echo "Build result: $RESULT";
echo "----------------------------------------------------------------------"
echo "";
echo "";

echo "======================================================================"
echo "Building by CLANG";
echo "======================================================================"
${COMPILER_CLANG} -c $i.s;
RESULT=$?
echo "----------------------------------------------------------------------"
echo "Build result: $RESULT";
echo "----------------------------------------------------------------------"
echo "";
echo "";
```




Result of "adrl_cpy_vmrs_vmsr.sh" execution:
```
$ ./adrl_cpy_vmrs_vmsr.sh 
======================================================================
Building by GCC
======================================================================
----------------------------------------------------------------------
Build result: 0
----------------------------------------------------------------------


======================================================================
Building by CLANG
======================================================================
adrl_cpy_vmrs_vmsr.s:2:1: error: invalid instruction, did you mean: adr?
adrl r0, add
^
adrl_cpy_vmrs_vmsr.s:3:1: error: invalid instruction, did you mean: cdp, cmp,
cps?
cpy r0, r1
^
adrl_cpy_vmrs_vmsr.s:4:1: error: instruction requires: VFP2
VMRS r2,FPEXC
^
adrl_cpy_vmrs_vmsr.s:5:1: error: instruction requires: VFP2
VMSR FPEXC,r2
^
----------------------------------------------------------------------
Build result: 1
----------------------------------------------------------------------
```

-- 
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/20190711/fc9eb4b8/attachment-0001.html>


More information about the llvm-bugs mailing list