Double indirection causes bad loop performance

XMLWordPrintable

    • Type: Enhancement
    • Resolution: Unresolved
    • Priority: Low

      The attached test case contains this loop.

          for (i=0; i<10; i++)
          {
              p1 = *list;
              p2 = *list++;
              *p2 = *p1 + 2;
          }
      

      Build it ...

      % cl6x -mv6740 -o3 -s -mw testcase.c
      

      Then inspect the resulting assembly file.

      All of the pointers are restrict qualified. Including list and *list. Despite that, the compiler generated comments indicate a dependence that is carried over from one loop to the next. The II (initiation interval) is 10, because each loop has to finish before the next one starts.

            Assignee:
            TI User
            Reporter:
            TI User
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:

                Connection: Intermediate to External PROD System
                EXTSYNC-2788 - Double indirection causes bad loop ...
                SYNCHRONIZED
                • Last Sync Date: