Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-70855

MSBuild parser multiplies warnings when compiling with /MP

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Minor Minor
    • analysis-model
    • Jenkins in Version 2.346.3
      Analysis Model API in Version 10.23.1
      Warnings Next Generation in Version 9.23.1

      When using switch /MP with MSBuild to enable multi-threaded compilation, the MSVC compiler will output a log line like

      195>c:\jenkins\workspace\develop\foo.h(76): warning C4100: 'Id': unreferenced formal parameter (compiling source file bar.cpp) [C:\jenkins\workspace\develop\project.vcxproj]
      

      for warnings in header files. These lines are repeated for every translation unit the header file is included in. They will only differ in the translation unit's file name (bar.cpp in the above example) and always refer to the same cause in the header file (foo.h in the above example).
      However, Jenkins treats each of these log lines as separate warnings. So if the same header is included in two different translation units Jenkins will report each warning in this header twice.
      This breaks quality gates when comparing builds using /MP with builds that don't.

          [JENKINS-70855] MSBuild parser multiplies warnings when compiling with /MP

          Ulli Hafner added a comment -

          I'm not sure what I can do here. The tool is not a human and just identifies duplicate warnings by a string comparison. In order to get that fixed you need to change the parser so that it does not contain the section that is different.

          Ulli Hafner added a comment - I'm not sure what I can do here. The tool is not a human and just identifies duplicate warnings by a string comparison. In order to get that fixed you need to change the parser so that it does not contain the section that is different.

          Marne added a comment -

          For me as a sole user of Jenkins it is not always clear which feature is implemented in which plugin, so I selected all that might be affected by this. The issue tracker then automatically assigned this ticket to you. As I understand now from your edits in this ticket the problem needs to be fixed in the analysis-model plugin and you are no longer the maintainer of said plugin? Could you point me in the right direction for who now maintains this plugin as the plugin page still lists you as maintainer?

          Marne added a comment - For me as a sole user of Jenkins it is not always clear which feature is implemented in which plugin, so I selected all that might be affected by this. The issue tracker then automatically assigned this ticket to you. As I understand now from your edits in this ticket the problem needs to be fixed in the analysis-model plugin and you are no longer the maintainer of said plugin? Could you point me in the right direction for who now maintains this plugin as the plugin page still lists you as maintainer?

          Ulli Hafner added a comment -

          No, I am still the maintainer of the plugin. I just removed the other components since the problem is in analysis-model only.

          I removed the assignee since I have to time to fix all issues in my plugin. No assignee means, that someone needs to volunteer.

          Ulli Hafner added a comment - No, I am still the maintainer of the plugin. I just removed the other components since the problem is in analysis-model only. I removed the assignee since I have to time to fix all issues in my plugin. No assignee means, that someone needs to volunteer.

            Unassigned Unassigned
            marne Marne
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: