Repository navigation
Conversation
|
Azure Pipelines: Successfully started running 3 pipeline(s). 12 pipeline(s) were filtered out due to trigger conditions. There may be pipelines that require an authorized user to comment /azp run to run. |
This was referenced Nov 2, 2026
- Remove CreatePipe/InternalCreatePipe, which have no callers.
- Move DeleteFileA, CreateDirectoryA/W, RemoveDirectoryW and
SetCurrentDirectoryA/W out of the PAL into palsuite helpers, matching
DeleteFileW; they were only used by PAL tests.
- Delete directory.cpp: the two internal GetCurrentDirectoryA callers now
use RealPathHelper("."), and DIRGetLastErrorFromErrno is gone with it.
- Delete pal/file.h, which duplicated file.hpp declarations and held the
unused find_obj struct, and fold the three MaxWCharToAcpLength*
constants into one.
- Remove the unused PROCINFO_ID enum and MAPProtectionToFileOpenFlags.
- Remove code guarded by OPEN64_IS_USED_INSTEAD_OF_OPEN and
WRITE_0_BYTES_HANGS_TTY, which are hardcoded to 0.
- Remove #ifndef CORECLR code in map.cpp (the PAL is always built with
CORECLR), along with the temp file handling it left unreachable.
- Remove the ONE_SHARED_MAPPING_PER_FILEREGION_PER_PROCESS fallback; the
configure check and all tryrun caches resolve it to 0.
- Remove an unreachable branch in InternalCanonicalizeRealPath and a
stale comment on InternalSetFilePointerForUnixFd.
- Drop errorpathnotfound checks that only exercised the test-side
DeleteFileA/DeleteFileW helpers.
Co-authored-by: Cursor <cursoragent@cursor.com>
am11
force-pushed
the
chore/pal-file-unused
branch
from
November 2, 2026 12:16
3dcd413 to
7b506fc
Compare
- Remove REALPATH_SUPPORTS_NONEXISTENT_FILES; the configure check, all tryrun caches and the WASI override resolve it to 0. - Fold InternalCreateFile, InternalWriteFile, InternalReadFile, InternalGetFileSize, InternalFlushFileBuffers, InternalCreateFileMapping, InternalMapViewOfFile and InternalUnmapViewOfFile into their public APIs, and inline InternalOpen. - Implement CreateFileW, GetFileSize and MapViewOfFile on top of CreateFileA, GetFileSizeEx and MapViewOfFileEx. - Make the remaining file.cpp and map.cpp helpers static and move the file mapping types from map.hpp into map.cpp. Co-authored-by: Cursor <cursoragent@cursor.com>
3 tasks
jkotas
reviewed
Nov 2, 2026
Revert palsuite.cpp/.h to main and drop DeleteFileW and the CreatePipe declaration; nothing uses them after the file_io tests were removed. Co-authored-by: Cursor <cursoragent@cursor.com>
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
pal/src/file(file.cpp,directory.cpp,path.cpp) andpal/src/mapwith their headers and PAL tests. This removes the PAL's Win32 file, path and mapping APIs (CreateFile,ReadFile/WriteFile,SetFilePointer,GetFileSize,FlushFileBuffers,GetStdHandle,CreateFileMapping/MapViewOfFile,GetFullPathName,SearchPathW,GetTempPathA,CreatePipe, ...).StgIO:FILE*andVMToOSInterfacemappingsFILE*; the JIT path is resolved withrealpathVMToOSInterfacemappings and minimal path handlingmmapTMPDIRinline (createdump now adds the missing trailing/)HAVE_PROCFS_STATM,ONE_SHARED_MAPPING_PER_FILEREGION_PER_PROCESS,REALPATH_SUPPORTS_NONEXISTENT_FILES,OPEN64_IS_USED_INSTEAD_OF_OPEN,WRITE_0_BYTES_HANGS_TTY) and their tryrun cache values.