From 18a9fa735503e96d69efd968c542e490abe69be0 Mon Sep 17 00:00:00 2001 From: gingerBill Date: Sat, 12 May 2018 10:27:55 +0100 Subject: Improve minimal dependency system --- src/ir_print.cpp | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'src/ir_print.cpp') diff --git a/src/ir_print.cpp b/src/ir_print.cpp index f8adc1e38..e24859413 100644 --- a/src/ir_print.cpp +++ b/src/ir_print.cpp @@ -1344,9 +1344,15 @@ void ir_print_instr(irFileBuffer *f, irModule *m, irValue *value) { case Token_Or: ir_write_str_lit(f, "or"); break; case Token_Xor: ir_write_str_lit(f, "xor"); break; case Token_Shl: ir_write_str_lit(f, "shl"); break; - case Token_Shr: ir_write_str_lit(f, "lshr"); break; case Token_Mul: ir_write_str_lit(f, "mul"); break; case Token_Not: ir_write_str_lit(f, "xor"); break; + case Token_Shr: + if (is_type_unsigned(elem_type)) { + ir_write_str_lit(f, "lshr"); + } else { + ir_write_str_lit(f, "ashr"); + } + break; case Token_AndNot: GB_PANIC("Token_AndNot Should never be called"); -- cgit v1.2.3