OLD | NEW |
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, 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" // Needed here to get TARGET_ARCH_X64. | 5 #include "vm/globals.h" // Needed here to get TARGET_ARCH_X64. |
6 #if defined(TARGET_ARCH_X64) | 6 #if defined(TARGET_ARCH_X64) |
7 | 7 |
8 #include "vm/cpu.h" | 8 #include "vm/cpu.h" |
9 #include "vm/instructions.h" | 9 #include "vm/instructions.h" |
10 #include "vm/object.h" | 10 #include "vm/object.h" |
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
66 *reinterpret_cast<uint32_t*>(start() + 1) = target - start() - kLengthInBytes; | 66 *reinterpret_cast<uint32_t*>(start() + 1) = target - start() - kLengthInBytes; |
67 CPU::FlushICache(start() + 1, kWordSize); | 67 CPU::FlushICache(start() + 1, kWordSize); |
68 } | 68 } |
69 | 69 |
70 | 70 |
71 const int* ShortCallPattern::pattern() const { | 71 const int* ShortCallPattern::pattern() const { |
72 static const int kCallPattern[kLengthInBytes] = {0xE8, -1, -1, -1, -1}; | 72 static const int kCallPattern[kLengthInBytes] = {0xE8, -1, -1, -1, -1}; |
73 return kCallPattern; | 73 return kCallPattern; |
74 } | 74 } |
75 | 75 |
| 76 |
| 77 const int* ReturnPattern::pattern() const { |
| 78 static const int kReturnPattern[kLengthInBytes] = { 0xC3 }; |
| 79 return kReturnPattern; |
| 80 } |
| 81 |
76 } // namespace dart | 82 } // namespace dart |
77 | 83 |
78 #endif // defined TARGET_ARCH_X64 | 84 #endif // defined TARGET_ARCH_X64 |
OLD | NEW |