Elliott Hughes | 2faa5f1 | 2012-01-30 14:42:07 -0800 | [diff] [blame] | 1 | /* |
| 2 | * Copyright (C) 2011 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 | */ |
Ian Rogers | 9651f42 | 2011-09-19 20:26:07 -0700 | [diff] [blame] | 16 | |
Brian Carlstrom | fc0e321 | 2013-07-17 14:40:12 -0700 | [diff] [blame] | 17 | #ifndef ART_RUNTIME_ASM_SUPPORT_H_ |
| 18 | #define ART_RUNTIME_ASM_SUPPORT_H_ |
Ian Rogers | 9651f42 | 2011-09-19 20:26:07 -0700 | [diff] [blame] | 19 | |
Ian Rogers | 4b07f17 | 2013-02-07 08:29:42 -0800 | [diff] [blame] | 20 | // Value loaded into rSUSPEND for quick. When this value is counted down to zero we do a suspend |
| 21 | // check. |
Ian Rogers | 4a510d8 | 2011-10-09 14:30:24 -0700 | [diff] [blame] | 22 | #define SUSPEND_CHECK_INTERVAL (1000) |
| 23 | |
Ian Rogers | d9c4fc9 | 2013-10-01 19:45:43 -0700 | [diff] [blame^] | 24 | // Offsets within java.lang.Object. |
| 25 | #define LOCK_WORD_OFFSET 4 |
| 26 | |
Ian Rogers | 4b07f17 | 2013-02-07 08:29:42 -0800 | [diff] [blame] | 27 | // Offsets within java.lang.String. |
buzbee | fc9e6fa | 2012-03-23 15:14:29 -0700 | [diff] [blame] | 28 | #define STRING_VALUE_OFFSET 8 |
| 29 | #define STRING_COUNT_OFFSET 12 |
| 30 | #define STRING_OFFSET_OFFSET 20 |
| 31 | #define STRING_DATA_OFFSET 12 |
| 32 | |
Jeff Hao | aa4a793 | 2013-05-13 11:28:27 -0700 | [diff] [blame] | 33 | // Offset of field Method::entry_point_from_compiled_code_ |
| 34 | #define METHOD_CODE_OFFSET 40 |
Jeff Hao | 5d91730 | 2013-02-27 17:57:33 -0800 | [diff] [blame] | 35 | |
Brian Carlstrom | fc0e321 | 2013-07-17 14:40:12 -0700 | [diff] [blame] | 36 | #endif // ART_RUNTIME_ASM_SUPPORT_H_ |