From b5512915d73328788020be659b49f93fa3afd212 Mon Sep 17 00:00:00 2001 From: Tony Kelman Date: Sun, 4 May 2014 14:10:17 -0700 Subject: [PATCH] Add libunwind patch from Pyston --- ...alidation-heuristic-to-allow-size-0-.patch | 22 +++++++++++++++++++ deps/Makefile | 1 + 2 files changed, 23 insertions(+) create mode 100644 deps/0001-Change-the-RBP-validation-heuristic-to-allow-size-0-.patch diff --git a/deps/0001-Change-the-RBP-validation-heuristic-to-allow-size-0-.patch b/deps/0001-Change-the-RBP-validation-heuristic-to-allow-size-0-.patch new file mode 100644 index 0000000000000..1d12a81af7a91 --- /dev/null +++ b/deps/0001-Change-the-RBP-validation-heuristic-to-allow-size-0-.patch @@ -0,0 +1,22 @@ +From e1d7c78d95e4b73a311f10149d0a54547d307d5d Mon Sep 17 00:00:00 2001 +From: Kevin Modzelewski +Date: Tue, 22 Apr 2014 15:50:40 -0700 +Subject: [PATCH] Change the RBP-validation heuristic to allow size-0 call frames + +--- +diff --git a/src/x86_64/Gstep.c b/src/x86_64/Gstep.c +index 9fa0967..809d60b 100644 +--- a/src/x86_64/Gstep.c ++++ b/src/x86_64/Gstep.c +@@ -173,7 +173,7 @@ unw_step (unw_cursor_t *cursor) + anything about new RBP (rbp1) since it may not be a frame + pointer in the frame above. Just check we get the value. */ + if (ret < 0 +- || rbp <= c->dwarf.cfa ++ || rbp < c->dwarf.cfa + || (rbp - c->dwarf.cfa) > 0x4000) + { + rip_loc = DWARF_NULL_LOC; +-- +1.7.4.1 + diff --git a/deps/Makefile b/deps/Makefile index d34be4b394ef8..2b34ea364dc8e 100644 --- a/deps/Makefile +++ b/deps/Makefile @@ -1303,6 +1303,7 @@ libunwind-$(UNWIND_VER).tar.gz: $(JLDOWNLOAD) $@ http://download.savannah.gnu.org/releases/libunwind/$@ libunwind-$(UNWIND_VER)/configure: libunwind-$(UNWIND_VER).tar.gz $(TAR) xfz $< + cd libunwind-$(UNWIND_VER) && patch -p1 < ../0001-Change-the-RBP-validation-heuristic-to-allow-size-0-.patch touch -c $@ libunwind-$(UNWIND_VER)/config.status: libunwind-$(UNWIND_VER)/configure cd libunwind-$(UNWIND_VER) && \