Patch 9.0.1567
Problem:    Profiler calculation may be wrong on 32 bit builds.
Solution:   Use 64 bit variable if possible. (Isao Sato, closes #12412)
Files:      src/profiler.c


*** ../vim-9.0.1566/src/profiler.c      2023-03-22 22:03:11.939208261 +0000
--- src/profiler.c      2023-05-19 13:18:10.536419710 +0100
***************
*** 123,132 ****
        QueryPerformanceFrequency(&fr);
        tm->QuadPart += (LONGLONG)((double)msec / 1000.0 * (double)fr.QuadPart);
  # else
!       long        fsec;
  
        PROF_GET_TIME(tm);
!       fsec = (long)tm->tv_fsec + (long)msec * (TV_FSEC_SEC / 1000);
        tm->tv_fsec = fsec % (long)TV_FSEC_SEC;
        tm->tv_sec += fsec / (long)TV_FSEC_SEC;
  # endif
--- 123,133 ----
        QueryPerformanceFrequency(&fr);
        tm->QuadPart += (LONGLONG)((double)msec / 1000.0 * (double)fr.QuadPart);
  # else
!       varnumber_T         fsec;       // this should be 64 bit if possible
  
        PROF_GET_TIME(tm);
!       fsec = (varnumber_T)tm->tv_fsec
!                      + (varnumber_T)msec * (varnumber_T)(TV_FSEC_SEC / 1000);
        tm->tv_fsec = fsec % (long)TV_FSEC_SEC;
        tm->tv_sec += fsec / (long)TV_FSEC_SEC;
  # endif
*** ../vim-9.0.1566/src/version.c       2023-05-18 20:07:08.672843369 +0100
--- src/version.c       2023-05-19 13:20:05.307771314 +0100
***************
*** 697,698 ****
--- 697,700 ----
  {   /* Add new patch number below this line */
+ /**/
+     1567,
  /**/

-- 
"Oh, no!  NOT the Spanish Inquisition!"
"NOBODY expects the Spanish Inquisition!!!"
                                -- Monty Python sketch --
"Oh, no!  NOT another option!"
"EVERYBODY expects another option!!!"
                                -- Discussion in vim-dev mailing list --

 /// Bram Moolenaar -- [email protected] -- http://www.Moolenaar.net   \\\
///                                                                      \\\
\\\        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ ///
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/vim_dev/20230519122146.292E71C0D4E%40moolenaar.net.

Raspunde prin e-mail lui