blob: 0b38bb7ac4f7dfe5630f4552ebade7f1a1dfc382 [file] [log] [blame]
Shih-wei Liaoa8a9c342012-03-03 22:35:16 -08001// Copyright 2012 Google Inc. All Rights Reserved.
2
3#ifndef ART_SRC_COMPILER_LLVM_RUNTIME_SUPPORT_LLVM_H_
4#define ART_SRC_COMPILER_LLVM_RUNTIME_SUPPORT_LLVM_H_
5
6namespace art {
7
Shih-wei Liao113f4fc2012-03-04 14:28:35 -08008//----------------------------------------------------------------------------
9// Thread
10//----------------------------------------------------------------------------
11
Shih-wei Liaoa8a9c342012-03-03 22:35:16 -080012void art_push_shadow_frame_from_code(void* new_shadow_frame);
13
14void art_pop_shadow_frame_from_code();
15
Shih-wei Liao113f4fc2012-03-04 14:28:35 -080016
17//----------------------------------------------------------------------------
18// Exception
19//----------------------------------------------------------------------------
20
Shih-wei Liaoa8a9c342012-03-03 22:35:16 -080021bool art_is_exception_pending_from_code();
22
Shih-wei Liao113f4fc2012-03-04 14:28:35 -080023void art_throw_div_zero_from_code();
24
25void art_throw_array_bounds_from_code(int32_t length, int32_t index);
26
27void art_throw_no_such_method_from_code(int32_t method_idx);
28
29void art_throw_null_pointer_exception_from_code();
30
31void art_throw_stack_overflow_from_code(void*);
32
33void art_throw_exception_from_code(Object* exception);
34
35int32_t art_find_catch_block_from_code(Object* exception, int32_t dex_pc);
36
37
Shih-wei Liaoa8a9c342012-03-03 22:35:16 -080038void art_test_suspend_from_code();
39
40void art_set_current_thread_from_code(void* thread_object_addr);
41
Logan Chien2771fb12012-03-06 16:28:35 +080042
43//----------------------------------------------------------------------------
44// Runtime Support Function Lookup Callback
45//----------------------------------------------------------------------------
46
47void* art_find_runtime_support_func(void* context, char const* name);
48
Shih-wei Liaoa8a9c342012-03-03 22:35:16 -080049} // namespace art
50
51#endif // ART_SRC_COMPILER_LLVM_RUNTIME_SUPPORT_LLVM_H_