Commit Graph

13950 Commits

Author SHA1 Message Date
Andrea Marchesini
9368a3d589 Bug 1171603 - Better size check in nsTSubstring::ReplacePrep. r=ehsan
--HG--
extra : rebase_source : 608ecb648abaebc7e8c78870e14c406027f1d2cb
2015-07-02 14:51:42 -04:00
Boris Kudryavtsev
027e60563e Bug 1155968 - Fix variable use before initialization. r=khuey 2015-06-02 12:17:00 +02:00
Boris Kudryavtsev
50bd38bd38 Bug 1155968 - Fix correct number of empty lines between objects to comply with PEP8. r=khuey 2015-05-20 21:56:00 +02:00
Boris Kudryavtsev
f75453e666 Bug 1155968 - Fix indentation warnings to comply with PEP8. r=khuey 2015-05-20 21:55:00 +02:00
Boris Kudryavtsev
13d9229e12 Bug 1155968 - Whitespace fixes in xpidl.py to comply with PEP8. r=khuey 2015-05-16 12:18:00 +02:00
Boris Kudryavtsev
fa8c2b1b78 Bug 1155968 - Change '==' and '!=' to 'is' and 'is not' to comply with PEP8. r=khuey 2015-05-14 19:50:00 +02:00
Boris Kudryavtsev
baaa8b054e Bug 1155968 - Correct indent not multiple of 4. r=khuey 2015-05-12 18:41:00 +02:00
Boris Kudryavtsev
26a5f1e8dc Bug 1155968 - Remove semicolons at ends of statements (PEP8). r=khuey 2015-05-09 12:38:00 +02:00
Boris Kudryavtsev
b24932ea8e Bug 1155968 - Move statements to their own lines. r=khuey 2015-05-05 17:24:00 +02:00
Boris Kudryavtsev
dc76fa3749 Bug 1155968 - Whitespace changes in header.py and runtests.py. r=khuey 2015-05-04 22:45:00 +02:00
Boris Kudryavtsev
8f40bd3325 Bug 1155968 - Remove trailing whitespace in header.py. r=khuey 2015-05-04 22:41:00 +02:00
Boris Kudryavtsev
5562b1dcb8 Bug 1155968 - Add blank lines where needed in xpcom/idl-parser. r=khuey 2015-05-04 22:35:00 +02:00
Boris Kudryavtsev
ec7138788a Bug 1155968 - Place imports on separate lines. r=khuey 2015-05-04 22:34:00 +02:00
William Chen
e2a8b6bfa3 Bug 1178513 - Add <extapp> element and interfaces to be used by ACL. r=khuey
--HG--
extra : rebase_source : 988379e48f84c04bcac181a6fc4c71325e3f0b02
2015-06-30 11:27:57 -07:00
Nathan Froyd
8b000ee8d1 Bug 1174344 - make error message for mismatched leak log entries more helpful; r=mccr8 2015-06-29 16:36:32 -04:00
Mike Hommey
f2057d31b4 Backout changeset f70b74488807 (bug 833117) for gtest bustage on Linux 2015-07-01 16:41:20 +09:00
Mike Hommey
6535b630b6 Bug 833117 - Replace g_slice_set_config() with G_SLICE environment variable. r=nfroyd,r=karlt
Using g_slice_set_config() fails with newer glib because the slice allocator
now has a static constructor that runs when glib is loaded, consequently
emitting a noisy error message which confuses people into believing it's the
root of their problems.

The only way left to force the slice allocator to use "system" malloc (in
practice, jemalloc) is to set the G_SLICE environment variable to
always-malloc, and that needs to happen before glib is loaded.

