bugThe libunwind project - Bugs: bug #41018, [PATCH] Switch back to .code 16...


bug #41018: [PATCH] Switch back to .code 16 after switching to .code 32 in thumb assembly

Submitted by:  Bernhard Rosenkraenzer <bero>
Submitted on:  Fri 27 Dec 2013 08:52:33 PM UTC  
Category: NoneSeverity: 3 - Normal
Item Group: NoneStatus: None
Privacy: PublicAssigned to: None
Open/Closed: Closed

Add a New Comment(Rich Markup)

You are not logged in

Please log in, so followups can be emailed to you.


Fri 27 Dec 2013 08:52:33 PM UTC, original submission:

The ARM Thumb implementation of unw_tdep_getcontext switches to ARM mode (".code 32"), but doesn't switch back to Thumb mode.

In gcc, this is fine (it automatically switches back to Thumb mode at the end of an asm block), but in clang, this causes bad assembly output (thumb instructions generated by C/C++ code later on are interpreted as ARM mode assembly, which can't work).

Switching back to Thumb mode manually fixes clang, and is a no-op for gcc.

Bernhard Rosenkraenzer <bero>


(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach File(s):

Attached Files
file #30121:  libunwind-clang-asm-fix.patch added by bero (503B - text/x-patch - Fix)


Depends on the following items: None found

Items that depend on this one: None found


Carbon-Copy List
  • -unavailable- added by djwatson24 (Updated the item)
  • -unavailable- added by bero
  • -unavailable- added by bero (Submitted the item)

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.


    Please enter the title of George Orwell's famous dystopian book (it's a date):



    Follow 3 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Fri 13 Jan 2017 05:27:43 PM UTCdjwatson24Open/ClosedOpen=>Closed
    Fri 27 Dec 2013 08:52:33 PM UTCberoAttached File-=>Added libunwind-clang-asm-fix.patch, #30121
      Carbon-Copy-=>Added -unavailable-

    Back to the top

    Powered by Savane 3.1-cleanup1