Commit Graph

247791 Commits

Author SHA1 Message Date
Eric Rahm
537c445a65 Bug 1171716 - Part 4: Use NS_ReleaseOnMainThread in JarChannel dtor. r=froydnj 2015-06-09 18:25:47 -07:00
Eric Rahm
373ce6a056 Bug 1171716 - Part 3: Use NS_ReleaseOnMainThread in WebSocketChannel dtor. r=froydnj 2015-06-09 18:25:46 -07:00
Eric Rahm
6e8f209b8b Bug 1171716 - Part 2: Use NS_ReleaseOnMainThread in nsBaseChannel. r=froydnj 2015-06-09 18:25:44 -07:00
Eric Rahm
1346d05111 Bug 1171716 - Part 1: Add NS_ReleaseOnMainThread. r=froydnj 2015-06-09 18:25:43 -07:00
Gregory Szorc
9add883718 Bug 1168607 - Add a native Mercurial finder; r=glandium
The hglib Mercurial finder was nice. But it is somewhat slow, as it
involves a separate Mercurial process.

This commit introduces a native Mercurial finder that speaks directly
to a Mercurial repository instance. It is significantly faster.

The new code is isolated to its own file because it imports Mercurial
code, which is GPL.
2015-06-09 13:49:45 -07:00
Gregory Szorc
31328c6c69 Bug 1168607 - Make mach file-info work with Mercurial repos; r=glandium
This commit adds support for specifying a Mercurial revision with `mach
file-info`. Aside from being a potentially useful feature, it proves
that MercurialRevisionFinder works with BuildReader.
2015-06-09 13:43:22 -07:00
Gregory Szorc
a0f182b4e8 Bug 1168607 - Add mode to MercurialFileFinder to support non-relative paths; r=glandium
The moz.build reader uses absolute paths when referencing moz.build
files. *Finder classes expect paths to be relative to a base. When we
switched the reader to use *Finder instances for I/O, we simply provided
a default FileFinder based at the filesystem root. This was quick and
easy. Things worked.

Unfortunately, that solution isn't ideal because not all *Finder
instances can accept absolute paths like that. The
MercurialRevisionFinder is one of them.

Changing the moz.build reader to talk in terms of relative paths is a
lot of work. While this would be ideal, it is significantly easier to
defer the problem until later and hack up MercurialRevisionFinder to
accept absolute paths. This commit does exactly that.

Bug 1171069 has been filed to track converting BuildReader to relative
paths.
2015-06-08 09:33:46 -07:00
Gregory Szorc
d64a7e66e6 Bug 1168607 - Implement a finder that reads from a Mercurial repo; r=glandium
Now that moz.build files use finders for I/O, we can start reading
moz.build data from other sources.

Version control is essentially a filesystem. We implement a finder
that speaks to Mercurial to obtain file data. It is able to obtain
file data from a specific revision in the repository.

We use the hglib package (which uses the Mercurial command server) for
speaking with Mercurial. This adds overhead compared to consuming the
raw Mercurial APIs. However, it also avoids GPL side-effects of
importing Mercurial's Python modules.

Testing shows that performance is good but not great. A follow-up
commit will introduce a GPL licensed Mercurial finder. For now, get
the base functionality in place.
2015-06-09 13:39:01 -07:00
Gregory Szorc
105df5a295 Bug 1168607 - Use mozpack Finders for reading moz.build files; r=glandium
Sometimes moz.build data may not come from the local filesystem. To
support defining moz.build data in other backing stores, we switch
moz.build reading to use mozpack's *Finder classes for I/O.

The use of a FileFinder bound to / is sub-optimal. We should ideally
be creating a finder bound to topsrcdir. However, doing this would
require refactoring a lot of path handling in the reader, as that code
makes many assumptions that paths are absolute. This would be excellent
follow-up work.

While I was here, I cleaned up some linter warnings for unused imports.

On my machine, this commit results in a slight slowdown of moz.build
reading. Before, `mach build-backend` was consistently reporting 1.99s
for reading 2,572 moz.build files. After, it is consistently reporting
2.07s, an increase of 4%. This is likely due to a) function call
overhead b) the cost of instantiating a few thousand File instances
c) FileFinder performing an os.path.exists() before returning File
instances. I believe the regression is tolerable.
2015-06-09 18:16:35 -07:00
Gregory Szorc
1c6e12f560 Bug 1168607 - Add a read() method to File; r=glandium
Passing raw file handles around is a bit dangerous because it could lead
to leaking file descriptors. Add a read() method that handles the simple
case of obtaining the full contents of a File instance.

