• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1/*
2 * Copyright (C) 2012 The Android Open Source Project
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 *      http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16
17#include "asm_support_mips.S"
18
19    .set noreorder
20    .balign 4
21
22    .extern artPortableProxyInvokeHandler
23ENTRY art_portable_proxy_invoke_handler
24    GENERATE_GLOBAL_POINTER
25    # Fake callee save ref and args frame set up, note portable doesn't use callee save frames.
26    # TODO: just save the registers that are needed in artPortableProxyInvokeHandler.
27    addiu  $sp, $sp, -64
28    .cfi_adjust_cfa_offset 64
29    sw     $ra, 60($sp)
30    .cfi_rel_offset 31, 60
31    sw     $s8, 56($sp)
32    .cfi_rel_offset 30, 56
33    sw     $gp, 52($sp)
34    .cfi_rel_offset 28, 52
35    sw     $s7, 48($sp)
36    .cfi_rel_offset 23, 48
37    sw     $s6, 44($sp)
38    .cfi_rel_offset 22, 44
39    sw     $s5, 40($sp)
40    .cfi_rel_offset 21, 40
41    sw     $s4, 36($sp)
42    .cfi_rel_offset 20, 36
43    sw     $s3, 32($sp)
44    .cfi_rel_offset 19, 32
45    sw     $s2, 28($sp)
46    .cfi_rel_offset 18, 28
47    sw     $a3, 12($sp)
48    .cfi_rel_offset 7, 12
49    sw     $a2, 8($sp)
50    .cfi_rel_offset 6, 8
51    sw     $a1, 4($sp)
52    .cfi_rel_offset 5, 4
53    # Begin argument set up.
54    sw      $a0, 0($sp)            # place proxy method at bottom of frame
55    move    $a2, rSELF             # pass Thread::Current
56    jal     artPortableProxyInvokeHandler  # (Method* proxy method, receiver, Thread*, SP)
57    move    $a3, $sp               # pass $sp
58    lw      $ra, 60($sp)           # restore $ra
59    jr      $ra
60    addiu   $sp, $sp, 64           # pop frame
61    .cfi_adjust_cfa_offset -64
62END art_portable_proxy_invoke_handler
63
64UNIMPLEMENTED art_portable_resolution_trampoline
65UNIMPLEMENTED art_portable_to_interpreter_bridge
66