diff options
author | Ian Rogers <irogers@google.com> | 2014-03-11 16:29:07 -0700 |
---|---|---|
committer | Ian Rogers <irogers@google.com> | 2014-03-11 16:29:07 -0700 |
commit | c6651298ef631d787a17c4f6f751bffe9e748a28 (patch) | |
tree | eac3ef112a805da566e851b2bab535df268ba8f1 | |
parent | d46a0b1c6bc5c1058085063f9ada94d5d6708bdc (diff) | |
download | art-c6651298ef631d787a17c4f6f751bffe9e748a28.zip art-c6651298ef631d787a17c4f6f751bffe9e748a28.tar.gz art-c6651298ef631d787a17c4f6f751bffe9e748a28.tar.bz2 |
Always reset CFI state.
.cfi_startproc simple may do even less than .cfi_startproc, so don't rely on
it. Instead, use regular .cfi_startporc and always set up the expected entry
state.
Change-Id: I6d3e8b8e4a07621bc99c062359a109eb76f85184
-rw-r--r-- | runtime/arch/arm/asm_support_arm.S | 4 | ||||
-rw-r--r-- | runtime/arch/mips/asm_support_mips.S | 4 | ||||
-rw-r--r-- | runtime/arch/x86/asm_support_x86.S | 3 | ||||
-rw-r--r-- | runtime/arch/x86_64/asm_support_x86_64.S | 3 |
4 files changed, 8 insertions, 6 deletions
diff --git a/runtime/arch/arm/asm_support_arm.S b/runtime/arch/arm/asm_support_arm.S index b421024..fb85feb 100644 --- a/runtime/arch/arm/asm_support_arm.S +++ b/runtime/arch/arm/asm_support_arm.S @@ -42,7 +42,9 @@ /* Cache alignment for function entry */ .balign 16 \name: - .cfi_startproc simple + .cfi_startproc + /* Ensure we get a sane starting CFA. */ + .cfi_def_cfa sp,0 .fnstart .endm diff --git a/runtime/arch/mips/asm_support_mips.S b/runtime/arch/mips/asm_support_mips.S index a14593b..d110b95 100644 --- a/runtime/arch/mips/asm_support_mips.S +++ b/runtime/arch/mips/asm_support_mips.S @@ -25,7 +25,9 @@ .global \name .balign 16 \name: - .cfi_startproc simple + .cfi_startproc + /* Ensure we get a sane starting CFA. */ + .cfi_def_cfa $sp,0 .endm .macro END name diff --git a/runtime/arch/x86/asm_support_x86.S b/runtime/arch/x86/asm_support_x86.S index 5bf7c55..e329530 100644 --- a/runtime/arch/x86/asm_support_x86.S +++ b/runtime/arch/x86/asm_support_x86.S @@ -104,8 +104,7 @@ MACRO1(DEFINE_FUNCTION, c_name) ALIGN_FUNCTION_ENTRY VAR(c_name, 0): CFI_STARTPROC - // TODO: we reset the CFA state here. It'd be better to use ".cfi_startproc simple" above but - // clang 3.4 doesn't support this. + // Ensure we get a sane starting CFA. CFI_DEF_CFA(esp, 4) END_MACRO diff --git a/runtime/arch/x86_64/asm_support_x86_64.S b/runtime/arch/x86_64/asm_support_x86_64.S index df2afb2..ca2489c 100644 --- a/runtime/arch/x86_64/asm_support_x86_64.S +++ b/runtime/arch/x86_64/asm_support_x86_64.S @@ -104,8 +104,7 @@ MACRO1(DEFINE_FUNCTION, c_name) ALIGN_FUNCTION_ENTRY VAR(c_name, 0): CFI_STARTPROC - // TODO: we reset the CFA state here. It'd be better to use ".cfi_startproc simple" above but - // clang 3.4 doesn't support this. + // Ensure we get a sane starting CFA. CFI_DEF_CFA(rsp, 8) END_MACRO |