location_t locus = gimple_location (stmt);
- if (gimple_asm_input_p (stmt))
+ if (gimple_asm_basic_p (stmt))
{
const char *s = gimple_asm_string (stmt);
tree string = build_string (strlen (s), s);
@code{GIMPLE_ASM} @code{G}.
@end deftypefn
+@deftypefn {GIMPLE function} bool gimple_asm_basic_p (const gasm *g)
+Return true if @code{G} is a basic asm rather than an extended asm.
+@end deftypefn
+
+@deftypefn {GIMPLE function} void gimple_asm_set_basic (gasm *g, bool basic_p)
+Mark asm statement @code{G} as a basic asm or an extended asm based on
+@code{BASIC_P}.
+@end deftypefn
+
@deftypefn {GIMPLE function} bool gimple_asm_volatile_p (const gasm *g)
Return true if @code{G} is an asm statement marked volatile.
@end deftypefn
}
/* Non-empty basic ASM implicitly clobbers memory. */
- if (gimple_asm_input_p (stmt) && strlen (gimple_asm_string (stmt)) != 0)
+ if (gimple_asm_basic_p (stmt) && strlen (gimple_asm_string (stmt)) != 0)
return true;
return false;
Keep this list sorted. */
enum gf_mask {
- GF_ASM_INPUT = 1 << 0,
+ GF_ASM_BASIC = 1 << 0,
GF_ASM_VOLATILE = 1 << 1,
GF_ASM_INLINE = 1 << 2,
GF_CALL_FROM_THUNK = 1 << 0,
}
-/* If INPUT_P is true, mark asm ASM_STMT as an ASM_INPUT. */
+/* Mark whether asm ASM_STMT is a basic asm or an extended asm, based on
+ BASIC_P. */
inline void
-gimple_asm_set_input (gasm *asm_stmt, bool input_p)
+gimple_asm_set_basic (gasm *asm_stmt, bool basic_p)
{
- if (input_p)
- asm_stmt->subcode |= GF_ASM_INPUT;
+ if (basic_p)
+ asm_stmt->subcode |= GF_ASM_BASIC;
else
- asm_stmt->subcode &= ~GF_ASM_INPUT;
+ asm_stmt->subcode &= ~GF_ASM_BASIC;
}
-/* Return true if asm ASM_STMT is an ASM_INPUT. */
+/* Return true if asm ASM_STMT is a basic asm rather than an extended asm. */
inline bool
-gimple_asm_input_p (const gasm *asm_stmt)
+gimple_asm_basic_p (const gasm *asm_stmt)
{
- return (asm_stmt->subcode & GF_ASM_INPUT) != 0;
+ return (asm_stmt->subcode & GF_ASM_BASIC) != 0;
}
ASM_VOLATILE_P (expr)
|| noutputs == 0
|| labels);
- gimple_asm_set_input (stmt, ASM_BASIC_P (expr));
+ gimple_asm_set_basic (stmt, ASM_BASIC_P (expr));
gimple_asm_set_inline (stmt, ASM_INLINE_P (expr));
gimplify_seq_add_stmt (pre_p, stmt);
if (gimple_asm_volatile_p (g1) != gimple_asm_volatile_p (g2))
return false;
- if (gimple_asm_input_p (g1) != gimple_asm_input_p (g2))
+ if (gimple_asm_basic_p (g1) != gimple_asm_basic_p (g2))
return false;
if (gimple_asm_inline_p (g1) != gimple_asm_inline_p (g2))
}
if (gasm *asm_stmt = dyn_cast <gasm *> (t))
- if (gimple_asm_volatile_p (asm_stmt) || gimple_asm_input_p (asm_stmt))
+ if (gimple_asm_volatile_p (asm_stmt) || gimple_asm_basic_p (asm_stmt))
return true;
return false;