| 66 | } |
| 67 | |
| 68 | DecodedOp* DecodedOpCache::get(U32 address) { |
| 69 | U32 pageIndex = address >> K_PAGE_SHIFT; |
| 70 | DecodedOpPageCache* page = getPageCache(pageIndex, false); |
| 71 | if (page) { |
| 72 | U32 offset = address & K_PAGE_MASK; |
| 73 | if (page->ops[offset] == nullptr) { |
| 74 | if (offset > 0 && page->ops[offset - 1] && page->ops[offset - 1]->lock) { |
| 75 | return page->ops[offset - 1]; |
| 76 | } |
| 77 | } |
| 78 | return page->ops[offset]; |
| 79 | } |
| 80 | return nullptr; |
| 81 | } |
| 82 | |
| 83 | void DecodedOpCache::removeStartAt(U32 address, U32 len, bool becauseOfWrite) { |
| 84 | U32 pageIndex = address >> K_PAGE_SHIFT; |
no outgoing calls
no test coverage detected