Optimize move file calls on Windows, saving about 2ms per call (1 call on startup)

RESOLVED FIXED in mozilla13

Status

()

Core
XPCOM
RESOLVED FIXED
6 years ago
6 years ago

People

(Reporter: bbondy, Assigned: bbondy)

Tracking

unspecified
mozilla13
x86_64
Windows 7
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

(Assignee)

Description

6 years ago
Created attachment 594445 [details] [diff] [review]
Patch v1.

In 2007, bug 375778 added the flag MOVEFILE_WRITE_THROUGH. This flag wasn't needed by the description of the problem in that bug though.

This flag causes the cache manager to flush the data to disk before returning.  

There is no benefit as far as consistency of the file data with subsequent calls though and we shouldn't do it from our file API because it incurs a cost of ~2ms.
Attachment #594445 - Flags: review?(benjamin)
(Assignee)

Updated

6 years ago
Depends on: 375778
Attachment #594445 - Flags: review?(benjamin) → review+
(Assignee)

Comment 1

6 years ago
http://hg.mozilla.org/integration/mozilla-inbound/rev/8787499fae84
Target Milestone: --- → mozilla13
https://hg.mozilla.org/mozilla-central/rev/8787499fae84
Status: NEW → RESOLVED
Last Resolved: 6 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.