Issue 178338
Summary [hexagon] NVCJ encoding failure
Labels backend:Hexagon
Assignees quic-akaryaki
Reporter androm3da
    This reduced test case from the linux kernel fails a roundtrip assembler/disassembler as of 21.x.  But now on main, it no longer fails. 

I bisected this "fix" down to dc3a4c0fcf49 `MC: Restructure MCFragment as a fixed part and a variable tail`.  But I'm under the impression that it's only masking the failure with some unrelated layout changes -- no longer triggering this issue, but the issue remains.

```
$ cat out.s
 .p2align        4
empty_zero_page:
    allocframe(#16)
    memd(r29+#0) = r19:18
        {
                r18 = ##65536
                if (!cmp.gtu(r1,r18.new)) jump:t .LBB0_1
        }
        .p2align 4
.LBB0_1:
        .size   empty_zero_page, .-empty_zero_page
```

```
$ ../obj_llvm/bin/llvm-mc  out.s -filetype=obj | ../obj_llvm/bin/llvm-objdump -d -

<stdin>:        file format elf32-hexagon

Disassembly of section .text:

00000000 <empty_zero_page>:
       0:       02 c0 9d a0     a09dc002 { allocframe(#0x10) } 
       4:       00 d2 dd a1     a1ddd200 { memd(r29+#0x0) = r19:18 } 
       8:       00 44 00 00     00004400 <unknown>
      14:       00 e1 44 22     2244e100 <unknown>
      18: 00 40 00 7f     7f004000 {      nop
      1c:       00 c0 00 7f 7f00c000        nop } 
```
_______________________________________________
llvm-bugs mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs

Reply via email to