Title: build.bat --tail-call-interp and errors/warnings in socketmodule · Issue #145929 · python/cpython · GitHub
Open Graph Title: build.bat --tail-call-interp and errors/warnings in socketmodule · Issue #145929 · python/cpython
X Title: build.bat --tail-call-interp and errors/warnings in socketmodule · Issue #145929 · python/cpython
Description: Bug report Bug description: Running build.bat --tail-call-interp ... leads to 1 error and 10 warnings about "Modules\socketmodule.c" and "Modules\socketmodule.h". The build fails due to 1 error in "Modules\socketmodule.c." "\Modules\sock...
Open Graph Description: Bug report Bug description: Running build.bat --tail-call-interp ... leads to 1 error and 10 warnings about "Modules\socketmodule.c" and "Modules\socketmodule.h". The build fails due to 1 error in ...
X Description: Bug report Bug description: Running build.bat --tail-call-interp ... leads to 1 error and 10 warnings about "Modules\socketmodule.c" and "Modules\socketmodule.h". The build fail...
Opengraph URL: https://github.com/python/cpython/issues/145929
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"build.bat --tail-call-interp and errors/warnings in socketmodule","articleBody":"# Bug report\n\n### Bug description:\n\nRunning `build.bat --tail-call-interp ...` leads to 1 error and 10 warnings about \"Modules\\socketmodule.c\" and \"Modules\\socketmodule.h\".\n\n1. The build fails due to 1 error in \"Modules\\socketmodule.c.\" \n2. \"\\Modules\\socketmodule.c\" leads to 4 `warning : ... is deprecated` statements.\n3. \"\\Modules\\socketmodule.h\" leads to 5 `warning : the current #pragma pack alignment value is modified in the included file [-Wpragma-pack] [C:\\Users\\hunte\\AppData\\Local\\cpython\\PCbuild\\FILE.vcxproj]` statements, where \"FILE\" is _freeze_module, _socket, or pythoncore.\n4. The build succeeds if in \"Modules\\socketmodule.c,\" I change line 3375 from `int dummy;` to `DWORD dummy;`.\n\n## Details\n\n1. Source files: github/python/cpython/3.14\n2. Command `build.bat --pgo --tail-call-interp \"/p:PlatformToolset=ClangCL\" \"/p:LLVMInstallDir=%pathCLang%\" \"/p:LLVMToolsVersion=%LLVMToolsVersion%\" \"/p:WholeProgramOptimization=true\"`.\n3. Both `build.bat -d` and `build.bat`, with the same source files, lead to 1 Warning and 0 Errors `c:\\clones\\cpython\\Modules\\unicodedata.c(1478,62): warning C4267: 'function': conversion from 'size_t' to 'int', possible loss of data [c:\\clones\\cpython\\PCbuild\\unicodedata.vcxproj]`.\n4. In total, `build.bat --tail-call-interp ...` leads to 715 warnings and 1 error.\n 1. No other errors or warnings refer to a \"`*.c`\" or \"`*.h`\" file.\n 2. One warning states `C:\\Users\\hunte\\AppData\\Local\\cpython\\PCbuild\\pythoncore.vcxproj(720,5): warning : Toolset ClangCL is not used for official builds. Your build may have errors or incompatibilities.`\n 3. All other warnings state `clang-cl : warning : argument unused during compilation: '/GL' [-Wunused-command-line-argument] [PATHto\\cpython\\PCbuild\\FILE.vcxproj]`, where \"FILE\" is one of exactly 45 different names. I think there are 55 \"`*.vcxproj`\" files in the directory.\n\n\u003cp>\n\u003cdetails>\u003csummary>The 1 error and 10 warnings about \"Modules\\socketmodule.c\" and \"Modules\\socketmodule.h\"\u003c/summary>\n\u003cp>\n\n```\n..\\Modules\\socketmodule.c(3377,51): error : incompatible pointer types passing 'int *' to parameter of type 'LPDWORD' (aka 'unsigned long *') [-Wincompatible-pointer-types] [C:\\Users\\hunte\\AppData\\Local\\cpython\\PCbuild\\_socket.vcxproj]\n..\\Modules\\socketmodule.c(6208,9): warning : 'gethostbyname' is deprecated: Use getaddrinfo() or GetAddrInfoW() instead or define _WINSOCK_DEPRECATED_NO_WARNINGS to disable deprecated API warnings [-Wdeprecated-declarations] [C:\\Users\\hunte\\AppData\\Local\\cpython\\PCbuild\\_socket.vcxproj]\n..\\Modules\\socketmodule.c(6313,9): warning : 'gethostbyaddr' is deprecated: Use getnameinfo() or GetNameInfoW() instead or define _WINSOCK_DEPRECATED_NO_WARNINGS to disable deprecated API warnings [-Wdeprecated-declarations] [C:\\Users\\hunte\\AppData\\Local\\cpython\\PCbuild\\_socket.vcxproj]\n..\\Modules\\socketmodule.c(6731,23): warning : 'inet_addr' is deprecated: Use inet_pton() or InetPton() instead or define _WINSOCK_DEPRECATED_NO_WARNINGS to disable deprecated API warnings [-Wdeprecated-declarations] [C:\\Users\\hunte\\AppData\\Local\\cpython\\PCbuild\\_socket.vcxproj]\n..\\Modules\\socketmodule.c(6775,33): warning : 'inet_ntoa' is deprecated: Use inet_ntop() or InetNtop() instead or define _WINSOCK_DEPRECATED_NO_WARNINGS to disable deprecated API warnings [-Wdeprecated-declarations] [C:\\Users\\hunte\\AppData\\Local\\cpython\\PCbuild\\_socket.vcxproj]\n..\\Modules\\socketmodule.h(21,11): warning : the current #pragma pack alignment value is modified in the included file [-Wpragma-pack] [C:\\Users\\hunte\\AppData\\Local\\cpython\\PCbuild\\_freeze_module.vcxproj]\n..\\Modules\\socketmodule.h(21,11): warning : the current #pragma pack alignment value is modified in the included file [-Wpragma-pack] [C:\\Users\\hunte\\AppData\\Local\\cpython\\PCbuild\\_socket.vcxproj]\n..\\Modules\\socketmodule.h(21,11): warning : the current #pragma pack alignment value is modified in the included file [-Wpragma-pack] [C:\\Users\\hunte\\AppData\\Local\\cpython\\PCbuild\\pythoncore.vcxproj]\n..\\Modules\\socketmodule.h(53,11): warning : the current #pragma pack alignment value is modified in the included file [-Wpragma-pack] [C:\\Users\\hunte\\AppData\\Local\\cpython\\PCbuild\\_freeze_module.vcxproj]\n..\\Modules\\socketmodule.h(53,11): warning : the current #pragma pack alignment value is modified in the included file [-Wpragma-pack] [C:\\Users\\hunte\\AppData\\Local\\cpython\\PCbuild\\_socket.vcxproj]\n..\\Modules\\socketmodule.h(53,11): warning : the current #pragma pack alignment value is modified in the included file [-Wpragma-pack] [C:\\Users\\hunte\\AppData\\Local\\cpython\\PCbuild\\pythoncore.vcxproj]\n```\n\n\u003c/p>\n\u003c/details> \n\u003c/p>\n\n## Success\n\n1. In \"Modules\\socketmodule.c,\" I changed line 3375 from `int dummy;` to `DWORD dummy;`.\n2. Rerun the build script.\n3. 547 Warnings and 0 Errors.\n\nThere are a few different file names between [uniqueWarningsBefore.txt](https://github.com/user-attachments/files/25978152/uniqueWarningsBefore.txt) and [uniqueWarningsAfter.txt](https://github.com/user-attachments/files/25978160/uniqueWarningsAfter.txt) if you think it's important.\n\n## Information you can almost certainly ignore.\n\n\u003cp>\n\u003cdetails>\u003csummary>Environment\u003c/summary>\n\u003cp>\n\n> Microsoft Windows [Version 10.0.26200.8037]\n\n> curl 8.18.0 (Windows) libcurl/8.18.0 Schannel zlib/1.3.1 WinIDN WinLDAP\n\n> clang version 22.1.1 (https://github.com/llvm/llvm-project fef02d48c08db859ef83f84232ed78bd9d1c323a)\nTarget: x86_64-pc-windows-msvc\nThread model: posix\nInstalledDir: C:\\clones\\clang_msvc\\bin\n\n> Python 3.14.3 (tags/v3.14.3:323c59a, Feb 3 2026, 16:04:56) [MSC v.1944 64 bit (AMD64)]\n\n[Visual Studio configuration](https://github.com/user-attachments/files/25977561/vsconfig.json)\n\n\u003c/p>\n\u003c/details> \n\u003c/p>\n\n\u003cp>\n\u003cdetails>\u003csummary>My batch files to build and install tail-call-interp\u003c/summary>\n\u003cp>\n\n_variables.cmd\n\n```bat\nSET path314raw=%LOCALAPPDATA%\\cpython\n```\n\ngo.cmd\n\n```bat\n@ECHO OFF\nCALL C:\\apps\\Z0Z_\\buildPython\\_variables.cmd\n\n:: LLVM clang version\nSET pathCLang=C:\\clones\\clang_msvc\nSET URLreleases=https://github.com/llvm/llvm-project/releases\n\nFOR /F \"tokens=3\" %%G IN ('%pathCLang%\\bin\\clang.exe --version ^| findstr clang') DO SET versionLLVM=%%G\nFOR /F \"delims=\" %%G IN ('curl -L -s -o NUL -w \"%%{url_effective}\" \"%URLreleases%/latest\"') DO SET URLlatest=%%G\nFOR /F \"tokens=7 delims=/\" %%G IN (\"%URLlatest%\") DO SET LLVMdirectory=%%G\nSET \"versionLLVMlatest=%LLVMdirectory:llvmorg-=%\"\n\nIF NOT \"%versionLLVM%\"==\"%versionLLVMlatest%\" (\n\tIF NOT EXIST %pathCLang% MKDIR %pathCLang%\n\n\tSET pathRelativeLLVM=clang+llvm-%versionLLVMlatest%-x86_64-pc-windows-msvc\n\tSET filename_tar=%pathRelativeLLVM%.tar\n\tSET filename_xz=%filename_tar%.xz\n\n\tcurl -L \"%URLreleases%/download/%LLVMdirectory%/%filename_xz%\" -o \"%pathCLang%\\%filename_xz%\"\n\n\tCALL 7z x -aoa \"-o%pathCLang%\" \"%pathCLang%\\%filename_xz%\"\n\tCALL 7z x -aoa \"-o%pathCLang%\" \"%pathCLang%\\%filename_tar%\" \"%pathRelativeLLVM%\\*\"\n\n\tROBOCOPY %pathCLang%\\%pathRelativeLLVM% %pathCLang% /MOVE /E /NJH /NDL /NFL\n\n\tDEL %pathCLang%\\%filename_tar%\n\tDEL %pathCLang%\\%filename_xz%\n)\n\n%pathCLang%\\bin\\clang.exe --version\n\n:: github/python/cpython/3.14 sync\nPUSHd %path314raw%\n\nCALL git checkout 3.14\nCALL git pull\n\nPOPd\n\n:: PCbuild\\build.bat\nPUSHd \"%path314raw%\\PCbuild\"\n\nFOR /F \"tokens=1 delims=.\" %%G IN (\"%versionLLVMlatest%\") DO SET LLVMToolsVersion=%%G\n\nCALL build.bat --pgo --tail-call-interp \"/p:PlatformToolset=ClangCL\" \"/p:LLVMInstallDir=%pathCLang%\" ^\n\t\"/p:LLVMToolsVersion=%LLVMToolsVersion%\" \"/p:WholeProgramOptimization=true\"\n@REM -Wno-unused-command-line-argument\n\nPOPd\n```\n\nregedit_copyFiles.cmd\n\n```bat\n@ECHO OFF\nCALL C:\\apps\\Z0Z_\\buildPython\\_variables.cmd\n\nSET z=z\nSET path314zCompiled=%path314raw%\\PCbuild\\amd64\nSET path314zInstalled=%LOCALAPPDATA%\\Programs\\Python\\Python314\n\nCOPY /Y \"%path314zCompiled%\\python.exe\" \"%path314zInstalled%\\python3.14%z%.exe\"\nCOPY /Y \"%path314zCompiled%\\python.pdb\" \"%path314zInstalled%\\python3.14%z%.pdb\"\nCOPY /Y \"%path314zCompiled%\\pythonw.exe\" \"%path314zInstalled%\\pythonw3.14%z%.exe\"\nCOPY /Y \"%path314zCompiled%\\pythonw.pdb\" \"%path314zInstalled%\\pythonw3.14%z%.pdb\"\nCOPY /Y \"%path314zCompiled%\\python3.*\" \"%path314zInstalled%\\python3%z%.*\"\nCOPY /Y \"%path314zCompiled%\\python314.*\" \"%path314zInstalled%\\python314%z%.*\"\nMOVE /Y \"%path314zInstalled%\\*.lib\" \"%path314zInstalled%\\libs\\\"\n\n\"%path314zInstalled%\\python3.14%z%.exe\" -VV\n\nSET \"keyRoot=HKCU\\Software\\Python\\PythonCore\\3.14%z%\"\n\nREG ADD \"%keyRoot%\" /F /T REG_SZ /V DisplayName /D \"Python 3.14 (64-bit, tail-call interpreter)\"\nREG ADD \"%keyRoot%\" /F /T REG_SZ /V SupportUrl /D \"https://www.python.org/\"\nREG ADD \"%keyRoot%\" /F /T REG_SZ /V Version /D \"3.14\"\nREG ADD \"%keyRoot%\" /F /T REG_SZ /V SysVersion /D \"3.14\"\nREG ADD \"%keyRoot%\" /F /T REG_SZ /V SysArchitecture /D \"64bit\"\n\nREG ADD \"%keyRoot%\\InstallPath\" /F /T REG_SZ /VE /D %path314zInstalled%\\\nREG ADD \"%keyRoot%\\InstallPath\" /F /T REG_SZ /V ExecutablePath /D \"%path314zInstalled%\\python3.14%z%.exe\"\nREG ADD \"%keyRoot%\\InstallPath\" /F /T REG_SZ /V WindowedExecutablePath /D \"%path314zInstalled%\\pythonw3.14%z%.exe\"\n\nREG ADD \"%keyRoot%\\PythonPath\" /F /T REG_SZ /VE /D %path314zInstalled%\\Lib\\;%path314zInstalled%\\DLLs\\\n\npy -0p\n```\n\n\u003c/p>\n\u003c/details> \n\u003c/p>\n\n\u003cp>\n\u003cdetails>\u003csummary>45 filenames with warning about unused /GL\u003c/summary>\n\u003cp>\n\n```\n_asyncio.vcxproj\n_bz2.vcxproj\n_ctypes_test.vcxproj\n_ctypes.vcxproj\n_decimal.vcxproj\n_elementtree.vcxproj\n_freeze_module.vcxproj\n_hashlib.vcxproj\n_lzma.vcxproj\n_multiprocessing.vcxproj\n_overlapped.vcxproj\n_queue.vcxproj\n_remote_debugging.vcxproj\n_socket.vcxproj\n_sqlite3.vcxproj\n_testbuffer.vcxproj\n_testcapi.vcxproj\n_testclinic_limited.vcxproj\n_testclinic.vcxproj\n_testconsole.vcxproj\n_testembed.vcxproj\n_testimportmultiple.vcxproj\n_testinternalcapi.vcxproj\n_testlimitedcapi.vcxproj\n_testmultiphase.vcxproj\n_testsinglephase.vcxproj\n_tkinter.vcxproj\n_uuid.vcxproj\n_wmi.vcxproj\n_zoneinfo.vcxproj\n_zstd.vcxproj\nliblzma.vcxproj\npyexpat.vcxproj\npylauncher.vcxproj\npyshellext.vcxproj\npython3dll.vcxproj\npythoncore.vcxproj\npywlauncher.vcxproj\nselect.vcxproj\nsqlite3.vcxproj\nunicodedata.vcxproj\nvenvlauncher.vcxproj\nvenvwlauncher.vcxproj\nwinsound.vcxproj\nzlib-ng.vcxproj\n```\n\n\u003c/p>\n\u003c/details> \n\u003c/p>\n\n\u003cp>\n\u003cdetails>\u003csummary>55 \"`*.vcxproj`\" files in PCBuild directory\u003c/summary>\n\u003cp>\n\n```\n_asyncio.vcxproj\n_bz2.vcxproj\n_ctypes_test.vcxproj\n_ctypes.vcxproj\n_decimal.vcxproj\n_elementtree.vcxproj\n_freeze_module.vcxproj\n_hashlib.vcxproj\n_lzma.vcxproj\n_multiprocessing.vcxproj\n_overlapped.vcxproj\n_queue.vcxproj\n_remote_debugging.vcxproj\n_socket.vcxproj\n_sqlite3.vcxproj\n_ssl.vcxproj\n_testbuffer.vcxproj\n_testcapi.vcxproj\n_testclinic_limited.vcxproj\n_testclinic.vcxproj\n_testconsole.vcxproj\n_testembed.vcxproj\n_testimportmultiple.vcxproj\n_testinternalcapi.vcxproj\n_testlimitedcapi.vcxproj\n_testmultiphase.vcxproj\n_testsinglephase.vcxproj\n_tkinter.vcxproj\n_uuid.vcxproj\n_wmi.vcxproj\n_zoneinfo.vcxproj\n_zstd.vcxproj\nliblzma.vcxproj\nopenssl.vcxproj\npyexpat.vcxproj\npylauncher.vcxproj\npyshellext.vcxproj\npython_uwp.vcxproj\npython.vcxproj\npython3dll.vcxproj\npythoncore.vcxproj\npythonw_uwp.vcxproj\npythonw.vcxproj\npywlauncher.vcxproj\nselect.vcxproj\nsqlite3.vcxproj\ntcl.vcxproj\ntk.vcxproj\nunicodedata.vcxproj\nvenvlauncher.vcxproj\nvenvwlauncher.vcxproj\nwinsound.vcxproj\nxxlimited_35.vcxproj\nxxlimited.vcxproj\nzlib-ng.vcxproj\n```\n\n\u003c/p>\n\u003c/details> \n\u003c/p>\n\n\u003cp>\n\u003cdetails>\u003csummary>10 files in directory that didn't have unused /GL warning\u003c/summary>\n\u003cp>\n\n```\n_ssl.vcxproj\nopenssl.vcxproj\npython_uwp.vcxproj\npython.vcxproj\npythonw_uwp.vcxproj\npythonw.vcxproj\ntcl.vcxproj\ntk.vcxproj\nxxlimited_35.vcxproj\nxxlimited.vcxproj\n```\n\n\u003c/p>\n\u003c/details> \n\u003c/p>\n\n### CPython versions tested on:\n\n3.14\n\n### Operating systems tested on:\n\nWindows","author":{"url":"https://github.com/hunterhogan","@type":"Person","name":"hunterhogan"},"datePublished":"2026-03-13T17:59:04Z","url":"https://github.com/python/cpython/issues/145929"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:d3c75f4b-2574-a7f0-eed9-04eed71e7a98 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | 896E:1F2F:1A9C30B:2356A2B:6B02098F |
| html-safe-nonce | 7f162bc7e0c9fcabab0eeb537872636c035944cbe3340839790a6063d069e2cb |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI4OTZFOjFGMkY6MUE5QzMwQjoyMzU2QTJCOjZCMDIwOThGIiwidmlzaXRvcl9pZCI6IjMwODg2NzM1MjIwNjkwMzY5NSIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | 107a27fb35c766b80ab521e2c4f535fa5a1dee641e96db46f90534cddcfb294e |
| hovercard-subject-tag | issue:4072605599 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/python/cpython/145929/issue_layout |
| twitter:image | https://opengraph.githubassets.com/b986151bad8c26b80559210ab5a0c9be0875360b80806e3675b022799402440d/python/cpython/issues/145929 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/b986151bad8c26b80559210ab5a0c9be0875360b80806e3675b022799402440d/python/cpython/issues/145929 |
| og:image:alt | Bug report Bug description: Running build.bat --tail-call-interp ... leads to 1 error and 10 warnings about "Modules\socketmodule.c" and "Modules\socketmodule.h". The build fails due to 1 error in ... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | hunterhogan |
| hostname | github.com |
| expected-hostname | github.com |
| None | 87e774ee7c6b3bee0490394e4d3e57ec9dbc956f74b87ea685dc8996c1676456 |
| turbo-cache-control | no-preview |
| go-import | github.com/python/cpython git https://github.com/python/cpython.git |
| octolytics-dimension-user_id | 1525981 |
| octolytics-dimension-user_login | python |
| octolytics-dimension-repository_id | 81598961 |
| octolytics-dimension-repository_nwo | python/cpython |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 81598961 |
| octolytics-dimension-repository_network_root_nwo | python/cpython |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 423dbb54c5e7bfecc838eb387c1435eb3d0e760d |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
Viewport: width=device-width