Package at.dms.kjc.sir

Contains the heart of the StreamIt Intermediate Representation, or SIR for short.

See:
          Description

Interface Summary
AttributeStreamVisitor This visitor is for visiting stream structures in the SIR.
SIRCodeUnit Interface of accessors for classes that define methods and field variables.
StreamVisitor This visitor is for visiting stream structures in the SIR.
 

Class Summary
EmptyAttributeStreamVisitor This is an empty attribute stream visitor that does nothing except the recursion.
EmptyStreamVisitor This is a stream visitor that does nothing.
InlineAssembly Statement used for generating inline assembly.
ReplacingStreamVisitor Visits all stream structures and replaces children with result from recursion.
SemanticChecker The purpose of this class it to semantic check a stream program.
SIRBeginMarker This statement is an annotation that marks the beginning of a given function or stream so that it can be followed through fusion, etc.
SIRBuilder This class is for building sample representations in the SIR.
SIRContainer This represents a 1-to-1 stream that can contain other streams as a hierarchical unit.
SIRCreatePortal Create Portal Expression.
SIRDummySink This represents a StreamIT filter that just pushes 1 for int type and 1.0f for float.
SIRDummySource This represents a StreamIT filter that just pushes 1 for int type and 1.0f for float.
SIRDynamicRateManager This class governs how dynamic rates are interpreted at a given point in the compiler.
SIRDynamicRatePolicy This represents a single policy for interpreting dynamic rates in a given part of the compiler.
SIRDynamicToken This represents the dynmic token '*' as in an I/O rate declaration: [2,*,*].
SIREndMarker This statement is an annotation that marks the end of a given function or stream so that it can be followed through fusion, etc.
SIRFeedbackLoop This represents a feedback loop construct.
SIRFileReader This represents a StreaMIT filter that reads from a data source.
SIRFileWriter This represents a StreaMIT filter that writes a file to a data source.
SIRFilter This represents a basic StreamIt filter.
SIRGlobal This class represents a data that is available to all filters.
SIRHelper This class represents a set of helper methods available to all filters.
SIRIdentity This represents a StreaMIT filter that just reads item and sends it along.
SIRInitStatement Init Statement.
SIRInterfaceTable This represents an interface table.
SIRJoiner This represents a stream construct with a single output and multiple inputs.
SIRJoinType This class enumerates the types of joiners.
SIRLatency This represents a latency for message delivery.
SIRLatencyMax This represents a maximum latency for message delivery.
SIRLatencyRange This represents a range of latencies for message delivery.
SIRLatencySet A set of Integers corresponding to possible latencies for message delivery.
SIRMarker This class represents an annotation in the IR.
SIRMessageStatement Message Sending Statement.
SIRNavigationUtils  
SIROperator This represents an operator in the stream graph.
SIRPeekExpression This represents a peek expression.
SIRPhasedFilter A StreamIt phased filter.
SIRPipeline This represents a pipeline of stream structures, as would be declared with a Stream construct in StreaMIT.
SIRPopExpression This represents a pop expression.
SIRPortal This represents a stream portal used for messaging
SIRPortalSender Represents a SIRStream and SIRLatency pair
SIRPredefinedFilter This represents a StreaMIT filter that has some compiler-defined functionality.
SIRPrintStatement This represents a print statement, originally formulated with System.out.println in StreaMIT.
SIRPushExpression This represents a push expression (can only be used as a statement).
SIRRangeExpression This represents a range [min,average,max], e.g., [1,2,3] or [1,*,*] as used in the declaration of an I/O rate.
SIRRecursiveStub This class represents a stub for something that was found to be recursive in the front-end, and needs to be expanded within the IR.
SIRRegReceiverStatement Register Receiver Statement.
SIRRegSenderStatement Register Sender Statement.
SIRSplitJoin This represents a SplitJoin construct.
SIRSplitter This represents a stream construct with a single input and multiple outputs.
SIRSplitType This class enumerates the types of splitters.
SIRStream This class represents a stream structure with one input and one output.
SIRStructure This class represents a data structure that may be passed between streams on tapes.
SIRToStreamIt Dump an SIR tree into a StreamIt program.
SIRTwoStageFilter A two-stage filter is a filter that has two work phases.
 

Package at.dms.kjc.sir Description

Contains the heart of the StreamIt Intermediate Representation, or SIR for short. This intermediate representation exists at two levels:

The stream graph is encapsulated in a structured hierarchy of single-input, single-output modules. At the base of this hierarchy is SIRFilter, which represents the basic StreamIt filter. Filters are composed into hierarchical graphs using the SIRPipeline, SIRSplitJoin, and SIRFeedbackLoop classes. There are also special kinds of pre-defined filters, such as SIRFileReader, SIRFileWriter, and SIRIdentity.

For statement-level StreamIt IR constructs, this package contains classes such as SIRPushExpression, SIRPopExpression, and SIRPeekExpression that reflect uses of those expressions from within a filter's work function. There also exist some SIR statements that are only for internal use by the compiler, and do not directly correspond to a keyword in the language (such as SIRBeginMarker, which tracks the beginning of a filter's code through fusion events).

The other important component of the SIR are the stream-level visitors. These visitors descend through the hierarchical stream graph and can be extended to perform an operation on each filter, pipeline, etc. The StreamVisitor interface (implemented by EmptyAttributeStreamVisitor) performs the recursion automatically and has a return type of void from each visit, while the AttributeStreamVisitor interface (implemented by EmptyAttributeStreamVisitor) uses user-defined recursion with return types from visits.

The hierarchical structure of the SIR is utilized by many optimization passes (notably, all of those packages under the "sir" directory of the source tree). For certain backends (such as RawBackend and ClusterBackend) the hierarchy of the stream graph is eventaully eliminated to form a flat graph representation.

The rationale behind the hierarchy of the SIR is described in the research paper, StreamIt: A Language for Streaming Applications.

See Also:
at.dms.kjc.flatgraph