Re: [PATCH] Fix rotate discovery in fold-const.c (PR tree-optimization/65014)

2015-02-12 Thread Richard Biener
On Thu, 12 Feb 2015, Jakub Jelinek wrote: > Hi! > > We pass the values after STRIP_NOPS to *ROTATE_EXPR build, which is > undesirable, as the testcase shows, the operand could very well end up being > a pointer rather than integer. Ugh, indeed tree_nop_conversion_p allows conversion to/from poin

[PATCH] Fix rotate discovery in fold-const.c (PR tree-optimization/65014)

2015-02-11 Thread Jakub Jelinek
Hi! We pass the values after STRIP_NOPS to *ROTATE_EXPR build, which is undesirable, as the testcase shows, the operand could very well end up being a pointer rather than integer. This patch fixes it by passing the original trees instead. Alternatively we could fold_convert the STRIP_NOPS result t