Menu

#2789 An unsigned long long arithmetic test from GCC fails for hc08/s08

closed-fixed
None
HC08
5
2019-03-19
2018-07-30
No

In [r10486], an arithmetic test from GCC 8.2 was added to the SDCC regression tests.
The test has multiple parts - the signed long long part fails for all backends except mcs51. The unsigned long long part passes for most backends, but fails for ds390 and hc08/s08. This bug report is about hc08/s08.
To reproduce, remove the preprocessor guard in tests/gcc-torture-execute-arith-rand-ll.c.

Philipp

Discussion

  • Maarten Brock

    Maarten Brock - 2018-12-12

    I'm most likely going to disable the whole longlong.c regression test for hc08 as it overflows the zero page with spill locations.

     
    • Philipp Klaus Krause

      Shouldn't we get a linker error on such an overflow instead of a failure at runtime?

      Philipp

       
      • Maarten Brock

        Maarten Brock - 2018-12-12

        Yes, we should. And with my local modifications (not ready yet) I do and thus observe that it was silently overflowing before. I suspect that the hc08 simulator treats addresses below 0x80 as RAM as well.

        I'm now trying to split the longlong.c tests in three parts so it will fit. If that succeeds we can continue to perform these tests.

         
  • Erik Petrich

    Erik Petrich - 2019-03-19
    • status: open --> closed-fixed
    • assigned_to: Erik Petrich
     
  • Erik Petrich

    Erik Petrich - 2019-03-19

    Same root cause as [#2704] and likewise fixed by [r11119

     

    Related

    Bugs: #2704


Log in to post a comment.

MongoDB Logo MongoDB