On 08/28/2017 09:06 AM, Alexander Monakov wrote:
Hello, The code in record_address_regs shown in the following patch assumes that if a given target cannot have two registers in a memory address, then the sole register, if present, must be the leftmost operand in the PLUS chain. I think this is not true if the target uses unspecs to signify special addressing modes such as TLS. In that case the unspec can be to the left of the register, and this function won't see the register. The proposed fix is to always recurse into non-constant operands like in the adjacent case of index registers being the same as base registers. OK to apply?
Yes. Thank you for the patch, Alexander. As I remember this code was adopted from the old regclass.