[LLVMbugs] [Bug 19699] New: Clang accepts OpenCL attribute req_workgroup_size of 0

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Fri May 9 08:42:56 PDT 2014


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

            Bug ID: 19699
           Summary: Clang accepts OpenCL attribute req_workgroup_size of 0
           Product: clang
           Version: trunk
          Hardware: PC
                OS: All
            Status: NEW
          Severity: normal
          Priority: P
         Component: -New Bugs
          Assignee: unassignedclangbugs at nondot.org
          Reporter: pedro.ferreira at imgtec.com
                CC: llvmbugs at cs.uiuc.edu
    Classification: Unclassified

Created attachment 12498
  --> http://llvm.org/bugs/attachment.cgi?id=12498&action=edit
Patch to add validation

OpenCL allows us to define the workgroup size used in a kernel in order to
further optimise the code, specifically to that size.
The syntax is
__attribute__((reqd_work_group_size(X, Y, Z)))

where X, Y and Z are compile-time known integers.
Currently clang allows any of those to be 0, which would be illegal in OpenCL.

The attached patch adds this validation; it's currently a draft and any
comments would be welcome.

-- 
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/20140509/3a924086/attachment.html>


More information about the llvm-bugs mailing list