i386: Fix assert in ix86_function_arg [PR105970]
commit1f8278bfcfc7f7157bf2b405471e67dd5097636b
authorUros Bizjak <ubizjak@gmail.com>
Fri, 17 Jun 2022 15:01:31 +0000 (17 17:01 +0200)
committerUros Bizjak <ubizjak@gmail.com>
Fri, 17 Jun 2022 15:02:25 +0000 (17 17:02 +0200)
tree7f052ad695f3635dbdd7485eb60fea53c53bc567
parent1d6044c250e3badfa2a403fee670b295106bf4fc
i386: Fix assert in ix86_function_arg [PR105970]

The mode of pointer argument should equal ptr_mode, not Pmode.

2022-06-17  Uroš Bizjak  <ubizjak@gmail.com>

gcc/ChangeLog:

PR target/105970
* config/i386/i386.cc (ix86_function_arg): Assert that
the mode of pointer argumet is equal to ptr_mode, not Pmode.

gcc/testsuite/ChangeLog:

PR target/105970
* gcc.target/i386/pr105970.c: New test.
gcc/config/i386/i386.cc
gcc/testsuite/gcc.target/i386/pr105970.c [new file with mode: 0644]