This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug target/79904] ICE in annotate_constant_pool_refs, at config/s390/s390.c:7909


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=79904

--- Comment #3 from Dominik Vogt <vogt at linux dot vnet.ibm.com> ---
Not sure what that means:

When UBSAN_CHECK_MUL is expanded, the generated Rtl wants the vector constant
"3" in the litaral pool (insn 30):

--
;; _2 = UBSAN_CHECK_MUL (_1, { 11, 22, 33, 44, 0, 0, 0, 0 });
(insn 23 22 24 (set (reg:DI 69) (const_int 0 [0]))
(code_label 24 23 25 4 (nil) [0 uses])
(insn 25 24 26 (set (mem/c:DI (plus:DI (reg/f:DI 55 virtual-stack-vars)
                (const_int -24 [0xffffffffffffffe8])) [0  S8 A64])
        (reg:DI 60 [ _1 ]))
(insn 26 25 27 (set (reg:QI 72)
        (mem/j:QI (plus:DI (plus:DI (reg/f:DI 55 virtual-stack-vars)
                    (reg:DI 69))
                (const_int -24 [0xffffffffffffffe8])) [0  S1 A8]))
(insn 27 26 28 (set (reg:SI 71)
        (ashift:SI (subreg:SI (reg:QI 72) 0)
            (const_int 24 [0x18]))) "/home/vogt/z.c":5 -1
(insn 28 27 29 (parallel [
            (set (reg:SI 71)
                (ashiftrt:SI (reg:SI 71)
                    (const_int 24 [0x18])))
            (clobber (reg:CC 33 %cc))
(insn 29 28 30 (set (reg:HI 70)
        (subreg:HI (reg:SI 71) 2))
(insn 30 29 31 (set (reg:QI 75)
        (mem/u/j:QI (plus:DI (reg:DI 69)
                (symbol_ref/u:DI ("*.LC1") [flags 0x2])) [0  S1 A8]))
                                 ^^^^^^^^^
...
--

Without Ubsan, each byte of the vector is expanded to separate code, loading
the constant and the vector element and multiplying both, without involving the
literal pool.  Is that the fault of the backend (i.e. not supporting vector Gcc
constants in the literal pool; or not telling Ubsan that vector constants are
not supported) or the fault of the Ubsan code that generates a literal pool Gcc
vector constant when it shouldn't?

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]