From e299ac7d5b1e7af7940766e1232f6e425029fab6 Mon Sep 17 00:00:00 2001 From: Khem Raj Date: Fri, 14 Oct 2016 05:04:07 -0700 Subject: binutils: Fix gas error with cfi_section inconsistencies This error is visible when using clang but not when using gcc this has been reported and fixed upstream. llvm bug https://llvm.org/bugs/show_bug.cgi?id=29017 binutils bug https://sourceware.org/bugzilla/show_bug.cgi?id=20648 (From OE-Core rev: e5a81575f11dc2a0ec9ee4184514750d2dbd09aa) Signed-off-by: Khem Raj Signed-off-by: Ross Burton Signed-off-by: Richard Purdie hand merged to apply against 2.26 Signed-off-by: Armin Kuster --- meta/recipes-devtools/binutils/binutils-2.26.inc | 1 + ..._sections-check-to-only-consider-compact-.patch | 97 ++++++++++++++++++++++ 2 files changed, 98 insertions(+) create mode 100644 meta/recipes-devtools/binutils/binutils/0015-Refine-.cfi_sections-check-to-only-consider-compact-.patch diff --git a/meta/recipes-devtools/binutils/binutils-2.26.inc b/meta/recipes-devtools/binutils/binutils-2.26.inc index 4b33b04238..283167c718 100644 --- a/meta/recipes-devtools/binutils/binutils-2.26.inc +++ b/meta/recipes-devtools/binutils/binutils-2.26.inc @@ -36,6 +36,7 @@ SRC_URI = "\ file://0014-Correct-nios2-_gp-address-computation.patch \ file://0015-allow-zero-length-elements.patch \ file://aarch64-tls.patch \ + file://0015-Refine-.cfi_sections-check-to-only-consider-compact-.patch \ " S = "${WORKDIR}/git" diff --git a/meta/recipes-devtools/binutils/binutils/0015-Refine-.cfi_sections-check-to-only-consider-compact-.patch b/meta/recipes-devtools/binutils/binutils/0015-Refine-.cfi_sections-check-to-only-consider-compact-.patch new file mode 100644 index 0000000000..f3e3a11b14 --- /dev/null +++ b/meta/recipes-devtools/binutils/binutils/0015-Refine-.cfi_sections-check-to-only-consider-compact-.patch @@ -0,0 +1,97 @@ +From 3d3424e9a8d6ad56160b98bf6e223c0346164468 Mon Sep 17 00:00:00 2001 +From: Matthew Fortune +Date: Thu, 29 Sep 2016 11:13:46 +0100 +Subject: [PATCH] Refine .cfi_sections check to only consider compact eh_frame + +The .cfi_sections directive can be safely used multiple times +with different sections named at any time unless the compact form +of exception handling is requested after CFI information has +been emitted. Only the compact form of CFI information changes +the way in which CFI is generated and therefore cannot be +retrospectively requested after generating CFI information. + +gas/ + + PR gas/20648 + * dw2gencfi.c (dot_cfi_sections): Refine the check for + inconsistent .cfi_sections to only consider compact vs non + compact forms. + * testsuite/gas/cfi/cfi-common-9.d: New file. + * testsuite/gas/cfi/cfi-common-9.s: New file. + * testsuite/gas/cfi/cfi.exp: Run new test. +--- +Upstream-Status: Backport +Signed-off-by: Khem Raj