[idd] clipboard: pipeline helper channel

Publish ordered four-record prefixes through the Helper mapping and ring
once per accepted burst. Wake blocked producers when the peer returns
credits while retaining the bounded polling fallback.

Move received payload ownership into manager work items and place remote
file-read data directly into the waiting caller’s bounded output buffer.
This removes avoidable 256 KiB copies without changing record ordering,
timeouts, cancellation, or reset semantics.
This commit is contained in:
Geoffrey McRae
2026-08-15 14:11:30 +10:00
parent b353b5ef06
commit 89b1ced8fc
6 changed files with 344 additions and 148 deletions

View File

@@ -138,6 +138,10 @@ private:
bool manifest = false;
KVMFRClipboardFileError error = KVMFR_CLIPBOARD_FILE_ERROR_NONE;
HANDLE event = nullptr;
// Borrowed by a synchronous READ until this request is removed while
// holding m_fileLock. Manifest LIST responses retain owned vector data.
uint8_t * output = nullptr;
uint32_t outputCapacity = 0;
std::vector<uint8_t> data;
~IncomingFileRequest();
@@ -322,8 +326,9 @@ private:
CClipboardSpool& spool);
void ClipboardState(bool available, uint64_t epoch) override;
ClipboardChannelResult ClipboardRecord(const KVMFRClipboardMessage& record,
const uint8_t * data) override;
ClipboardChannelResult ClipboardRecord(
const KVMFRClipboardMessage& record,
std::vector<uint8_t>&& data) override;
void ClipboardReset(uint64_t epoch, uint32_t reason) override;
public: