[PATCH 2/4] builtin: allow linearization to fail

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Allow the linearization of builtins to fail and continue with
the normal linearization of OP_CALLs. The motivation for this
is for the linearization of target specific builtins.

Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@xxxxxxxxx>
---
 linearize.c | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

diff --git a/linearize.c b/linearize.c
index 1a2677713123..bf55045bcbce 100644
--- a/linearize.c
+++ b/linearize.c
@@ -1513,8 +1513,11 @@ static pseudo_t linearize_call_expression(struct entrypoint *ep, struct expressi
 	fntype = fn->ctype;
 
 	// handle builtins
-	if (fntype->op && fntype->op->linearize)
-		return fntype->op->linearize(ep, expr);
+	if (fntype->op && fntype->op->linearize) {
+		retval = fntype->op->linearize(ep, expr);
+		if (retval)
+			return retval;
+	}
 
 	ctype = &fntype->ctype;
 	if (fntype->type == SYM_NODE)
-- 
2.28.0




[Index of Archives]     [Newbies FAQ]     [LKML]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Trinity Fuzzer Tool]

  Powered by Linux