diff options
author | Aliaksey Kandratsenka (aka Aliaksei Kandratsenka) <alkondratenko@gmail.com> | 2015-09-26 09:43:50 -0700 |
---|---|---|
committer | Aliaksey Kandratsenka (aka Aliaksei Kandratsenka) <alkondratenko@gmail.com> | 2015-09-26 09:43:50 -0700 |
commit | 7707582448d5bdf311d88726c5f77fcbb0bedd09 (patch) | |
tree | 23c20e99c9e6f932418c9b1d0cee49ecbe20878d | |
parent | 5078abdb331e63d7a216994f186eb736861f8df7 (diff) | |
parent | 9eb63bddfb7a8a7b086bb3daceeeaa2e3b1d8f67 (diff) | |
download | gperftools-7707582448d5bdf311d88726c5f77fcbb0bedd09.tar.gz |
Merge pull request #717 from myrsloik/master
Use correct mangled new and delete symbols on windows x64
-rw-r--r-- | src/windows/patch_functions.cc | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/windows/patch_functions.cc b/src/windows/patch_functions.cc index ff1bec7..52e3870 100644 --- a/src/windows/patch_functions.cc +++ b/src/windows/patch_functions.cc @@ -101,6 +101,16 @@ const int kMaxModules = 8182; // These are hard-coded, unfortunately. :-( They are also probably // compiler specific. See get_mangled_names.cc, in this directory, // for instructions on how to update these names for your compiler. +#ifdef _WIN64 +const char kMangledNew[] = "??2@YAPEAX_K@Z"; +const char kMangledNewArray[] = "??_U@YAPEAX_K@Z"; +const char kMangledDelete[] = "??3@YAXPEAX@Z"; +const char kMangledDeleteArray[] = "??_V@YAXPEAX@Z"; +const char kMangledNewNothrow[] = "??2@YAPEAX_KAEBUnothrow_t@std@@@Z"; +const char kMangledNewArrayNothrow[] = "??_U@YAPEAX_KAEBUnothrow_t@std@@@Z"; +const char kMangledDeleteNothrow[] = "??3@YAXPEAXAEBUnothrow_t@std@@@Z"; +const char kMangledDeleteArrayNothrow[] = "??_V@YAXPEAXAEBUnothrow_t@std@@@Z"; +#else const char kMangledNew[] = "??2@YAPAXI@Z"; const char kMangledNewArray[] = "??_U@YAPAXI@Z"; const char kMangledDelete[] = "??3@YAXPAX@Z"; @@ -109,6 +119,7 @@ const char kMangledNewNothrow[] = "??2@YAPAXIABUnothrow_t@std@@@Z"; const char kMangledNewArrayNothrow[] = "??_U@YAPAXIABUnothrow_t@std@@@Z"; const char kMangledDeleteNothrow[] = "??3@YAXPAXABUnothrow_t@std@@@Z"; const char kMangledDeleteArrayNothrow[] = "??_V@YAXPAXABUnothrow_t@std@@@Z"; +#endif // This is an unused but exported symbol that we can use to tell the // MSVC linker to bring in libtcmalloc, via the /INCLUDE linker flag. |