-/**
- * Get register constraints for an operand at position @p
- */
-static inline const arch_register_req_t *arch_get_in_register_req(
- const ir_node *node, int pos)
-{
- const backend_info_t *info = be_get_info(node);
- if (info->in_reqs == NULL)
- return arch_no_register_req;
- return info->in_reqs[pos];
-}
-
-/**
- * Get register constraint for a produced result (the @p pos result)
- */
-static inline const arch_register_req_t *arch_get_out_register_req(
- const ir_node *node, int pos)
-{
- const backend_info_t *info = be_get_info(node);
- if (info->out_infos == NULL)
- return arch_no_register_req;
- return info->out_infos[pos].req;
-}
-
-static inline void arch_set_out_register_req(ir_node *node, int pos,
- const arch_register_req_t *req)
-{
- backend_info_t *info = be_get_info(node);
- assert(pos < (int) arch_irn_get_n_outs(node));
- info->out_infos[pos].req = req;
-}
-
-static inline void arch_set_in_register_reqs(ir_node *node,
- const arch_register_req_t **in_reqs)
-{
- backend_info_t *info = be_get_info(node);
- info->in_reqs = in_reqs;
-}
-
-static inline const arch_register_req_t **arch_get_in_register_reqs(
- const ir_node *node)
-{
- backend_info_t *info = be_get_info(node);
- return info->in_reqs;
-}
-
-/**
- * Check if the given register is callee save, ie. will be save by the callee.
- */
-static inline bool arch_register_is_callee_save(
- const arch_env_t *arch_env,
- const arch_register_t *reg)
-{
- if (arch_env->impl->register_saved_by)
- return arch_env->impl->register_saved_by(reg, /*callee=*/1);
- return false;
-}
-
-/**
- * Check if the given register is caller save, ie. must be save by the caller.
- */
-static inline bool arch_register_is_caller_save(
- const arch_env_t *arch_env,
- const arch_register_t *reg)
-{
- if (arch_env->impl->register_saved_by)
- return arch_env->impl->register_saved_by(reg, /*callee=*/0);
- return false;
-}
-