Instruction Cache Miss Tracing with Integrated Branch Trace Circuit

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Existing systems fail to effectively trace and address instruction cache misses, particularly in complex software environments with multiple parallel threads, leading to indeterministic execution and cache thrashing, which complicates the optimization of time-critical code.

Innovation Solution

A system and method that integrates a cache hit-miss trace circuit with a branch trace circuit to identify cache misses and report instruction addresses, enhancing the Nexus interface with a modified Branch Trace Message to include cache miss indicators, allowing for improved tracing of function call sequences and cache-miss details.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Speed

If instruction cache is used to store frequently accessed program text, then execution speed is improved, but cache thrashing occurs when cache replacement happens frequently

Engineering Contradiction:
Improveexecution speedVSAvoidexecution determinism
Core Design Contradiction:
SpeedVSReliability

Solution Approach 1:

The patent implements trace circuits that proactively monitor and record cache hit/miss status and branch information before actual cache thrashing affects execution. By capturing this data in advance through dedicated trace logic integrated with the cache controller, the system can identify problematic code regions and optimize them beforehand, preventing indeterministic execution behavior.

Inventive Principle:
Principle #10Preliminary action

2Adaptability or versatility

If multiple concurrent software threads are used to implement time-bounded software actions, then functionality is improved, but asynchronous pre-emption occurs depending on mutual priority

Engineering Contradiction:
Improvesoftware functionalityVSAvoidexecution timing
Core Design Contradiction:
Adaptability or versatilityVSLoss of time

Solution Approach 1:

The patent implements trace circuits that provide feedback information about cache performance and branch execution across multiple software threads. By monitoring cache hit/miss status and branch information for each thread independently, the system can identify which threads are experiencing cache thrashing and adjust scheduling or code placement to ensure time-bounded execution requirements are met.

Inventive Principle:
Principle #23Feedback

3Quantity of substance

If cache replacement logic is implemented to evict cache regions, then space for new data is created, but cache-thrashing situations occur when replacement happens very frequently

Engineering Contradiction:
Improvecache capacityVSAvoidcode execution efficiency
Core Design Contradiction:
Quantity of substanceVSProductivity

Solution Approach 1:

The patent implements trace circuits that proactively monitor cache access patterns and identify code regions experiencing frequent cache misses before they cause significant performance degradation. By capturing cache hit/miss status and branch information in advance, the system can optimize code placement or adjust cache configuration beforehand, preventing productivity loss from cache thrashing.

Inventive Principle:
Principle #10Preliminary action

4Loss of information

If existing trace systems are used to trace function call sequences, then function invocation information is obtained, but cache-miss information is not identified

Engineering Contradiction:
Improvefunction call tracingVSAvoidcache-miss identification
Core Design Contradiction:
Loss of informationVSMeasurement precision

Solution Approach 1:

The patent merges existing branch trace circuits with new cache hit/miss trace circuits into an integrated tracing system. The branch trace circuits continue to provide function call sequence information while the integrated cache hit/miss trace circuits add cache performance data. This combination allows simultaneous observation of both function invocation patterns and cache behavior, enabling precise identification of which function calls experience cache misses.

Inventive Principle:
Principle #5Merging (Combining)

Data Source

PatentUS12481592B2System and method for tracing instruction cache misses
Publication Date: 2025.11.25 NXP USA INC
  • US12481592B2 patent drawing
  • US12481592B2 patent drawing
  • US12481592B2 patent drawing

AI summary

A system on chip (SoC) architecture includes an integrated branch and cache hit-miss trace circuit operably coupled to a CPU core, a first trace circuit, and a cache hit-miss trace circuit. Following an occurrence of a cache-fetch instruction: the cache hit-miss trace circuit identifies whether the fetch instruction is a cache-missed instruction, and, in response thereto, sends a cache miss report message that includes a fetch instruction address to the first trace circuit. The first trace circuit is configured to identify whether the fetch instruction is a taken-branch instruction and creates a modified branch trace response message (BTM) that includes the fetch instruction address and sends the modified BTM to a create trace messages circuit. The modified BTM indicates an instruction address of the cache miss.