diff options
author | Ian Rogers <irogers@google.com> | 2014-02-22 07:45:58 +0000 |
---|---|---|
committer | Gerrit Code Review <noreply-gerritcodereview@google.com> | 2014-02-22 07:45:58 +0000 |
commit | 67f8ce291f4f8d12b37b27450a19a5ebdeb03a8b (patch) | |
tree | 379b85e814eda9de0a20b96575be2e73544a55ff /runtime | |
parent | 9a5ebb52fbfe22061cdb93340474eef6b2135897 (diff) | |
parent | 8016a12a5f9c2ea70b52e353a0169ba836ee9402 (diff) | |
download | art-67f8ce291f4f8d12b37b27450a19a5ebdeb03a8b.zip art-67f8ce291f4f8d12b37b27450a19a5ebdeb03a8b.tar.gz art-67f8ce291f4f8d12b37b27450a19a5ebdeb03a8b.tar.bz2 |
Merge "Make X86 assembly labels local."
Diffstat (limited to 'runtime')
-rw-r--r-- | runtime/arch/x86/jni_entrypoints_x86.S | 4 | ||||
-rw-r--r-- | runtime/arch/x86/portable_entrypoints_x86.S | 12 | ||||
-rw-r--r-- | runtime/arch/x86/quick_entrypoints_x86.S | 68 |
3 files changed, 42 insertions, 42 deletions
diff --git a/runtime/arch/x86/jni_entrypoints_x86.S b/runtime/arch/x86/jni_entrypoints_x86.S index 2eb5ada..ebd82b5 100644 --- a/runtime/arch/x86/jni_entrypoints_x86.S +++ b/runtime/arch/x86/jni_entrypoints_x86.S @@ -30,8 +30,8 @@ DEFINE_FUNCTION art_jni_dlsym_lookup_stub addl LITERAL(8), %esp // restore the stack CFI_ADJUST_CFA_OFFSET(-12) cmpl LITERAL(0), %eax // check if returned method code is null - je no_native_code_found // if null, jump to return to handle + je .Lno_native_code_found // if null, jump to return to handle jmp *%eax // otherwise, tail call to intended method -no_native_code_found: +.Lno_native_code_found: ret END_FUNCTION art_jni_dlsym_lookup_stub diff --git a/runtime/arch/x86/portable_entrypoints_x86.S b/runtime/arch/x86/portable_entrypoints_x86.S index 4bd6173..5f270f8 100644 --- a/runtime/arch/x86/portable_entrypoints_x86.S +++ b/runtime/arch/x86/portable_entrypoints_x86.S @@ -52,16 +52,16 @@ DEFINE_FUNCTION art_portable_invoke_stub POP ebp // pop ebp mov 20(%esp), %ecx // get result pointer cmpl LITERAL(68), 24(%esp) // test if result type char == 'D' - je return_double_portable + je .Lreturn_double_portable cmpl LITERAL(70), 24(%esp) // test if result type char == 'F' - je return_float_portable + je .Lreturn_float_portable mov %eax, (%ecx) // store the result mov %edx, 4(%ecx) // store the other half of the result ret -return_double_portable: +.Lreturn_double_portable: fstpl (%ecx) // store the floating point result as double ret -return_float_portable: +.Lreturn_float_portable: fstps (%ecx) // store the floating point result as float ret END_FUNCTION art_portable_invoke_stub @@ -109,9 +109,9 @@ DEFINE_FUNCTION art_portable_resolution_trampoline CFI_RESTORE(%ebp) CFI_DEF_CFA(%esp, 4) testl %eax, %eax - jz resolve_fail + jz .Lresolve_fail jmp * %eax -resolve_fail: // Resolution failed, return with exception pending. +.Lresolve_fail: // Resolution failed, return with exception pending. ret END_FUNCTION art_portable_resolution_trampoline diff --git a/runtime/arch/x86/quick_entrypoints_x86.S b/runtime/arch/x86/quick_entrypoints_x86.S index 7597a4e..b1f2275 100644 --- a/runtime/arch/x86/quick_entrypoints_x86.S +++ b/runtime/arch/x86/quick_entrypoints_x86.S @@ -285,14 +285,14 @@ DEFINE_FUNCTION art_quick_invoke_stub mov %edx, 4(%ecx) // store the other half of the result mov 24(%esp), %edx // get the shorty cmpb LITERAL(68), (%edx) // test if result type char == 'D' - je return_double_quick + je .Lreturn_double_quick cmpb LITERAL(70), (%edx) // test if result type char == 'F' - je return_float_quick + je .Lreturn_float_quick ret -return_double_quick: +.Lreturn_double_quick: movsd %xmm0, (%ecx) // store the floating point result ret -return_float_quick: +.Lreturn_float_quick: movss %xmm0, (%ecx) // store the floating point result ret END_FUNCTION art_quick_invoke_stub @@ -514,32 +514,32 @@ TWO_ARG_DOWNCALL art_quick_handle_fill_data, artHandleFillArrayDataFromCode, RET DEFINE_FUNCTION art_quick_lock_object testl %eax, %eax // null check object/eax - jz slow_lock -retry_lock: + jz .Lslow_lock +.Lretry_lock: movl LOCK_WORD_OFFSET(%eax), %ecx // ecx := lock word test LITERAL(0xC0000000), %ecx // test the 2 high bits. - jne slow_lock // slow path if either of the two high bits are set. + jne .Lslow_lock // slow path if either of the two high bits are set. movl %fs:THREAD_ID_OFFSET, %edx // edx := thread id test %ecx, %ecx - jnz already_thin // lock word contains a thin lock + jnz .Lalready_thin // lock word contains a thin lock // unlocked case - %edx holds thread id with count of 0 movl %eax, %ecx // remember object in case of retry xor %eax, %eax // eax == 0 for comparison with lock word in cmpxchg lock cmpxchg %edx, LOCK_WORD_OFFSET(%ecx) - jnz cmpxchg_fail // cmpxchg failed retry + jnz .Lcmpxchg_fail // cmpxchg failed retry ret -cmpxchg_fail: +.Lcmpxchg_fail: movl %ecx, %eax // restore eax - jmp retry_lock -already_thin: + jmp .Lretry_lock +.Lalready_thin: cmpw %ax, %dx // do we hold the lock already? - jne slow_lock + jne .Lslow_lock addl LITERAL(65536), %eax // increment recursion count test LITERAL(0xC0000000), %eax // overflowed if either of top two bits are set - jne slow_lock // count overflowed so go slow + jne .Lslow_lock // count overflowed so go slow movl %eax, LOCK_WORD_OFFSET(%ecx) // update lockword, cmpxchg not necessary as we hold lock ret -slow_lock: +.Lslow_lock: SETUP_REF_ONLY_CALLEE_SAVE_FRAME // save ref containing registers for GC mov %esp, %edx // remember SP SETUP_GOT_NOSAVE // clobbers EBX @@ -558,22 +558,22 @@ END_FUNCTION art_quick_lock_object DEFINE_FUNCTION art_quick_unlock_object testl %eax, %eax // null check object/eax - jz slow_unlock + jz .Lslow_unlock movl LOCK_WORD_OFFSET(%eax), %ecx // ecx := lock word movl %fs:THREAD_ID_OFFSET, %edx // edx := thread id test %ecx, %ecx - jb slow_unlock // lock word contains a monitor + jb .Lslow_unlock // lock word contains a monitor cmpw %cx, %dx // does the thread id match? - jne slow_unlock + jne .Lslow_unlock cmpl LITERAL(65536), %ecx - jae recursive_thin_unlock + jae .Lrecursive_thin_unlock movl LITERAL(0), LOCK_WORD_OFFSET(%eax) ret -recursive_thin_unlock: +.Lrecursive_thin_unlock: subl LITERAL(65536), %ecx mov %ecx, LOCK_WORD_OFFSET(%eax) ret -slow_unlock: +.Lslow_unlock: SETUP_REF_ONLY_CALLEE_SAVE_FRAME // save ref containing registers for GC mov %esp, %edx // remember SP SETUP_GOT_NOSAVE // clobbers EBX @@ -651,21 +651,21 @@ END_FUNCTION art_quick_aput_obj_with_bound_check DEFINE_FUNCTION art_quick_aput_obj test %edx, %edx // store of null - jz do_aput_null + jz .Ldo_aput_null movl CLASS_OFFSET(%eax), %ebx movl CLASS_COMPONENT_TYPE_OFFSET(%ebx), %ebx cmpl CLASS_OFFSET(%edx), %ebx // value's type == array's component type - trivial assignability - jne check_assignability -do_aput: + jne .Lcheck_assignability +.Ldo_aput: movl %edx, OBJECT_ARRAY_DATA_OFFSET(%eax, %ecx, 4) movl %fs:THREAD_CARD_TABLE_OFFSET, %edx shrl LITERAL(7), %eax movb %dl, (%edx, %eax) ret -do_aput_null: +.Ldo_aput_null: movl %edx, OBJECT_ARRAY_DATA_OFFSET(%eax, %ecx, 4) ret -check_assignability: +.Lcheck_assignability: PUSH eax // save arguments PUSH ecx PUSH edx @@ -679,7 +679,7 @@ check_assignability: addl LITERAL(16), %esp // pop arguments CFI_ADJUST_CFA_OFFSET(-16) testl %eax, %eax - jz throw_array_store_exception + jz .Lthrow_array_store_exception POP edx POP ecx POP eax @@ -688,7 +688,7 @@ check_assignability: shrl LITERAL(7), %eax movb %dl, (%edx, %eax) ret -throw_array_store_exception: +.Lthrow_array_store_exception: POP edx POP ecx POP eax @@ -792,14 +792,14 @@ END_FUNCTION art_quick_f2l DEFINE_FUNCTION art_quick_idivmod cmpl LITERAL(0x80000000), %eax - je check_arg2 // special case -args_ok: + je .Lcheck_arg2 // special case +.Largs_ok: cdq // edx:eax = sign extend eax idiv %ecx // (edx,eax) = (edx:eax % ecx, edx:eax / ecx) ret -check_arg2: +.Lcheck_arg2: cmpl LITERAL(-1), %ecx - jne args_ok + jne .Largs_ok xorl %edx, %edx ret // eax already holds min int END_FUNCTION art_quick_idivmod @@ -1308,12 +1308,12 @@ DEFINE_FUNCTION art_quick_string_compareto * edi: pointer to comp string data */ repe cmpsw // find nonmatching chars in [%esi] and [%edi], up to length %ecx - jne not_equal + jne .Lnot_equal POP edi // pop callee save reg POP esi // pop callee save reg ret .balign 16 -not_equal: +.Lnot_equal: movzwl -2(%esi), %eax // get last compared char from this string movzwl -2(%edi), %ecx // get last compared char from comp string subl %ecx, %eax // return the difference |