[Bug target/104914] [MIPS] wrong comparison with scrabbled int value

2023-07-05 Thread syq at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104914

--- Comment #6 from YunQiang Su  ---
In RTL (xx.c.256r.expand), there is 

(insn 10 9 11 2 (set (zero_extract:DI (reg/v:DI 200 [ val ])
(const_int 8 [0x8])
(const_int 0 [0]))
(subreg:DI (reg:QI 202) 0)) "xx.c":4:29 -1
 (nil))


Maybe, it wrong as the mode cannot show the real length of val.

[Bug target/104914] [MIPS] wrong comparison with scrabbled int value

2023-07-04 Thread syq at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104914

--- Comment #5 from YunQiang Su  ---
Another possible fix is to emit a SLL for extendsidi2, but
I am worrying about it may break something else.

[Bug target/104914] [MIPS] wrong comparison with scrabbled int value

2023-07-04 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104914

Andrew Pinski  changed:

   What|Removed |Added

 CC||pinskia at gcc dot gnu.org

--- Comment #4 from Andrew Pinski  ---
I had remembered fixing a similar issue before. I will look at this later
today. And yes ins should have been used instead of dins.

[Bug target/104914] [MIPS] wrong comparison with scrabbled int value

2023-07-04 Thread syq at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104914

--- Comment #3 from YunQiang Su  ---
Ohhh, I think that the real problem is that:

why DINS is used instead of INS when work with an INT?

[Bug target/104914] [MIPS] wrong comparison with scrabbled int value

2023-07-04 Thread syq at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104914

YunQiang Su  changed:

   What|Removed |Added

 CC||syq at gcc dot gnu.org

--- Comment #2 from YunQiang Su  ---
In fact, gcc-11 works with `short', for which, seh is used to sign extending.

[Bug target/104914] [MIPS] wrong comparison with scrabbled int value

2022-03-14 Thread mmyangfl at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104914

--- Comment #1 from Yangfl  ---
Original issue: https://github.com/matplotlib/matplotlib/issues/21789