Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-46144

-Wsign-compare warnings in mozjs build

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Major - P3
    • Resolution: Duplicate
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: Internal Code
    • Labels:
      None

      Description

      These 4 warnings happen on every clean mongod build.
      We should get rid of them by setting appropriate CXXFLAGS when compiling mozjs.

      [1260/3530] Compiling build/dynamic_gcc_ninja/third_party/mozjs-60/extract/modules/fdlibm/e_sqrt.dyn.o
      src/third_party/mozjs-60/extract/modules/fdlibm/e_sqrt.cpp: In function ‘double fdlibm::sqrt(double)’:
      src/third_party/mozjs-60/extract/modules/fdlibm/e_sqrt.cpp:158:16: warning: comparison of integer expressions of different signedness: ‘uint32_t’ {aka ‘unsigned int’} and ‘int32_t’ {aka ‘int’} [-Wsign-compare]
         if(((t1&sign)==sign)&&(s1&sign)==0) s0 += 1;
             ~~~~~~~~~^~~~~~
      [1264/3530] Compiling build/dynamic_gcc_ninja/third_party/mozjs-60/extract/modules/fdlibm/e_pow.dyn.o
      src/third_party/mozjs-60/extract/modules/fdlibm/e_pow.cpp: In function ‘double fdlibm::pow(double, double)’:
      src/third_party/mozjs-60/extract/modules/fdlibm/e_pow.cpp:131:21: warning: comparison of integer expressions of different signedness: ‘int32_t’ {aka ‘int’} and ‘uint32_t’ {aka ‘unsigned int’} [-Wsign-compare]
             if((j<<(52-k))==ly) yisint = 2-(j&1);
                ~~~~~~~~~~~^~~~
      [1267/3530] Compiling build/dynamic_gcc_ninja/third_party/mozjs-60/extract/modules/fdlibm/s_ceil.dyn.o
      src/third_party/mozjs-60/extract/modules/fdlibm/s_ceil.cpp: In function ‘double fdlibm::ceil(double)’:
      src/third_party/mozjs-60/extract/modules/fdlibm/s_ceil.cpp:63:8: warning: comparison of integer expressions of different signedness: ‘uint32_t’ {aka ‘unsigned int’} and ‘int32_t’ {aka ‘int’} [-Wsign-compare]
          if(j<i1) i0+=1; /* got a carry */
             ~^~~
      [1272/3530] Compiling build/dynamic_gcc_ninja/third_party/mozjs-60/extract/modules/fdlibm/s_floor.dyn.o
      src/third_party/mozjs-60/extract/modules/fdlibm/s_floor.cpp: In function ‘double fdlibm::floor(double)’:
      src/third_party/mozjs-60/extract/modules/fdlibm/s_floor.cpp:64:8: warning: comparison of integer expressions of different signedness: ‘uint32_t’ {aka ‘unsigned int’} and ‘int32_t’ {aka ‘int’} [-Wsign-compare]
          if(j<i1) i0 +=1 ;  /* got a carry */
             ~^~~
      
      

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              backlog-server-devtools DO NOT USE - Backlog - Dev Tools
              Reporter:
              billy.donahue Billy Donahue
              Participants:
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: