29.01.2015 Views

Embedded Software for SoC - Grupo de Mecatrônica EESC/USP

Embedded Software for SoC - Grupo de Mecatrônica EESC/USP

Embedded Software for SoC - Grupo de Mecatrônica EESC/USP

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Compiler-Directed ILP Extraction 247<br />

exploit control speculation to reduce control <strong>de</strong>pen<strong>de</strong>nce height, which enables<br />

the generation of more compact, higher ILP static schedules.<br />

1.2. Overview<br />

The proposed algorithm iterates through three main phases: speculation,<br />

cluster binding and modulo scheduling (see Figure 19-4). At each iteration,<br />

relying on effective load balancing heuristics, the algorithm incrementally<br />

extracts/exposes additional (“profitable”) ILP, i.e., speculates loop body<br />

operations that are more likely to lead to a <strong>de</strong>crease in initiation interval during<br />

modulo scheduling. The resulting loop operations are then assigned to the<br />

machine’s clusters and, finally, the loop is modulo scheduled generating actual<br />

VLIW co<strong>de</strong>. An additional critical phase (executed right after binding)<br />

attempts to leverage required data transfers across clusters to realize the<br />

speculative co<strong>de</strong>, thus minimizing their potential impact on per<strong>for</strong>mance (see<br />

<strong>de</strong>tails in Section 4).<br />

To the best of our knowledge, there is no other algorithm in the literature<br />

on compiler-directed predicated co<strong>de</strong> optimizations that jointly consi<strong>de</strong>rs<br />

control speculation and modulo scheduling in the context of clustered EPIC<br />

machines. In the experiments section we will show that, by jointly consi<strong>de</strong>ring<br />

speculation and modulo scheduling in a resource aware context, and by<br />

minimizing the impact in per<strong>for</strong>mance of data transfers across clusters, the<br />

algorithm proposed in this paper can dramatically reduce a loop’s initiation<br />

interval with upto 68.2% improvement with respect to a baseline algorithm<br />

representative of the state of the art.<br />

2. OPTIMIZING SPECULATION<br />

In this Section, we discuss the process of <strong>de</strong>ciding which loop operations to<br />

speculate so as to achieve a more effective utilization of datapath resources<br />

and improve per<strong>for</strong>mance (initiation interval). The algorithm <strong>for</strong> optimizing<br />

speculation, <strong>de</strong>scribed in <strong>de</strong>tail in Section 3, uses the concept of load profiles<br />

to estimate the distribution of load over the scheduling ranges of operations,<br />

as well as across the clusters of the target VLIW/EPIC processor. Section 2.1<br />

explains how these load profiles are calculated. Section 2.2 discusses how<br />

the process of speculation alters these profiles and introduces the key i<strong>de</strong>as<br />

exploited by our algorithm.<br />

2.1. Load profile calculation<br />

The load profile is a measure of resource requirements nee<strong>de</strong>d to execute a<br />

Control Data Flow Graph (CDFG) with a <strong>de</strong>sirable schedule latency. Note<br />

that, when predicated co<strong>de</strong> is consi<strong>de</strong>red, the branching constructs actually<br />

correspond to the <strong>de</strong>finition of a predicate (<strong>de</strong>noted PD in Figure 19-1), and

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!