[hackers] [scc] [cc2-qbe] Add OPTR operation || Roberto E. Vargas Caballero

From: <git_AT_suckless.org>
Date: Sat, 23 Apr 2016 19:05:56 +0200 (CEST)

commit 18152113a1cefc45b164a77e476e2b958744f8cc
Author: Roberto E. Vargas Caballero <Roberto E. Vargas Caballero>
AuthorDate: Fri Apr 22 22:03:17 2016 +0200
Commit: Roberto E. Vargas Caballero <Roberto E. Vargas Caballero>
CommitDate: Fri Apr 22 22:04:41 2016 +0200

    [cc2-qbe] Add OPTR operation
    
    In this case we only have to load twice the child
    of the node.

diff --git a/cc2/arch/qbe/cgen.c b/cc2/arch/qbe/cgen.c
index 9b4e61c..74bfff3 100644
--- a/cc2/arch/qbe/cgen.c
+++ b/cc2/arch/qbe/cgen.c
_AT_@ -290,7 +290,10 @@ cgen(Node *np)
         case OPAR:
         case ONEG:
         case OADDR:
+ abort();
         case OPTR:
+ np->left = load(load(l));
+ return tmpnode(np);
         case OINC:
         case ODEC:
                 abort();
Received on Sat Apr 23 2016 - 19:05:56 CEST

This archive was generated by hypermail 2.3.0 : Sat Apr 23 2016 - 19:12:28 CEST