This should ideally be a method on BaseFile. But this would require
extra work and isn't needed. So we've deferred it until bug 1170329.
2015-06-02 09:37:45 -07:00
Gregory Szorc
b4a637bb54 Bug 1168607 - Add get method to finders; r=glandium
Today, the *Finder classes are optimized for doing matching and
returning multiple results. However, sometimes only looking for a
single file is wanted.

This commit implements the "get" method on all the *Finder classes.
It returns a BaseFile or None.

FileFinder._find_file has been refactored into FileFinder.get
to avoid code duplication.
2015-06-04 11:24:03 -07:00
Xidorn Quan
921ab27a26 Bug 1166960 - Remove redundant call to UnlockPointer and unnecessary check before calling that function. r=smaug 2015-06-10 13:14:57 +12:00
Xidorn Quan
a8384e6fa4 Bug 1172664 - Use [NSApplication setPresentationOptions:] instead of SetSystemUIMode for hide os chrome. r=smichaud 2015-06-10 13:13:49 +12:00
Xidorn Quan
58e820f6a4 Bug 1171328 - Convert nsTableFrame::GetChildAreaOffset() and its friends to use LogicalMargin. r=dholbert 2015-06-10 13:13:49 +12:00
Eric Rahm
b72a862d28 Bug 1172138 - Call PR_LogInit before profiler_init. r=froydnj 2015-06-09 17:44:46 -07:00
Chris Manchester
edcfca9dfd Bug 1149670 - Add a mach command to find tests in specified directories and prepare a commit to push them to try.;r=ahal 2015-05-28 15:57:21 -07:00
Chris Manchester
4e303fe7a6 Bug 1173026 - Fix typo in path to taskcluster build definition.;r=mrrrgn 2015-06-09 17:37:02 -07:00
Mike Hommey
e7316de18a Bug 1172800 - Create actual functions to execute moz.build templates. r=gps
The current mode of execution of templates doesn't allow them to more advanced
control flow, like returning early, returning or yielding values, because that
mode of execution is equivalent to running the code at the top level of a .py
file.

Making the templates executed through a function call, although trickier,
allows those control flows, which will be useful for template as context
managers.
2015-06-10 09:33:22 +09:00
Mike Hommey
ad313aeb3b Bug 1172800 - Avoid using inspect.getsourcelines() and inspect.getfile(). r=gps
inspect.getsourcelines() and inspect.getfile() involve I/O out of our control.
Our use of those functions, however, doesn't require all their smarts. In fact,
we only use them on function objects, for which we can just do the work
ourselves without involving inspect functions that trigger I/O.
2015-06-10 09:33:21 +09:00
Mike Hommey
d86ab35b59 Bug 1172800 - Move moz.build template handling in a separate class. r=gps
This will make subsequent refactorings a bit more intelligible.
2015-06-10 09:33:20 +09:00
Mike Hommey
6421f64a64 Bug 1172800 - Fixup after bug 991983. r=gps 2015-06-10 09:33:19 +09:00
Mike Hommey
1f8e80ba43 Bug 985857 - Automatically log mach output and add a command to display it. r=gps 2015-06-10 09:33:19 +09:00
Birunthan Mohanathas
cdc698bf0f Bug 968520 - Add mozilla::fallible to more FallibleTArray::InsertElementsAt calls. r=froydnj 2015-06-09 17:27:35 -07:00
Birunthan Mohanathas
67cae0519f Bug 968520 - Add more fallible variants of nsTArray::InsertElementsAt. r=froydnj 2015-06-09 17:27:31 -07:00
Birunthan Mohanathas
c84827bad2 Bug 968520 - Add mozilla::fallible to FallibleTArray::InsertElementSorted calls. r=froydnj 2015-06-08 13:40:00 -07:00
Birunthan Mohanathas
bd16fa84fb Bug 968520 - Add fallible variants of nsTArray::InsertElementSorted. r=froydnj 2015-06-08 13:39:57 -07:00
Birunthan Mohanathas
24c1c3301c Bug 968520 - Make nsTArray::InsertElementSorted support moves. r=froydnj 2015-06-08 13:39:53 -07:00
Birunthan Mohanathas
3959b83c21 Bug 968520 - Add mozilla::fallible to FallibleArray calls in tests. r=froydnj 2015-06-08 13:39:49 -07:00
Birunthan Mohanathas
1a70198650 Bug 1170758 - Make non-debug GraphSpewer constructor explicit. r=nbp 2015-06-02 15:10:16 -07:00
Ehsan Akhgari
170eef9b5a Bug 1173029 - Remove mFinalURL from InternalResponse; r=baku a=KWierso 2015-06-09 20:08:09 -04:00
Ehsan Akhgari
20d697dd4d Bug 1170937 - Set the URL on the Response object created from a fetch() properly if the underlying channel gets redirected; r=baku 2015-06-09 20:07:48 -04:00
Wes Kocher
13b7b7bfbe Backed out changeset ec31f39d4df8 (bug 1170937) for mochitest-e10s-4 permafail CLOSED TREE 2015-06-09 15:16:42 -07:00
Wes Kocher
1743ba7608 Backed out changeset e33db57c3fec (bug 1173029) 2015-06-09 15:16:30 -07:00
Wes Kocher
715960ba05 Backed out changeset 8ee308c30146 (bug 1161166) for debug osx mochitest failures 2015-06-09 15:12:29 -07:00
Wes Kocher
f36a4ced9d Backed out changeset 1be05715932f (bug 1161166) 2015-06-09 15:12:21 -07:00
David Keeler
08dfe96c6a bug 1170303 - treat malformed name information in certificates as a domain name mismatch r=Cykesiopka 2015-06-01 13:55:23 -07:00
JW Wang
9b52f419be Bug 1172390 - Align stream blocking of decoded stream with play state of MDSM. r=roc. 2015-06-08 16:51:39 +08:00
David Keeler
1bf24e0cc5 bug 1171557 - make test_cert_trust.js certs a bit more realistic r=mgoodwin
According to the Baseline Requirements, root certificates MUST NOT
have the extendedKeyUsage extension. The extension is optional for
intermediates and required for end-entity certificates. This change
modifies the test certificates so they're more in line with the BRs.
2015-06-03 15:37:38 -07:00
David Keeler
25303078e1 bug 1171557 - convert test_cert_trust.js to generate certificates at build time r=mgoodwin 2015-06-03 15:12:00 -07:00
Steve Fink
aa255c9d4d Bug 1172682 - Comment and refactor analysis code, r=terrence
The one change this patch makes in functionality is that it properly computes minimumUse in more cases, in anticipation of it being used for hazards (in addition to its current use for unnecessary roots).
2015-06-09 14:53:40 -07:00
Steve Fink
75000ea7c0 No bug. Add a --function argument for analyzing a single function by name. 2015-06-09 14:53:17 -07:00
Steve Fink
9093873417 Bug 1166101 - redirect aka os.file.redirect should not be available in fuzzing mode 2015-06-08 12:32:17 -07:00
Trevor Saunders
1d487a4fcd bug 1172538 - make sure a document has an IPC actor before shutting it down r=davidb, lsocks
If a document is shutdown before ever being bound to a parent document it
doesn't have an associated IPC actor, so we shouldn't try and shut one down.
2015-06-09 17:49:05 -04:00
Ben Turner
2f9806beef Bug 1173002 - Set worker system principal flag correctly when created from chrome, r=bz, a=kwierso. 2015-06-09 14:34:00 -07:00
David Major
668cc497e7 Bug 1173107: Add hexa() around various hr logging. r=jrmuizel a=KWierso 2015-06-09 16:48:59 -04:00
Ehsan Akhgari
f4ffa1a9b5 Bug 1173029 - Remove mFinalURL from InternalResponse; r=baku a=KWierso 2015-06-09 17:17:59 -04:00
Ehsan Akhgari
97406e9c52 Bug 1170937 - Set the URL on the Response object created from a fetch() properly if the underlying channel gets redirected; r=baku 2015-06-09 17:17:52 -04:00
Daniel Holbert
cf7f1c6cfe Bug 1171171: Move nsAppRunner's gfxPrefs #include out of windows-specific section. r=milan a=KWierso 2015-06-09 14:07:08 -07:00
Ryan VanderMeulen
66c96f535b Merge m-c to inbound. a=merge 2015-06-09 16:15:48 -04:00
Jonathan Griffin
e7ecc2c820 Bug 1170632 - Add win and linux64-pgo e10s runtimes files, a=fix bustage 2015-06-09 13:08:42 -07:00