[LLVMbugs] [Bug 22552] New: Backend fails at __builtin_ia32_rdrand32_step, if driver is missing -mrdrnd

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Wed Feb 11 14:48:05 PST 2015


http://llvm.org/bugs/show_bug.cgi?id=22552

            Bug ID: 22552
           Summary: Backend fails at __builtin_ia32_rdrand32_step, if
                    driver is missing -mrdrnd
           Product: clang
           Version: trunk
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: P
         Component: LLVM Codegen
          Assignee: unassignedclangbugs at nondot.org
          Reporter: ismail.pazarbasi at gmail.com
                CC: llvmbugs at cs.uiuc.edu
    Classification: Unclassified

This seems more like a bug than QoI issue. Given:

int /*__attribute__((target("randr")))*/ f() {
  unsigned int v;
  __builtin_ia32_rdrand32_step(&v);
  return v;
}

Without -mrdrnd, clang exits with code 70.

fatal error: error in backend: Cannot select: 0x63a57d0: i32,glue,ch =
X86ISD::RDRAND 0x636c0d0 [ORD=2] [ID=5]
In function: _Z1fv
clang-3.7: error: clang frontend command failed with exit code 70 (use -v to
see invocation)

With -mrdrnd, works as expected.
% clang -c -o randr.o randr.cpp -mrdrnd && echo $?
0

Perhaps, we can warn/error about about missing features.

-- 
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/20150211/1b40b548/attachment.html>


More information about the llvm-bugs mailing list