[Bug target/124670] New: bpf: Fix bogosity in zero_extendsidi2 for reg -> reg

vineetg at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Fri Mar 27 20:59:17 GMT 2026


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

            Bug ID: 124670
           Summary: bpf: Fix bogosity in zero_extendsidi2 for reg -> reg
           Product: gcc
           Version: 16.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: target
          Assignee: unassigned at gcc dot gnu.org
          Reporter: vineetg at gcc dot gnu.org
  Target Milestone: ---

When debugging the ABI codegen noticed that zero_extendsidi2 currently
generates a noop

RTL

(insn 15 14 16 (set (reg:DI 0 %r0 [24])
        (zero_extend:DI (reg:SI 0 %r0 [23]))) {zero_extendsidi2}
     (nil))

current asm
    r0 = r1

expected asm
    w0 = w1

Testing a patch which fixes this.


More information about the Gcc-bugs mailing list