Fortunately, the firefox and plugin-container executables don't depend on
glib. Unfortunately, webapprt does, so the problem remains for web apps
running through it. xpcshell and other executables that depend on libxul
directly (as opposed to loading it dynamically) are not covered either.
2015-07-01 15:29:46 +09:00
Ryan VanderMeulen
faaac1a61d Backed out changeset 37bee149c935 (bug 968520) for checktest failures. 2015-06-30 15:47:18 -04:00
Birunthan Mohanathas
ebd21e20f1 Bug 968520 - Add nsTArray::Assign. r=froydnj 2015-06-30 11:16:03 -07:00
Jan de Mooij
976586cb5f Bug 1177825 - Remove JSVAL_* constants. r=evilpie 2015-06-29 18:36:44 -07:00
Wes Kocher
b4ebe3c719 Merge m-c to inbound, a=merge 2015-06-29 17:28:20 -07:00
ffxbld
264ecae3ce Update configs. IGNORE BROKEN CHANGESETS CLOSED TREE NO BUG a=release ba=release 2015-06-29 13:34:04 -07:00
Ryan VanderMeulen
872107fe72 Backed out changeset a1089f3645fc (bug 1151506) because it didn't fix the crashes it was intended to. a=lizzard 2015-06-29 14:53:55 -04:00
Nicholas Nethercote
459a5b589b Bug 1176163 - Remove remaining uses of PL_DHashTableEnumerate() from xpcom/. r=froydnj.
--HG--
extra : rebase_source : 5e79d10647c138a28370d36d28a1c1227af8167b
2015-06-18 18:09:37 -07:00
David Major
d15cf4043f Bug 1151506: Work around broken binary callers of xptiInterfaceInfo. r=froydnj
--HG--
extra : rebase_source : 7a27a2da649ab44113525dec7f2ea365688c1c81
2015-06-26 10:33:44 -07:00
Nathan Froyd
2c8aa84236 Bug 1178317 - eliminate large static constructor from ShimInterfaceInfo.cpp; r=poiru
Constructing kComponentsInterfaceShimMap required a static constructor
on some compilers, due to a non-constexpr constructor and the necessity
of copying non-constexpr things like nsIID.  This static constructor is
large (several kilobytes of object code on x86-64) and completely
unnecessary.

To fix this, let's add a constexpr (well, MOZ_CONSTEXPR) constructor to
ComponentsInterfaceShimEntry.  This change alone doesn't completely
solve our problem, because the nsIID member still needs to be copied.
But doing that copying is silly: we only use the IID for constructing a
ShimInterfaceInfo in ShimInterfaceInfo::MaybeConstruct, and the
ShimInterfaceInfo constructor takes a const reference.  So let's store a
const reference in ComponentsInterfaceShimEntry, too, and make that
structure significantly smaller in the process.
2015-06-29 10:59:59 -04:00
Nathan Froyd
4d01d51096 Bug 1178363 - make nsTimerImpl::GetGeneration a private method; r=poiru
Since GetGeneration() is only called by nsTimerEvent, it doesn't need to
be public.
2015-06-29 13:09:11 -04:00
Nathan Froyd
ed7e987ecb Bug 1178363 - make nsTimerImpl::PostTimerEvent a private method; r=poiru
PostTimerEvent is only called by the timer thread, which is already able
to access private members of nsTimerImpl; there's no reason for
PostTimerEvent to be public.
2015-06-29 10:33:30 -04:00
Nathan Froyd
889fc1ad61 Bug 1178363 - make MOZ_TASK_TRACER-dependent bits of nsTimerImpl private; r=poiru
GetTracedTask() is only called from nsTimerImpl itself, so it doesn't
need to be public.  GetTLSTraceInfo() is called from the timer thread,
which has access to our private members already.
2015-06-18 12:02:23 -04:00
Nathan Froyd
4fea06a3a3 Bug 1178363 - make nsTimerImpl::Fire a private method; r=poiru
This method is only called by nsTimerEvent, which is an implementation
detail of nsTimerImpl.
2015-06-18 12:00:56 -04:00
Nathan Froyd
22b75ae28f Bug 1178363 - make nsTimerImpl::SetDelayInternal a private method; r=poiru
Nothing outside nsTimerImpl uses it, and with a name like
"SetDelayInternal", nothing should.
2015-06-17 21:40:18 -04:00
Ryan VanderMeulen
5f5c327690 Backed out changeset 8b4e4083639e (bug 1171931) for B2G debug emulator bustage. 2015-06-25 19:48:42 -04:00
Juan Gomez
702a59d135 Bug 1171931 - Refactor duplicated code using XRE_IsParent/ContentProcess. r=froydnj
--HG--
extra : rebase_source : 2ecbe6c1dd8a7ad8dc529b53349ad431cf1116c9
2015-06-24 14:11:00 -04:00
David Major
17a51c4514 Bug 1151506 - Null-check the count parameter in GetConstantCount. r=froydnj 2015-06-24 09:07:11 -07:00
Chris Peterson
cd8ae89cff Bug 1175049 - Fix non-universal 32-bit build on OS X with Xcode 6.3 tools. r=josh 2015-06-14 00:20:27 -07:00
Bill McCloskey
a2c6c7d4bf Bug 1143006 - Show warning for http-on-* in child process (r=mrbkap) 2015-06-19 17:35:06 -07:00
Benoit Girard
8d6a67f6d3 Bug 1172216 - Move nsStackwalk to mozglue. r=glandium
--HG--
rename : xpcom/base/nsStackWalk.cpp => mozglue/misc/StackWalk.cpp
rename : xpcom/base/nsStackWalk.h => mozglue/misc/StackWalk.h
extra : commitid : EMbWGfjKvdq
extra : rebase_source : b7308eb569cc1a019d3b7a92aaff0de7a49b5682
2015-06-10 16:32:45 -04:00
Benoit Girard
2c6df6a9a9 Bug 858927 - Move the mozilla::TimeStamp into mozglue. r=glandium
--HG--
rename : xpcom/ds/TimeStamp.cpp => mozglue/misc/TimeStamp.cpp
rename : xpcom/ds/TimeStamp.h => mozglue/misc/TimeStamp.h
rename : xpcom/ds/TimeStamp_darwin.cpp => mozglue/misc/TimeStamp_darwin.cpp
rename : xpcom/ds/TimeStamp_posix.cpp => mozglue/misc/TimeStamp_posix.cpp
rename : xpcom/ds/TimeStamp_windows.cpp => mozglue/misc/TimeStamp_windows.cpp
rename : xpcom/ds/TimeStamp_windows.h => mozglue/misc/TimeStamp_windows.h
extra : commitid : 2MSXRaRzXEd
extra : rebase_source : 45ded19677e8557deb3b9203777656f5a13f6c04
2015-06-05 16:03:11 -04:00
Ryan VanderMeulen
bb011905c4 Bug 704368 - Re-enable test_nsIProcess_stress.js on Linux64 debug.
--HG--
extra : amend_source : 901edc75c301857b2eaa094920cf410f336003a0
2015-06-18 11:28:51 -04:00
Carsten "Tomcat" Book
78ccc28817 merge mozilla-inbound to mozilla-central a=merge 2015-06-18 15:13:19 +02:00
Tom Tromey
0b980d99e6 Bug 1159507 - make allocation times consistent with timeline; r=fitzgen,mccr8 2015-06-17 13:01:27 -07:00
Nicholas Nethercote
0d28f19c4a Bug 1173600 (part 3) - Add PLDHashTable::RemovingIterator. r=froydnj.
--HG--
extra : rebase_source : 1158e03a699987e366b46b9e045613f6b9fe1a59
2015-06-10 17:04:07 -07:00
Nicholas Nethercote
fb490785c1 Bug 1173600 (part 2) - Move post-enumeration shrinking code into its own function. r=froydnj.
This will allow it to be re-used by the removing iterator class.

--HG--
extra : rebase_source : 2bdd33427894c291aa507469628a3ba99b80c568
2015-06-10 16:36:02 -07:00
Nicholas Nethercote
e8172cd960 Bug 1173600 (part 1) - Tweak PLDHashTable post-enumeration shrinking. r=froydnj.
This patch factors out the existing capacity calculation code in HashShift()
into a new function called BestCapacity(), and then reuses it for
post-enumeration shrinking.

BestCapacity() computes capacity with |CeilingLog2(ceil(length * 4 / 3))|,
which ensures a minimum capacity while respecting the "max 75% full" and
"capacity is a power of two" constraints. In contrast, the old post-enumeration
shrink calculation was |CeilingLog2(length + length/2)|, which gives higher
results in some cases. (Both calculations also ensured the capacity wasn't too
small.) E.g. if length is 48, the former calculation will give 64, while the
latter will give 128.

Therefore, post-enumeration shrinking will no longer give a
larger-than-necessary capacity some cases. This feels like the right thing to
do in isolation, and making it consistent with HashShift() -- used during table
construction -- is also good.

--HG--
extra : rebase_source : 55e982b601c345d10da7abd03a13aec3f5b61598
2015-06-10 13:54:06 -07:00
Boris Zbarsky
075355a9e5 Bug 1175601. Make nsIFile.getRelativeDescriptor work with paths with paths with arbitrary numbers of segments, not just 32. r=froydnj 2015-06-17 16:17:22 -04:00
Boris Zbarsky
bf8f45932e Bug 1175600. Add getRelativePath/setRelativePath to nsIFile. r=froydnj 2015-06-17 16:17:20 -04:00
Nicholas Nethercote
e94846adea Bug 11746250 (follow-up) - Fix link errors on Linux and Android. r=me. 2015-06-16 23:48:53 -07:00
Nicholas Nethercote
a1b715b5df Bug 1174625 - Overhaul PLDHashTable's iterator. r=froydnj.
This change splits PLDHashTable::Iterator::NextEntry() into two separate
functions, which allow you to get the current element and advance the iterator
separately, which means you can use a for-loop to iterate instead of a
while-loop.

As part of this change, the internals of PLDHashTable::Iterator were
significantly changed and simplified (and modelled after js::HashTable's
equivalent code). It's no longer duplicating code from PL_DHashTableEnumerator.
The chaos mode code was a casualty of this, but given how unreliable that code
has proven to be (see bug 1173212, bug 1174046) this is for the best. (We can
reimplement chaos mode once PLDHashTable::Iterator is back on more solid
footing again, if we think it's important.)

All these changes will make it much easier to add an alternative Iterator that
removes elements, which was turning out to be difficult with the prior code.

In order to make the for-loop header usually fit on a single line, I
deliberately renamed a bunch of things to have shorter names.

In summary, you used to write this:

  PLDHashTable::Iterator iter(&table);
  while (iter.HasMoreEntries()) {
    auto entry = static_cast<FooEntry*>(iter.NextEntry());
    // ... do stuff with |entry| ...
  }
  // iter's scope extends beyond here

and now you write this:

  for (auto iter = table.Iter(); !iter.Done(); iter.Next()) {
    auto entry = static_cast<FooEntry*>(iter.Get());
    // ... do stuff with |entry| ...
  }
  // iter's scope doesn't reach here

--HG--
extra : rebase_source : fa5cac2fc50b1ab7624030bced4763131280f4d8
2015-06-11 21:19:53 -07:00
Andrew McCreight
e7103d0010 Bug 1174796 - Make sure ReleaseNow releases everything. r=smaug 2015-06-16 14:19:07 -07:00
Shelly Lin
4eff0a1842 Bug 1113562 - Expected delay time of tasks should not be the latency of those kind. r=sinker
--HG--
extra : rebase_source : b5e012fb6570e87270a0924fbe395dc56e6242ec
2015-06-16 10:57:19 +08:00