[llvm-bugs] [Bug 46210] New: GVN hoists over "synchronizing" call with `inaccessiblemem_only" attribute

via llvm-bugs llvm-bugs at lists.llvm.org
Thu Jun 4 14:45:33 PDT 2020


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

            Bug ID: 46210
           Summary: GVN hoists over "synchronizing" call with
                    `inaccessiblemem_only" attribute
           Product: libraries
           Version: trunk
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: Scalar Optimizations
          Assignee: unassignedbugs at nondot.org
          Reporter: jdoerfert at anl.gov
                CC: llvm-bugs at lists.llvm.org

Created attachment 23582
  --> https://bugs.llvm.org/attachment.cgi?id=23582&action=edit
positive and negative test case

The attached test mimics a "critical region" (see PR45854) with an update
inside.
In both cases the calls surrounding the load+store pair are annotated with
inaccessiblememonly. However, only in the case the call is marked `nosync` it
is sound for GVN to hoist the load out of the loop. Basically, the call might
be a barrier to prevent races, wait for a signal indicating the global was
initialized, ...

-- 
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/20200604/8ec501f9/attachment.html>


More information about the llvm-bugs mailing list