mirror of
https://github.com/roytam1/palemoon27.git
synced 2026-05-26 14:18:48 +00:00
import changes from `dev' branch of rmottola/Arctic-Fox:
- Bug 1126544 - Update sixgill to handle more constructs and manage memory better (e487a0cd05) - Bug 1182407 - Use unpack feature of tooltool wherever possible. r=mshal (6bde76a413) - Bug 1123386 - Part 4: Update the tooltool manifests for the OSX and Linux static analysis builds in order to upgrade clang; r=rail (517ae90efa) - Bug 1204722 - Make sure that unboxed arrays created from literals are compatible with the type of the literal's elements, r=jandem. (400663edb4) - Bug 1117259 - Disable the no-unused-local-typedef warning if clang supports it; r=gps (16e2e49fc6) - Bug 1126813 - Turn on the -Wrange-loop-analysis warning if available; r=gps (1c783e1ed2) - Bug 1191688 - Add -nologo option to rc.exe. r=ted (9c5dbe2b89) - Bug 1150312 - Remove MOZ_SHARK. r=glandium (ba6db939d4) - Bug 1186636 - Add a pref to configure -moz prefixed gradients support. r=dholbert (9c41ae7460) - missing parts of Bug 1077282: Cleanup uses of GreD vs GreBinD, introcuded by v2 signature changes on OSX. Based on initial patch by rstrong. r=bsmedberg (af60bfc743) - de-palemoon (d8b7bae74f) - Bug 932100 - Part 1: Remove load-time dependency on user32. r=bsmedberg (9864a0ed0c) - missing part of Bug 932100 - Part 2: Move DLL blocklist code to mozglue. r=bsmedberg, r=glandium (6497ad86bd) - Bug 1194890 - Ensure that any user32 imports to mozglue are delay loaded; r=glandium (afa0a8d14e) - Bug 1082792 - Build firefox.exe with -MD in ASAN builds; r=glandium (89771bb4c0) - missing VPX/WEBM stuff (ec425938c9) - Bug 1184452 - Correctly reject @font-face descriptors that have garbage after them. r=heycam (f530fc858e) - Bug 1189922. Add a preference to enable global whitelisting of the CSSUnprefixingService. r=dholbert (e2997cb125) - Bug 1198732 - IonMonkey: MIPS32: Fix calculate frame size in generateEnterJIT. r=nbp (454d75946d) - Bug 1199057 - IonMonkey: MIPS32: Plumb new.target on the stack and make it accessible to JSNatives. r=nbp (01d5cb04c2) - Bug 1204306 - IonMonkey: MIPS32: Clean up MacroAssembler functions that aliased to Assembler. r=arai (600dc73280) - Bug 1199080 - IonMonkey: MIPS32: Fix treating saved frame bit as part# o the frame type. r=nbp (5e4e5ba250) - Bug 1099448 - Don't accept box properties with invalid calc() or rgb() etc. function values. r=dbaron (5737e8c300) - Bug 1203142 - Insert /**/ separate between two adjacent '-' symbols when serializing token streams. r=simon.sapin (06fb613d6c) - Bug 1057680 - Add support for font-stretch values in the font shorthand. r=jdaggett (8d8e24751d) - Bug 1155485 - Mark nsFrameManagerBase::mPresShell as MOZ_NON_OWNING_REF; r=roc (e79e28bbd0) - Bug 1121760 (part 5) - Remove PL_DHashMarkTableImmutable(). r=poiru. (8d8c7d9d65) - Bug 1121760 (part 6) - Move all remaining PL_DHash*() functions into PLDHashTable. r=poiru. (d36ec167cc)
This commit is contained in:
@@ -1,28 +1,23 @@
|
||||
[
|
||||
{
|
||||
"size": 51,
|
||||
"digest": "c8e40edb314eeabfb92c77cf5ff9a7857033f15dd65a00349bcf9e3e5b75624afc71f733b2ff7e029c20a78313038409c2bd022bf7e5a7e0c487fc2c2d640986",
|
||||
"algorithm": "sha512",
|
||||
"filename": "setup.sh"
|
||||
},
|
||||
{
|
||||
"size": 80458572,
|
||||
"digest": "e5101f9dee1e462f6cbd3897ea57eede41d23981825c7b20d91d23ab461875d54d3dfc24999aa58a31e8b01f49fb3140e05ffe5af2957ef1d1afb89fd0dfe1ad",
|
||||
"algorithm": "sha512",
|
||||
"filename": "gcc.tar.xz",
|
||||
"unpack": "True"
|
||||
"unpack": true
|
||||
},
|
||||
{
|
||||
"size": 167175,
|
||||
"digest": "0b71a936edf5bd70cf274aaa5d7abc8f77fe8e7b5593a208f805cc9436fac646b9c4f0b43c2b10de63ff3da671497d35536077ecbc72dba7f8159a38b580f831",
|
||||
"algorithm": "sha512",
|
||||
"filename": "sccache.tar.bz2"
|
||||
"filename": "sccache.tar.bz2",
|
||||
"unpack": true
|
||||
},
|
||||
{
|
||||
"size": 31057326,
|
||||
"digest": "b844c3e52be493d2cacafa58c4a924b89c9be8d2dcc2a7c71aed58c253d8035fba4d51df309f73e3c4342a1f3c3898a9a25c4815e2112888d1280f43c41c8e51",
|
||||
"algorithm": "sha512",
|
||||
"filename": "moztt.tar.bz2",
|
||||
"unpack": "True"
|
||||
"unpack": true
|
||||
}
|
||||
]
|
||||
|
||||
@@ -1,28 +1,23 @@
|
||||
[
|
||||
{
|
||||
"size": 51,
|
||||
"digest": "c8e40edb314eeabfb92c77cf5ff9a7857033f15dd65a00349bcf9e3e5b75624afc71f733b2ff7e029c20a78313038409c2bd022bf7e5a7e0c487fc2c2d640986",
|
||||
"algorithm": "sha512",
|
||||
"filename": "setup.sh"
|
||||
},
|
||||
{
|
||||
"size": 80458572,
|
||||
"digest": "e5101f9dee1e462f6cbd3897ea57eede41d23981825c7b20d91d23ab461875d54d3dfc24999aa58a31e8b01f49fb3140e05ffe5af2957ef1d1afb89fd0dfe1ad",
|
||||
"algorithm": "sha512",
|
||||
"filename": "gcc.tar.xz",
|
||||
"unpack": "True"
|
||||
"unpack": true
|
||||
},
|
||||
{
|
||||
"size": 167175,
|
||||
"digest": "0b71a936edf5bd70cf274aaa5d7abc8f77fe8e7b5593a208f805cc9436fac646b9c4f0b43c2b10de63ff3da671497d35536077ecbc72dba7f8159a38b580f831",
|
||||
"algorithm": "sha512",
|
||||
"filename": "sccache.tar.bz2"
|
||||
"filename": "sccache.tar.bz2",
|
||||
"unpack": true
|
||||
},
|
||||
{
|
||||
"size": 31057326,
|
||||
"digest": "b844c3e52be493d2cacafa58c4a924b89c9be8d2dcc2a7c71aed58c253d8035fba4d51df309f73e3c4342a1f3c3898a9a25c4815e2112888d1280f43c41c8e51",
|
||||
"algorithm": "sha512",
|
||||
"filename": "moztt.tar.bz2",
|
||||
"unpack": "True"
|
||||
"unpack": true
|
||||
}
|
||||
]
|
||||
|
||||
@@ -3,28 +3,24 @@
|
||||
"clang_version": "r183744"
|
||||
},
|
||||
{
|
||||
"size": 88,
|
||||
"digest": "0d2ae9bcd7cea34ec0b768270725e98410dbb3bc150c7381e0dcf3eb5dbb3e69ac76dbb0f46b056151d6a6fa8681cab06da68173ae8598f3397b8f7628e67381",
|
||||
"algorithm": "sha512",
|
||||
"filename": "setup.sh"
|
||||
},
|
||||
{
|
||||
"size": 59602619,
|
||||
"digest": "86662ebc0ef650490559005948c4f0cb015dad72c7cac43732c2bf2995247081e30c139cf8008d19670a0009fc302c4eee2676981ee3f9ff4a15c01af22b783b",
|
||||
"algorithm": "sha512",
|
||||
"filename": "clang.tar.bz2"
|
||||
"filename": "clang.tar.bz2",
|
||||
"unpack": true
|
||||
},
|
||||
{
|
||||
"size": 167175,
|
||||
"digest": "0b71a936edf5bd70cf274aaa5d7abc8f77fe8e7b5593a208f805cc9436fac646b9c4f0b43c2b10de63ff3da671497d35536077ecbc72dba7f8159a38b580f831",
|
||||
"algorithm": "sha512",
|
||||
"filename": "sccache.tar.bz2"
|
||||
"filename": "sccache.tar.bz2",
|
||||
"unpack": true
|
||||
},
|
||||
{
|
||||
"size": 31057326,
|
||||
"digest": "b844c3e52be493d2cacafa58c4a924b89c9be8d2dcc2a7c71aed58c253d8035fba4d51df309f73e3c4342a1f3c3898a9a25c4815e2112888d1280f43c41c8e51",
|
||||
"algorithm": "sha512",
|
||||
"filename": "moztt.tar.bz2",
|
||||
"unpack": "True"
|
||||
"unpack": true
|
||||
}
|
||||
]
|
||||
|
||||
@@ -1,27 +1,23 @@
|
||||
[
|
||||
{
|
||||
"size": 82,
|
||||
"digest": "70a6126249e40aa1da32248bf6bfe45e0d8c87334579ec0cf69403e61b635e27c766d9bf08d530978286552f158ee24c74b0168a57cc6b734dcfed4fc5e09cff",
|
||||
"algorithm": "sha512",
|
||||
"filename": "setup.sh"
|
||||
},
|
||||
{
|
||||
"size": 80458572,
|
||||
"digest": "e5101f9dee1e462f6cbd3897ea57eede41d23981825c7b20d91d23ab461875d54d3dfc24999aa58a31e8b01f49fb3140e05ffe5af2957ef1d1afb89fd0dfe1ad",
|
||||
"algorithm": "sha512",
|
||||
"filename": "gcc.tar.xz"
|
||||
"filename": "gcc.tar.xz",
|
||||
"unpack": true
|
||||
},
|
||||
{
|
||||
"size": 167175,
|
||||
"digest": "0b71a936edf5bd70cf274aaa5d7abc8f77fe8e7b5593a208f805cc9436fac646b9c4f0b43c2b10de63ff3da671497d35536077ecbc72dba7f8159a38b580f831",
|
||||
"algorithm": "sha512",
|
||||
"filename": "sccache.tar.bz2"
|
||||
"filename": "sccache.tar.bz2",
|
||||
"unpack": true
|
||||
},
|
||||
{
|
||||
"size": 31057326,
|
||||
"digest": "b844c3e52be493d2cacafa58c4a924b89c9be8d2dcc2a7c71aed58c253d8035fba4d51df309f73e3c4342a1f3c3898a9a25c4815e2112888d1280f43c41c8e51",
|
||||
"algorithm": "sha512",
|
||||
"filename": "moztt.tar.bz2",
|
||||
"unpack": "True"
|
||||
"unpack": true
|
||||
}
|
||||
]
|
||||
|
||||
@@ -3,28 +3,24 @@
|
||||
"clang_version": "r183744"
|
||||
},
|
||||
{
|
||||
"size": 88,
|
||||
"digest": "0d2ae9bcd7cea34ec0b768270725e98410dbb3bc150c7381e0dcf3eb5dbb3e69ac76dbb0f46b056151d6a6fa8681cab06da68173ae8598f3397b8f7628e67381",
|
||||
"algorithm": "sha512",
|
||||
"filename": "setup.sh"
|
||||
},
|
||||
{
|
||||
"size": 59602619,
|
||||
"digest": "86662ebc0ef650490559005948c4f0cb015dad72c7cac43732c2bf2995247081e30c139cf8008d19670a0009fc302c4eee2676981ee3f9ff4a15c01af22b783b",
|
||||
"algorithm": "sha512",
|
||||
"filename": "clang.tar.bz2"
|
||||
"filename": "clang.tar.bz2",
|
||||
"unpack": true
|
||||
},
|
||||
{
|
||||
"size": 167175,
|
||||
"digest": "0b71a936edf5bd70cf274aaa5d7abc8f77fe8e7b5593a208f805cc9436fac646b9c4f0b43c2b10de63ff3da671497d35536077ecbc72dba7f8159a38b580f831",
|
||||
"algorithm": "sha512",
|
||||
"filename": "sccache.tar.bz2"
|
||||
"filename": "sccache.tar.bz2",
|
||||
"unpack": true
|
||||
},
|
||||
{
|
||||
"size": 31057326,
|
||||
"digest": "b844c3e52be493d2cacafa58c4a924b89c9be8d2dcc2a7c71aed58c253d8035fba4d51df309f73e3c4342a1f3c3898a9a25c4815e2112888d1280f43c41c8e51",
|
||||
"algorithm": "sha512",
|
||||
"filename": "moztt.tar.bz2",
|
||||
"unpack": "True"
|
||||
"unpack": true
|
||||
}
|
||||
]
|
||||
|
||||
@@ -6,22 +6,17 @@
|
||||
"filename": "mozmake.exe"
|
||||
},
|
||||
{
|
||||
"size": 51,
|
||||
"digest": "c8e40edb314eeabfb92c77cf5ff9a7857033f15dd65a00349bcf9e3e5b75624afc71f733b2ff7e029c20a78313038409c2bd022bf7e5a7e0c487fc2c2d640986",
|
||||
"algorithm": "sha512",
|
||||
"filename": "setup.sh"
|
||||
},
|
||||
{
|
||||
"size": 167175,
|
||||
"digest": "0b71a936edf5bd70cf274aaa5d7abc8f77fe8e7b5593a208f805cc9436fac646b9c4f0b43c2b10de63ff3da671497d35536077ecbc72dba7f8159a38b580f831",
|
||||
"algorithm": "sha512",
|
||||
"filename": "sccache.tar.bz2"
|
||||
"filename": "sccache.tar.bz2",
|
||||
"unpack": true
|
||||
},
|
||||
{
|
||||
"size": 31057326,
|
||||
"digest": "b844c3e52be493d2cacafa58c4a924b89c9be8d2dcc2a7c71aed58c253d8035fba4d51df309f73e3c4342a1f3c3898a9a25c4815e2112888d1280f43c41c8e51",
|
||||
"algorithm": "sha512",
|
||||
"filename": "moztt.tar.bz2",
|
||||
"unpack": "True"
|
||||
"unpack": true
|
||||
}
|
||||
]
|
||||
|
||||
@@ -35,6 +35,11 @@
|
||||
|
||||
#ifdef XP_WIN
|
||||
// we want a wmain entry point
|
||||
#ifdef MOZ_ASAN
|
||||
// ASAN requires firefox.exe to be built with -MD, and it's OK if we don't
|
||||
// support Windows XP SP2 in ASAN builds.
|
||||
#define XRE_DONT_SUPPORT_XPSP2
|
||||
#endif
|
||||
#include "nsWindowsWMain.cpp"
|
||||
#define snprintf _snprintf
|
||||
#define strcasecmp _stricmp
|
||||
@@ -43,6 +48,7 @@
|
||||
|
||||
#include "nsXPCOMPrivate.h" // for MAXPATHLEN and XPCOM_DLL
|
||||
#include "mozilla/StartupTimeline.h"
|
||||
#include "mozilla/WindowsDllBlocklist.h"
|
||||
|
||||
using namespace mozilla;
|
||||
|
||||
@@ -72,10 +78,19 @@ static void Output(const char *fmt, ... )
|
||||
#if MOZ_WINCONSOLE
|
||||
fwprintf_s(stderr, wide_msg);
|
||||
#else
|
||||
MessageBoxW(nullptr,
|
||||
wide_msg,
|
||||
L"Pale Moon",
|
||||
MB_OK | MB_ICONERROR | MB_SETFOREGROUND);
|
||||
// Linking user32 at load-time interferes with the DLL blocklist (bug 932100).
|
||||
// This is a rare codepath, so we can load user32 at run-time instead.
|
||||
HMODULE user32 = LoadLibraryW(L"user32.dll");
|
||||
if (user32) {
|
||||
decltype(MessageBoxW)* messageBoxW =
|
||||
(decltype(MessageBoxW)*) GetProcAddress(user32, "MessageBoxW");
|
||||
if (messageBoxW) {
|
||||
messageBoxW(nullptr, wide_msg, L"Pale Moon", MB_OK
|
||||
| MB_ICONERROR
|
||||
| MB_SETFOREGROUND);
|
||||
}
|
||||
FreeLibrary(user32);
|
||||
}
|
||||
#endif
|
||||
#endif
|
||||
|
||||
@@ -105,9 +120,6 @@ static bool IsArg(const char* arg, const char* s)
|
||||
XRE_GetFileFromPathType XRE_GetFileFromPath;
|
||||
XRE_CreateAppDataType XRE_CreateAppData;
|
||||
XRE_FreeAppDataType XRE_FreeAppData;
|
||||
#ifdef XRE_HAS_DLL_BLOCKLIST
|
||||
XRE_SetupDllBlocklistType XRE_SetupDllBlocklist;
|
||||
#endif
|
||||
XRE_StartupTimelineRecordType XRE_StartupTimelineRecord;
|
||||
XRE_mainType XRE_main;
|
||||
XRE_StopLateWriteChecksType XRE_StopLateWriteChecks;
|
||||
@@ -116,9 +128,6 @@ static const nsDynamicFunctionLoad kXULFuncs[] = {
|
||||
{ "XRE_GetFileFromPath", (NSFuncPtr*) &XRE_GetFileFromPath },
|
||||
{ "XRE_CreateAppData", (NSFuncPtr*) &XRE_CreateAppData },
|
||||
{ "XRE_FreeAppData", (NSFuncPtr*) &XRE_FreeAppData },
|
||||
#ifdef XRE_HAS_DLL_BLOCKLIST
|
||||
{ "XRE_SetupDllBlocklist", (NSFuncPtr*) &XRE_SetupDllBlocklist },
|
||||
#endif
|
||||
{ "XRE_StartupTimelineRecord", (NSFuncPtr*) &XRE_StartupTimelineRecord },
|
||||
{ "XRE_main", (NSFuncPtr*) &XRE_main },
|
||||
{ "XRE_StopLateWriteChecks", (NSFuncPtr*) &XRE_StopLateWriteChecks },
|
||||
@@ -131,7 +140,7 @@ static int do_main(int argc, char* argv[], nsIFile *xreDirectory)
|
||||
nsresult rv;
|
||||
uint32_t mainFlags = 0;
|
||||
|
||||
// Allow palemoon.exe to launch XULRunner apps via -app <application.ini>
|
||||
// Allow firefox.exe to launch XULRunner apps via -app <application.ini>
|
||||
// Note that -app must be the *first* argument.
|
||||
const char *appDataFile = getenv("XUL_APP_FILE");
|
||||
if (appDataFile && *appDataFile) {
|
||||
@@ -178,7 +187,6 @@ static int do_main(int argc, char* argv[], nsIFile *xreDirectory)
|
||||
return result;
|
||||
}
|
||||
|
||||
// Desktop browser launch
|
||||
ScopedAppData appData(&sAppData);
|
||||
nsCOMPtr<nsIFile> exeFile;
|
||||
rv = mozilla::BinaryPath::GetFile(argv[0], getter_AddRefs(exeFile));
|
||||
@@ -190,10 +198,7 @@ static int do_main(int argc, char* argv[], nsIFile *xreDirectory)
|
||||
nsCOMPtr<nsIFile> greDir;
|
||||
exeFile->GetParent(getter_AddRefs(greDir));
|
||||
#ifdef XP_MACOSX
|
||||
nsCOMPtr<nsIFile> parent;
|
||||
greDir->GetParent(getter_AddRefs(parent));
|
||||
greDir = parent.forget();
|
||||
greDir->AppendNative(NS_LITERAL_CSTRING(kOSXResourcesFolder));
|
||||
greDir->SetNativeLeafName(NS_LITERAL_CSTRING(kOSXResourcesFolder));
|
||||
#endif
|
||||
nsCOMPtr<nsIFile> appSubdir;
|
||||
greDir->Clone(getter_AddRefs(appSubdir));
|
||||
@@ -334,6 +339,18 @@ int main(int argc, char* argv[])
|
||||
|
||||
nsIFile *xreDirectory;
|
||||
|
||||
#ifdef HAS_DLL_BLOCKLIST
|
||||
DllBlocklist_Initialize();
|
||||
|
||||
#ifdef DEBUG
|
||||
// In order to be effective against AppInit DLLs, the blocklist must be
|
||||
// initialized before user32.dll is loaded into the process (bug 932100).
|
||||
if (GetModuleHandleA("user32.dll")) {
|
||||
fprintf(stderr, "DLL blocklist was unable to intercept AppInit DLLs.\n");
|
||||
}
|
||||
#endif
|
||||
#endif
|
||||
|
||||
nsresult rv = InitXPCOMGlue(argv[0], &xreDirectory);
|
||||
if (NS_FAILED(rv)) {
|
||||
return 255;
|
||||
@@ -341,9 +358,6 @@ int main(int argc, char* argv[])
|
||||
|
||||
XRE_StartupTimelineRecord(mozilla::StartupTimeline::START, start);
|
||||
|
||||
#ifdef XRE_HAS_DLL_BLOCKLIST
|
||||
XRE_SetupDllBlocklist();
|
||||
#endif
|
||||
|
||||
int result = do_main(argc, argv, xreDirectory);
|
||||
|
||||
|
||||
@@ -1,17 +1,12 @@
|
||||
[
|
||||
{
|
||||
"clang_version": "r183744"
|
||||
"clang_version": "r241406"
|
||||
},
|
||||
{
|
||||
"size": 47,
|
||||
"digest": "2005a41fe97a5e00997063705f39d42b6a43b1cf7ba306cbc7b1513de34cdcd050fc6326efa2107f19ba0cc67914745dbf13154fa748010a93cf072481ef4aaa",
|
||||
"size": 100307285,
|
||||
"digest": "4d147d0072a928945fc1e938f39a5d0a9d3c676399c09e092c8750b2f973cdbbebda8d94d4d05805fae74a5c49c54263dc22b8b443c23c9a0ae830a261d3cf30",
|
||||
"algorithm": "sha512",
|
||||
"filename": "setup.sh"
|
||||
},
|
||||
{
|
||||
"size": 70206124,
|
||||
"digest": "a6b8046bd9485f9387dcb1c14b8d442822f02b1caa61b653e8b6cfd96906deadfb4b29809f2cd2b71f919b321d97dd2ebec6020c15f6d485f1641c0f710a762f",
|
||||
"algorithm": "sha512",
|
||||
"filename": "clang.tar.bz2"
|
||||
"filename": "clang.tar.bz2",
|
||||
"unpack": true,
|
||||
}
|
||||
]
|
||||
|
||||
@@ -1,20 +1,16 @@
|
||||
[
|
||||
{
|
||||
"size": 82,
|
||||
"digest": "70a6126249e40aa1da32248bf6bfe45e0d8c87334579ec0cf69403e61b635e27c766d9bf08d530978286552f158ee24c74b0168a57cc6b734dcfed4fc5e09cff",
|
||||
"algorithm": "sha512",
|
||||
"filename": "setup.sh"
|
||||
},
|
||||
{
|
||||
"size": 80458572,
|
||||
"digest": "e5101f9dee1e462f6cbd3897ea57eede41d23981825c7b20d91d23ab461875d54d3dfc24999aa58a31e8b01f49fb3140e05ffe5af2957ef1d1afb89fd0dfe1ad",
|
||||
"algorithm": "sha512",
|
||||
"filename": "gcc.tar.xz"
|
||||
"filename": "gcc.tar.xz",
|
||||
"unpack": true
|
||||
},
|
||||
{
|
||||
"size": 167175,
|
||||
"digest": "0b71a936edf5bd70cf274aaa5d7abc8f77fe8e7b5593a208f805cc9436fac646b9c4f0b43c2b10de63ff3da671497d35536077ecbc72dba7f8159a38b580f831",
|
||||
"algorithm": "sha512",
|
||||
"filename": "sccache.tar.bz2"
|
||||
"filename": "sccache.tar.bz2",
|
||||
"unpack": true
|
||||
}
|
||||
]
|
||||
|
||||
@@ -1,17 +1,12 @@
|
||||
[
|
||||
{
|
||||
"clang_version": "r183744"
|
||||
"clang_version": "r241406"
|
||||
},
|
||||
{
|
||||
"size": 47,
|
||||
"digest": "2005a41fe97a5e00997063705f39d42b6a43b1cf7ba306cbc7b1513de34cdcd050fc6326efa2107f19ba0cc67914745dbf13154fa748010a93cf072481ef4aaa",
|
||||
"size": 100307285,
|
||||
"digest": "4d147d0072a928945fc1e938f39a5d0a9d3c676399c09e092c8750b2f973cdbbebda8d94d4d05805fae74a5c49c54263dc22b8b443c23c9a0ae830a261d3cf30",
|
||||
"algorithm": "sha512",
|
||||
"filename": "setup.sh"
|
||||
},
|
||||
{
|
||||
"size": 70350828,
|
||||
"digest": "6cd04e8ec44c6fef159349c22bd0476891e4a2d46479f9586283eaf3305e42f79c720d40dfec0e78d8899c1651189b12e285de60862ffd0612b0dac7a0c336c6",
|
||||
"algorithm": "sha512",
|
||||
"filename": "clang.tar.bz2"
|
||||
"filename": "clang.tar.bz2",
|
||||
"unpack": true
|
||||
}
|
||||
]
|
||||
|
||||
@@ -1,20 +1,16 @@
|
||||
[
|
||||
{
|
||||
"size": 82,
|
||||
"digest": "70a6126249e40aa1da32248bf6bfe45e0d8c87334579ec0cf69403e61b635e27c766d9bf08d530978286552f158ee24c74b0168a57cc6b734dcfed4fc5e09cff",
|
||||
"algorithm": "sha512",
|
||||
"filename": "setup.sh"
|
||||
},
|
||||
{
|
||||
"size": 80458572,
|
||||
"digest": "e5101f9dee1e462f6cbd3897ea57eede41d23981825c7b20d91d23ab461875d54d3dfc24999aa58a31e8b01f49fb3140e05ffe5af2957ef1d1afb89fd0dfe1ad",
|
||||
"algorithm": "sha512",
|
||||
"filename": "gcc.tar.xz"
|
||||
"filename": "gcc.tar.xz",
|
||||
"unpack": true
|
||||
},
|
||||
{
|
||||
"size": 167175,
|
||||
"digest": "0b71a936edf5bd70cf274aaa5d7abc8f77fe8e7b5593a208f805cc9436fac646b9c4f0b43c2b10de63ff3da671497d35536077ecbc72dba7f8159a38b580f831",
|
||||
"algorithm": "sha512",
|
||||
"filename": "sccache.tar.bz2"
|
||||
"filename": "sccache.tar.bz2",
|
||||
"unpack": true
|
||||
}
|
||||
]
|
||||
|
||||
@@ -1,23 +1,19 @@
|
||||
[
|
||||
{
|
||||
"clang_version": "r183744"
|
||||
"clang_version": "r241406"
|
||||
},
|
||||
{
|
||||
"size": 88,
|
||||
"digest": "0d2ae9bcd7cea34ec0b768270725e98410dbb3bc150c7381e0dcf3eb5dbb3e69ac76dbb0f46b056151d6a6fa8681cab06da68173ae8598f3397b8f7628e67381",
|
||||
"algorithm": "sha512",
|
||||
"filename": "setup.sh"
|
||||
},
|
||||
{
|
||||
"size": 59602619,
|
||||
"digest": "86662ebc0ef650490559005948c4f0cb015dad72c7cac43732c2bf2995247081e30c139cf8008d19670a0009fc302c4eee2676981ee3f9ff4a15c01af22b783b",
|
||||
"size": 86465808,
|
||||
"digest": "947eaaf11ac8cbe12e11b48c8b052721e018d31fb8ce20f8bf14b117b6623c56513b1422d8d9c8011bc0b0b985ef74d8f181e7200c6d7a05d79a1bce0d75ddee",
|
||||
"algorithm": "sha512",
|
||||
"filename": "clang.tar.bz2"
|
||||
"filename": "clang.tar.bz2",
|
||||
"unpack": true
|
||||
},
|
||||
{
|
||||
"size": 167175,
|
||||
"digest": "0b71a936edf5bd70cf274aaa5d7abc8f77fe8e7b5593a208f805cc9436fac646b9c4f0b43c2b10de63ff3da671497d35536077ecbc72dba7f8159a38b580f831",
|
||||
"algorithm": "sha512",
|
||||
"filename": "sccache.tar.bz2"
|
||||
"filename": "sccache.tar.bz2",
|
||||
"unpack": true
|
||||
}
|
||||
]
|
||||
|
||||
@@ -3,21 +3,17 @@
|
||||
"clang_version": "r183744"
|
||||
},
|
||||
{
|
||||
"size": 88,
|
||||
"digest": "0d2ae9bcd7cea34ec0b768270725e98410dbb3bc150c7381e0dcf3eb5dbb3e69ac76dbb0f46b056151d6a6fa8681cab06da68173ae8598f3397b8f7628e67381",
|
||||
"algorithm": "sha512",
|
||||
"filename": "setup.sh"
|
||||
},
|
||||
{
|
||||
"size": 59602619,
|
||||
"digest": "86662ebc0ef650490559005948c4f0cb015dad72c7cac43732c2bf2995247081e30c139cf8008d19670a0009fc302c4eee2676981ee3f9ff4a15c01af22b783b",
|
||||
"algorithm": "sha512",
|
||||
"filename": "clang.tar.bz2"
|
||||
"filename": "clang.tar.bz2",
|
||||
"unpack": true
|
||||
},
|
||||
{
|
||||
"size": 167175,
|
||||
"digest": "0b71a936edf5bd70cf274aaa5d7abc8f77fe8e7b5593a208f805cc9436fac646b9c4f0b43c2b10de63ff3da671497d35536077ecbc72dba7f8159a38b580f831",
|
||||
"algorithm": "sha512",
|
||||
"filename": "sccache.tar.bz2"
|
||||
"filename": "sccache.tar.bz2",
|
||||
"unpack": true
|
||||
}
|
||||
]
|
||||
|
||||
@@ -6,15 +6,10 @@
|
||||
"filename": "mozmake.exe"
|
||||
},
|
||||
{
|
||||
"size": 176,
|
||||
"digest": "2809058907ac5eefdc394113d2e4fe76ba559ac61c2eca2f88e7a12a74bdf44a15d9039fa8aa229f7362a14b67d67395063f68147ae098beac5dfcc78aff98da",
|
||||
"algorithm": "sha512",
|
||||
"filename": "setup.sh"
|
||||
},
|
||||
{
|
||||
"size": 167175,
|
||||
"digest": "0b71a936edf5bd70cf274aaa5d7abc8f77fe8e7b5593a208f805cc9436fac646b9c4f0b43c2b10de63ff3da671497d35536077ecbc72dba7f8159a38b580f831",
|
||||
"algorithm": "sha512",
|
||||
"filename": "sccache.tar.bz2"
|
||||
"filename": "sccache.tar.bz2",
|
||||
"unpack": true
|
||||
}
|
||||
]
|
||||
|
||||
@@ -6,15 +6,10 @@
|
||||
"filename": "mozmake.exe"
|
||||
},
|
||||
{
|
||||
"size": 176,
|
||||
"digest": "2809058907ac5eefdc394113d2e4fe76ba559ac61c2eca2f88e7a12a74bdf44a15d9039fa8aa229f7362a14b67d67395063f68147ae098beac5dfcc78aff98da",
|
||||
"algorithm": "sha512",
|
||||
"filename": "setup.sh"
|
||||
},
|
||||
{
|
||||
"size": 167175,
|
||||
"digest": "0b71a936edf5bd70cf274aaa5d7abc8f77fe8e7b5593a208f805cc9436fac646b9c4f0b43c2b10de63ff3da671497d35536077ecbc72dba7f8159a38b580f831",
|
||||
"algorithm": "sha512",
|
||||
"filename": "sccache.tar.bz2"
|
||||
"filename": "sccache.tar.bz2",
|
||||
"unpack": true
|
||||
}
|
||||
]
|
||||
|
||||
+18
-13
@@ -1497,9 +1497,12 @@ if test "$GNU_CC"; then
|
||||
|
||||
# Turn off the following warnings that -Wall turns on:
|
||||
# -Wno-unused - lots of violations in third-party code
|
||||
# -Wno-unused-local-typedef - catches unused typedefs, which are commonly used in assertion macros
|
||||
#
|
||||
_WARNINGS_CFLAGS="${_WARNINGS_CFLAGS} -Wno-unused"
|
||||
|
||||
MOZ_CXX_SUPPORTS_WARNING(-Wno-, unused-local-typedef, ac_cxx_has_wno_unused_local_typedef)
|
||||
|
||||
if test -z "$INTEL_CC" -a -z "$CLANG_CC"; then
|
||||
# Don't use -Wcast-align with ICC or clang
|
||||
case "$CPU_ARCH" in
|
||||
@@ -1556,6 +1559,7 @@ if test "$GNU_CXX"; then
|
||||
# -Woverloaded-virtual - function declaration hides virtual function from base class
|
||||
# -Wparentheses - catches `if (a=b)` and operator precedence bugs
|
||||
# -Wpointer-arith - catches pointer arithmetic using NULL or sizeof(void)
|
||||
# -Wrange-loop-analysis - catches copies during range-based for loops.
|
||||
# -Wreturn-type - catches missing returns, zero false positives
|
||||
# -Wsequence-point - catches undefined order behavior like `a = a++`
|
||||
# -Wsign-compare - catches comparison of signed and unsigned types
|
||||
@@ -1587,18 +1591,21 @@ if test "$GNU_CXX"; then
|
||||
_WARNINGS_CXXFLAGS="${_WARNINGS_CXXFLAGS} -Werror=unused-label"
|
||||
|
||||
MOZ_CXX_SUPPORTS_WARNING(-Werror=, non-literal-null-conversion, ac_cxx_has_werror_non_literal_null_conversion)
|
||||
MOZ_CXX_SUPPORTS_WARNING(-Werror=, range-loop-analysis, ac_cxx_has_range_loop_analysis)
|
||||
MOZ_CXX_SUPPORTS_WARNING(-Werror=, sometimes-uninitialized, ac_cxx_has_sometimes_uninitialized)
|
||||
fi
|
||||
|
||||
# Turn off the following warnings that -Wall turns on:
|
||||
# -Wno-invalid-offsetof - we use offsetof on non-POD types frequently
|
||||
# -Wno-inline-new-delete - we inline 'new' and 'delete' in mozalloc
|
||||
# -Wno-unused-local-typedef - catches unused typedefs, which are commonly used in assertion macros
|
||||
# for performance reasons, and because GCC and clang accept it (though
|
||||
# clang warns about it).
|
||||
#
|
||||
_WARNINGS_CXXFLAGS="${_WARNINGS_CXXFLAGS} -Wno-invalid-offsetof"
|
||||
|
||||
MOZ_CXX_SUPPORTS_WARNING(-Wno-, inline-new-delete, ac_cxx_has_wno_inline_new_delete)
|
||||
MOZ_CXX_SUPPORTS_WARNING(-Wno-, unused-local-typedef, ac_cxx_has_wno_unused_local_typedef)
|
||||
|
||||
if test -z "$INTEL_CXX" -a -z "$CLANG_CXX"; then
|
||||
# Don't use -Wcast-align with ICC or clang
|
||||
@@ -1750,18 +1757,6 @@ if test -n "$MOZ_JPROF"; then
|
||||
AC_DEFINE(MOZ_JPROF)
|
||||
fi
|
||||
|
||||
dnl ========================================================
|
||||
dnl shark
|
||||
dnl ========================================================
|
||||
MOZ_ARG_ENABLE_BOOL(shark,
|
||||
[ --enable-shark Enable shark remote profiling. Implies --enable-profiling.],
|
||||
MOZ_SHARK=1,
|
||||
MOZ_SHARK= )
|
||||
if test -n "$MOZ_SHARK"; then
|
||||
MOZ_PROFILING=1
|
||||
AC_DEFINE(MOZ_SHARK)
|
||||
fi
|
||||
|
||||
dnl ========================================================
|
||||
dnl instruments
|
||||
dnl ========================================================
|
||||
@@ -2249,6 +2244,7 @@ ia64*-hpux*)
|
||||
dnl Probably also a compiler bug, but what can you do?
|
||||
PROFILE_USE_LDFLAGS="-LTCG:PGUPDATE"
|
||||
LDFLAGS="$LDFLAGS -DYNAMICBASE"
|
||||
RCFLAGS="-nologo"
|
||||
if test "$_CC_MAJOR_VERSION" = "18" -a "$_CC_BUILD_VERSION" = "31101"; then
|
||||
dnl Use MaxILKSize as a workaround for LNK1248 in VS2013update4
|
||||
dnl See https://connect.microsoft.com/VisualStudio/feedback/details/1044914/fatal-error-lnk1248
|
||||
@@ -5257,6 +5253,13 @@ if test -n "$MOZ_VPX"; then
|
||||
|
||||
AC_CHECK_LIB(vpx, vpx_codec_dec_init_ver, [],
|
||||
[AC_MSG_ERROR([--with-system-libvpx requested but symbol vpx_codec_dec_init_ver not found])])
|
||||
|
||||
MOZ_CHECK_HEADER([vpx_mem/vpx_mem.h],
|
||||
[AC_CHECK_FUNC(vpx_mem_set_functions)])
|
||||
if test "$ac_cv_header_vpx_mem_vpx_mem_h" = no -o \
|
||||
"$ac_cv_func_vpx_mem_set_functions" = no; then
|
||||
AC_DEFINE(MOZ_VPX_NO_MEM_REPORTING)
|
||||
fi
|
||||
fi
|
||||
CFLAGS=$_SAVE_CFLAGS
|
||||
LIBS=$_SAVE_LIBS
|
||||
@@ -5358,6 +5361,9 @@ if test -n "$MOZ_VPX" -a -z "$MOZ_NATIVE_LIBVPX"; then
|
||||
else
|
||||
AC_MSG_WARN([No assembler or assembly support for libvpx. Using unoptimized C routines.])
|
||||
fi
|
||||
|
||||
dnl native libvpx no longer has vpx_mem_set_functions
|
||||
AC_DEFINE(MOZ_VPX_NO_MEM_REPORTING)
|
||||
fi
|
||||
|
||||
dnl ========================================================
|
||||
@@ -8072,7 +8078,6 @@ AC_SUBST(MOZ_DEBUG_LDFLAGS)
|
||||
AC_SUBST(WARNINGS_AS_ERRORS)
|
||||
AC_SUBST(MOZ_EXTENSIONS)
|
||||
AC_SUBST(MOZ_JPROF)
|
||||
AC_SUBST(MOZ_SHARK)
|
||||
AC_SUBST(MOZ_INSTRUMENTS)
|
||||
AC_SUBST(MOZ_CALLGRIND)
|
||||
AC_SUBST(MOZ_VTUNE)
|
||||
|
||||
@@ -211,8 +211,8 @@ NS_GetContentList(nsINode* aRootNode,
|
||||
{
|
||||
ContentListHashtableHashKey,
|
||||
ContentListHashtableMatchEntry,
|
||||
PL_DHashMoveEntryStub,
|
||||
PL_DHashClearEntryStub
|
||||
PLDHashTable::MoveEntryStub,
|
||||
PLDHashTable::ClearEntryStub
|
||||
};
|
||||
|
||||
// Initialize the hashtable if needed.
|
||||
@@ -314,8 +314,8 @@ GetFuncStringContentList(nsINode* aRootNode,
|
||||
{
|
||||
FuncStringContentListHashtableHashKey,
|
||||
FuncStringContentListHashtableMatchEntry,
|
||||
PL_DHashMoveEntryStub,
|
||||
PL_DHashClearEntryStub
|
||||
PLDHashTable::MoveEntryStub,
|
||||
PLDHashTable::ClearEntryStub
|
||||
};
|
||||
|
||||
// Initialize the hashtable if needed.
|
||||
|
||||
@@ -502,9 +502,9 @@ nsContentUtils::Init()
|
||||
if (!sEventListenerManagersHash) {
|
||||
static const PLDHashTableOps hash_table_ops =
|
||||
{
|
||||
PL_DHashVoidPtrKeyStub,
|
||||
PL_DHashMatchEntryStub,
|
||||
PL_DHashMoveEntryStub,
|
||||
PLDHashTable::HashVoidPtrKeyStub,
|
||||
PLDHashTable::MatchEntryStub,
|
||||
PLDHashTable::MoveEntryStub,
|
||||
EventListenerManagerHashClearEntry,
|
||||
EventListenerManagerHashInitEntry
|
||||
};
|
||||
|
||||
@@ -3990,9 +3990,9 @@ nsDocument::SetSubDocumentFor(Element* aElement, nsIDocument* aSubDoc)
|
||||
|
||||
static const PLDHashTableOps hash_table_ops =
|
||||
{
|
||||
PL_DHashVoidPtrKeyStub,
|
||||
PL_DHashMatchEntryStub,
|
||||
PL_DHashMoveEntryStub,
|
||||
PLDHashTable::HashVoidPtrKeyStub,
|
||||
PLDHashTable::MatchEntryStub,
|
||||
PLDHashTable::MoveEntryStub,
|
||||
SubDocClearEntry,
|
||||
SubDocInitEntry
|
||||
};
|
||||
|
||||
@@ -265,7 +265,7 @@ nsPropertyTable::PropertyList::PropertyList(nsIAtom *aName,
|
||||
void *aDtorData,
|
||||
bool aTransfer)
|
||||
: mName(aName),
|
||||
mObjectValueMap(PL_DHashGetStubOps(), sizeof(PropertyListMapEntry)),
|
||||
mObjectValueMap(PLDHashTable::StubOps(), sizeof(PropertyListMapEntry)),
|
||||
mDtorFunc(aDtorFunc),
|
||||
mDtorData(aDtorData),
|
||||
mTransfer(aTransfer),
|
||||
|
||||
@@ -106,7 +106,7 @@ static const PLDHashTableOps hash_table_ops =
|
||||
{
|
||||
GlobalNameHashHashKey,
|
||||
GlobalNameHashMatchEntry,
|
||||
PL_DHashMoveEntryStub,
|
||||
PLDHashTable::MoveEntryStub,
|
||||
GlobalNameHashClearEntry,
|
||||
GlobalNameHashInitEntry
|
||||
};
|
||||
|
||||
@@ -405,7 +405,7 @@ CreateNPObjWrapperTable()
|
||||
}
|
||||
|
||||
sNPObjWrappers =
|
||||
new PLDHashTable(PL_DHashGetStubOps(), sizeof(NPObjWrapperHashEntry));
|
||||
new PLDHashTable(PLDHashTable::StubOps(), sizeof(NPObjWrapperHashEntry));
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
@@ -757,9 +757,9 @@ XULDocument::AddBroadcastListenerFor(Element& aBroadcaster, Element& aListener,
|
||||
}
|
||||
|
||||
static const PLDHashTableOps gOps = {
|
||||
PL_DHashVoidPtrKeyStub,
|
||||
PL_DHashMatchEntryStub,
|
||||
PL_DHashMoveEntryStub,
|
||||
PLDHashTable::HashVoidPtrKeyStub,
|
||||
PLDHashTable::MatchEntryStub,
|
||||
PLDHashTable::MoveEntryStub,
|
||||
ClearBroadcasterMapEntry,
|
||||
nullptr
|
||||
};
|
||||
|
||||
@@ -21,7 +21,7 @@
|
||||
*/
|
||||
class nsContentSupportMap {
|
||||
public:
|
||||
nsContentSupportMap() : mMap(PL_DHashGetStubOps(), sizeof(Entry)) { }
|
||||
nsContentSupportMap() : mMap(PLDHashTable::StubOps(), sizeof(Entry)) { }
|
||||
~nsContentSupportMap() { }
|
||||
|
||||
nsresult Put(nsIContent* aElement, nsTemplateMatch* aMatch) {
|
||||
|
||||
@@ -19,7 +19,7 @@ protected:
|
||||
PLDHashTable mTable;
|
||||
|
||||
public:
|
||||
nsTemplateMap() : mTable(PL_DHashGetStubOps(), sizeof(Entry)) { }
|
||||
nsTemplateMap() : mTable(PLDHashTable::StubOps(), sizeof(Entry)) { }
|
||||
|
||||
~nsTemplateMap() { }
|
||||
|
||||
|
||||
@@ -630,7 +630,7 @@ public:
|
||||
StringHash,
|
||||
HashMatchEntry,
|
||||
MoveEntry,
|
||||
PL_DHashClearEntryStub,
|
||||
PLDHashTable::ClearEntryStub,
|
||||
nullptr
|
||||
};
|
||||
|
||||
|
||||
@@ -145,11 +145,7 @@ GeckoChildProcessHost::GetPathToBinary(FilePath& exePath)
|
||||
NS_NewLocalFile(nsDependentString(gGREBinPath), false,
|
||||
getter_AddRefs(childProcPath));
|
||||
// We need to use an App Bundle on OS X so that we can hide
|
||||
// the dock icon. See Bug 557225.
|
||||
nsCOMPtr<nsIFile> tempPath;
|
||||
childProcPath->GetParent(getter_AddRefs(tempPath));
|
||||
childProcPath = tempPath.forget();
|
||||
childProcPath->AppendNative(NS_LITERAL_CSTRING("MacOS"));
|
||||
// the dock icon. See Bug 557225.
|
||||
childProcPath->AppendNative(NS_LITERAL_CSTRING("plugin-container.app"));
|
||||
childProcPath->AppendNative(NS_LITERAL_CSTRING("Contents"));
|
||||
childProcPath->AppendNative(NS_LITERAL_CSTRING("MacOS"));
|
||||
|
||||
@@ -18,9 +18,6 @@
|
||||
#ifdef MOZ_INSTRUMENTS
|
||||
# include "devtools/Instruments.h"
|
||||
#endif
|
||||
#ifdef MOZ_SHARK
|
||||
# include "devtools/sharkctl.h"
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifdef XP_WIN
|
||||
@@ -68,10 +65,6 @@ StartOSXProfiling(const char* profileName, pid_t pid)
|
||||
{
|
||||
bool ok = true;
|
||||
const char* profiler = nullptr;
|
||||
#ifdef MOZ_SHARK
|
||||
ok = Shark::Start();
|
||||
profiler = "Shark";
|
||||
#endif
|
||||
#ifdef MOZ_INSTRUMENTS
|
||||
ok = Instruments::Start(pid);
|
||||
profiler = "Instruments";
|
||||
@@ -106,9 +99,6 @@ JS_StopProfiling(const char* profileName)
|
||||
{
|
||||
bool ok = true;
|
||||
#ifdef __APPLE__
|
||||
#ifdef MOZ_SHARK
|
||||
Shark::Stop();
|
||||
#endif
|
||||
#ifdef MOZ_INSTRUMENTS
|
||||
Instruments::Stop(profileName);
|
||||
#endif
|
||||
@@ -131,12 +121,8 @@ ControlProfilers(bool toState)
|
||||
|
||||
if (! probes::ProfilingActive && toState) {
|
||||
#ifdef __APPLE__
|
||||
#if defined(MOZ_SHARK) || defined(MOZ_INSTRUMENTS)
|
||||
#if defined(MOZ_INSTRUMENTS)
|
||||
const char* profiler;
|
||||
#ifdef MOZ_SHARK
|
||||
ok = Shark::Start();
|
||||
profiler = "Shark";
|
||||
#endif
|
||||
#ifdef MOZ_INSTRUMENTS
|
||||
ok = Instruments::Resume();
|
||||
profiler = "Instruments";
|
||||
@@ -154,9 +140,6 @@ ControlProfilers(bool toState)
|
||||
#endif
|
||||
} else if (probes::ProfilingActive && ! toState) {
|
||||
#ifdef __APPLE__
|
||||
#ifdef MOZ_SHARK
|
||||
Shark::Stop();
|
||||
#endif
|
||||
#ifdef MOZ_INSTRUMENTS
|
||||
Instruments::Pause();
|
||||
#endif
|
||||
@@ -347,7 +330,7 @@ ClearMaxGCPauseAccumulator(JSContext* cx, unsigned argc, Value* vp)
|
||||
return true;
|
||||
}
|
||||
|
||||
#if defined(MOZ_SHARK) || defined(MOZ_INSTRUMENTS)
|
||||
#if defined(MOZ_INSTRUMENTS)
|
||||
|
||||
static bool
|
||||
IgnoreAndReturnTrue(JSContext* cx, unsigned argc, Value* vp)
|
||||
@@ -402,7 +385,7 @@ static const JSFunctionSpec profiling_functions[] = {
|
||||
JS_FN("dumpProfile", DumpProfile, 2,0),
|
||||
JS_FN("getMaxGCPauseSinceClear", GetMaxGCPauseSinceClear, 0, 0),
|
||||
JS_FN("clearMaxGCPauseAccumulator", ClearMaxGCPauseAccumulator, 0, 0),
|
||||
#if defined(MOZ_SHARK) || defined(MOZ_INSTRUMENTS)
|
||||
#if defined(MOZ_INSTRUMENTS)
|
||||
/* Keep users of the old shark API happy. */
|
||||
JS_FN("connectShark", IgnoreAndReturnTrue, 0,0),
|
||||
JS_FN("disconnectShark", IgnoreAndReturnTrue, 0,0),
|
||||
|
||||
+8
-13
@@ -1258,10 +1258,12 @@ if test "$GNU_CC"; then
|
||||
# Turn off the following warnings that -Wall turns on:
|
||||
# -Wno-unused - lots of violations in third-party code
|
||||
# -Wno-inline-new-delete - we inline 'new' and 'delete' in mozalloc
|
||||
# -Wno-unused-local-typedef - catches unused typedefs, which are commonly used in assertion macros
|
||||
#
|
||||
_WARNINGS_CFLAGS="${_WARNINGS_CFLAGS} -Wno-unused"
|
||||
|
||||
MOZ_CXX_SUPPORTS_WARNING(-Wno-, inline-new-delete, ac_cxx_has_wno_inline_new_delete)
|
||||
MOZ_CXX_SUPPORTS_WARNING(-Wno-, unused-local-typedef, ac_cxx_has_wno_unused_local_typedef)
|
||||
|
||||
if test -z "$INTEL_CC" -a -z "$CLANG_CC"; then
|
||||
# Don't use -Wcast-align with ICC or clang
|
||||
@@ -1320,6 +1322,7 @@ if test "$GNU_CXX"; then
|
||||
# -Wparentheses - catches `if (a=b)` and operator precedence bugs
|
||||
# -Wpointer-arith - catches pointer arithmetic using NULL or sizeof(void)
|
||||
# -Wpointer-to-int-cast - catches casts from pointer to different sized int
|
||||
# -Wrange-loop-analysis - catches copies during range-based for loops.
|
||||
# -Wreorder - catches ctor initializer list not matching class definition order
|
||||
# -Wreturn-type - catches missing returns, zero false positives
|
||||
# -Wsequence-point - catches undefined order behavior like `a = a++`
|
||||
@@ -1360,14 +1363,18 @@ if test "$GNU_CXX"; then
|
||||
|
||||
MOZ_CXX_SUPPORTS_WARNING(-Werror=, conversion-null, ac_cxx_has_werror_conversion_null)
|
||||
MOZ_CXX_SUPPORTS_WARNING(-Werror=, non-literal-null-conversion, ac_cxx_has_werror_non_literal_null_conversion)
|
||||
MOZ_CXX_SUPPORTS_WARNING(-Werror=, range-loop-analysis, ac_cxx_has_range_loop_analysis)
|
||||
MOZ_CXX_SUPPORTS_WARNING(-Werror=, sometimes-uninitialized, ac_cxx_has_sometimes_uninitialized)
|
||||
fi
|
||||
|
||||
# Turn off the following warnings that -Wall turns on:
|
||||
# -Wno-invalid-offsetof - we use offsetof on non-POD types frequently
|
||||
# -Wno-unused-local-typedef - catches unused typedefs, which are commonly used in assertion macros
|
||||
#
|
||||
_WARNINGS_CXXFLAGS="${_WARNINGS_CXXFLAGS} -Wno-invalid-offsetof"
|
||||
|
||||
MOZ_CXX_SUPPORTS_WARNING(-Wno-, unused-local-typedef, ac_cxx_has_wno_unused_local_typedef)
|
||||
|
||||
if test -z "$INTEL_CXX" -a -z "$CLANG_CXX"; then
|
||||
# Don't use -Wcast-align with ICC or clang
|
||||
case "$CPU_ARCH" in
|
||||
@@ -1838,6 +1845,7 @@ ia64*-hpux*)
|
||||
dnl Probably also a compiler bug, but what can you do?
|
||||
PROFILE_USE_LDFLAGS="-LTCG:PGUPDATE"
|
||||
LDFLAGS="$LDFLAGS -DYNAMICBASE"
|
||||
RCFLAGS="-nologo"
|
||||
fi
|
||||
AC_DEFINE(HAVE_SNPRINTF)
|
||||
AC_DEFINE(HAVE__MSIZE)
|
||||
@@ -3211,18 +3219,6 @@ if test -n "$MOZ_JPROF"; then
|
||||
AC_DEFINE(MOZ_JPROF)
|
||||
fi
|
||||
|
||||
dnl ========================================================
|
||||
dnl shark
|
||||
dnl ========================================================
|
||||
MOZ_ARG_ENABLE_BOOL(shark,
|
||||
[ --enable-shark Enable shark remote profiling. Implies --enable-profiling.],
|
||||
MOZ_SHARK=1,
|
||||
MOZ_SHARK= )
|
||||
if test -n "$MOZ_SHARK"; then
|
||||
MOZ_PROFILING=1
|
||||
AC_DEFINE(MOZ_SHARK)
|
||||
fi
|
||||
|
||||
dnl ========================================================
|
||||
dnl instruments
|
||||
dnl ========================================================
|
||||
@@ -3672,7 +3668,6 @@ AC_SUBST(MOZ_DEBUG_DISABLE_DEFS)
|
||||
AC_SUBST(MOZ_DEBUG_LDFLAGS)
|
||||
AC_SUBST(WARNINGS_AS_ERRORS)
|
||||
AC_SUBST(MOZ_JPROF)
|
||||
AC_SUBST(MOZ_SHARK)
|
||||
AC_SUBST(MOZ_INSTRUMENTS)
|
||||
AC_SUBST(MOZ_CALLGRIND)
|
||||
AC_SUBST(MOZ_VTUNE)
|
||||
|
||||
@@ -6,12 +6,7 @@
|
||||
"size": 24657188,
|
||||
"digest": "28258eff929158c04dd7d6839bd3c4aa8963c2d478fe88e55cc98d58d878cc673e3625be5c92fe5b6c45bae38980b9919d9aaa7f32a2d8fee89294e90e2a1e2f",
|
||||
"algorithm": "sha512",
|
||||
"filename": "gcc.tar.xz"
|
||||
},
|
||||
{
|
||||
"size": 40,
|
||||
"digest": "459b332864aece4742cd1a6886e56cf3f202e5c27bb481cfae6145ce3e2e52fb34d1448788c6618e58a26a64e415341895326d293e0d2968e56efc0ae990acd0",
|
||||
"algorithm": "sha512",
|
||||
"filename": "setup.sh.gcc"
|
||||
"filename": "gcc.tar.xz",
|
||||
"unpack": true
|
||||
}
|
||||
]
|
||||
|
||||
@@ -6,12 +6,7 @@
|
||||
"size": 79831648,
|
||||
"digest": "958d0dfb531ac6911187cf57907317144a547b884c79dcb483668f0e468ab9f031492ab49177edebf6a6437680b69f54a346a37b4316da78c0ff87aa39c5f2c3",
|
||||
"algorithm": "sha512",
|
||||
"filename": "gcc.tar.xz"
|
||||
},
|
||||
{
|
||||
"size": 40,
|
||||
"digest": "459b332864aece4742cd1a6886e56cf3f202e5c27bb481cfae6145ce3e2e52fb34d1448788c6618e58a26a64e415341895326d293e0d2968e56efc0ae990acd0",
|
||||
"algorithm": "sha512",
|
||||
"filename": "setup.sh.gcc"
|
||||
"filename": "gcc.tar.xz",
|
||||
"unpack": true
|
||||
}
|
||||
]
|
||||
|
||||
@@ -1,17 +1,13 @@
|
||||
[
|
||||
{
|
||||
"sixgill_version": "0.9.1-177"
|
||||
},
|
||||
{
|
||||
"size": 2281048,
|
||||
"digest": "266cba549d2959a5c2e669c85b9adea4d0008e2e23658b844f94540cf41c55df5503ac5858f252418b01d140a48fb235725f2681fb4cbf172f8b283b2874b96c",
|
||||
"algorithm": "sha512",
|
||||
"filename": "sixgill.tar.xz"
|
||||
},
|
||||
{
|
||||
"size": 48,
|
||||
"digest": "9f4a123b8b037c4313c7065f872e07af38390f352f2498b41779c389fa1a0712e5f588d7b3d9a124875916f5257434da83553b560d7d146192f3f6c8da6f0412",
|
||||
"algorithm": "sha512",
|
||||
"filename": "setup.sh.sixgill"
|
||||
}
|
||||
{
|
||||
"hg_id" : "0b889f399d47+ cleaner/qtip/tip",
|
||||
"sixgill_version" : "0.9.1-177"
|
||||
},
|
||||
{
|
||||
"algorithm" : "sha512",
|
||||
"digest" : "bb7fcbcaf8d160bba92fa66b2e3607f3335d68c8339996c880ea5757c6e611b74ced6c6d5c50d523fc8d688cc922ee6e1628f3fb514af8ebeb9c877ad580e5fd",
|
||||
"filename" : "sixgill.tar.xz",
|
||||
"size" : 2159496,
|
||||
"unpack": true
|
||||
}
|
||||
]
|
||||
|
||||
@@ -1,17 +1,13 @@
|
||||
[
|
||||
{
|
||||
"sixgill_version": "0.9.1-177"
|
||||
},
|
||||
{
|
||||
"size": 2316808,
|
||||
"digest": "e58eece57ef7688db4c999b0069b2e4607b1514f681d636969e40a19633173d3b2636fd9a624b58166c789e99c6ba67bfafbdae1d335ac4df018c9f52503f0e4",
|
||||
"algorithm": "sha512",
|
||||
"filename": "sixgill.tar.xz"
|
||||
},
|
||||
{
|
||||
"size": 48,
|
||||
"digest": "9f4a123b8b037c4313c7065f872e07af38390f352f2498b41779c389fa1a0712e5f588d7b3d9a124875916f5257434da83553b560d7d146192f3f6c8da6f0412",
|
||||
"algorithm": "sha512",
|
||||
"filename": "setup.sh.sixgill"
|
||||
}
|
||||
{
|
||||
"hg_id" : "0b889f399d47+ cleaner/qtip/tip",
|
||||
"sixgill_version" : "0.9.1-177"
|
||||
},
|
||||
{
|
||||
"algorithm" : "sha512",
|
||||
"digest" : "c5c22d19005a1389d8dc04e405f5b99e6b8755908fb52a285ff516213d9f32e1e64d5c402a3ee2e52bceffa7dee71852c9d922ec0003e1642a701a0daadb06d3",
|
||||
"filename" : "sixgill.tar.xz",
|
||||
"size" : 2255520,
|
||||
"unpack": true
|
||||
}
|
||||
]
|
||||
|
||||
@@ -0,0 +1,7 @@
|
||||
|
||||
x = [1e81];
|
||||
x.map(function() {});
|
||||
x.pop();
|
||||
x.push([]);
|
||||
[].map(function() {});
|
||||
eval("[1/0]");
|
||||
@@ -504,7 +504,7 @@ CodeGeneratorMIPS::visitMulI(LMulI* ins)
|
||||
// Result is -0 if lhs or rhs is negative.
|
||||
// In that case result must be double value so bailout
|
||||
Register scratch = SecondScratchReg;
|
||||
masm.ma_or(scratch, ToRegister(lhs), ToRegister(rhs));
|
||||
masm.as_or(scratch, ToRegister(lhs), ToRegister(rhs));
|
||||
bailoutCmp32(Assembler::Signed, scratch, scratch, ins->snapshot());
|
||||
|
||||
masm.bind(&done);
|
||||
@@ -795,19 +795,19 @@ CodeGeneratorMIPS::visitBitOpI(LBitOpI* ins)
|
||||
if (rhs->isConstant())
|
||||
masm.ma_or(ToRegister(dest), ToRegister(lhs), Imm32(ToInt32(rhs)));
|
||||
else
|
||||
masm.ma_or(ToRegister(dest), ToRegister(lhs), ToRegister(rhs));
|
||||
masm.as_or(ToRegister(dest), ToRegister(lhs), ToRegister(rhs));
|
||||
break;
|
||||
case JSOP_BITXOR:
|
||||
if (rhs->isConstant())
|
||||
masm.ma_xor(ToRegister(dest), ToRegister(lhs), Imm32(ToInt32(rhs)));
|
||||
else
|
||||
masm.ma_xor(ToRegister(dest), ToRegister(lhs), ToRegister(rhs));
|
||||
masm.as_xor(ToRegister(dest), ToRegister(lhs), ToRegister(rhs));
|
||||
break;
|
||||
case JSOP_BITAND:
|
||||
if (rhs->isConstant())
|
||||
masm.ma_and(ToRegister(dest), ToRegister(lhs), Imm32(ToInt32(rhs)));
|
||||
else
|
||||
masm.ma_and(ToRegister(dest), ToRegister(lhs), ToRegister(rhs));
|
||||
masm.as_and(ToRegister(dest), ToRegister(lhs), ToRegister(rhs));
|
||||
break;
|
||||
default:
|
||||
MOZ_CRASH("unexpected binary opcode");
|
||||
@@ -1646,7 +1646,7 @@ CodeGeneratorMIPS::visitBitAndAndBranch(LBitAndAndBranch* lir)
|
||||
if (lir->right()->isConstant())
|
||||
masm.ma_and(ScratchRegister, ToRegister(lir->left()), Imm32(ToInt32(lir->right())));
|
||||
else
|
||||
masm.ma_and(ScratchRegister, ToRegister(lir->left()), ToRegister(lir->right()));
|
||||
masm.as_and(ScratchRegister, ToRegister(lir->left()), ToRegister(lir->right()));
|
||||
emitBranch(ScratchRegister, ScratchRegister, Assembler::NonZero, lir->ifTrue(),
|
||||
lir->ifFalse());
|
||||
}
|
||||
|
||||
@@ -25,7 +25,7 @@ MacroAssembler::not32(Register reg)
|
||||
void
|
||||
MacroAssembler::and32(Register src, Register dest)
|
||||
{
|
||||
ma_and(dest, dest, src);
|
||||
as_and(dest, dest, src);
|
||||
}
|
||||
|
||||
void
|
||||
|
||||
@@ -459,12 +459,6 @@ MacroAssemblerMIPS::ma_and(Register rd, Register rs)
|
||||
as_and(rd, rd, rs);
|
||||
}
|
||||
|
||||
void
|
||||
MacroAssemblerMIPS::ma_and(Register rd, Register rs, Register rt)
|
||||
{
|
||||
as_and(rd, rs, rt);
|
||||
}
|
||||
|
||||
void
|
||||
MacroAssemblerMIPS::ma_and(Register rd, Imm32 imm)
|
||||
{
|
||||
@@ -489,12 +483,6 @@ MacroAssemblerMIPS::ma_or(Register rd, Register rs)
|
||||
as_or(rd, rd, rs);
|
||||
}
|
||||
|
||||
void
|
||||
MacroAssemblerMIPS::ma_or(Register rd, Register rs, Register rt)
|
||||
{
|
||||
as_or(rd, rs, rt);
|
||||
}
|
||||
|
||||
void
|
||||
MacroAssemblerMIPS::ma_or(Register rd, Imm32 imm)
|
||||
{
|
||||
@@ -519,12 +507,6 @@ MacroAssemblerMIPS::ma_xor(Register rd, Register rs)
|
||||
as_xor(rd, rd, rs);
|
||||
}
|
||||
|
||||
void
|
||||
MacroAssemblerMIPS::ma_xor(Register rd, Register rs, Register rt)
|
||||
{
|
||||
as_xor(rd, rs, rt);
|
||||
}
|
||||
|
||||
void
|
||||
MacroAssemblerMIPS::ma_xor(Register rd, Imm32 imm)
|
||||
{
|
||||
@@ -556,12 +538,6 @@ MacroAssemblerMIPS::ma_addu(Register rd, Register rs, Imm32 imm)
|
||||
}
|
||||
}
|
||||
|
||||
void
|
||||
MacroAssemblerMIPS::ma_addu(Register rd, Register rs, Register rt)
|
||||
{
|
||||
as_addu(rd, rs, rt);
|
||||
}
|
||||
|
||||
void
|
||||
MacroAssemblerMIPS::ma_addu(Register rd, Register rs)
|
||||
{
|
||||
@@ -615,12 +591,6 @@ MacroAssemblerMIPS::ma_addTestOverflow(Register rd, Register rs, Imm32 imm, Labe
|
||||
}
|
||||
|
||||
// Subtract.
|
||||
void
|
||||
MacroAssemblerMIPS::ma_subu(Register rd, Register rs, Register rt)
|
||||
{
|
||||
as_subu(rd, rs, rt);
|
||||
}
|
||||
|
||||
void
|
||||
MacroAssemblerMIPS::ma_subu(Register rd, Register rs, Imm32 imm)
|
||||
{
|
||||
@@ -644,7 +614,7 @@ MacroAssemblerMIPS::ma_subTestOverflow(Register rd, Register rs, Register rt, La
|
||||
Label goodSubtraction;
|
||||
// Use second scratch. The instructions generated by ma_b don't use the
|
||||
// second scratch register.
|
||||
ma_subu(rd, rs, rt);
|
||||
as_subu(rd, rs, rt);
|
||||
|
||||
as_xor(ScratchRegister, rs, rt); // If same sign, no overflow
|
||||
ma_b(ScratchRegister, Imm32(0), &goodSubtraction, Assembler::GreaterThanOrEqual, ShortJump);
|
||||
@@ -1610,7 +1580,7 @@ MacroAssemblerMIPSCompat::sub32(Imm32 imm, Register dest)
|
||||
void
|
||||
MacroAssemblerMIPSCompat::sub32(Register src, Register dest)
|
||||
{
|
||||
ma_subu(dest, dest, src);
|
||||
as_subu(dest, dest, src);
|
||||
}
|
||||
|
||||
void
|
||||
@@ -1629,7 +1599,7 @@ MacroAssemblerMIPSCompat::addPtr(const Address& src, Register dest)
|
||||
void
|
||||
MacroAssemblerMIPSCompat::subPtr(Register src, Register dest)
|
||||
{
|
||||
ma_subu(dest, dest, src);
|
||||
as_subu(dest, dest, src);
|
||||
}
|
||||
|
||||
void
|
||||
@@ -2643,7 +2613,7 @@ MacroAssemblerMIPSCompat::loadConstantDouble(double dp, FloatRegister dest)
|
||||
void
|
||||
MacroAssemblerMIPSCompat::branchTestInt32Truthy(bool b, const ValueOperand& value, Label* label)
|
||||
{
|
||||
ma_and(ScratchRegister, value.payloadReg(), value.payloadReg());
|
||||
as_and(ScratchRegister, value.payloadReg(), value.payloadReg());
|
||||
ma_b(ScratchRegister, ScratchRegister, label, b ? NonZero : Zero);
|
||||
}
|
||||
|
||||
|
||||
@@ -116,19 +116,16 @@ class MacroAssemblerMIPS : public Assembler
|
||||
|
||||
// and
|
||||
void ma_and(Register rd, Register rs);
|
||||
void ma_and(Register rd, Register rs, Register rt);
|
||||
void ma_and(Register rd, Imm32 imm);
|
||||
void ma_and(Register rd, Register rs, Imm32 imm);
|
||||
|
||||
// or
|
||||
void ma_or(Register rd, Register rs);
|
||||
void ma_or(Register rd, Register rs, Register rt);
|
||||
void ma_or(Register rd, Imm32 imm);
|
||||
void ma_or(Register rd, Register rs, Imm32 imm);
|
||||
|
||||
// xor
|
||||
void ma_xor(Register rd, Register rs);
|
||||
void ma_xor(Register rd, Register rs, Register rt);
|
||||
void ma_xor(Register rd, Imm32 imm);
|
||||
void ma_xor(Register rd, Register rs, Imm32 imm);
|
||||
|
||||
@@ -149,14 +146,12 @@ class MacroAssemblerMIPS : public Assembler
|
||||
// arithmetic based ops
|
||||
// add
|
||||
void ma_addu(Register rd, Register rs, Imm32 imm);
|
||||
void ma_addu(Register rd, Register rs, Register rt);
|
||||
void ma_addu(Register rd, Register rs);
|
||||
void ma_addu(Register rd, Imm32 imm);
|
||||
void ma_addTestOverflow(Register rd, Register rs, Register rt, Label* overflow);
|
||||
void ma_addTestOverflow(Register rd, Register rs, Imm32 imm, Label* overflow);
|
||||
|
||||
// subtract
|
||||
void ma_subu(Register rd, Register rs, Register rt);
|
||||
void ma_subu(Register rd, Register rs, Imm32 imm);
|
||||
void ma_subu(Register rd, Imm32 imm);
|
||||
void ma_subTestOverflow(Register rd, Register rs, Register rt, Label* overflow);
|
||||
|
||||
@@ -97,13 +97,13 @@ ICBinaryArith_Int32::Compiler::generateStubCode(MacroAssembler& masm)
|
||||
break;
|
||||
}
|
||||
case JSOP_BITOR:
|
||||
masm.ma_or(R0.payloadReg() , R0.payloadReg(), R1.payloadReg());
|
||||
masm.as_or(R0.payloadReg() , R0.payloadReg(), R1.payloadReg());
|
||||
break;
|
||||
case JSOP_BITXOR:
|
||||
masm.ma_xor(R0.payloadReg() , R0.payloadReg(), R1.payloadReg());
|
||||
masm.as_xor(R0.payloadReg() , R0.payloadReg(), R1.payloadReg());
|
||||
break;
|
||||
case JSOP_BITAND:
|
||||
masm.ma_and(R0.payloadReg() , R0.payloadReg(), R1.payloadReg());
|
||||
masm.as_and(R0.payloadReg() , R0.payloadReg(), R1.payloadReg());
|
||||
break;
|
||||
case JSOP_LSH:
|
||||
// MIPS will only use 5 lowest bits in R1 as shift offset.
|
||||
|
||||
@@ -162,6 +162,17 @@ JitRuntime::generateEnterJIT(JSContext* cx, EnterJitType type)
|
||||
Loop over argv vector, push arguments onto stack in reverse order
|
||||
***************************************************************/
|
||||
|
||||
// if we are constructing, that also needs to include newTarget
|
||||
{
|
||||
Label noNewTarget;
|
||||
masm.branchTest32(Assembler::Zero, s2, Imm32(CalleeToken_FunctionConstructing),
|
||||
&noNewTarget);
|
||||
|
||||
masm.add32(Imm32(1), reg_argc);
|
||||
|
||||
masm.bind(&noNewTarget);
|
||||
}
|
||||
|
||||
masm.as_sll(s0, reg_argc, 3); // s0 = argc * 8
|
||||
masm.addPtr(reg_argv, s0); // s0 = argv + argc * 8
|
||||
|
||||
@@ -314,7 +325,7 @@ JitRuntime::generateEnterJIT(JSContext* cx, EnterJitType type)
|
||||
// Pop arguments off the stack.
|
||||
// s0 <- 8*argc (size of all arguments we pushed on the stack)
|
||||
masm.pop(s0);
|
||||
masm.rshiftPtr(Imm32(4), s0);
|
||||
masm.rshiftPtr(Imm32(FRAMESIZE_SHIFT), s0);
|
||||
masm.addPtr(s0, StackPointer);
|
||||
|
||||
// Store the returned value into the slotVp
|
||||
@@ -430,13 +441,35 @@ JitRuntime::generateArgumentsRectifier(JSContext* cx, void** returnAddrOut)
|
||||
masm.andPtr(Imm32(CalleeTokenMask), numArgsReg);
|
||||
masm.load16ZeroExtend(Address(numArgsReg, JSFunction::offsetOfNargs()), numArgsReg);
|
||||
|
||||
masm.ma_subu(t1, numArgsReg, s3);
|
||||
masm.as_subu(t1, numArgsReg, s3);
|
||||
|
||||
masm.moveValue(UndefinedValue(), ValueOperand(t3, t4));
|
||||
// Get the topmost argument.
|
||||
masm.ma_sll(t0, s3, Imm32(3)); // t0 <- nargs * 8
|
||||
masm.as_addu(t2, sp, t0); // t2 <- sp + nargs * 8
|
||||
masm.addPtr(Imm32(sizeof(RectifierFrameLayout)), t2);
|
||||
|
||||
masm.movePtr(StackPointer, t2); // Save %sp.
|
||||
{
|
||||
Label notConstructing;
|
||||
|
||||
masm.branchTest32(Assembler::Zero, calleeTokenReg, Imm32(CalleeToken_FunctionConstructing),
|
||||
¬Constructing);
|
||||
|
||||
// Add sizeof(Value) to overcome |this|
|
||||
masm.subPtr(Imm32(sizeof(Value)), StackPointer);
|
||||
masm.load32(Address(t2, NUNBOX32_TYPE_OFFSET + sizeof(Value)), t0);
|
||||
masm.store32(t0, Address(StackPointer, NUNBOX32_TYPE_OFFSET));
|
||||
masm.load32(Address(t2, NUNBOX32_PAYLOAD_OFFSET + sizeof(Value)), t0);
|
||||
masm.store32(t0, Address(StackPointer, NUNBOX32_PAYLOAD_OFFSET));
|
||||
|
||||
// Include the newly pushed newTarget value in the frame size
|
||||
// calculated below.
|
||||
masm.add32(Imm32(1), numArgsReg);
|
||||
|
||||
masm.bind(¬Constructing);
|
||||
}
|
||||
|
||||
// Push undefined.
|
||||
masm.moveValue(UndefinedValue(), ValueOperand(t3, t4));
|
||||
{
|
||||
Label undefLoopTop;
|
||||
masm.bind(&undefLoopTop);
|
||||
@@ -448,11 +481,6 @@ JitRuntime::generateArgumentsRectifier(JSContext* cx, void** returnAddrOut)
|
||||
masm.ma_b(t1, t1, &undefLoopTop, Assembler::NonZero, ShortJump);
|
||||
}
|
||||
|
||||
// Get the topmost argument.
|
||||
masm.ma_sll(t0, s3, Imm32(3)); // t0 <- nargs * 8
|
||||
masm.addPtr(t0, t2); // t2 <- t2(saved sp) + nargs * 8
|
||||
masm.addPtr(Imm32(sizeof(RectifierFrameLayout)), t2);
|
||||
|
||||
// Push arguments, |nargs| + 1 times (to include |this|).
|
||||
{
|
||||
Label copyLoopTop, initialSkip;
|
||||
@@ -1118,7 +1146,7 @@ JitRuntime::generateProfilerExitFrameTailStub(JSContext* cx)
|
||||
// Going into the conditionals, we will have:
|
||||
// FrameDescriptor.size in scratch1
|
||||
// FrameDescriptor.type in scratch2
|
||||
masm.ma_and(scratch2, scratch1, Imm32((1 << FRAMESIZE_SHIFT) - 1));
|
||||
masm.ma_and(scratch2, scratch1, Imm32((1 << FRAMETYPE_BITS) - 1));
|
||||
masm.rshiftPtr(Imm32(FRAMESIZE_SHIFT), scratch1);
|
||||
|
||||
// Handling of each case is dependent on FrameDescriptor.type
|
||||
@@ -1163,7 +1191,7 @@ JitRuntime::generateProfilerExitFrameTailStub(JSContext* cx)
|
||||
|
||||
// Store return frame in lastProfilingFrame.
|
||||
// scratch2 := StackPointer + Descriptor.size*1 + JitFrameLayout::Size();
|
||||
masm.ma_addu(scratch2, StackPointer, scratch1);
|
||||
masm.as_addu(scratch2, StackPointer, scratch1);
|
||||
masm.ma_addu(scratch2, scratch2, Imm32(JitFrameLayout::Size()));
|
||||
masm.storePtr(scratch2, lastProfilingFrame);
|
||||
masm.ret();
|
||||
@@ -1197,7 +1225,7 @@ JitRuntime::generateProfilerExitFrameTailStub(JSContext* cx)
|
||||
//
|
||||
masm.bind(&handle_BaselineStub);
|
||||
{
|
||||
masm.ma_addu(scratch3, StackPointer, scratch1);
|
||||
masm.as_addu(scratch3, StackPointer, scratch1);
|
||||
Address stubFrameReturnAddr(scratch3,
|
||||
JitFrameLayout::Size() +
|
||||
BaselineStubFrameLayout::offsetOfReturnAddress());
|
||||
@@ -1254,7 +1282,7 @@ JitRuntime::generateProfilerExitFrameTailStub(JSContext* cx)
|
||||
masm.bind(&handle_Rectifier);
|
||||
{
|
||||
// scratch2 := StackPointer + Descriptor.size*1 + JitFrameLayout::Size();
|
||||
masm.ma_addu(scratch2, StackPointer, scratch1);
|
||||
masm.as_addu(scratch2, StackPointer, scratch1);
|
||||
masm.add32(Imm32(JitFrameLayout::Size()), scratch2);
|
||||
masm.loadPtr(Address(scratch2, RectifierFrameLayout::offsetOfDescriptor()), scratch3);
|
||||
masm.ma_srl(scratch1, scratch3, Imm32(FRAMESIZE_SHIFT));
|
||||
@@ -1275,7 +1303,7 @@ JitRuntime::generateProfilerExitFrameTailStub(JSContext* cx)
|
||||
masm.storePtr(scratch3, lastProfilingCallSite);
|
||||
|
||||
// scratch3 := RectFrame + Rect-Descriptor.Size + RectifierFrameLayout::Size()
|
||||
masm.ma_addu(scratch3, scratch2, scratch1);
|
||||
masm.as_addu(scratch3, scratch2, scratch1);
|
||||
masm.add32(Imm32(RectifierFrameLayout::Size()), scratch3);
|
||||
masm.storePtr(scratch3, lastProfilingFrame);
|
||||
masm.ret();
|
||||
@@ -1290,7 +1318,7 @@ JitRuntime::generateProfilerExitFrameTailStub(JSContext* cx)
|
||||
masm.bind(&checkOk);
|
||||
}
|
||||
#endif
|
||||
masm.ma_addu(scratch3, scratch2, scratch1);
|
||||
masm.as_addu(scratch3, scratch2, scratch1);
|
||||
Address stubFrameReturnAddr(scratch3, RectifierFrameLayout::Size() +
|
||||
BaselineStubFrameLayout::offsetOfReturnAddress());
|
||||
masm.loadPtr(stubFrameReturnAddr, scratch2);
|
||||
@@ -1322,7 +1350,7 @@ JitRuntime::generateProfilerExitFrameTailStub(JSContext* cx)
|
||||
masm.bind(&handle_IonAccessorIC);
|
||||
{
|
||||
// scratch2 := StackPointer + Descriptor.size + JitFrameLayout::Size()
|
||||
masm.ma_addu(scratch2, StackPointer, scratch1);
|
||||
masm.as_addu(scratch2, StackPointer, scratch1);
|
||||
masm.addPtr(Imm32(JitFrameLayout::Size()), scratch2);
|
||||
|
||||
// scratch3 := AccFrame-Descriptor.Size
|
||||
@@ -1346,7 +1374,7 @@ JitRuntime::generateProfilerExitFrameTailStub(JSContext* cx)
|
||||
|
||||
// lastProfilingFrame := AccessorFrame + AccFrame-Descriptor.Size +
|
||||
// IonAccessorICFrameLayout::Size()
|
||||
masm.ma_addu(scratch1, scratch2, scratch3);
|
||||
masm.as_addu(scratch1, scratch2, scratch3);
|
||||
masm.addPtr(Imm32(IonAccessorICFrameLayout::Size()), scratch1);
|
||||
masm.storePtr(scratch1, lastProfilingFrame);
|
||||
masm.ret();
|
||||
|
||||
@@ -852,8 +852,40 @@ ObjectGroup::newArrayObject(ExclusiveContext* cx,
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
return NewCopiedArrayTryUseGroup(cx, group, vp, length, newKind,
|
||||
ShouldUpdateTypes::DontUpdate);
|
||||
// The type of the elements being added will already be reflected in type
|
||||
// information, but make sure when creating an unboxed array that the
|
||||
// common element type is suitable for the unboxed representation.
|
||||
ShouldUpdateTypes updateTypes = ShouldUpdateTypes::DontUpdate;
|
||||
if (group->maybePreliminaryObjects())
|
||||
group->maybePreliminaryObjects()->maybeAnalyze(cx, group);
|
||||
if (group->maybeUnboxedLayout()) {
|
||||
switch (group->unboxedLayout().elementType()) {
|
||||
case JSVAL_TYPE_BOOLEAN:
|
||||
if (elementType != TypeSet::BooleanType())
|
||||
updateTypes = ShouldUpdateTypes::Update;
|
||||
break;
|
||||
case JSVAL_TYPE_INT32:
|
||||
if (elementType != TypeSet::Int32Type())
|
||||
updateTypes = ShouldUpdateTypes::Update;
|
||||
break;
|
||||
case JSVAL_TYPE_DOUBLE:
|
||||
if (elementType != TypeSet::Int32Type() && elementType != TypeSet::DoubleType())
|
||||
updateTypes = ShouldUpdateTypes::Update;
|
||||
break;
|
||||
case JSVAL_TYPE_STRING:
|
||||
if (elementType != TypeSet::StringType())
|
||||
updateTypes = ShouldUpdateTypes::Update;
|
||||
break;
|
||||
case JSVAL_TYPE_OBJECT:
|
||||
if (elementType != TypeSet::NullType() && !elementType.get().isObjectUnchecked())
|
||||
updateTypes = ShouldUpdateTypes::Update;
|
||||
break;
|
||||
default:
|
||||
MOZ_CRASH();
|
||||
}
|
||||
}
|
||||
|
||||
return NewCopiedArrayTryUseGroup(cx, group, vp, length, newKind, updateTypes);
|
||||
}
|
||||
|
||||
// Try to change the group of |source| to match that of |target|.
|
||||
|
||||
@@ -15,8 +15,6 @@ if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'cocoa':
|
||||
'xpcshellMacUtils.mm',
|
||||
]
|
||||
|
||||
if CONFIG['MOZ_SHARK']:
|
||||
DEFINES['MOZ_SHARK'] = True
|
||||
if CONFIG['MOZ_CALLGRIND']:
|
||||
DEFINES['MOZ_CALLGRIND'] = True
|
||||
|
||||
|
||||
@@ -176,7 +176,7 @@ Native2WrappedNativeMap::newMap(int length)
|
||||
}
|
||||
|
||||
Native2WrappedNativeMap::Native2WrappedNativeMap(int length)
|
||||
: mTable(new PLDHashTable(PL_DHashGetStubOps(), sizeof(Entry), length))
|
||||
: mTable(new PLDHashTable(PLDHashTable::StubOps(), sizeof(Entry), length))
|
||||
{
|
||||
}
|
||||
|
||||
@@ -204,8 +204,8 @@ const struct PLDHashTableOps IID2WrappedJSClassMap::Entry::sOps =
|
||||
{
|
||||
HashIIDPtrKey,
|
||||
MatchIIDPtrKey,
|
||||
PL_DHashMoveEntryStub,
|
||||
PL_DHashClearEntryStub
|
||||
PLDHashTable::MoveEntryStub,
|
||||
PLDHashTable::ClearEntryStub
|
||||
};
|
||||
|
||||
// static
|
||||
@@ -232,8 +232,8 @@ const struct PLDHashTableOps IID2NativeInterfaceMap::Entry::sOps =
|
||||
{
|
||||
HashIIDPtrKey,
|
||||
MatchIIDPtrKey,
|
||||
PL_DHashMoveEntryStub,
|
||||
PL_DHashClearEntryStub
|
||||
PLDHashTable::MoveEntryStub,
|
||||
PLDHashTable::ClearEntryStub
|
||||
};
|
||||
|
||||
// static
|
||||
@@ -276,7 +276,7 @@ ClassInfo2NativeSetMap::newMap(int length)
|
||||
}
|
||||
|
||||
ClassInfo2NativeSetMap::ClassInfo2NativeSetMap(int length)
|
||||
: mTable(new PLDHashTable(PL_DHashGetStubOps(), sizeof(Entry), length))
|
||||
: mTable(new PLDHashTable(PLDHashTable::StubOps(), sizeof(Entry), length))
|
||||
{
|
||||
}
|
||||
|
||||
@@ -312,7 +312,7 @@ ClassInfo2WrappedNativeProtoMap::newMap(int length)
|
||||
}
|
||||
|
||||
ClassInfo2WrappedNativeProtoMap::ClassInfo2WrappedNativeProtoMap(int length)
|
||||
: mTable(new PLDHashTable(PL_DHashGetStubOps(), sizeof(Entry), length))
|
||||
: mTable(new PLDHashTable(PLDHashTable::StubOps(), sizeof(Entry), length))
|
||||
{
|
||||
}
|
||||
|
||||
@@ -412,8 +412,8 @@ const struct PLDHashTableOps NativeSetMap::Entry::sOps =
|
||||
{
|
||||
HashNativeKey,
|
||||
Match,
|
||||
PL_DHashMoveEntryStub,
|
||||
PL_DHashClearEntryStub
|
||||
PLDHashTable::MoveEntryStub,
|
||||
PLDHashTable::ClearEntryStub
|
||||
};
|
||||
|
||||
// static
|
||||
@@ -467,7 +467,7 @@ const struct PLDHashTableOps IID2ThisTranslatorMap::Entry::sOps =
|
||||
{
|
||||
HashIIDPtrKey,
|
||||
Match,
|
||||
PL_DHashMoveEntryStub,
|
||||
PLDHashTable::MoveEntryStub,
|
||||
Clear
|
||||
};
|
||||
|
||||
@@ -538,8 +538,8 @@ const struct PLDHashTableOps XPCNativeScriptableSharedMap::Entry::sOps =
|
||||
{
|
||||
Hash,
|
||||
Match,
|
||||
PL_DHashMoveEntryStub,
|
||||
PL_DHashClearEntryStub
|
||||
PLDHashTable::MoveEntryStub,
|
||||
PLDHashTable::ClearEntryStub
|
||||
};
|
||||
|
||||
// static
|
||||
@@ -596,7 +596,7 @@ XPCWrappedNativeProtoMap::newMap(int length)
|
||||
}
|
||||
|
||||
XPCWrappedNativeProtoMap::XPCWrappedNativeProtoMap(int length)
|
||||
: mTable(new PLDHashTable(PL_DHashGetStubOps(), sizeof(PLDHashEntryStub),
|
||||
: mTable(new PLDHashTable(PLDHashTable::StubOps(), sizeof(PLDHashEntryStub),
|
||||
length))
|
||||
{
|
||||
}
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
|
||||
// Note that most of the declarations for hash table entries begin with
|
||||
// a pointer to something or another. This makes them look enough like
|
||||
// the PLDHashEntryStub struct that the default OPs (PL_DHashGetStubOps())
|
||||
// the PLDHashEntryStub struct that the default ops (PLDHashTable::StubOps())
|
||||
// just do the right thing for most of our needs.
|
||||
|
||||
// no virtuals in the maps - all the common stuff inlined
|
||||
|
||||
@@ -69,10 +69,10 @@ PlaceholderMapMatchEntry(PLDHashTable *table, const PLDHashEntryHdr *hdr,
|
||||
}
|
||||
|
||||
static const PLDHashTableOps PlaceholderMapOps = {
|
||||
PL_DHashVoidPtrKeyStub,
|
||||
PLDHashTable::HashVoidPtrKeyStub,
|
||||
PlaceholderMapMatchEntry,
|
||||
PL_DHashMoveEntryStub,
|
||||
PL_DHashClearEntryStub,
|
||||
PLDHashTable::MoveEntryStub,
|
||||
PLDHashTable::ClearEntryStub,
|
||||
nullptr
|
||||
};
|
||||
|
||||
|
||||
@@ -21,6 +21,7 @@
|
||||
|
||||
#include "nsDebug.h"
|
||||
#include "pldhash.h"
|
||||
#include "mozilla/Attributes.h"
|
||||
|
||||
class nsIFrame;
|
||||
class nsIPresShell;
|
||||
@@ -51,7 +52,7 @@ protected:
|
||||
class UndisplayedMap;
|
||||
|
||||
// weak link, because the pres shell owns us
|
||||
nsIPresShell* mPresShell;
|
||||
nsIPresShell* MOZ_NON_OWNING_REF mPresShell;
|
||||
// the pres shell owns the style set
|
||||
nsStyleSet* mStyleSet;
|
||||
nsIFrame* mRootFrame;
|
||||
|
||||
@@ -583,9 +583,7 @@ Declaration::GetValue(nsCSSProperty aProperty, nsAString& aValue,
|
||||
} else {
|
||||
// properties reset by this shorthand property to their
|
||||
// initial values but not represented in its syntax
|
||||
if (stretch->GetUnit() != eCSSUnit_Enumerated ||
|
||||
stretch->GetIntValue() != NS_STYLE_FONT_STRETCH_NORMAL ||
|
||||
sizeAdjust->GetUnit() != eCSSUnit_None ||
|
||||
if (sizeAdjust->GetUnit() != eCSSUnit_None ||
|
||||
featureSettings->GetUnit() != eCSSUnit_Normal ||
|
||||
languageOverride->GetUnit() != eCSSUnit_Normal ||
|
||||
fontKerning->GetIntValue() != NS_FONT_KERNING_AUTO ||
|
||||
@@ -625,6 +623,12 @@ Declaration::GetValue(nsCSSProperty aProperty, nsAString& aValue,
|
||||
aSerialization);
|
||||
aValue.Append(char16_t(' '));
|
||||
}
|
||||
if (stretch->GetUnit() != eCSSUnit_Enumerated ||
|
||||
stretch->GetIntValue() != NS_FONT_STRETCH_NORMAL) {
|
||||
stretch->AppendToString(eCSSProperty_font_stretch, aValue,
|
||||
aSerialization);
|
||||
aValue.Append(char16_t(' '));
|
||||
}
|
||||
size->AppendToString(eCSSProperty_font_size, aValue, aSerialization);
|
||||
if (lh->GetUnit() != eCSSUnit_Normal) {
|
||||
aValue.Append(char16_t('/'));
|
||||
|
||||
+204
-44
@@ -58,6 +58,10 @@ typedef nsCSSProps::KTableValue KTableValue;
|
||||
// pref-backed bool values (hooked up in nsCSSParser::Startup)
|
||||
static bool sOpentypeSVGEnabled;
|
||||
static bool sUnprefixingServiceEnabled;
|
||||
#ifdef NIGHTLY_BUILD
|
||||
static bool sUnprefixingServiceGloballyWhitelisted;
|
||||
#endif
|
||||
static bool sMozGradientsEnabled;
|
||||
|
||||
const uint32_t
|
||||
nsCSSProps::kParserVariantTable[eCSSProperty_COUNT_no_shorthands] = {
|
||||
@@ -744,7 +748,23 @@ protected:
|
||||
bool ParseProperty(nsCSSProperty aPropID);
|
||||
bool ParsePropertyByFunction(nsCSSProperty aPropID);
|
||||
bool ParseSingleValueProperty(nsCSSValue& aValue,
|
||||
nsCSSProperty aPropID);
|
||||
nsCSSProperty aPropID);
|
||||
|
||||
// These are similar to ParseSingleValueProperty but only work for
|
||||
// properties that are parsed with ParseBoxProperties or
|
||||
// ParseGroupedBoxProperty. Stores in aConsumedTokens whether any tokens
|
||||
// were consumed.
|
||||
//
|
||||
// Only works with variants with the following flags:
|
||||
// A, C, H, K, L, N, P, CALC.
|
||||
bool ParseBoxPropertyVariant(nsCSSValue& aValue,
|
||||
uint32_t aVariantMask,
|
||||
const KTableValue aKeywordTable[],
|
||||
uint32_t aRestrictions,
|
||||
bool& aConsumedTokens);
|
||||
bool ParseBoxProperty(nsCSSValue& aValue,
|
||||
nsCSSProperty aPropID,
|
||||
bool& aConsumedTokens);
|
||||
|
||||
enum PriorityParsingStatus {
|
||||
ePriority_None,
|
||||
@@ -1043,6 +1063,10 @@ protected:
|
||||
bool ParseVariant(nsCSSValue& aValue,
|
||||
int32_t aVariantMask,
|
||||
const KTableValue aKeywordTable[]);
|
||||
bool ParseVariantWithRestrictions(nsCSSValue& aValue,
|
||||
int32_t aVariantMask,
|
||||
const KTableValue aKeywordTable[],
|
||||
uint32_t aRestrictions);
|
||||
bool ParseNonNegativeVariant(nsCSSValue& aValue,
|
||||
int32_t aVariantMask,
|
||||
const KTableValue aKeywordTable[]);
|
||||
@@ -2139,6 +2163,7 @@ SeparatorRequiredBetweenTokens(nsCSSTokenSerializationType aToken1,
|
||||
aToken2 == eCSSTokenSerialization_URange ||
|
||||
aToken2 == eCSSTokenSerialization_CDC;
|
||||
case eCSSTokenSerialization_Symbol_Hash:
|
||||
case eCSSTokenSerialization_Symbol_Minus:
|
||||
return aToken2 == eCSSTokenSerialization_Ident ||
|
||||
aToken2 == eCSSTokenSerialization_Function ||
|
||||
aToken2 == eCSSTokenSerialization_URL_or_BadURL ||
|
||||
@@ -2147,7 +2172,6 @@ SeparatorRequiredBetweenTokens(nsCSSTokenSerializationType aToken1,
|
||||
aToken2 == eCSSTokenSerialization_Percentage ||
|
||||
aToken2 == eCSSTokenSerialization_Dimension ||
|
||||
aToken2 == eCSSTokenSerialization_URange;
|
||||
case eCSSTokenSerialization_Symbol_Minus:
|
||||
case eCSSTokenSerialization_Number:
|
||||
return aToken2 == eCSSTokenSerialization_Ident ||
|
||||
aToken2 == eCSSTokenSerialization_Function ||
|
||||
@@ -3732,8 +3756,16 @@ CSSParserImpl::ParseFontDescriptor(nsCSSFontFaceRule* aRule)
|
||||
return false;
|
||||
}
|
||||
|
||||
if (!ExpectEndProperty())
|
||||
return false;
|
||||
// Expect termination by ;, }, or EOF.
|
||||
if (GetToken(true)) {
|
||||
if (!mToken.IsSymbol(';') &&
|
||||
!mToken.IsSymbol('}')) {
|
||||
UngetToken();
|
||||
REPORT_UNEXPECTED_TOKEN(PEExpectEndValue);
|
||||
return false;
|
||||
}
|
||||
UngetToken();
|
||||
}
|
||||
|
||||
aRule->SetDesc(descID, value);
|
||||
return true;
|
||||
@@ -6667,6 +6699,13 @@ CSSParserImpl::ShouldUseUnprefixingService()
|
||||
return false;
|
||||
}
|
||||
|
||||
#ifdef NIGHTLY_BUILD
|
||||
if (sUnprefixingServiceGloballyWhitelisted) {
|
||||
// Unprefixing is globally whitelisted,
|
||||
// so no need to check mSheetPrincipal.
|
||||
return true;
|
||||
}
|
||||
#endif
|
||||
// Unprefixing enabled; see if our principal is whitelisted for unprefixing.
|
||||
return mSheetPrincipal && mSheetPrincipal->IsOnCSSUnprefixingWhitelist();
|
||||
}
|
||||
@@ -7165,6 +7204,24 @@ CSSParserImpl::TranslateDimension(nsCSSValue& aValue,
|
||||
VARIANT_CALC | \
|
||||
VARIANT_OPENTYPE_SVG_KEYWORD
|
||||
|
||||
bool
|
||||
CSSParserImpl::ParseVariantWithRestrictions(nsCSSValue& aValue,
|
||||
int32_t aVariantMask,
|
||||
const KTableValue aKeywordTable[],
|
||||
uint32_t aRestrictions)
|
||||
{
|
||||
switch (aRestrictions) {
|
||||
default:
|
||||
MOZ_ASSERT(false, "should not be reached");
|
||||
case 0:
|
||||
return ParseVariant(aValue, aVariantMask, aKeywordTable);
|
||||
case CSS_PROPERTY_VALUE_NONNEGATIVE:
|
||||
return ParseNonNegativeVariant(aValue, aVariantMask, aKeywordTable);
|
||||
case CSS_PROPERTY_VALUE_AT_LEAST_ONE:
|
||||
return ParseOneOrLargerVariant(aValue, aVariantMask, aKeywordTable);
|
||||
}
|
||||
}
|
||||
|
||||
// Note that callers passing VARIANT_CALC in aVariantMask will get
|
||||
// full-range parsing inside the calc() expression, and the code that
|
||||
// computes the calc will be required to clamp the resulting value to an
|
||||
@@ -7401,7 +7458,8 @@ CSSParserImpl::ParseVariant(nsCSSValue& aValue,
|
||||
// a generated gradient
|
||||
nsDependentString tmp(tk->mIdent, 0);
|
||||
bool isLegacy = false;
|
||||
if (StringBeginsWith(tmp, NS_LITERAL_STRING("-moz-"))) {
|
||||
if (sMozGradientsEnabled &&
|
||||
StringBeginsWith(tmp, NS_LITERAL_STRING("-moz-"))) {
|
||||
tmp.Rebind(tmp, 5);
|
||||
isLegacy = true;
|
||||
}
|
||||
@@ -9691,8 +9749,12 @@ CSSParserImpl::ParseBoxProperties(const nsCSSProperty aPropIDs[])
|
||||
int32_t count = 0;
|
||||
nsCSSRect result;
|
||||
NS_FOR_CSS_SIDES (index) {
|
||||
if (! ParseSingleValueProperty(result.*(nsCSSRect::sides[index]),
|
||||
aPropIDs[index])) {
|
||||
bool consumedTokens;
|
||||
if (!ParseBoxProperty(result.*(nsCSSRect::sides[index]),
|
||||
aPropIDs[index], consumedTokens)) {
|
||||
if (consumedTokens) {
|
||||
return false;
|
||||
}
|
||||
break;
|
||||
}
|
||||
count++;
|
||||
@@ -9738,8 +9800,17 @@ CSSParserImpl::ParseGroupedBoxProperty(int32_t aVariantMask,
|
||||
|
||||
int32_t count = 0;
|
||||
NS_FOR_CSS_SIDES (index) {
|
||||
if (!ParseNonNegativeVariant(result.*(nsCSSRect::sides[index]),
|
||||
aVariantMask, nullptr)) {
|
||||
bool consumedTokens;
|
||||
if (!ParseBoxPropertyVariant(result.*(nsCSSRect::sides[index]),
|
||||
aVariantMask, nullptr,
|
||||
CSS_PROPERTY_VALUE_NONNEGATIVE,
|
||||
consumedTokens)) {
|
||||
if (consumedTokens) {
|
||||
// we consumed some tokens, which means we failed in the middle
|
||||
// of parsing a multi-token value, and thus we shouldn't just
|
||||
// exit the loop and return true
|
||||
return false;
|
||||
}
|
||||
break;
|
||||
}
|
||||
count++;
|
||||
@@ -10330,6 +10401,79 @@ CSSParserImpl::ParsePropertyByFunction(nsCSSProperty aPropID)
|
||||
#define BG_CLR (BG_CENTER | BG_LEFT | BG_RIGHT)
|
||||
#define BG_LR (BG_LEFT | BG_RIGHT)
|
||||
|
||||
bool
|
||||
CSSParserImpl::ParseBoxPropertyVariant(nsCSSValue& aValue,
|
||||
uint32_t aVariantMask,
|
||||
const KTableValue aKeywordTable[],
|
||||
uint32_t aRestrictions,
|
||||
bool& aConsumedTokens)
|
||||
{
|
||||
aConsumedTokens = false;
|
||||
|
||||
uint32_t lineBefore, colBefore;
|
||||
if (!GetNextTokenLocation(true, &lineBefore, &colBefore)) {
|
||||
return false;
|
||||
}
|
||||
|
||||
if (!ParseVariantWithRestrictions(aValue, aVariantMask, aKeywordTable,
|
||||
aRestrictions)) {
|
||||
uint32_t lineAfter, colAfter;
|
||||
if (!GetNextTokenLocation(true, &lineAfter, &colAfter)) {
|
||||
// any single token value that was invalid will have been pushed back,
|
||||
// so GetNextTokenLocation encountering EOF means we failed while
|
||||
// parsing a multi-token value
|
||||
aConsumedTokens = true;
|
||||
} else if (lineAfter != lineBefore || colAfter != colBefore) {
|
||||
aConsumedTokens = true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
aConsumedTokens = true;
|
||||
return true;
|
||||
}
|
||||
|
||||
bool
|
||||
CSSParserImpl::ParseBoxProperty(nsCSSValue& aValue,
|
||||
nsCSSProperty aPropID,
|
||||
bool& aConsumedTokens)
|
||||
{
|
||||
aConsumedTokens = false;
|
||||
|
||||
if (aPropID < 0 || aPropID >= eCSSProperty_COUNT_no_shorthands) {
|
||||
MOZ_ASSERT(false, "must only be called for longhand properties");
|
||||
return false;
|
||||
}
|
||||
|
||||
MOZ_ASSERT(!nsCSSProps::PropHasFlags(aPropID,
|
||||
CSS_PROPERTY_VALUE_PARSER_FUNCTION),
|
||||
"must only be called for non-function-parsed properties");
|
||||
|
||||
uint32_t variant = nsCSSProps::ParserVariant(aPropID);
|
||||
if (variant == 0) {
|
||||
MOZ_ASSERT(false, "must only be called for variant-parsed properties");
|
||||
return false;
|
||||
}
|
||||
|
||||
if (aPropID == eCSSProperty_script_level ||
|
||||
aPropID == eCSSProperty_math_display) {
|
||||
MOZ_ASSERT(false, "must not be called for unsafe properties");
|
||||
return false;
|
||||
}
|
||||
|
||||
if (variant & ~(VARIANT_AHKLP | VARIANT_COLOR | VARIANT_CALC)) {
|
||||
MOZ_ASSERT(false, "must only be called for properties that take certain "
|
||||
"variants");
|
||||
return false;
|
||||
}
|
||||
|
||||
const KTableValue* kwtable = nsCSSProps::kKeywordTableTable[aPropID];
|
||||
uint32_t restrictions = nsCSSProps::ValueRestrictions(aPropID);
|
||||
|
||||
return ParseBoxPropertyVariant(aValue, variant, kwtable, restrictions,
|
||||
aConsumedTokens);
|
||||
}
|
||||
|
||||
bool
|
||||
CSSParserImpl::ParseSingleValueProperty(nsCSSValue& aValue,
|
||||
nsCSSProperty aPropID)
|
||||
@@ -10414,17 +10558,9 @@ CSSParserImpl::ParseSingleValueProperty(nsCSSValue& aValue,
|
||||
aPropID == eCSSProperty_math_display))
|
||||
return false;
|
||||
|
||||
const KTableValue *kwtable = nsCSSProps::kKeywordTableTable[aPropID];
|
||||
switch (nsCSSProps::ValueRestrictions(aPropID)) {
|
||||
default:
|
||||
MOZ_ASSERT(false, "should not be reached");
|
||||
case 0:
|
||||
return ParseVariant(aValue, variant, kwtable);
|
||||
case CSS_PROPERTY_VALUE_NONNEGATIVE:
|
||||
return ParseNonNegativeVariant(aValue, variant, kwtable);
|
||||
case CSS_PROPERTY_VALUE_AT_LEAST_ONE:
|
||||
return ParseOneOrLargerVariant(aValue, variant, kwtable);
|
||||
}
|
||||
const KTableValue* kwtable = nsCSSProps::kKeywordTableTable[aPropID];
|
||||
uint32_t restrictions = nsCSSProps::ValueRestrictions(aPropID);
|
||||
return ParseVariantWithRestrictions(aValue, variant, kwtable, restrictions);
|
||||
}
|
||||
|
||||
// font-descriptor: descriptor ':' value ';'
|
||||
@@ -12122,12 +12258,6 @@ CSSParserImpl::ParseCursor()
|
||||
bool
|
||||
CSSParserImpl::ParseFont()
|
||||
{
|
||||
static const nsCSSProperty fontIDs[] = {
|
||||
eCSSProperty_font_style,
|
||||
eCSSProperty_font_variant_caps,
|
||||
eCSSProperty_font_weight
|
||||
};
|
||||
|
||||
nsCSSValue family;
|
||||
if (ParseVariant(family, VARIANT_HK, nsCSSProps::kFontKTable)) {
|
||||
if (eCSSUnit_Inherit == family.GetUnit() ||
|
||||
@@ -12176,35 +12306,60 @@ CSSParserImpl::ParseFont()
|
||||
return true;
|
||||
}
|
||||
|
||||
// Get optional font-style, font-variant and font-weight (in any order)
|
||||
const int32_t numProps = 3;
|
||||
// Get optional font-style, font-variant, font-weight, font-stretch
|
||||
// (in any order)
|
||||
|
||||
// Indexes into fontIDs[] and values[] arrays.
|
||||
const int kFontStyleIndex = 0;
|
||||
const int kFontVariantIndex = 1;
|
||||
const int kFontWeightIndex = 2;
|
||||
const int kFontStretchIndex = 3;
|
||||
|
||||
// The order of the initializers here must match the order of the indexes
|
||||
// defined above!
|
||||
static const nsCSSProperty fontIDs[] = {
|
||||
eCSSProperty_font_style,
|
||||
eCSSProperty_font_variant_caps,
|
||||
eCSSProperty_font_weight,
|
||||
eCSSProperty_font_stretch
|
||||
};
|
||||
|
||||
const int32_t numProps = MOZ_ARRAY_LENGTH(fontIDs);
|
||||
nsCSSValue values[numProps];
|
||||
int32_t found = ParseChoice(values, fontIDs, numProps);
|
||||
if (found < 0 ||
|
||||
eCSSUnit_Inherit == values[0].GetUnit() ||
|
||||
eCSSUnit_Initial == values[0].GetUnit() ||
|
||||
eCSSUnit_Unset == values[0].GetUnit()) { // illegal data
|
||||
eCSSUnit_Inherit == values[kFontStyleIndex].GetUnit() ||
|
||||
eCSSUnit_Initial == values[kFontStyleIndex].GetUnit() ||
|
||||
eCSSUnit_Unset == values[kFontStyleIndex].GetUnit()) { // illegal data
|
||||
return false;
|
||||
}
|
||||
if ((found & 1) == 0) {
|
||||
if ((found & (1 << kFontStyleIndex)) == 0) {
|
||||
// Provide default font-style
|
||||
values[0].SetIntValue(NS_FONT_STYLE_NORMAL, eCSSUnit_Enumerated);
|
||||
values[kFontStyleIndex].SetIntValue(NS_FONT_STYLE_NORMAL,
|
||||
eCSSUnit_Enumerated);
|
||||
}
|
||||
if ((found & 2) == 0) {
|
||||
if ((found & (1 << kFontVariantIndex)) == 0) {
|
||||
// Provide default font-variant
|
||||
values[1].SetNormalValue();
|
||||
values[kFontVariantIndex].SetNormalValue();
|
||||
} else {
|
||||
if (values[1].GetUnit() == eCSSUnit_Enumerated &&
|
||||
values[1].GetIntValue() != NS_FONT_VARIANT_CAPS_SMALLCAPS) {
|
||||
if (values[kFontVariantIndex].GetUnit() == eCSSUnit_Enumerated &&
|
||||
values[kFontVariantIndex].GetIntValue() !=
|
||||
NS_FONT_VARIANT_CAPS_SMALLCAPS) {
|
||||
// only normal or small-caps is allowed in font shorthand
|
||||
// this also assumes other values for font-variant-caps never overlap
|
||||
// possible values for style or weight
|
||||
return false;
|
||||
}
|
||||
}
|
||||
if ((found & 4) == 0) {
|
||||
if ((found & (1 << kFontWeightIndex)) == 0) {
|
||||
// Provide default font-weight
|
||||
values[2].SetIntValue(NS_FONT_WEIGHT_NORMAL, eCSSUnit_Enumerated);
|
||||
values[kFontWeightIndex].SetIntValue(NS_FONT_WEIGHT_NORMAL,
|
||||
eCSSUnit_Enumerated);
|
||||
}
|
||||
if ((found & (1 << kFontStretchIndex)) == 0) {
|
||||
// Provide default font-stretch
|
||||
values[kFontStretchIndex].SetIntValue(NS_FONT_STRETCH_NORMAL,
|
||||
eCSSUnit_Enumerated);
|
||||
}
|
||||
|
||||
// Get mandatory font-size
|
||||
@@ -12235,13 +12390,12 @@ CSSParserImpl::ParseFont()
|
||||
eCSSUnit_Unset != family.GetUnit()) {
|
||||
AppendValue(eCSSProperty__x_system_font, nsCSSValue(eCSSUnit_None));
|
||||
AppendValue(eCSSProperty_font_family, family);
|
||||
AppendValue(eCSSProperty_font_style, values[0]);
|
||||
AppendValue(eCSSProperty_font_variant_caps, values[1]);
|
||||
AppendValue(eCSSProperty_font_weight, values[2]);
|
||||
AppendValue(eCSSProperty_font_style, values[kFontStyleIndex]);
|
||||
AppendValue(eCSSProperty_font_variant_caps, values[kFontVariantIndex]);
|
||||
AppendValue(eCSSProperty_font_weight, values[kFontWeightIndex]);
|
||||
AppendValue(eCSSProperty_font_size, size);
|
||||
AppendValue(eCSSProperty_line_height, lineHeight);
|
||||
AppendValue(eCSSProperty_font_stretch,
|
||||
nsCSSValue(NS_FONT_STRETCH_NORMAL, eCSSUnit_Enumerated));
|
||||
AppendValue(eCSSProperty_font_stretch, values[kFontStretchIndex]);
|
||||
AppendValue(eCSSProperty_font_size_adjust, nsCSSValue(eCSSUnit_None));
|
||||
AppendValue(eCSSProperty_font_feature_settings, nsCSSValue(eCSSUnit_Normal));
|
||||
AppendValue(eCSSProperty_font_language_override, nsCSSValue(eCSSUnit_Normal));
|
||||
@@ -15651,6 +15805,12 @@ nsCSSParser::Startup()
|
||||
"gfx.font_rendering.opentype_svg.enabled");
|
||||
Preferences::AddBoolVarCache(&sUnprefixingServiceEnabled,
|
||||
"layout.css.unprefixing-service.enabled");
|
||||
#ifdef NIGHTLY_BUILD
|
||||
Preferences::AddBoolVarCache(&sUnprefixingServiceGloballyWhitelisted,
|
||||
"layout.css.unprefixing-service.globally-whitelisted");
|
||||
#endif
|
||||
Preferences::AddBoolVarCache(&sMozGradientsEnabled,
|
||||
"layout.css.prefixes.gradients");
|
||||
}
|
||||
|
||||
nsCSSParser::nsCSSParser(mozilla::css::Loader* aLoader,
|
||||
|
||||
@@ -359,7 +359,7 @@ RuleHash_NameSpaceTable_MatchEntry(PLDHashTable *table,
|
||||
}
|
||||
|
||||
static const PLDHashTableOps RuleHash_TagTable_Ops = {
|
||||
PL_DHashVoidPtrKeyStub,
|
||||
PLDHashTable::HashVoidPtrKeyStub,
|
||||
RuleHash_TagTable_MatchEntry,
|
||||
RuleHash_TagTable_MoveEntry,
|
||||
RuleHash_TagTable_ClearEntry,
|
||||
@@ -369,7 +369,7 @@ static const PLDHashTableOps RuleHash_TagTable_Ops = {
|
||||
// Case-sensitive ops.
|
||||
static const RuleHashTableOps RuleHash_ClassTable_CSOps = {
|
||||
{
|
||||
PL_DHashVoidPtrKeyStub,
|
||||
PLDHashTable::HashVoidPtrKeyStub,
|
||||
RuleHash_CSMatchEntry,
|
||||
RuleHash_MoveEntry,
|
||||
RuleHash_ClearEntry,
|
||||
@@ -393,7 +393,7 @@ static const RuleHashTableOps RuleHash_ClassTable_CIOps = {
|
||||
// Case-sensitive ops.
|
||||
static const RuleHashTableOps RuleHash_IdTable_CSOps = {
|
||||
{
|
||||
PL_DHashVoidPtrKeyStub,
|
||||
PLDHashTable::HashVoidPtrKeyStub,
|
||||
RuleHash_CSMatchEntry,
|
||||
RuleHash_MoveEntry,
|
||||
RuleHash_ClearEntry,
|
||||
@@ -850,8 +850,8 @@ AtomSelector_GetKey(PLDHashTable *table, const PLDHashEntryHdr *hdr)
|
||||
|
||||
// Case-sensitive ops.
|
||||
static const PLDHashTableOps AtomSelector_CSOps = {
|
||||
PL_DHashVoidPtrKeyStub,
|
||||
PL_DHashMatchEntryStub,
|
||||
PLDHashTable::HashVoidPtrKeyStub,
|
||||
PLDHashTable::MatchEntryStub,
|
||||
AtomSelector_MoveEntry,
|
||||
AtomSelector_ClearEntry,
|
||||
AtomSelector_InitEntry
|
||||
@@ -3409,8 +3409,8 @@ InitWeightEntry(PLDHashEntryHdr *hdr, const void *key)
|
||||
static const PLDHashTableOps gRulesByWeightOps = {
|
||||
HashIntKey,
|
||||
MatchWeightEntry,
|
||||
PL_DHashMoveEntryStub,
|
||||
PL_DHashClearEntryStub,
|
||||
PLDHashTable::MoveEntryStub,
|
||||
PLDHashTable::ClearEntryStub,
|
||||
InitWeightEntry
|
||||
};
|
||||
|
||||
|
||||
@@ -104,7 +104,7 @@ enum nsCSSTokenType {
|
||||
// need to insert a "/**/" string between a '|' delim and a '|=' dashmatch
|
||||
// and between a '/' delim and a '*=' containsmatch.
|
||||
//
|
||||
// https://dvcs.w3.org/hg/csswg/raw-file/372e659027a0/css-syntax/Overview.html#serialization
|
||||
// https://drafts.csswg.org/css-syntax/#serialization
|
||||
enum nsCSSTokenSerializationType {
|
||||
eCSSTokenSerialization_Nothing,
|
||||
eCSSTokenSerialization_Whitespace,
|
||||
|
||||
@@ -171,7 +171,7 @@ MappedAttrTable_MatchEntry(PLDHashTable *table, const PLDHashEntryHdr *hdr,
|
||||
static const PLDHashTableOps MappedAttrTable_Ops = {
|
||||
MappedAttrTable_HashKey,
|
||||
MappedAttrTable_MatchEntry,
|
||||
PL_DHashMoveEntryStub,
|
||||
PLDHashTable::MoveEntryStub,
|
||||
MappedAttrTable_ClearEntry,
|
||||
nullptr
|
||||
};
|
||||
@@ -222,7 +222,7 @@ LangRuleTable_InitEntry(PLDHashEntryHdr *hdr, const void *key)
|
||||
static const PLDHashTableOps LangRuleTable_Ops = {
|
||||
LangRuleTable_HashKey,
|
||||
LangRuleTable_MatchEntry,
|
||||
PL_DHashMoveEntryStub,
|
||||
PLDHashTable::MoveEntryStub,
|
||||
LangRuleTable_ClearEntry,
|
||||
LangRuleTable_InitEntry
|
||||
};
|
||||
|
||||
@@ -104,7 +104,7 @@ nsRuleNode::ChildrenHashHashKey(PLDHashTable *aTable, const void *aKey)
|
||||
static_cast<const nsRuleNode::Key*>(aKey);
|
||||
// Disagreement on importance and level for the same rule is extremely
|
||||
// rare, so hash just on the rule.
|
||||
return PL_DHashVoidPtrKeyStub(aTable, key->mRule);
|
||||
return PLDHashTable::HashVoidPtrKeyStub(aTable, key->mRule);
|
||||
}
|
||||
|
||||
/* static */ bool
|
||||
@@ -127,8 +127,8 @@ nsRuleNode::ChildrenHashOps = {
|
||||
// large size allocations.
|
||||
ChildrenHashHashKey,
|
||||
ChildrenHashMatchEntry,
|
||||
PL_DHashMoveEntryStub,
|
||||
PL_DHashClearEntryStub,
|
||||
PLDHashTable::MoveEntryStub,
|
||||
PLDHashTable::ClearEntryStub,
|
||||
nullptr
|
||||
};
|
||||
|
||||
|
||||
@@ -15,12 +15,12 @@ var gCSSFontFaceDescriptors = {
|
||||
domProp: "fontFamily",
|
||||
values: [ "\"serif\"", "\"cursive\"", "seriff", "Times New Roman", "TimesRoman", "\"Times New Roman\"" ],
|
||||
/* not clear that the generics are really invalid */
|
||||
invalid_values: [ "sans-serif", "Times New Roman, serif", "'Times New Roman', serif", "cursive", "fantasy" ]
|
||||
invalid_values: [ "sans-serif", "Times New Roman, serif", "'Times New Roman', serif", "cursive", "fantasy", "Times )", "Times !", "Times ! foo", "Times ! important" ]
|
||||
},
|
||||
"font-stretch": {
|
||||
domProp: "fontStretch",
|
||||
values: [ "normal", "ultra-condensed", "extra-condensed", "condensed", "semi-condensed", "semi-expanded", "expanded", "extra-expanded", "ultra-expanded" ],
|
||||
invalid_values: [ "wider", "narrower" ]
|
||||
invalid_values: [ "wider", "narrower", "normal ! important", "normal )" ]
|
||||
},
|
||||
"font-style": {
|
||||
domProp: "fontStyle",
|
||||
@@ -53,11 +53,15 @@ var gCSSFontFaceDescriptors = {
|
||||
"url(404.ttf) format(\"truetype\",)",
|
||||
"local(\"Times New\" Roman)",
|
||||
"local(serif)", /* is this valid? */
|
||||
"url(404.ttf) )",
|
||||
"url(404.ttf) ) foo",
|
||||
"url(404.ttf) ! important",
|
||||
"url(404.ttf) ! hello",
|
||||
]
|
||||
},
|
||||
"unicode-range": {
|
||||
domProp: null,
|
||||
values: [ "U+0-10FFFF", "U+3-7B3", "U+3??", "U+6A", "U+3????", "U+???", "U+302-302", "U+0-7,U+A-C", "U+100-17F,U+200-17F", "U+3??, U+500-513 ,U+612 , U+4????", "U+1FFF,U+200-27F" ],
|
||||
invalid_values: [ "U+1????-2????", "U+0-7,A-C", "U+100-17F,200-17F" ]
|
||||
invalid_values: [ "U+1????-2????", "U+0-7,A-C", "U+100-17F,200-17F", "U+6A!important", "U+6A)" ]
|
||||
}
|
||||
}
|
||||
|
||||
@@ -802,7 +802,8 @@ var gCSSProperties = {
|
||||
type: CSS_TYPE_LONGHAND,
|
||||
initial_values: [ "1", "1 1 1 1" ],
|
||||
other_values: [ "0", "0%", "0px", "auto auto auto auto", "10 10% auto 15px", "10px 10px 10px 10px", "10", "10 10", "10 10 10" ],
|
||||
invalid_values: [ "-10", "-10px", "-10%", "10 10 10 10 10", "10 10 10 10 auto", "auto auto auto auto auto" ]
|
||||
invalid_values: [ "-10", "-10px", "-10%", "10 10 10 10 10", "10 10 10 10 auto", "auto auto auto auto auto", "10px calc(nonsense)", "1px red" ],
|
||||
unbalanced_values: [ "10px calc(" ]
|
||||
},
|
||||
"border-image-outset": {
|
||||
domProp: "borderImageOutset",
|
||||
@@ -810,7 +811,8 @@ var gCSSProperties = {
|
||||
type: CSS_TYPE_LONGHAND,
|
||||
initial_values: [ "0", "0 0 0 0" ],
|
||||
other_values: [ "10px", "10", "10 10", "10 10 10", "10 10 10 10", "10px 10 10 10px" ],
|
||||
invalid_values: [ "-10", "-10px", "-10%", "10%", "10 10 10 10 10" ]
|
||||
invalid_values: [ "-10", "-10px", "-10%", "10%", "10 10 10 10 10", "10px calc(nonsense)", "1px red" ],
|
||||
unbalanced_values: [ "10px calc(" ]
|
||||
},
|
||||
"border-image-repeat": {
|
||||
domProp: "borderImageRepeat",
|
||||
@@ -2138,7 +2140,8 @@ var gCSSProperties = {
|
||||
subproperties: [ "border-top-color", "border-right-color", "border-bottom-color", "border-left-color" ],
|
||||
initial_values: [ "currentColor", "currentColor currentColor", "currentColor currentColor currentColor", "currentColor currentColor currentcolor CURRENTcolor" ],
|
||||
other_values: [ "green", "currentColor green", "currentColor currentColor green", "currentColor currentColor currentColor green", "rgba(255,128,0,0.5)", "transparent" ],
|
||||
invalid_values: [ "#0", "#00", "#0000", "#00000", "#0000000", "#00000000", "#000000000" ],
|
||||
invalid_values: [ "#0", "#00", "#0000", "#00000", "#0000000", "#00000000", "#000000000", "red rgb(nonsense)", "red 1px" ],
|
||||
unbalanced_values: [ "red rgb(" ],
|
||||
quirks_values: { "000000": "#000000", "96ed2a": "#96ed2a" },
|
||||
},
|
||||
"border-left": {
|
||||
@@ -2313,7 +2316,8 @@ var gCSSProperties = {
|
||||
prerequisites: { "border-style": "solid" },
|
||||
initial_values: [ "medium", "3px", "medium medium", "3px medium medium", "medium 3px medium medium", "calc(3px) 3px calc(5px - 2px) calc(2px - -1px)" ],
|
||||
other_values: [ "thin", "thick", "1px", "2em", "2px 0 0px 1em", "calc(2em)" ],
|
||||
invalid_values: [ "5%" ],
|
||||
invalid_values: [ "5%", "1px calc(nonsense)", "1px red" ],
|
||||
unbalanced_values: [ "1px calc(" ],
|
||||
quirks_values: { "5": "5px" },
|
||||
},
|
||||
"bottom": {
|
||||
@@ -2486,7 +2490,7 @@ var gCSSProperties = {
|
||||
"font-kerning", "font-synthesis", "font-variant-alternates", "font-variant-caps", "font-variant-east-asian",
|
||||
"font-variant-ligatures", "font-variant-numeric", "font-variant-position" ],
|
||||
initial_values: [ (gInitialFontFamilyIsSansSerif ? "medium sans-serif" : "medium serif") ],
|
||||
other_values: [ "large serif", "9px fantasy", "bold italic small-caps 24px/1.4 Times New Roman, serif", "small inherit roman", "small roman inherit",
|
||||
other_values: [ "large serif", "9px fantasy", "condensed bold italic small-caps 24px/1.4 Times New Roman, serif", "small inherit roman", "small roman inherit",
|
||||
// system fonts
|
||||
"caption", "icon", "menu", "message-box", "small-caption", "status-bar",
|
||||
// Gecko-specific system fonts
|
||||
@@ -2854,8 +2858,9 @@ var gCSSProperties = {
|
||||
type: CSS_TYPE_TRUE_SHORTHAND,
|
||||
subproperties: [ "margin-top", "margin-right", "margin-bottom", "margin-left" ],
|
||||
initial_values: [ "0", "0px 0 0em", "0% 0px 0em 0pt" ],
|
||||
other_values: [ "3px 0", "2em 4px 2pt", "1em 2em 3px 4px" ],
|
||||
invalid_values: [],
|
||||
other_values: [ "3px 0", "2em 4px 2pt", "1em 2em 3px 4px", "1em calc(2em + 3px) 4ex 5cm" ],
|
||||
invalid_values: [ "1px calc(nonsense)", "1px red" ],
|
||||
unbalanced_values: [ "1px calc(" ],
|
||||
quirks_values: { "5": "5px", "3px 6px 2 5px": "3px 6px 2px 5px" },
|
||||
},
|
||||
"margin-bottom": {
|
||||
@@ -3148,7 +3153,8 @@ var gCSSProperties = {
|
||||
subproperties: [ "padding-top", "padding-right", "padding-bottom", "padding-left" ],
|
||||
initial_values: [ "0", "0px 0 0em", "0% 0px 0em 0pt", "calc(0px) calc(0em) calc(-2px) calc(-1%)" ],
|
||||
other_values: [ "3px 0", "2em 4px 2pt", "1em 2em 3px 4px" ],
|
||||
invalid_values: [],
|
||||
invalid_values: [ "1px calc(nonsense)", "1px red" ],
|
||||
unbalanced_values: [ "1px calc(" ],
|
||||
quirks_values: { "5": "5px", "3px 6px 2 5px": "3px 6px 2px 5px" },
|
||||
},
|
||||
"padding-bottom": {
|
||||
|
||||
@@ -56,8 +56,8 @@ var all_but_one = {
|
||||
"font-variant": "normal",
|
||||
"font-weight": "bold",
|
||||
"font-size": "small",
|
||||
"font-stretch": "normal",
|
||||
"font-size-adjust": "none", // has to be default value
|
||||
"font-stretch": "normal", // has to be default value
|
||||
"font-feature-settings": "normal", // has to be default value
|
||||
"font-language-override": "normal", // has to be default value
|
||||
"font-kerning": "auto", // has to be default value
|
||||
@@ -78,10 +78,10 @@ is(s.getPropertyValue("font"), "",
|
||||
s.setProperty("line-height", "1.5", "");
|
||||
isnot(s.getPropertyValue("font"), "",
|
||||
"font shorthand should produce value when all subproperties set");
|
||||
s.setProperty("font-stretch", "condensed", "");
|
||||
s.setProperty("font-size-adjust", "0.5", "");
|
||||
is(s.getPropertyValue("font"), "",
|
||||
"font shorthand should be empty when font-stretch is non-default");
|
||||
s.setProperty("font-stretch", "normal", "");
|
||||
"font shorthand should be empty when font-size-adjust is non-default");
|
||||
s.setProperty("font-size-adjust", "none", "");
|
||||
isnot(s.getPropertyValue("font"), "",
|
||||
"font shorthand should produce value when all subproperties set");
|
||||
s.removeProperty("font");
|
||||
|
||||
@@ -113,7 +113,7 @@ e.setAttribute("style", "font: medium serif");
|
||||
isnot(e.style.font, "", "should have font shorthand");
|
||||
e.setAttribute("style", "font: medium serif; font-size-adjust: 0.45");
|
||||
is(e.style.font, "", "should not have font shorthand");
|
||||
e.setAttribute("style", "font: medium serif; font-stretch: condensed");
|
||||
e.setAttribute("style", "font: medium serif; font-feature-settings: 'liga' off");
|
||||
is(e.style.font, "", "should not have font shorthand");
|
||||
|
||||
// Test that all combinations of background-clip and background-origin
|
||||
|
||||
@@ -35,6 +35,12 @@ var values = [
|
||||
["--a: var(--b)var(--c); --b:orange; --c:red;", "--a", " orange/**/red"],
|
||||
["--a: var(--b)var(--c,red); --b:orange;", "--a", " orange/**/red"],
|
||||
["--a: var(--b,orange)var(--c); --c:red;", "--a", " orange/**/red"],
|
||||
["--a: var(--b)-; --b:-;", "--a", " -/**/-"],
|
||||
["--a: var(--b)--; --b:-;", "--a", " -/**/--"],
|
||||
["--a: var(--b)--x; --b:-;", "--a", " -/**/--x"],
|
||||
["--a: var(--b)var(--c); --b:-; --c:-;", "--a", " -/**/-"],
|
||||
["--a: var(--b)var(--c); --b:--; --c:-;", "--a", " --/**/-"],
|
||||
["--a: var(--b)var(--c); --b:--x; --c:-;", "--a", " --x/**/-"],
|
||||
["counter-reset: var(--a)red; --a:orange;", "counter-reset", "orange 0 red 0"],
|
||||
["--a: var(--b)var(--c); --c:[c]; --b:('ab", "--a", " ('ab')[c]"],
|
||||
["--a: '", "--a", " ''"],
|
||||
|
||||
@@ -31,8 +31,8 @@ SpanningCellSorter::~SpanningCellSorter()
|
||||
SpanningCellSorter::HashTableOps = {
|
||||
HashTableHashKey,
|
||||
HashTableMatchEntry,
|
||||
PL_DHashMoveEntryStub,
|
||||
PL_DHashClearEntryStub,
|
||||
PLDHashTable::MoveEntryStub,
|
||||
PLDHashTable::ClearEntryStub,
|
||||
nullptr
|
||||
};
|
||||
|
||||
|
||||
@@ -2557,10 +2557,17 @@ pref("layout.css.prefixes.transitions", true);
|
||||
pref("layout.css.prefixes.animations", true);
|
||||
pref("layout.css.prefixes.box-sizing", true);
|
||||
pref("layout.css.prefixes.font-features", true);
|
||||
pref("layout.css.prefixes.gradients", true);
|
||||
|
||||
// Is the CSS Unprefixing Service enabled? (This service emulates support
|
||||
// for certain vendor-prefixed properties & values, for sites on a "fixlist".)
|
||||
pref("layout.css.unprefixing-service.enabled", false);
|
||||
pref("layout.css.unprefixing-service.enabled", true);
|
||||
#ifdef NIGHTLY_BUILD
|
||||
// Is the CSS Unprefixing Service whitelisted for all domains?
|
||||
// (This pref is only honored in Nightly builds and can be removed when
|
||||
// Bug 1177263 is fixed.)
|
||||
pref("layout.css.unprefixing-service.globally-whitelisted", false);
|
||||
#endif
|
||||
|
||||
// Is support for the :scope selector enabled?
|
||||
pref("layout.css.scope-pseudo.enabled", true);
|
||||
|
||||
@@ -80,9 +80,9 @@ static bool gShouldCleanupDeadNodes = false;
|
||||
|
||||
|
||||
static PLDHashTableOps pref_HashTableOps = {
|
||||
PL_DHashStringKey,
|
||||
PLDHashTable::HashStringKey,
|
||||
matchPrefEntry,
|
||||
PL_DHashMoveEntryStub,
|
||||
PLDHashTable::MoveEntryStub,
|
||||
clearPrefEntry,
|
||||
nullptr,
|
||||
};
|
||||
|
||||
@@ -34,6 +34,10 @@ if CONFIG['OS_TARGET'] == 'WINNT':
|
||||
'WindowsDllBlocklist.cpp',
|
||||
]
|
||||
DEFFILE = 'mozglue.def'
|
||||
# We'll break the DLL blocklist if we immediately load user32.dll
|
||||
DELAYLOAD_DLLS += [
|
||||
'user32.dll',
|
||||
]
|
||||
DISABLE_STL_WRAPPING = True
|
||||
OS_LIBS += [
|
||||
'version',
|
||||
|
||||
@@ -87,9 +87,9 @@ RequestHashInitEntry(PLDHashEntryHdr *entry, const void *key)
|
||||
|
||||
static const PLDHashTableOps sRequestHashOps =
|
||||
{
|
||||
PL_DHashVoidPtrKeyStub,
|
||||
PLDHashTable::HashVoidPtrKeyStub,
|
||||
RequestHashMatchEntry,
|
||||
PL_DHashMoveEntryStub,
|
||||
PLDHashTable::MoveEntryStub,
|
||||
RequestHashClearEntry,
|
||||
RequestHashInitEntry
|
||||
};
|
||||
|
||||
@@ -68,9 +68,9 @@ public:
|
||||
|
||||
static PLDHashNumber HashKey(KeyTypePointer aKey)
|
||||
{
|
||||
// PL_DHashStringKey doesn't use the table parameter, so we can safely
|
||||
// pass nullptr
|
||||
return PL_DHashStringKey(nullptr, aKey);
|
||||
// PLDHashTable::HashStringKey doesn't use the table parameter, so we can
|
||||
// safely pass nullptr
|
||||
return PLDHashTable::HashStringKey(nullptr, aKey);
|
||||
}
|
||||
|
||||
enum { ALLOW_MEMMOVE = true };
|
||||
|
||||
@@ -85,8 +85,8 @@ StringCompare(PLDHashTable *table, const PLDHashEntryHdr *entry,
|
||||
static const PLDHashTableOps ops = {
|
||||
StringHash,
|
||||
StringCompare,
|
||||
PL_DHashMoveEntryStub,
|
||||
PL_DHashClearEntryStub,
|
||||
PLDHashTable::MoveEntryStub,
|
||||
PLDHashTable::ClearEntryStub,
|
||||
nullptr
|
||||
};
|
||||
|
||||
|
||||
@@ -50,18 +50,18 @@ static PLDHashNumber
|
||||
|
||||
|
||||
static const PLDHashTableOps EntityToUnicodeOps = {
|
||||
PL_DHashStringKey,
|
||||
PLDHashTable::HashStringKey,
|
||||
matchNodeString,
|
||||
PL_DHashMoveEntryStub,
|
||||
PL_DHashClearEntryStub,
|
||||
PLDHashTable::MoveEntryStub,
|
||||
PLDHashTable::ClearEntryStub,
|
||||
nullptr,
|
||||
};
|
||||
|
||||
static const PLDHashTableOps UnicodeToEntityOps = {
|
||||
hashUnicodeValue,
|
||||
matchNodeUnicode,
|
||||
PL_DHashMoveEntryStub,
|
||||
PL_DHashClearEntryStub,
|
||||
PLDHashTable::MoveEntryStub,
|
||||
PLDHashTable::ClearEntryStub,
|
||||
nullptr,
|
||||
};
|
||||
|
||||
@@ -109,8 +109,8 @@ nsHTMLEntities::AddRefTable(void)
|
||||
entry->node = node;
|
||||
}
|
||||
#ifdef DEBUG
|
||||
PL_DHashMarkTableImmutable(gUnicodeToEntity);
|
||||
PL_DHashMarkTableImmutable(gEntityToUnicode);
|
||||
gUnicodeToEntity->MarkImmutable();
|
||||
gEntityToUnicode->MarkImmutable();
|
||||
#endif
|
||||
}
|
||||
++gTableRefCnt;
|
||||
|
||||
@@ -161,7 +161,7 @@ Assertion::Assertion(nsIRDFResource* aSource)
|
||||
NS_ADDREF(mSource);
|
||||
|
||||
u.hash.mPropertyHash =
|
||||
new PLDHashTable(PL_DHashGetStubOps(), sizeof(Entry));
|
||||
new PLDHashTable(PLDHashTable::StubOps(), sizeof(Entry));
|
||||
}
|
||||
|
||||
Assertion::Assertion(nsIRDFResource* aSource,
|
||||
@@ -734,8 +734,8 @@ NS_NewRDFInMemoryDataSource(nsISupports* aOuter, const nsIID& aIID, void** aResu
|
||||
|
||||
|
||||
InMemoryDataSource::InMemoryDataSource(nsISupports* aOuter)
|
||||
: mForwardArcs(PL_DHashGetStubOps(), sizeof(Entry))
|
||||
, mReverseArcs(PL_DHashGetStubOps(), sizeof(Entry))
|
||||
: mForwardArcs(PLDHashTable::StubOps(), sizeof(Entry))
|
||||
, mReverseArcs(PLDHashTable::StubOps(), sizeof(Entry))
|
||||
, mNumObservers(0)
|
||||
, mReadCount(0)
|
||||
{
|
||||
|
||||
+10
-10
@@ -141,8 +141,8 @@ struct ResourceHashEntry : public PLDHashEntryHdr {
|
||||
static const PLDHashTableOps gResourceTableOps = {
|
||||
ResourceHashEntry::HashKey,
|
||||
ResourceHashEntry::MatchEntry,
|
||||
PL_DHashMoveEntryStub,
|
||||
PL_DHashClearEntryStub,
|
||||
PLDHashTable::MoveEntryStub,
|
||||
PLDHashTable::ClearEntryStub,
|
||||
nullptr
|
||||
};
|
||||
|
||||
@@ -176,8 +176,8 @@ struct LiteralHashEntry : public PLDHashEntryHdr {
|
||||
static const PLDHashTableOps gLiteralTableOps = {
|
||||
LiteralHashEntry::HashKey,
|
||||
LiteralHashEntry::MatchEntry,
|
||||
PL_DHashMoveEntryStub,
|
||||
PL_DHashClearEntryStub,
|
||||
PLDHashTable::MoveEntryStub,
|
||||
PLDHashTable::ClearEntryStub,
|
||||
nullptr
|
||||
};
|
||||
|
||||
@@ -210,8 +210,8 @@ struct IntHashEntry : public PLDHashEntryHdr {
|
||||
static const PLDHashTableOps gIntTableOps = {
|
||||
IntHashEntry::HashKey,
|
||||
IntHashEntry::MatchEntry,
|
||||
PL_DHashMoveEntryStub,
|
||||
PL_DHashClearEntryStub,
|
||||
PLDHashTable::MoveEntryStub,
|
||||
PLDHashTable::ClearEntryStub,
|
||||
nullptr
|
||||
};
|
||||
|
||||
@@ -248,8 +248,8 @@ struct DateHashEntry : public PLDHashEntryHdr {
|
||||
static const PLDHashTableOps gDateTableOps = {
|
||||
DateHashEntry::HashKey,
|
||||
DateHashEntry::MatchEntry,
|
||||
PL_DHashMoveEntryStub,
|
||||
PL_DHashClearEntryStub,
|
||||
PLDHashTable::MoveEntryStub,
|
||||
PLDHashTable::ClearEntryStub,
|
||||
nullptr
|
||||
};
|
||||
|
||||
@@ -365,8 +365,8 @@ struct BlobHashEntry : public PLDHashEntryHdr {
|
||||
static const PLDHashTableOps gBlobTableOps = {
|
||||
BlobHashEntry::HashKey,
|
||||
BlobHashEntry::MatchEntry,
|
||||
PL_DHashMoveEntryStub,
|
||||
PL_DHashClearEntryStub,
|
||||
PLDHashTable::MoveEntryStub,
|
||||
PLDHashTable::ClearEntryStub,
|
||||
nullptr
|
||||
};
|
||||
|
||||
|
||||
@@ -107,9 +107,9 @@ class nsCertOverrideEntry final : public PLDHashEntryHdr
|
||||
|
||||
static PLDHashNumber HashKey(KeyTypePointer aKey)
|
||||
{
|
||||
// PL_DHashStringKey doesn't use the table parameter, so we can safely
|
||||
// pass nullptr
|
||||
return PL_DHashStringKey(nullptr, aKey);
|
||||
// PLDHashTable::HashStringKey doesn't use the table parameter, so we can
|
||||
// safely pass nullptr
|
||||
return PLDHashTable::HashStringKey(nullptr, aKey);
|
||||
}
|
||||
|
||||
enum { ALLOW_MEMMOVE = false };
|
||||
|
||||
@@ -84,9 +84,9 @@ CompareCacheClearEntry(PLDHashTable *table, PLDHashEntryHdr *hdr)
|
||||
}
|
||||
|
||||
static const PLDHashTableOps gMapOps = {
|
||||
PL_DHashVoidPtrKeyStub,
|
||||
PLDHashTable::HashVoidPtrKeyStub,
|
||||
CompareCacheMatchEntry,
|
||||
PL_DHashMoveEntryStub,
|
||||
PLDHashTable::MoveEntryStub,
|
||||
CompareCacheClearEntry,
|
||||
CompareCacheInitEntry
|
||||
};
|
||||
|
||||
@@ -87,9 +87,9 @@ class nsClientAuthRememberEntry final : public PLDHashEntryHdr
|
||||
|
||||
static PLDHashNumber HashKey(KeyTypePointer aKey)
|
||||
{
|
||||
// PL_DHashStringKey doesn't use the table parameter, so we can safely
|
||||
// pass nullptr
|
||||
return PL_DHashStringKey(nullptr, aKey);
|
||||
// PLDHashTable::HashStringKey doesn't use the table parameter, so we can
|
||||
// safely pass nullptr
|
||||
return PLDHashTable::HashStringKey(nullptr, aKey);
|
||||
}
|
||||
|
||||
enum { ALLOW_MEMMOVE = false };
|
||||
|
||||
@@ -29,10 +29,10 @@ ObjectSetInitEntry(PLDHashEntryHdr *hdr, const void *key)
|
||||
}
|
||||
|
||||
static const PLDHashTableOps gSetOps = {
|
||||
PL_DHashVoidPtrKeyStub,
|
||||
PLDHashTable::HashVoidPtrKeyStub,
|
||||
ObjectSetMatchEntry,
|
||||
PL_DHashMoveEntryStub,
|
||||
PL_DHashClearEntryStub,
|
||||
PLDHashTable::MoveEntryStub,
|
||||
PLDHashTable::ClearEntryStub,
|
||||
ObjectSetInitEntry
|
||||
};
|
||||
|
||||
|
||||
@@ -70,10 +70,10 @@ RequestMapInitEntry(PLDHashEntryHdr *hdr, const void *key)
|
||||
}
|
||||
|
||||
static const PLDHashTableOps gMapOps = {
|
||||
PL_DHashVoidPtrKeyStub,
|
||||
PLDHashTable::HashVoidPtrKeyStub,
|
||||
RequestMapMatchEntry,
|
||||
PL_DHashMoveEntryStub,
|
||||
PL_DHashClearEntryStub,
|
||||
PLDHashTable::MoveEntryStub,
|
||||
PLDHashTable::ClearEntryStub,
|
||||
RequestMapInitEntry
|
||||
};
|
||||
|
||||
|
||||
@@ -3,5 +3,5 @@
|
||||
"digest": "3b2d18eb0194d82c70c5ee17487ccbac309f9b2e9839fe7ca4a27a9a06f6338bb24394476da78559685d99151fccc85fdde03297aa73ee2f7fb3183e11925c4d",
|
||||
"algorithm": "sha512",
|
||||
"filename": "AVDs-x86-android-4.2_r1-build-2013-11-13-ubuntu.tar.gz",
|
||||
"unpack": "True"
|
||||
"unpack": true
|
||||
}]
|
||||
|
||||
@@ -38,9 +38,7 @@ config = {
|
||||
'tools_dir': "/tools",
|
||||
'compiler_manifest': "build/gcc.manifest",
|
||||
'b2g_compiler_manifest': "build/gcc-b2g.manifest",
|
||||
'compiler_setup': "setup.sh.gcc",
|
||||
'sixgill_manifest': "build/sixgill.manifest",
|
||||
'sixgill_setup': "setup.sh.sixgill",
|
||||
|
||||
# Mock.
|
||||
"mock_packages": [
|
||||
|
||||
@@ -272,14 +272,14 @@ class B2GHazardBuild(PurgeMixin, B2GBuildBaseScript):
|
||||
|
||||
def get_blobs(self):
|
||||
dirs = self.query_abs_dirs()
|
||||
self.tooltool_fetch(self.query_compiler_manifest(), "sh " + self.config['compiler_setup'],
|
||||
dirs['abs_work_dir'])
|
||||
self.tooltool_fetch(self.query_sixgill_manifest(), "sh " + self.config['sixgill_setup'],
|
||||
dirs['abs_work_dir'])
|
||||
self.tooltool_fetch(self.query_compiler_manifest(),
|
||||
output_dir=dirs['abs_work_dir'])
|
||||
self.tooltool_fetch(self.query_sixgill_manifest(),
|
||||
output_dir=dirs['abs_work_dir'])
|
||||
if not os.path.exists(dirs['target_compiler_base']):
|
||||
self.mkdir_p(dirs['target_compiler_base'])
|
||||
self.tooltool_fetch(self.query_b2g_compiler_manifest(), "sh " + self.config['compiler_setup'],
|
||||
dirs['target_compiler_base'])
|
||||
self.tooltool_fetch(self.query_b2g_compiler_manifest(),
|
||||
output_dir=dirs['target_compiler_base'])
|
||||
|
||||
def clobber_shell(self):
|
||||
dirs = self.query_abs_dirs()
|
||||
|
||||
@@ -387,10 +387,10 @@ class SpidermonkeyBuild(MockMixin,
|
||||
work_dir = self.query_abs_dirs()['abs_work_dir']
|
||||
if not os.path.exists(work_dir):
|
||||
self.mkdir_p(work_dir)
|
||||
self.tooltool_fetch(self.query_compiler_manifest(), "sh " + self.config['compiler_setup'],
|
||||
work_dir)
|
||||
self.tooltool_fetch(self.query_sixgill_manifest(), "sh " + self.config['sixgill_setup'],
|
||||
work_dir)
|
||||
self.tooltool_fetch(self.query_compiler_manifest(),
|
||||
output_dir=work_dir)
|
||||
self.tooltool_fetch(self.query_sixgill_manifest(),
|
||||
output_dir=work_dir)
|
||||
|
||||
def clobber_shell(self):
|
||||
self.analysis.clobber_shell(self)
|
||||
|
||||
@@ -95,9 +95,9 @@ class nsDefaultComparator <nsDocLoader::nsListenerInfo, nsIWebProgressListener*>
|
||||
|
||||
/* static */ const PLDHashTableOps nsDocLoader::sRequestInfoHashOps =
|
||||
{
|
||||
PL_DHashVoidPtrKeyStub,
|
||||
PL_DHashMatchEntryStub,
|
||||
PL_DHashMoveEntryStub,
|
||||
PLDHashTable::HashVoidPtrKeyStub,
|
||||
PLDHashTable::MatchEntryStub,
|
||||
PLDHashTable::MoveEntryStub,
|
||||
nsDocLoader::RequestInfoHashClearEntry,
|
||||
nsDocLoader::RequestInfoHashInitEntry
|
||||
};
|
||||
|
||||
@@ -794,10 +794,10 @@ PtrToNodeMatchEntry(PLDHashTable* aTable,
|
||||
}
|
||||
|
||||
static PLDHashTableOps PtrNodeOps = {
|
||||
PL_DHashVoidPtrKeyStub,
|
||||
PLDHashTable::HashVoidPtrKeyStub,
|
||||
PtrToNodeMatchEntry,
|
||||
PL_DHashMoveEntryStub,
|
||||
PL_DHashClearEntryStub,
|
||||
PLDHashTable::MoveEntryStub,
|
||||
PLDHashTable::ClearEntryStub,
|
||||
nullptr
|
||||
};
|
||||
|
||||
|
||||
+25
-11
@@ -136,6 +136,18 @@ extern nsresult nsStringInputStreamConstructor(nsISupports*, REFNSIID, void**);
|
||||
#include "mozilla/ipc/GeckoChildProcessHost.h"
|
||||
|
||||
#include "ogg/ogg.h"
|
||||
#if defined(MOZ_VPX) && !defined(MOZ_VPX_NO_MEM_REPORTING)
|
||||
#if defined(HAVE_STDINT_H)
|
||||
// mozilla-config.h defines HAVE_STDINT_H, and then it's defined *again* in
|
||||
// vpx_config.h (which we include via vpx_mem.h, below). This redefinition
|
||||
// triggers a build warning on MSVC, so we have to #undef it first.
|
||||
#undef HAVE_STDINT_H
|
||||
#endif
|
||||
#include "vpx_mem/vpx_mem.h"
|
||||
#endif
|
||||
#ifdef MOZ_WEBM
|
||||
#include "nestegg/nestegg.h"
|
||||
#endif
|
||||
|
||||
#include "GeckoProfiler.h"
|
||||
|
||||
@@ -594,17 +606,6 @@ NS_InitXPCOM2(nsIServiceManager** aResult,
|
||||
xpcomLib->GetPath(path);
|
||||
gGREBinPath = ToNewUnicode(path);
|
||||
|
||||
#ifdef XP_MACOSX
|
||||
nsCOMPtr<nsIFile> parent;
|
||||
xpcomLib->GetParent(getter_AddRefs(parent));
|
||||
parent->AppendNative(NS_LITERAL_CSTRING("MacOS"));
|
||||
bool pathExists = false;
|
||||
parent->Exists(&pathExists);
|
||||
if (pathExists) {
|
||||
xpcomLib = parent.forget();
|
||||
}
|
||||
#endif
|
||||
|
||||
xpcomLib->AppendNative(nsDependentCString(XPCOM_DLL));
|
||||
nsDirectoryService::gService->Set(NS_XPCOM_LIBRARY_FILE, xpcomLib);
|
||||
|
||||
@@ -669,6 +670,16 @@ NS_InitXPCOM2(nsIServiceManager** aResult,
|
||||
OggReporter::CountingRealloc,
|
||||
OggReporter::CountingFree);
|
||||
|
||||
#if defined(MOZ_VPX) && !defined(MOZ_VPX_NO_MEM_REPORTING)
|
||||
// And for VPX.
|
||||
vpx_mem_set_functions(VPXReporter::CountingMalloc,
|
||||
VPXReporter::CountingCalloc,
|
||||
VPXReporter::CountingRealloc,
|
||||
VPXReporter::CountingFree,
|
||||
memcpy,
|
||||
memset,
|
||||
memmove);
|
||||
#endif
|
||||
|
||||
// Initialize the JS engine.
|
||||
if (!JS_Init()) {
|
||||
@@ -723,6 +734,9 @@ NS_InitXPCOM2(nsIServiceManager** aResult,
|
||||
#ifdef MOZ_VPX
|
||||
RegisterStrongMemoryReporter(new VPXReporter());
|
||||
#endif
|
||||
#ifdef MOZ_WEBM
|
||||
RegisterStrongMemoryReporter(new NesteggReporter());
|
||||
#endif
|
||||
|
||||
mozilla::HangMonitor::Startup();
|
||||
mozilla::BackgroundHangMonitor::Startup();
|
||||
|
||||
@@ -289,7 +289,7 @@ AtomTableInitEntry(PLDHashEntryHdr* aEntry, const void* aKey)
|
||||
static const PLDHashTableOps AtomTableOps = {
|
||||
AtomTableGetHash,
|
||||
AtomTableMatchKey,
|
||||
PL_DHashMoveEntryStub,
|
||||
PLDHashTable::MoveEntryStub,
|
||||
AtomTableClearEntry,
|
||||
AtomTableInitEntry
|
||||
};
|
||||
|
||||
@@ -51,10 +51,10 @@ ArenaStrdup(const nsAFlatCString& aString, PLArenaPool* aArena)
|
||||
}
|
||||
|
||||
static const struct PLDHashTableOps property_HashTableOps = {
|
||||
PL_DHashStringKey,
|
||||
PL_DHashMatchStringKey,
|
||||
PL_DHashMoveEntryStub,
|
||||
PL_DHashClearEntryStub,
|
||||
PLDHashTable::HashStringKey,
|
||||
PLDHashTable::MatchStringKey,
|
||||
PLDHashTable::MoveEntryStub,
|
||||
PLDHashTable::ClearEntryStub,
|
||||
nullptr,
|
||||
};
|
||||
|
||||
|
||||
@@ -64,7 +64,7 @@ matchNameKeysCaseInsensitive(PLDHashTable*, const PLDHashEntryHdr* aHdr,
|
||||
}
|
||||
|
||||
/*
|
||||
* caseInsensitiveHashKey is just like PL_DHashStringKey except it
|
||||
* caseInsensitiveHashKey is just like PLDHashTable::HashStringKey except it
|
||||
* uses (*s & ~0x20) instead of simply *s. This means that "aFOO" and
|
||||
* "afoo" and "aFoo" will all hash to the same thing. It also means
|
||||
* that some strings that aren't case-insensensitively equal will hash
|
||||
@@ -96,8 +96,8 @@ caseInsensitiveStringHashKey(PLDHashTable* aTable, const void* aKey)
|
||||
static const struct PLDHashTableOps nametable_CaseInsensitiveHashTableOps = {
|
||||
caseInsensitiveStringHashKey,
|
||||
matchNameKeysCaseInsensitive,
|
||||
PL_DHashMoveEntryStub,
|
||||
PL_DHashClearEntryStub,
|
||||
PLDHashTable::MoveEntryStub,
|
||||
PLDHashTable::ClearEntryStub,
|
||||
nullptr,
|
||||
};
|
||||
|
||||
@@ -147,7 +147,7 @@ nsStaticCaseInsensitiveNameTable::nsStaticCaseInsensitiveNameTable(
|
||||
entry->mIndex = index;
|
||||
}
|
||||
#ifdef DEBUG
|
||||
PL_DHashMarkTableImmutable(&mNameTable);
|
||||
mNameTable.MarkImmutable();
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
@@ -282,7 +282,7 @@ public:
|
||||
*/
|
||||
void MarkImmutable()
|
||||
{
|
||||
PL_DHashMarkTableImmutable(&mTable);
|
||||
mTable.MarkImmutable();
|
||||
}
|
||||
#endif
|
||||
|
||||
@@ -345,7 +345,7 @@ nsTHashtable<EntryType>::Ops()
|
||||
{
|
||||
s_HashKey,
|
||||
s_MatchEntry,
|
||||
EntryType::ALLOW_MEMMOVE ? ::PL_DHashMoveEntryStub : s_CopyEntry,
|
||||
EntryType::ALLOW_MEMMOVE ? PLDHashTable::MoveEntryStub : s_CopyEntry,
|
||||
s_ClearEntry,
|
||||
s_InitEntry
|
||||
};
|
||||
|
||||
+28
-47
@@ -62,32 +62,32 @@ public:
|
||||
|
||||
#endif
|
||||
|
||||
PLDHashNumber
|
||||
PL_DHashStringKey(PLDHashTable* aTable, const void* aKey)
|
||||
/* static */ PLDHashNumber
|
||||
PLDHashTable::HashStringKey(PLDHashTable* aTable, const void* aKey)
|
||||
{
|
||||
return HashString(static_cast<const char*>(aKey));
|
||||
}
|
||||
|
||||
PLDHashNumber
|
||||
PL_DHashVoidPtrKeyStub(PLDHashTable* aTable, const void* aKey)
|
||||
/* static */ PLDHashNumber
|
||||
PLDHashTable::HashVoidPtrKeyStub(PLDHashTable* aTable, const void* aKey)
|
||||
{
|
||||
return (PLDHashNumber)(ptrdiff_t)aKey >> 2;
|
||||
}
|
||||
|
||||
bool
|
||||
PL_DHashMatchEntryStub(PLDHashTable* aTable,
|
||||
const PLDHashEntryHdr* aEntry,
|
||||
const void* aKey)
|
||||
/* static */ bool
|
||||
PLDHashTable::MatchEntryStub(PLDHashTable* aTable,
|
||||
const PLDHashEntryHdr* aEntry,
|
||||
const void* aKey)
|
||||
{
|
||||
const PLDHashEntryStub* stub = (const PLDHashEntryStub*)aEntry;
|
||||
|
||||
return stub->key == aKey;
|
||||
}
|
||||
|
||||
bool
|
||||
PL_DHashMatchStringKey(PLDHashTable* aTable,
|
||||
const PLDHashEntryHdr* aEntry,
|
||||
const void* aKey)
|
||||
/* static */ bool
|
||||
PLDHashTable::MatchStringKey(PLDHashTable* aTable,
|
||||
const PLDHashEntryHdr* aEntry,
|
||||
const void* aKey)
|
||||
{
|
||||
const PLDHashEntryStub* stub = (const PLDHashEntryStub*)aEntry;
|
||||
|
||||
@@ -97,45 +97,32 @@ PL_DHashMatchStringKey(PLDHashTable* aTable,
|
||||
strcmp((const char*)stub->key, (const char*)aKey) == 0);
|
||||
}
|
||||
|
||||
MOZ_ALWAYS_INLINE void
|
||||
PLDHashTable::MoveEntryStub(const PLDHashEntryHdr* aFrom,
|
||||
/* static */ void
|
||||
PLDHashTable::MoveEntryStub(PLDHashTable* aTable,
|
||||
const PLDHashEntryHdr* aFrom,
|
||||
PLDHashEntryHdr* aTo)
|
||||
{
|
||||
memcpy(aTo, aFrom, mEntrySize);
|
||||
memcpy(aTo, aFrom, aTable->mEntrySize);
|
||||
}
|
||||
|
||||
void
|
||||
PL_DHashMoveEntryStub(PLDHashTable* aTable,
|
||||
const PLDHashEntryHdr* aFrom,
|
||||
PLDHashEntryHdr* aTo)
|
||||
/* static */ void
|
||||
PLDHashTable::ClearEntryStub(PLDHashTable* aTable, PLDHashEntryHdr* aEntry)
|
||||
{
|
||||
aTable->MoveEntryStub(aFrom, aTo);
|
||||
memset(aEntry, 0, aTable->mEntrySize);
|
||||
}
|
||||
|
||||
MOZ_ALWAYS_INLINE void
|
||||
PLDHashTable::ClearEntryStub(PLDHashEntryHdr* aEntry)
|
||||
{
|
||||
memset(aEntry, 0, mEntrySize);
|
||||
}
|
||||
|
||||
void
|
||||
PL_DHashClearEntryStub(PLDHashTable* aTable, PLDHashEntryHdr* aEntry)
|
||||
{
|
||||
aTable->ClearEntryStub(aEntry);
|
||||
}
|
||||
|
||||
static const PLDHashTableOps stub_ops = {
|
||||
PL_DHashVoidPtrKeyStub,
|
||||
PL_DHashMatchEntryStub,
|
||||
PL_DHashMoveEntryStub,
|
||||
PL_DHashClearEntryStub,
|
||||
static const PLDHashTableOps gStubOps = {
|
||||
PLDHashTable::HashVoidPtrKeyStub,
|
||||
PLDHashTable::MatchEntryStub,
|
||||
PLDHashTable::MoveEntryStub,
|
||||
PLDHashTable::ClearEntryStub,
|
||||
nullptr
|
||||
};
|
||||
|
||||
const PLDHashTableOps*
|
||||
PL_DHashGetStubOps(void)
|
||||
/* static */ const PLDHashTableOps*
|
||||
PLDHashTable::StubOps()
|
||||
{
|
||||
return &stub_ops;
|
||||
return &gStubOps;
|
||||
}
|
||||
|
||||
static bool
|
||||
@@ -853,16 +840,10 @@ PLDHashTable::Iterator::Remove()
|
||||
}
|
||||
|
||||
#ifdef DEBUG
|
||||
MOZ_ALWAYS_INLINE void
|
||||
void
|
||||
PLDHashTable::MarkImmutable()
|
||||
{
|
||||
mChecker.SetNonWritable();
|
||||
}
|
||||
|
||||
void
|
||||
PL_DHashMarkTableImmutable(PLDHashTable* aTable)
|
||||
{
|
||||
aTable->MarkImmutable();
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
+18
-40
@@ -398,9 +398,24 @@ public:
|
||||
void MarkImmutable();
|
||||
#endif
|
||||
|
||||
void MoveEntryStub(const PLDHashEntryHdr* aFrom, PLDHashEntryHdr* aTo);
|
||||
// If you use PLDHashEntryStub or a subclass of it as your entry struct, and
|
||||
// if your entries move via memcpy and clear via memset(0), you can use these
|
||||
// stub operations.
|
||||
static const PLDHashTableOps* StubOps();
|
||||
|
||||
void ClearEntryStub(PLDHashEntryHdr* aEntry);
|
||||
// The individual stub operations in StubOps().
|
||||
static PLDHashNumber HashVoidPtrKeyStub(PLDHashTable* aTable,
|
||||
const void* aKey);
|
||||
static bool MatchEntryStub(PLDHashTable* aTable,
|
||||
const PLDHashEntryHdr* aEntry, const void* aKey);
|
||||
static void MoveEntryStub(PLDHashTable* aTable, const PLDHashEntryHdr* aFrom,
|
||||
PLDHashEntryHdr* aTo);
|
||||
static void ClearEntryStub(PLDHashTable* aTable, PLDHashEntryHdr* aEntry);
|
||||
|
||||
// Hash/match operations for tables holding C strings.
|
||||
static PLDHashNumber HashStringKey(PLDHashTable* aTable, const void* aKey);
|
||||
static bool MatchStringKey(PLDHashTable* aTable,
|
||||
const PLDHashEntryHdr* aEntry, const void* aKey);
|
||||
|
||||
// This is an iterator for PLDHashtable. Assertions will detect some, but not
|
||||
// all, mid-iteration table modifications that might invalidate (e.g.
|
||||
@@ -582,47 +597,10 @@ struct PLDHashTableOps
|
||||
PLDHashInitEntry initEntry;
|
||||
};
|
||||
|
||||
// Default implementations for the above mOps.
|
||||
|
||||
PLDHashNumber
|
||||
PL_DHashStringKey(PLDHashTable* aTable, const void* aKey);
|
||||
|
||||
// A minimal entry is a subclass of PLDHashEntryHdr and has void key pointer.
|
||||
// A minimal entry is a subclass of PLDHashEntryHdr and has a void* key pointer.
|
||||
struct PLDHashEntryStub : public PLDHashEntryHdr
|
||||
{
|
||||
const void* key;
|
||||
};
|
||||
|
||||
PLDHashNumber
|
||||
PL_DHashVoidPtrKeyStub(PLDHashTable* aTable, const void* aKey);
|
||||
|
||||
bool
|
||||
PL_DHashMatchEntryStub(PLDHashTable* aTable,
|
||||
const PLDHashEntryHdr* aEntry,
|
||||
const void* aKey);
|
||||
|
||||
bool
|
||||
PL_DHashMatchStringKey(PLDHashTable* aTable,
|
||||
const PLDHashEntryHdr* aEntry,
|
||||
const void* aKey);
|
||||
|
||||
void
|
||||
PL_DHashMoveEntryStub(PLDHashTable* aTable,
|
||||
const PLDHashEntryHdr* aFrom,
|
||||
PLDHashEntryHdr* aTo);
|
||||
|
||||
void
|
||||
PL_DHashClearEntryStub(PLDHashTable* aTable, PLDHashEntryHdr* aEntry);
|
||||
|
||||
// If you use PLDHashEntryStub or a subclass of it as your entry struct, and
|
||||
// if your entries move via memcpy and clear via memset(0), you can use these
|
||||
// stub operations.
|
||||
const PLDHashTableOps*
|
||||
PL_DHashGetStubOps(void);
|
||||
|
||||
#ifdef DEBUG
|
||||
void
|
||||
PL_DHashMarkTableImmutable(PLDHashTable* aTable);
|
||||
#endif
|
||||
|
||||
#endif /* pldhash_h___ */
|
||||
|
||||
@@ -77,7 +77,7 @@ TestCrashyOperation(void (*aCrashyOperation)())
|
||||
void
|
||||
InitCapacityOk_InitialLengthTooBig()
|
||||
{
|
||||
PLDHashTable t(PL_DHashGetStubOps(), sizeof(PLDHashEntryStub),
|
||||
PLDHashTable t(PLDHashTable::StubOps(), sizeof(PLDHashEntryStub),
|
||||
PLDHashTable::kMaxInitialLength + 1);
|
||||
}
|
||||
|
||||
@@ -87,7 +87,7 @@ InitCapacityOk_InitialEntryStoreTooBig()
|
||||
// Try the smallest disallowed power-of-two entry store size, which is 2^32
|
||||
// bytes (which overflows to 0). (Note that the 2^23 *length* gets converted
|
||||
// to a 2^24 *capacity*.)
|
||||
PLDHashTable t(PL_DHashGetStubOps(), (uint32_t)1 << 23, (uint32_t)1 << 8);
|
||||
PLDHashTable t(PLDHashTable::StubOps(), (uint32_t)1 << 23, (uint32_t)1 << 8);
|
||||
}
|
||||
|
||||
TEST(PLDHashTableTest, InitCapacityOk)
|
||||
@@ -95,12 +95,12 @@ TEST(PLDHashTableTest, InitCapacityOk)
|
||||
// Try the largest allowed capacity. With kMaxCapacity==1<<26, this
|
||||
// would allocate (if we added an element) 0.5GB of entry store on 32-bit
|
||||
// platforms and 1GB on 64-bit platforms.
|
||||
PLDHashTable t1(PL_DHashGetStubOps(), sizeof(PLDHashEntryStub),
|
||||
PLDHashTable t1(PLDHashTable::StubOps(), sizeof(PLDHashEntryStub),
|
||||
PLDHashTable::kMaxInitialLength);
|
||||
|
||||
// Try the largest allowed power-of-two entry store size, which is 2^31 bytes
|
||||
// (Note that the 2^23 *length* gets converted to a 2^24 *capacity*.)
|
||||
PLDHashTable t2(PL_DHashGetStubOps(), (uint32_t)1 << 23, (uint32_t)1 << 7);
|
||||
PLDHashTable t2(PLDHashTable::StubOps(), (uint32_t)1 << 23, (uint32_t)1 << 7);
|
||||
|
||||
// Try a too-large capacity (which aborts).
|
||||
TestCrashyOperation(InitCapacityOk_InitialLengthTooBig);
|
||||
@@ -117,7 +117,7 @@ TEST(PLDHashTableTest, InitCapacityOk)
|
||||
|
||||
TEST(PLDHashTableTest, LazyStorage)
|
||||
{
|
||||
PLDHashTable t(PL_DHashGetStubOps(), sizeof(PLDHashEntryStub));
|
||||
PLDHashTable t(PLDHashTable::StubOps(), sizeof(PLDHashEntryStub));
|
||||
|
||||
// PLDHashTable allocates entry storage lazily. Check that all the non-add
|
||||
// operations work appropriately when the table is empty and the storage
|
||||
@@ -158,9 +158,9 @@ TrivialInitEntry(PLDHashEntryHdr* aEntry, const void* aKey)
|
||||
|
||||
static const PLDHashTableOps trivialOps = {
|
||||
TrivialHash,
|
||||
PL_DHashMatchEntryStub,
|
||||
PL_DHashMoveEntryStub,
|
||||
PL_DHashClearEntryStub,
|
||||
PLDHashTable::MatchEntryStub,
|
||||
PLDHashTable::MoveEntryStub,
|
||||
PLDHashTable::ClearEntryStub,
|
||||
TrivialInitEntry
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user