aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/flow.c
diff options
authorLuc Van Oostenryck <luc.vanoostenryck@gmail.com>2021-03-14 15:12:21 +0100
committerLuc Van Oostenryck <luc.vanoostenryck@gmail.com>2021-03-19 23:56:44 +0100
commit4ac342d1efdbeda4c8cd3b79d53ae6b15f1f5cfc (patch)
tree3544e4e77215960a67a7dfc49a200016110ffb50 /flow.c
parentffa92f53257da38844e9f6f7ffbd71a777c6e54c (diff)
downloadsparse-dev-4ac342d1efdbeda4c8cd3b79d53ae6b15f1f5cfc.tar.gz
rename insert_branch() to convert_to_jump()
Since the existing branch is now reused, nothing is inserted anymore. So, rename this function to the more explanatory: convert_to_jump(). Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
Diffstat (limited to 'flow.c')
-rw-r--r--flow.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/flow.c b/flow.c
index 38e0ccad..8106cfc0 100644
--- a/flow.c
+++ b/flow.c
@@ -268,7 +268,7 @@ try_to_rewrite_target:
*/
if (bb_list_size(target->parents) != 1)
return retval;
- insert_branch(insn, final);
+ convert_to_jump(insn, final);
return 1;
}
@@ -711,7 +711,7 @@ void vrfy_flow(struct entrypoint *ep)
///
// change a switch or a conditional branch into a branch
-int insert_branch(struct instruction *insn, struct basic_block *target)
+int convert_to_jump(struct instruction *insn, struct basic_block *target)
{
struct basic_block *bb = insn->bb;
struct basic_block *child;