[llvm-bugs] [Bug 44681] New: Missed optimization opportunity with globals that are never written to

via llvm-bugs llvm-bugs at lists.llvm.org
Mon Jan 27 09:18:14 PST 2020


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

            Bug ID: 44681
           Summary: Missed optimization opportunity with globals that are
                    never written to
           Product: new-bugs
           Version: trunk
          Hardware: All
                OS: All
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: new bugs
          Assignee: unassignedbugs at nondot.org
          Reporter: klrehm123 at gmail.com
                CC: htmldeveloper at gmail.com, llvm-bugs at lists.llvm.org

//////////////////////
long long z = 2325;
long long test() {
    return z;
}
//////////////////////

Am I wrong in believing this could potentially be optimized down? I have no
idea if global variables need to be preserved if they're never written to.

-- 
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/20200127/d63d9e4e/attachment.html>


More information about the llvm-bugs mailing list