From b2bb837d2209a302224d5261d225cf5ed05a72c0 Mon Sep 17 00:00:00 2001 From: Sebastien Bourdeauducq Date: Wed, 23 Jul 2014 17:10:12 -0600 Subject: [PATCH] compiler/ir: add binary AND and OR --- artiq/compiler/ir.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/artiq/compiler/ir.py b/artiq/compiler/ir.py index d31d2f1ea..636757445 100644 --- a/artiq/compiler/ir.py +++ b/artiq/compiler/ir.py @@ -28,8 +28,12 @@ _binop_to_builder = { ast.Mult: "mul", ast.FloorDiv: "sdiv", ast.Mod: "srem", + ast.LShift: "shl", - ast.RShift: "ashr" + ast.RShift: "ashr", + + ast.BitAnd: "and_", + ast.BitOr: "or_", } def _emit_expr(env, builder, ns, node):