зеркало из https://github.com/mozilla/gecko-dev.git
Bug 748654 - drop patch making us use mozalloc in angle - r=jgilbert
This commit is contained in:
Родитель
c25e00d46c
Коммит
3e01d03f6d
|
@ -140,8 +140,6 @@ DEFINES += -DANGLE_USE_NSPR -DANGLE_BUILD -DCOMPILER_IMPLEMENTATION
|
|||
DEFINES += -DANGLE_DISABLE_TRACE
|
||||
DEFINES += -DANGLE_COMPILE_OPTIMIZATION_LEVEL=D3DCOMPILE_OPTIMIZATION_LEVEL0
|
||||
|
||||
EXTRA_DSO_LDOPTS = $(MOZALLOC_LIB)
|
||||
|
||||
ifdef MOZ_ANGLE
|
||||
|
||||
# libEGL depends on (links against!) libGLESv2!
|
||||
|
|
|
@ -53,8 +53,6 @@ NVIDIA HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
|||
#include "compiler/compilerdebug.h"
|
||||
#include "compiler/preprocessor/slglobals.h"
|
||||
|
||||
#include "../../../../../memory/mozalloc/mozalloc.h"
|
||||
|
||||
#undef malloc
|
||||
#undef realloc
|
||||
#undef free
|
||||
|
@ -325,13 +323,21 @@ static int GrowAtomTable(AtomTable *atable, int size)
|
|||
|
||||
if (atable->size < size) {
|
||||
if (atable->amap) {
|
||||
newmap = moz_xrealloc(atable->amap, sizeof(int)*size);
|
||||
newrev = moz_xrealloc(atable->arev, sizeof(int)*size);
|
||||
newmap = realloc(atable->amap, sizeof(int)*size);
|
||||
newrev = realloc(atable->arev, sizeof(int)*size);
|
||||
} else {
|
||||
newmap = moz_xmalloc(sizeof(int)*size);
|
||||
newrev = moz_xmalloc(sizeof(int)*size);
|
||||
newmap = malloc(sizeof(int)*size);
|
||||
newrev = malloc(sizeof(int)*size);
|
||||
atable->size = 0;
|
||||
}
|
||||
if (!newmap || !newrev) {
|
||||
/* failed to grow -- error */
|
||||
if (newmap)
|
||||
atable->amap = newmap;
|
||||
if (newrev)
|
||||
atable->arev = newrev;
|
||||
return -1;
|
||||
}
|
||||
memset(&newmap[atable->size], 0, (size - atable->size) * sizeof(int));
|
||||
memset(&newrev[atable->size], 0, (size - atable->size) * sizeof(int));
|
||||
atable->amap = newmap;
|
||||
|
|
|
@ -166,5 +166,3 @@ EXTRA_DSO_LDOPTS = "$(MOZ_DIRECTX_SDK_PATH)/lib/$(MOZ_DIRECTX_SDK_CPU_SUFFIX)/d3
|
|||
dwmapi.lib \
|
||||
delayimp.lib \
|
||||
/delayload:dwmapi.dll
|
||||
|
||||
EXTRA_DSO_LDOPTS += $(MOZALLOC_LIB)
|
||||
|
|
|
@ -175,5 +175,3 @@ include $(topsrcdir)/config/rules.mk
|
|||
EXTRA_DSO_LDOPTS = "$(MOZ_DIRECTX_SDK_PATH)/lib/$(MOZ_DIRECTX_SDK_CPU_SUFFIX)/d3d9.lib" \
|
||||
"$(MOZ_DIRECTX_SDK_PATH)/lib/$(MOZ_DIRECTX_SDK_CPU_SUFFIX)/d3dx9.lib" \
|
||||
"$(MOZ_DIRECTX_SDK_PATH)/lib/$(MOZ_DIRECTX_SDK_CPU_SUFFIX)/D3DCompiler.lib"
|
||||
|
||||
EXTRA_DSO_LDOPTS += $(MOZALLOC_LIB)
|
||||
|
|
Загрузка…
Ссылка в новой задаче