📄 rtl.texi
字号:
@cindex @code{integrated}, in @code{reg}@item REG_FUNCTION_VALUE_P (@var{x})Nonzero in a @code{reg} if it is the place in which this function'svalue is going to be returned. (This happens only in a hardregister.) Stored in the @code{integrated} field and printed as@samp{/i}.The same hard register may be used also for collecting the values offunctions called by this one, but @code{REG_FUNCTION_VALUE_P} is zeroin this kind of use.@findex SUBREG_PROMOTED_VAR_P@cindex @code{subreg} and @samp{/s}@cindex @code{in_struct}, in @code{subreg}@item SUBREG_PROMOTED_VAR_PNonzero in a @code{subreg} if it was made when accessing an object thatwas promoted to a wider mode in accord with the @code{PROMOTED_MODE} machinedescription macro (@pxref{Storage Layout}). In this case, the mode ofthe @code{subreg} is the declared mode of the object and the mode of@code{SUBREG_REG} is the mode of the register that holds the object.Promoted variables are always either sign- or zero-extended to the widermode on every assignment. Stored in the @code{in_struct} field andprinted as @samp{/s}.@findex SUBREG_PROMOTED_UNSIGNED_P@cindex @code{subreg} and @samp{/u}@cindex @code{unchanging}, in @code{subreg}@item SUBREG_PROMOTED_UNSIGNED_PNonzero in a @code{subreg} that has @code{SUBREG_PROMOTED_VAR_P} nonzeroif the object being referenced is kept zero-extended and zero if itis kept sign-extended. Stored in the @code{unchanging} field andprinted as @samp{/u}.@findex RTX_UNCHANGING_P @cindex @code{reg} and @samp{/u}@cindex @code{mem} and @samp{/u}@cindex @code{unchanging}, in @code{reg} and @code{mem}@cindex @samp{/u} in RTL dump@item RTX_UNCHANGING_P (@var{x})Nonzero in a @code{reg} or @code{mem} if the value is not changed.(This flag is not set for memory references via pointers to constants.Such pointers only guarantee that the object will not be changedexplicitly by the current function. The object might be changed byother functions or by aliasing.) Stored in the@code{unchanging} field and printed as @samp{/u}.@findex RTX_INTEGRATED_P @cindex @code{integrated}, in @code{insn}@item RTX_INTEGRATED_P (@var{insn})Nonzero in an insn if it resulted from an in-line function call.Stored in the @code{integrated} field and printed as @samp{/i}. Thismay be deleted; nothing currently depends on it.@findex SYMBOL_REF_USED@cindex @code{used}, in @code{symbol_ref}@item SYMBOL_REF_USED (@var{x})In a @code{symbol_ref}, indicates that @var{x} has been used. This isnormally only used to ensure that @var{x} is only declared externalonce. Stored in the @code{used} field.@findex SYMBOL_REF_FLAG@cindex @code{symbol_ref} and @samp{/v}@cindex @code{volatil}, in @code{symbol_ref}@item SYMBOL_REF_FLAG (@var{x})In a @code{symbol_ref}, this is used as a flag for machine-specific purposes.Stored in the @code{volatil} field and printed as @samp{/v}.@findex LABEL_OUTSIDE_LOOP_P@cindex @code{label_ref} and @samp{/s}@cindex @code{in_struct}, in @code{label_ref}@item LABEL_OUTSIDE_LOOP_PIn @code{label_ref} expressions, nonzero if this is a reference to alabel that is outside the innermost loop containing the reference to thelabel. Stored in the @code{in_struct} field and printed as @samp{/s}.@findex INSN_DELETED_P @cindex @code{volatil}, in @code{insn}@item INSN_DELETED_P (@var{insn})In an insn, nonzero if the insn has been deleted. Stored in the@code{volatil} field and printed as @samp{/v}.@findex INSN_ANNULLED_BRANCH_P@cindex @code{insn} and @samp{/u}@cindex @code{unchanging}, in @code{insn}@item INSN_ANNULLED_BRANCH_P (@var{insn})In an @code{insn} in the delay slot of a branch insn, indicates that anannulling branch should be used. See the discussion under@code{sequence} below. Stored in the @code{unchanging} field and printedas @samp{/u}.@findex INSN_FROM_TARGET_P@cindex @code{insn} and @samp{/s}@cindex @code{in_struct}, in @code{insn}@cindex @samp{/s} in RTL dump@item INSN_FROM_TARGET_P (@var{insn})In an @code{insn} in a delay slot of a branch, indicates that the insnis from the target of the branch. If the branch insn has@code{INSN_ANNULLED_BRANCH_P} set, this insn should only be executed ifthe branch is taken. For annulled branches with this bit clear, theinsn should be executed only if the branch is not taken. Stored in the@code{in_struct} field and printed as @samp{/s}.@findex CONSTANT_POOL_ADDRESS_P @cindex @code{symbol_ref} and @samp{/u}@cindex @code{unchanging}, in @code{symbol_ref}@item CONSTANT_POOL_ADDRESS_P (@var{x})Nonzero in a @code{symbol_ref} if it refers to part of the currentfunction's ``constants pool''. These are addresses close to thebeginning of the function, and GNU CC assumes they can be addresseddirectly (perhaps with the help of base registers). Stored in the@code{unchanging} field and printed as @samp{/u}.@findex CONST_CALL_P@cindex @code{call_insn} and @samp{/u}@cindex @code{unchanging}, in @code{call_insn}@item CONST_CALL_P (@var{x})In a @code{call_insn}, indicates that the insn represents a call to a constfunction. Stored in the @code{unchanging} field and printed as @samp{/u}.@findex LABEL_PRESERVE_P@cindex @code{code_label} and @samp{/i}@cindex @code{in_struct}, in @code{code_label}@item LABEL_PRESERVE_P (@var{x})In a @code{code_label}, indicates that the label can never be deleted.Labels referenced by a non-local goto will have this bit set. Storedin the @code{in_struct} field and printed as @samp{/s}.@findex SCHED_GROUP_P@cindex @code{insn} and @samp{/i}@cindex @code{in_struct}, in @code{insn}@item SCHED_GROUP_P (@var{insn})During instruction scheduling, in an insn, indicates that the previous insnmust be scheduled together with this insn. This is used to ensure thatcertain groups of instructions will not be split up by the instructionscheduling pass, for example, @code{use} insns before a @code{call_insn} maynot be separated from the @code{call_insn}. Stored in the @code{in_struct}field and printed as @samp{/s}.@end tableThese are the fields which the above macros refer to:@table @code@findex used@item usedNormally, this flag is used only momentarily, at the end of RTLgeneration for a function, to count the number of times an expressionappears in insns. Expressions that appear more than once are copied,according to the rules for shared structure (@pxref{Sharing}).In a @code{symbol_ref}, it indicates that an external declaration forthe symbol has already been written.In a @code{reg}, it is used by the leaf register renumbering code to ensurethat each register is only renumbered once.@findex volatil@item volatilThis flag is used in @code{mem}, @code{symbol_ref} and @code{reg}expressions and in insns. In RTL dump files, it is printed as@samp{/v}.@cindex volatile memory referencesIn a @code{mem} expression, it is 1 if the memory reference is volatile.Volatile memory references may not be deleted, reordered or combined.In a @code{symbol_ref} expression, it is used for machine-specific purposes.In a @code{reg} expression, it is 1 if the value is a user-level variable.0 indicates an internal compiler temporary.In an insn, 1 means the insn has been deleted.@findex in_struct@item in_structIn @code{mem} expressions, it is 1 if the memory datum referred to isall or part of a structure or array; 0 if it is (or might be) a scalarvariable. A reference through a C pointer has 0 because the pointermight point to a scalar variable. This information allows the compilerto determine something about possible cases of aliasing.In an insn in the delay slot of a branch, 1 means that this insn is fromthe target of the branch.During instruction scheduling, in an insn, 1 means that this insn must bescheduled as part of a group together with the previous insn.In @code{reg} expressions, it is 1 if the register has its entire lifecontained within the test expression of some loopl.In @code{subreg} expressions, 1 means that the @code{subreg} is accessingan object that has had its mode promoted from a wider mode.In @code{label_ref} expressions, 1 means that the referenced label isoutside the innermost loop containing the insn in which the @code{label_ref}was found.In @code{code_label} expressions, it is 1 if the label may never be deleted.This is used for labels which are the target of non-local gotos.In an RTL dump, this flag is represented as @samp{/s}.@findex unchanging@item unchangingIn @code{reg} and @code{mem} expressions, 1 meansthat the value of the expression never changes.In @code{subreg} expressions, it is 1 if the @code{subreg} references anunsigned object whose mode has been promoted to a wider mode.In an insn, 1 means that this is an annulling branch.In a @code{symbol_ref} expression, 1 means that this symbol addressessomething in the per-function constants pool.In a @code{call_insn}, 1 means that this instruction is a call to aconst function.In an RTL dump, this flag is represented as @samp{/u}.@findex integrated@item integratedIn some kinds of expressions, including insns, this flag means thertl was produced by procedure integration.In a @code{reg} expression, this flag indicates the registercontaining the value to be returned by the current function. Onmachines that pass parameters in registers, the same register numbermay be used for parameters as well, but this flag is not set on suchuses.@end table@node Machine Modes, Constants, Flags, RTL@section Machine Modes@cindex machine modes@findex enum machine_modeA machine mode describes a size of data object and the representation usedfor it. In the C code, machine modes are represented by an enumerationtype, @code{enum machine_mode}, defined in @file{machmode.def}. Each RTLexpression has room for a machine mode and so do certain kinds of treeexpressions (declarations and types, to be precise).In debugging dumps and machine descriptions, the machine mode of an RTLexpression is written after the expression code with a colon to separatethem. The letters @samp{mode} which appear at the end of each machine modename are omitted. For example, @code{(reg:SI 38)} is a @code{reg}expression with machine mode @code{SImode}. If the mode is@code{VOIDmode}, it is not written at all.Here is a table of machine modes. The term ``byte'' below refers to anobject of @code{BITS_PER_UNIT} bits (@pxref{Storage Layout}).@table @code@findex QImode@item QImode``Quarter-Integer'' mode represents a single byte treated as an integer.@findex HImode@item HImode``Half-Integer'' mode represents a two-byte integer.@findex PSImode@item PSImode``Partial Single Integer'' mode represents an integer which occupiesfour bytes but which doesn't really use all four. On some machines,this is the right mode to use for pointers.@findex SImode@item SImode``Single Integer'' mode represents a four-byte integer.@findex PDImode@item PDImode``Partial Double Integer'' mode represents an integer which occupieseight bytes but which doesn't really use all eight. On some machines,this is the right mode to use for certain pointers.@findex DImode@item DImode``Double Integer'' mode represents an eight-byte integer.@findex TImode@item TImode``Tetra Integer'' (?) mode represents a sixteen-byte integer.@findex SFmode@item SFmode``Single Floating'' mode represents a single-precision (four byte) floatingpoint number.@findex DFmode@item DFmode``Double Floating'' mode represents a double-precision (eight byte) floatingpoint number.@findex XFmode@item XFmode``Extended Floating'' mode represents a triple-precision (twelve byte)floating point number. This mode is used for IEEE extended floatingpoint.@findex TFmode@item TFmode``Tetra Floating'' mode represents a quadruple-precision (sixteen byte)floating point number.@findex CCmode@item CCmode``Condition Code'' mode represents the value of a condition code, whichis a machine-specific set of bits used to represent the result of acomparison operation. Other machine-specific modes may also be used forthe condition code. These modes are not used on machines that use@code{cc0} (see @pxref{Condition Code}).@findex BLKmode@item BLKmode``Block'' mode represents values that are aggregates to which none ofthe other modes apply. In RTL, only memory references can have this mode,and only if they appear in string-move or vector instructions. On machineswhich have no such instructions, @code{BLKmode} will not appear in RTL.@findex VOIDmode@item VOIDmodeVoid mode means the absence of a mode or an unspecified mode.For example, RTL expressions of code @code{const_int} have mode@code{VOIDmode} because they can be taken to have whatever mode the contextrequires. In debugging dumps of RTL, @code{VOIDmode} is expressed bythe absence of any mode.@findex SCmode@findex DCmode
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -