summaryrefslogtreecommitdiffstats
path: root/compiler/dex/quick/x86/codegen_x86.h
diff options
context:
space:
mode:
authorBill Buzbee <buzbee@android.com>2014-05-16 17:31:55 +0000
committerGerrit Code Review <noreply-gerritcodereview@google.com>2014-05-16 17:31:56 +0000
commit1e97c4a4ab9f17d1394b952882d59d894b1e3c74 (patch)
tree1942cbd3407f75e81e21200f56211aa8ed3bb767 /compiler/dex/quick/x86/codegen_x86.h
parentc001b0952513690216f9a14153a839d569a91538 (diff)
parent9ee801f5308aa3c62ae3bedae2658612762ffb91 (diff)
downloadart-1e97c4a4ab9f17d1394b952882d59d894b1e3c74.tar.gz
art-1e97c4a4ab9f17d1394b952882d59d894b1e3c74.tar.bz2
art-1e97c4a4ab9f17d1394b952882d59d894b1e3c74.zip
Merge "Add x86_64 code generation support"
Diffstat (limited to 'compiler/dex/quick/x86/codegen_x86.h')
-rw-r--r--compiler/dex/quick/x86/codegen_x86.h9
1 files changed, 8 insertions, 1 deletions
diff --git a/compiler/dex/quick/x86/codegen_x86.h b/compiler/dex/quick/x86/codegen_x86.h
index ef8c33c8eb..47d17925a4 100644
--- a/compiler/dex/quick/x86/codegen_x86.h
+++ b/compiler/dex/quick/x86/codegen_x86.h
@@ -24,7 +24,7 @@ namespace art {
class X86Mir2Lir FINAL : public Mir2Lir {
public:
- X86Mir2Lir(CompilationUnit* cu, MIRGraph* mir_graph, ArenaAllocator* arena);
+ X86Mir2Lir(CompilationUnit* cu, MIRGraph* mir_graph, ArenaAllocator* arena, bool gen64bit);
// Required for target - codegen helpers.
bool SmallLiteralDivRem(Instruction::Code dalvik_opcode, bool is_div, RegLocation rl_src,
@@ -325,10 +325,12 @@ class X86Mir2Lir FINAL : public Mir2Lir {
std::vector<uint8_t>* ReturnCallFrameInformation();
private:
+ size_t ComputeSize(const X86EncodingMap* entry, int base, int displacement, bool has_sib);
void EmitPrefix(const X86EncodingMap* entry);
void EmitOpcode(const X86EncodingMap* entry);
void EmitPrefixAndOpcode(const X86EncodingMap* entry);
void EmitDisp(uint8_t base, int disp);
+ void EmitModrmThread(uint8_t reg_or_opcode);
void EmitModrmDisp(uint8_t reg_or_opcode, uint8_t base, int disp);
void EmitModrmSibDisp(uint8_t reg_or_opcode, uint8_t base, uint8_t index, int scale, int disp);
void EmitImm(const X86EncodingMap* entry, int imm);
@@ -578,6 +580,8 @@ class X86Mir2Lir FINAL : public Mir2Lir {
*/
void AnalyzeDoubleUse(RegLocation rl_use);
+ bool Gen64Bit() const { return gen64bit_; }
+
// Information derived from analysis of MIR
// The compiler temporary for the code address of the method.
@@ -606,6 +610,9 @@ class X86Mir2Lir FINAL : public Mir2Lir {
// Epilogue increment of stack pointer.
LIR* stack_increment_;
+
+ // 64-bit mode
+ bool gen64bit_;
};
} // namespace art