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

--- Comment #2 from David Malcolm <dmalcolm at gcc dot gnu.org> ---
Works for me; I wasn't able to reproduce.

Does the fix for PR jit/82826 (r254458) help?

If I add this to set_options in harness.h:

  gcc_jit_context_set_bool_option (
    ctxt,
    GCC_JIT_BOOL_OPTION_DUMP_GENERATED_CODE,
    1);

it dumps the generated code.

Rerunning using:

  make check-jit RUNTESTFLAGS="-v -v -v jit.exp=test-alignment.c"

I get the following for test_aligned_reading_s2 and test_aligned_writing_s2:

.Ltext0:
        .p2align 4,,15
        .globl  test_aligned_reading_s2
        .type   test_aligned_reading_s2, @function
test_aligned_reading_s2:
.LFB56:
        .cfi_startproc
.LVL0:
        movzbl  (%rdi), %eax
        mulb    2(%rdi)
        ret
        .cfi_endproc
.LFE56:
        .size   test_aligned_reading_s2, .-test_aligned_reading_s2
        .p2align 4,,15
        .globl  test_aligned_writing_s2
        .type   test_aligned_writing_s2, @function
test_aligned_writing_s2:
.LFB57:
        .cfi_startproc
.LVL1:
        movb    $5, (%rdi)
        movb    $7, 2(%rdi)
        jmp     test_aligned_reading_s2@PLT

for the "_s2" case.

What do you get?  Thanks.

Reply via email to