#1761 Test for #3184920 failing

closed-fixed
5
2011-02-20
2011-02-19
No

support/regression/tests/bug-3184920.c fails for hc08. To reproduce remove the #if !defined(SDCC_hc08) in that file.

Philipp

Discussion

  • Erik Petrich

    Erik Petrich - 2011-02-20
    • labels: 587905 --> regression test
     
  • Erik Petrich

    Erik Petrich - 2011-02-20

    It's a bug in the hc08 port only to the extent that some feel that big endian architectures are a bug. For this reason it also fails the host target on sparc64-unknown-netbsd and sparc-sun-solaris systems in our distributed compiler farm. If this test was addressing a problem in the z80 code generator, perhaps #if defined(SDCC_z80) would be better. Otherwise I think we need an endian.h and use it to make this test endian agnostic.

     
  • Maarten Brock

    Maarten Brock - 2011-02-20

    Endianness can be solved by accepting either order in the check. Though I'm not sure if that may accidentally pass for the original bug.

    But it will also fail when structs are not packed to byte boundaries which is likely on any non-8-bit architecture. That it passes for gcc on x86 seems pure luck.

     
  • Philipp Klaus Krause

    • assigned_to: nobody --> spth
    • status: open --> open-fixed
     
  • Philipp Klaus Krause

    Fixed in revision #6238.

    Philipp

     
  • Philipp Klaus Krause

    • status: open-fixed --> closed-fixed
     

Log in to post a comment.