On 2026/05/21 21:32, Evgeny Kotkov wrote:
> Jun Omae <[email protected]> writes:
>
>> It occurs only with MSVC toolset v143 (--vsnet-version=2022) and Whole
>> Program Optimization enabled. It doesn't with v142 (--vsnet-version=2019).
>>
>> svn_fs_fs__delete_revprops_shard() is built by the optimization to
>> delete the "revprops/0" directory even if `shard` argument is 0.
>>
>> Workaround is to disable the optimization.
>
> Interesting. Could be a compiler issue or an UB somewhere in the code.
>
> Would you mind providing more details on your environment to make it easier
> to reproduce?
It is able to reproduce using cmake with toolset v143.
1. Pass -vcvars_ver=14.44 to vcvars64.bat
2. Pass CMAKE_INTERPROCEDURAL_OPTIMIZATION=ON to cmake configure
(The option makes Whole Program Optimization enabled in cmake build)
E.g.
[[[
C:\Program Files (x86)\Microsoft Visual
Studio\18\BuildTools\VC\Auxiliary\Build\vcvars64.bat -vcvars_ver=14.44
python.exe gen-make.py -t cmake
cmake.exe ^
-B out ^
-D CMAKE_GENERATOR=Ninja ^
-D CMAKE_BUILD_TYPE=Release ^
-D CMAKE_INTERPROCEDURAL_OPTIMIZATION=ON ^
...
cmake.exe --build out --config Release
]]]
The issue is raised only with v143 (14.44). It is not with v142 (14.29) and
v145 (14.51).
> 1) Are you building for x64 or x86?
x64.
> 2) What is the specific compiler version?
>
> It can be a bit tricky to determine the actual version of the compiler that
> was used during build. One possible way is to set the `C/C++ > All Options
> > Suppress Startup Banner` vcxproj setting to `No` and scan the output for
> a line like "Microsoft (R) C/C++ Optimizing Compiler Version 19.44.35227".
Patch the following to build/generator/templates/vcnet_vcxproj.ezt:
[[[
[else] <Optimization>Full</Optimization>
+ <SuppressStartupBanner>false</SuppressStartupBanner>
<InlineFunctionExpansion>AnySuitable</InlineFunctionExpansion>
]]]
Received the following log.
[[[
PS C:\usr\src\subversion\subversion-1.14.5> grep -3 'Optimizing Compiler
Version' .\Release\msbuild.log
VSTEL_ProjectID={4D9A7B20-8C00-03D8-7C98-F6430DA8D354}
Done executing task "SetEnv".
68>ClCompile:
Microsoft (R) C/C++ Optimizing Compiler Version 19.44.35227 for x64
89>Task "SetEnv"
VSTEL_SolutionPath=C:\usr\src\subversion\subversion-1.14.5\subversion_vcnet.sln
68>ClCompile:
...
]]]
> 3) Are you testing a shared or static build?
shared.
> 4) If your environment is ready for that, could you try the same with the
> 1.14.5 tarball to see if the problem is new?
Yes, reproduced on 1.14.5 with r1934466, r1899028 and r1929564 cherry-picked
(because 1.14.5 cannot be built with VS2022 and latest apr, expat, zlib, ...).
[[[
[1/1] svnfsfs_tests.py..................................................FAILURE
At least one test FAILED, checking
C:\usr\src\subversion\subversion-1.14.5\Release\dav-tests.log
FAIL: svnfsfs_tests.py 2: load-index in a packed repo
Summary of test results:
2 tests PASSED
1 test FAILED
Python version: 3.14.4.
SUMMARY: Some tests failed
]]]
[[[
I: CMD: svnadmin.exe verify svn-test-work\repositories\svnfsfs_tests-2
I: CMD:
C:\usr\src\subversion\subversion-1.14.5\Release\subversion\svnadmin/svnadmin.exe
verify svn-test-work\repositories\svnfsfs_tests-2 exited with 1
I: <TIME = 0.021100>
I: * Verifying metadata at revision 0 ...
I: * Error verifying repository metadata.
I: svnadmin: E160006: No such packed revision 0
W: Unexpected output
W: EXPECTED STDERR (match_all=True):
W: ACTUAL STDERR:
W: | * Error verifying repository metadata.
W: | svnadmin: E160006: No such packed revision 0
W: DIFF STDERR (match_all=True):
W: | --- EXPECTED STDERR (match_all=True)
W: | +++ ACTUAL STDERR
W: | @@ -0,0 +1,2 @@
W: | +* Error verifying repository metadata.
W: | +svnadmin: E160006: No such packed revision 0
W: CWD: C:\usr\src\subversion\subversion-1.14.5\Release\subversion\tests\cmdline
]]]
--
Jun Omae <[email protected]> (大前 潤)