[Bug c++/83710] Unsigned with Signed multiplication followed by right shift

2018-01-06 Thread chanpreet.singh at nxp dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83710 --- Comment #8 from Chanpreet Singh --- (In reply to Jakub Jelinek from comment #7) > You shouldn't read random blogs, but the standard of the language you are > writing in. > E.g. in n3797.pdf it is in [expr]/10: > "Otherwise, the integral promo

[Bug c++/83710] Unsigned with Signed multiplication followed by right shift

2018-01-06 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83710 Jakub Jelinek changed: What|Removed |Added CC||jakub at gcc dot gnu.org --- Comment #7

[Bug c++/83710] Unsigned with Signed multiplication followed by right shift

2018-01-06 Thread chanpreet.singh at nxp dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83710 --- Comment #6 from Chanpreet Singh --- (In reply to Andrew Pinski from comment #5) > (In reply to Chanpreet Singh from comment #4) > > (In reply to Andrew Pinski from comment #3) > > > For imull discussion see > > > https://stackoverflow.com/que

[Bug c++/83710] Unsigned with Signed multiplication followed by right shift

2018-01-06 Thread pinskia at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83710 --- Comment #5 from Andrew Pinski --- (In reply to Chanpreet Singh from comment #4) > (In reply to Andrew Pinski from comment #3) > > For imull discussion see > > https://stackoverflow.com/questions/42587607/why-is-imul-used-for- > > multiplying-

[Bug c++/83710] Unsigned with Signed multiplication followed by right shift

2018-01-06 Thread chanpreet.singh at nxp dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83710 --- Comment #4 from Chanpreet Singh --- (In reply to Andrew Pinski from comment #3) > For imull discussion see > https://stackoverflow.com/questions/42587607/why-is-imul-used-for- > multiplying-unsigned-numbers . I understand that. However, can

[Bug c++/83710] Unsigned with Signed multiplication followed by right shift

2018-01-06 Thread pinskia at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83710 --- Comment #3 from Andrew Pinski --- For imull discussion see https://stackoverflow.com/questions/42587607/why-is-imul-used-for-multiplying-unsigned-numbers .

[Bug c++/83710] Unsigned with Signed multiplication followed by right shift

2018-01-06 Thread chanpreet.singh at nxp dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83710 --- Comment #2 from Chanpreet Singh --- Can you please clarify a bit? In the above code, there are 3 vairable, c(int), b(unsigned int) & a(int). The type of 'a*b' is expected to be (int) [same as type of 'c', as also 'imull' instruction is used].

[Bug c++/83710] Unsigned with Signed multiplication followed by right shift

2018-01-06 Thread sch...@linux-m68k.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83710 Andreas Schwab changed: What|Removed |Added Status|UNCONFIRMED |RESOLVED Resolution|---