Commit 0910ef4a authored by Matthias Braun's avatar Matthias Braun
Browse files

ia32: fix overly conservative upper_bits_clean (by avoiding undefined behaviour)

parent a579c4b6
......@@ -3022,7 +3022,8 @@ static bool upper_bits_clean(ir_node *transformed_node, ir_mode *mode)
return shifted == 0 || shifted == -1;
} else {
unsigned long shifted = (unsigned long)attr->offset;
shifted >>= get_mode_size_bits(mode);
shifted >>= get_mode_size_bits(mode)-1;
shifted >>= 1;
return shifted == 0;
}
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment