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

            Bug ID: 40892
           Summary: Large number of locals in zlib output
           Product: libraries
           Version: trunk
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: Backend: WebAssembly
          Assignee: unassignedb...@nondot.org
          Reporter: alonza...@gmail.com
                CC: llvm-bugs@lists.llvm.org

Created attachment 21517
  --> https://bugs.llvm.org/attachment.cgi?id=21517&action=edit
cheerp output for comparison

Comparing to cheerp, the core $deflate function in their output has 7 locals,
while the wasm backend's version has 85. This may explain why the size of the
function is much larger.

I'm not sure what's going on here. One pattern I noticed is constants with one
set and one  get (e.g., 11664 - might help to search for that const). There are
'runs' of such assignments to locals (each with a different value), and they
all have this pattern. They also seem to end up used in the same code area
later. I guess they are a bunch of phis, with the other value being the zero
initialization (does LLVM use that?).

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
llvm-bugs mailing list
llvm-bugs@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs

Reply via email to