OLD | NEW |
1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file |
2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
4 | 4 |
| 5 // TODO(zra): Remove when tests are ready to enable. |
| 6 #include "platform/globals.h" |
| 7 #if !defined(TARGET_ARCH_ARM64) |
| 8 |
5 #include "vm/assembler.h" | 9 #include "vm/assembler.h" |
6 #include "vm/disassembler.h" | 10 #include "vm/disassembler.h" |
7 #include "vm/unit_test.h" | 11 #include "vm/unit_test.h" |
8 #include "vm/virtual_memory.h" | 12 #include "vm/virtual_memory.h" |
9 | 13 |
10 namespace dart { | 14 namespace dart { |
11 | 15 |
12 TEST_CASE(Disassembler) { | 16 TEST_CASE(Disassembler) { |
13 Assembler assembler; | 17 Assembler assembler; |
14 // The used instructions work on all platforms. | 18 // The used instructions work on all platforms. |
15 Register reg = static_cast<Register>(0); | 19 Register reg = static_cast<Register>(0); |
16 assembler.PopRegister(reg); | 20 assembler.PopRegister(reg); |
17 assembler.Stop("testing disassembler"); | 21 assembler.Stop("testing disassembler"); |
18 | 22 |
19 // Only verify that the disassembler does not crash. | 23 // Only verify that the disassembler does not crash. |
20 AssemblerTest test("Disassembler", &assembler); | 24 AssemblerTest test("Disassembler", &assembler); |
21 test.Assemble(); | 25 test.Assemble(); |
22 Disassembler::Disassemble(test.entry(), test.entry() + assembler.CodeSize()); | 26 Disassembler::Disassemble(test.entry(), test.entry() + assembler.CodeSize()); |
23 } | 27 } |
24 | 28 |
25 } // namespace dart | 29 } // namespace dart |
| 30 |
| 31 #endif // !defined(TARGET_ARCH_ARM64) |
OLD | NEW |