[LLVMbugs] [Bug 279] NEW: [llvmgcc] "constructor" code generation can be improved

bugzilla-daemon at cs.uiuc.edu bugzilla-daemon at cs.uiuc.edu
Tue Mar 9 19:14:23 PST 2004


http://llvm.cs.uiuc.edu/bugs/show_bug.cgi?id=279

           Summary: [llvmgcc] "constructor" code generation can be improved
           Product: tools
           Version: 1.0
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: llvm-gcc
        AssignedTo: unassignedbugs at nondot.org
        ReportedBy: sabre at nondot.org


Though we are generating better code for GCC CONSTRUCTOR nodes (See Bug 275), we
still aren't doing as well as we should do.  In particular, we handle cases like
this poorly:

int foo(int X) {
  int Arr[100] = { X };     // Should use memset
  int Arr[10000] = { 1 };   // Should use memset

  // Should memcpy the whole thing
  struct { int A, B } Pairs[10] = { {1, 2 }, { 0, 0 } };
}

... While the first ones could be addressed right now, the last one requires a
rewrite of how we handle constructors, which is needed to fix several code
correctness bugs anyway.  This bug is just a tracker for when this happens.

-Chris



------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.



More information about the llvm-bugs mailing list