Crysis 3 Remastered (and 2 probably) in RT mode rely on GetFileSize() returning available read size (more exactly, correctly return 0 when no data is available) on pipe it uses to read the output from child dxc.exe process it creates (and hangs forever trying to read the pipe when we return INVALID_FILE_SIZE). While MSDN explicitly says that "You cannot use the GetFileSize function with a handle of a nonseeking device such as a pipe or a communications device.", if application dares GetFileSize (or NtQueryInformationFile(FileStandardInformation)) actually works for named and unnamed pipes.