summaryrefslogtreecommitdiffstats
path: root/llvm/test/CodeGen/ARM/inlineasm-switch-mode-oneway-from-thumb.ll
Commit message (Collapse)AuthorAgeFilesLines
* Revert r265817Colin LeMahieu2016-04-081-1/+1
| | | | | | lld tests need to be addressed. llvm-svn: 265822
* [llvm-objdump] Printing hex instead of dec by defaultColin LeMahieu2016-04-081-1/+1
| | | | | | Differential Revision: http://reviews.llvm.org/D18770 llvm-svn: 265817
* Don't use "llc -filetype=obj" now that the codepath is the same.Rafael Espindola2014-01-241-1/+1
| | | | | | | r200011 remove the special codepaths in MC for inline asm, so we can now test all the logic with just llc + llvm-mc. llvm-svn: 200013
* Fix inline assembly that switches between ARM and Thumb modesGreg Fitzgerald2014-01-221-0/+18
This patch restores the ARM mode if the user's inline assembly does not. In the object streamer, it ensures that instructions following the inline assembly are encoded correctly and that correct mapping symbols are emitted. For the asm streamer, it emits a .arm or .thumb directive. This patch does not ensure that the inline assembly contains the ADR instruction to switch modes at runtime. The problem we need to solve is code like this: int foo(int a, int b) { int r = a + b; asm volatile( ".align 2 \n" ".arm \n" "add r0,r0,r0 \n" : : "r"(r)); return r+1; } If we compile this function in thumb mode then the inline assembly will switch to arm mode. We need to make sure that we switch back to thumb mode after emitting the inline assembly or we will incorrectly encode the instructions that follow (i.e. the assembly instructions for return r+1). Based on patch by David Peixotto Change-Id: Ib57f6d2d78a22afad5de8693fba6230ff56ba48b llvm-svn: 199818
OpenPOWER on IntegriCloud