Speed up mkdepend on Windows + VMWare

RESOLVED FIXED

Status

()

Core
Build Config
RESOLVED FIXED
10 years ago
10 years ago

People

(Reporter: roc, Assigned: roc)

Tracking

({verified1.8.1.8})

Trunk
x86
Windows XP
verified1.8.1.8
Points:
---
Bug Flags:
in-testsuite -

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(2 attachments)

Created attachment 265348 [details] [diff] [review]
fix

I build on Windows under VMWare, with the sources in VMWare's shared file system and local objdirs. I noticed that mkdepend was running incredibly slowly. For example, mkdepend on nsPresShell.cpp:
real    0m32.250s
user    0m0.031s
sys     0m0.031s

Primitive profiling suggests that it was spending most of its time blocked on stat() calls searching include directories for include files. On a hunch I replaced the stat() calls to check for file existence with a call to GetFileAttributesEx. The result:
real    0m1.578s
user    0m0.015s
sys     0m0.015s

I suspect the issue is that stat() fills in a lot of fields like inode and user/group/other permissions that are expensive to gather on Windows, especially in VMWare's file system perhaps.
Attachment #265348 - Flags: review?(benjamin)
Attachment #265348 - Flags: review?(benjamin) → review+
checked in
Status: NEW → RESOLVED
Last Resolved: 10 years ago
Resolution: --- → FIXED

Updated

10 years ago
Depends on: 381686

Comment 2

10 years ago
Created attachment 265789 [details] [diff] [review]
Bustage?

The patch breaks the tinderbox build on Solaris: http://tinderbox.mozilla.org/showbuilds.cgi?tree=Firefox-Ports. S_ISDIR should be the POSIX macro for this check.
Attachment #265789 - Flags: review?

Updated

10 years ago
Attachment #265789 - Flags: review? → review?(benjamin)
Flags: in-testsuite-
Attachment #265789 - Flags: review?(benjamin) → review+

Comment 3

10 years ago
Checking in include.c;
/cvsroot/mozilla/config/mkdepend/include.c,v  <--  include.c
new revision: 3.6; previous revision: 3.5
done

Updated

10 years ago
Duplicate of this bug: 381686
roc, any chance this could get landed on the 1.8.1 branch as well?
Dunno. Nominate it and find out
Attachment #265348 - Flags: approval1.8.1.5?
Attachment #265789 - Flags: approval1.8.1.5?
Comment on attachment 265348 [details] [diff] [review]
fix

approved for 1.8.1.5, a=dveditz for release-drivers
Attachment #265348 - Flags: approval1.8.1.5? → approval1.8.1.5+
Attachment #265789 - Flags: approval1.8.1.5? → approval1.8.1.5+
Comment on attachment 265348 [details] [diff] [review]
fix

closing tree early, this will have to wait for next time
Attachment #265348 - Flags: approval1.8.1.6?
Attachment #265348 - Flags: approval1.8.1.5-
Attachment #265348 - Flags: approval1.8.1.5+
Attachment #265789 - Flags: approval1.8.1.6?
Attachment #265789 - Flags: approval1.8.1.5-
Attachment #265789 - Flags: approval1.8.1.5+
Comment on attachment 265348 [details] [diff] [review]
fix

approved for 1.8.1.7, a=dveditz for release-drivers
Attachment #265348 - Flags: approval1.8.1.7? → approval1.8.1.7+
Attachment #265789 - Flags: approval1.8.1.7? → approval1.8.1.7+
Keywords: checkin-needed
Whiteboard: checkin needed for mozilla1.8 branch
Keywords: checkin-needed → fixed1.8.1.7

Updated

10 years ago
Whiteboard: checkin needed for mozilla1.8 branch

Updated

10 years ago
Keywords: fixed1.8.1.8 → verified1.8.1.8
You need to log in before you can comment on or make changes to this bug.