blob: 73a9d7ae5ffe6ace2082c0ac36806b026839a198 [file] [log] [blame]
buzbee67bf8852011-08-17 17:51:35 -07001/*
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 */
16
17/*
18 * Common defines for all Dalvik code.
19 */
20#ifndef DALVIK_COMMON_H_
21#define DALVIK_COMMON_H_
22
Elliott Hughes54e7df12011-09-16 11:47:04 -070023#include <assert.h>
buzbee67bf8852011-08-17 17:51:35 -070024#include <stdbool.h>
25#include <stdint.h>
26#include <stdio.h>
Elliott Hughes54e7df12011-09-16 11:47:04 -070027
Ian Rogers5d76c432011-10-31 21:42:49 -070028#include "card_table.h"
buzbeec143c552011-08-20 17:38:58 -070029#include "class_linker.h"
Brian Carlstrom16192862011-09-12 17:50:06 -070030#include "compiler.h"
buzbeec143c552011-08-20 17:38:58 -070031#include "dex_cache.h"
Elliott Hughes54e7df12011-09-16 11:47:04 -070032#include "logging.h"
33#include "monitor.h"
34#include "object.h"
35#include "thread.h"
buzbeec143c552011-08-20 17:38:58 -070036#include "utils.h"
buzbee67bf8852011-08-17 17:51:35 -070037
38// From Common.h
buzbee67bf8852011-08-17 17:51:35 -070039typedef uint8_t u1;
40typedef uint16_t u2;
41typedef uint32_t u4;
42typedef uint64_t u8;
43typedef int8_t s1;
44typedef int16_t s2;
45typedef int32_t s4;
46typedef int64_t s8;
47typedef unsigned long long u8;
48
buzbeec143c552011-08-20 17:38:58 -070049//Skip old DexFile.h
50#define LIBDEX_DEXFILE_H_
51//Skip old vm/Common.h
52#define DALVIK_COMMON_H_
53//Make inlines inline
54#define DEX_INLINE inline
55#include "DexOpcodes.h"
56#include "InstrUtils.h"
buzbee67bf8852011-08-17 17:51:35 -070057
buzbeec143c552011-08-20 17:38:58 -070058typedef art::Array Array;
Brian Carlstrom16192862011-09-12 17:50:06 -070059typedef art::Class Class;
60typedef art::Compiler Compiler;
61typedef art::Field Field;
62typedef art::JValue JValue;
buzbeec143c552011-08-20 17:38:58 -070063typedef art::Method Method;
Brian Carlstrom3320cf42011-10-04 14:58:28 -070064typedef art::CompiledMethod CompiledMethod;
buzbeec143c552011-08-20 17:38:58 -070065typedef art::Object Object;
buzbeec143c552011-08-20 17:38:58 -070066typedef art::String String;
Brian Carlstrom16192862011-09-12 17:50:06 -070067typedef art::Thread Thread;
buzbee67bf8852011-08-17 17:51:35 -070068
buzbeeed3e9302011-09-23 17:34:19 -070069// use to switch visibility on DCHECK tracebacks
70#if 1
71#define STATIC
72#else
73#define STATIC static
74#endif
75
buzbee67bf8852011-08-17 17:51:35 -070076#include "Compiler.h"
77
78#endif