OLD | NEW |
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2014, 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 #include "vm/globals.h" | 5 #include "vm/globals.h" |
6 #if defined(TARGET_ARCH_ARM64) | 6 #if defined(TARGET_ARCH_ARM64) |
7 | 7 |
8 #include "vm/code_patcher.h" | 8 #include "vm/code_patcher.h" |
9 #include "vm/cpu.h" | 9 #include "vm/cpu.h" |
10 #include "vm/debugger.h" | 10 #include "vm/debugger.h" |
11 #include "vm/instructions.h" | 11 #include "vm/instructions.h" |
12 #include "vm/stub_code.h" | 12 #include "vm/stub_code.h" |
13 | 13 |
14 namespace dart { | 14 namespace dart { |
15 | 15 |
| 16 #ifndef PRODUCT |
| 17 |
16 RawCode* CodeBreakpoint::OrigStubAddress() const { | 18 RawCode* CodeBreakpoint::OrigStubAddress() const { |
17 return saved_value_; | 19 return saved_value_; |
18 } | 20 } |
19 | 21 |
20 | 22 |
21 void CodeBreakpoint::PatchCode() { | 23 void CodeBreakpoint::PatchCode() { |
22 ASSERT(!is_enabled_); | 24 ASSERT(!is_enabled_); |
23 Code& stub_target = Code::Handle(); | 25 Code& stub_target = Code::Handle(); |
24 switch (breakpoint_kind_) { | 26 switch (breakpoint_kind_) { |
25 case RawPcDescriptors::kIcCall: | 27 case RawPcDescriptors::kIcCall: |
(...skipping 24 matching lines...) Expand all Loading... |
50 CodePatcher::PatchPoolPointerCallAt( | 52 CodePatcher::PatchPoolPointerCallAt( |
51 pc_, code, Code::Handle(saved_value_)); | 53 pc_, code, Code::Handle(saved_value_)); |
52 break; | 54 break; |
53 } | 55 } |
54 default: | 56 default: |
55 UNREACHABLE(); | 57 UNREACHABLE(); |
56 } | 58 } |
57 is_enabled_ = false; | 59 is_enabled_ = false; |
58 } | 60 } |
59 | 61 |
| 62 #endif // !PRODUCT |
| 63 |
60 } // namespace dart | 64 } // namespace dart |
61 | 65 |
62 #endif // defined TARGET_ARCH_ARM64 | 66 #endif // defined TARGET_ARCH_ARM64 |
OLD | NEW |