# Y2038 compliance broken on 32bit

**URL:** https://forum.ada-lang.io/t/y2038-compliance-broken-on-32bit/4731
**Category:** General
**Tags:** gnat
**Created:** [September 10, 2026, 10:39am UTC](https://forum.ada-lang.io/t/y2038-compliance-broken-on-32bit/4731 "2026-09-10T10:39:42Z")
**Posts on this page:** 10
**Page:** 1

<div class="post-metadata">

### Author: ![PeterBB](https://forum.ada-lang.io/user_avatar/forum.ada-lang.io/peterbb/32/1089_2.png) [@PeterBB](https://forum.ada-lang.io/u/PeterBB)
#### Post date: [September 10, 2026, 10:39am UTC](https://forum.ada-lang.io/t/y2038-compliance-broken-on-32bit/4731/1 "2026-09-10T10:39:43Z")

</div>

Hi,

regarding [Bug report](https://gcc.gnu.org/bugzilla/show_bug.cgi?id=114065)

Wondering if there is any chance of this being fixed in 16.3?

Leads to another question. What is the future, for gnat on 32bit?

Regards,

Peter

---

<div class="post-metadata">

### Author: ![godunko](https://forum.ada-lang.io/user_avatar/forum.ada-lang.io/godunko/32/22_2.png) [@godunko](https://forum.ada-lang.io/u/godunko)
#### Post date: [September 10, 2026, 2:31pm UTC](https://forum.ada-lang.io/t/y2038-compliance-broken-on-32bit/4731/2 "2026-09-10T14:31:07Z")

</div>

I suppose 32bit era comes to past. Except embedded systems, but usually they are crosses hosted on 64bit

---

<div class="post-metadata">

### Author: ![PeterBB](https://forum.ada-lang.io/user_avatar/forum.ada-lang.io/peterbb/32/1089_2.png) [@PeterBB](https://forum.ada-lang.io/u/PeterBB)
#### Post date: [September 11, 2026, 9:10pm UTC](https://forum.ada-lang.io/t/y2038-compliance-broken-on-32bit/4731/3 "2026-09-11T21:10:57Z")

</div>

Having looked into this a bit further, it seems to me that time routines are generally OK,

but dates after Y-2038 are broken on 32 bit. (Y2038 is fine on 64bit)

---

<div class="post-metadata">

### Author: ![PeterBB](https://forum.ada-lang.io/user_avatar/forum.ada-lang.io/peterbb/32/1089_2.png) [@PeterBB](https://forum.ada-lang.io/u/PeterBB)
#### Post date: [September 13, 2026, 12:58pm UTC](https://forum.ada-lang.io/t/y2038-compliance-broken-on-32bit/4731/4 "2026-09-13T12:58:42Z")

</div>

```ada
-- Test y2038 compliance with
-- faketime -f '+20y' ./test

with Ada.Calendar, Ada.Text_IO;
procedure test is
   Y : Ada.Calendar.Year_Number;
   M : Ada.Calendar.Month_Number;
   D : Ada.Calendar.Day_Number;
   S : Duration;

begin
   Ada.Calendar.Split (Ada.Calendar.Clock, Y, M, D, S);
   Ada.Text_IO.Put_Line (Y'Img & M'Img & D'Img);
end test;

```

---

<div class="post-metadata">

### Author: ![dmitry-kazakov](https://forum.ada-lang.io/user_avatar/forum.ada-lang.io/dmitry-kazakov/32/522_2.png) [@dmitry-kazakov](https://forum.ada-lang.io/u/dmitry-kazakov)
#### Post date: [September 13, 2026, 1:37pm UTC](https://forum.ada-lang.io/t/y2038-compliance-broken-on-32bit/4731/5 "2026-09-13T13:37:47Z")

</div>

> [@PeterBB](#):
>
> `faketime -f '+20y' ./test`

The most recent 32-bit GNAT I have is 14.2.0 on armhf gives wrong answer:

` 1910 8 3`

---

<div class="post-metadata">

### Author: ![PeterBB](https://forum.ada-lang.io/user_avatar/forum.ada-lang.io/peterbb/32/1089_2.png) [@PeterBB](https://forum.ada-lang.io/u/PeterBB)
#### Post date: [September 13, 2026, 7:28pm UTC](https://forum.ada-lang.io/t/y2038-compliance-broken-on-32bit/4731/6 "2026-09-13T19:28:27Z")

</div>

Indeed. It’s not a recent regression.  
I’ve tested 32bit gnat versions, 13, 14, 15, 16 and its broken on all of them.

---

<div class="post-metadata">

### Author: ![PeterBB](https://forum.ada-lang.io/user_avatar/forum.ada-lang.io/peterbb/32/1089_2.png) [@PeterBB](https://forum.ada-lang.io/u/PeterBB)
#### Post date: [September 18, 2026, 10:24am UTC](https://forum.ada-lang.io/t/y2038-compliance-broken-on-32bit/4731/7 "2026-09-18T10:24:17Z")

</div>

This topic should be tagged ‘gnat’ rather than ‘releases’.

Is there any way to retag it?

---

<div class="post-metadata">

### Author: ![AdaOrbit](https://forum.ada-lang.io/user_avatar/forum.ada-lang.io/adaorbit/32/879_2.png) [@AdaOrbit](https://forum.ada-lang.io/u/AdaOrbit)
#### Post date: [September 18, 2026, 11:24am UTC](https://forum.ada-lang.io/t/y2038-compliance-broken-on-32bit/4731/8 "2026-09-18T11:24:54Z")

</div>

Hi, the _category_ is ‘release’ and there is no ‘gnat’ category. I can change it to ‘help’ if you want.

For now I have added the gnat tag but didn’t change the category (unless you want me to).

---

<div class="post-metadata">

### Author: ![PeterBB](https://forum.ada-lang.io/user_avatar/forum.ada-lang.io/peterbb/32/1089_2.png) [@PeterBB](https://forum.ada-lang.io/u/PeterBB)
#### Post date: [September 18, 2026, 1:03pm UTC](https://forum.ada-lang.io/t/y2038-compliance-broken-on-32bit/4731/9 "2026-09-18T13:03:01Z")

</div>

Thanks for adding the ‘gnat’ tag.  
Yes, please remove ‘release’ category. As the bug exists in 13-16, and probably always existed,

it clearly has nothing to do with any recent release.

---

<div class="post-metadata">

### Author: ![PeterBB](https://forum.ada-lang.io/user_avatar/forum.ada-lang.io/peterbb/32/1089_2.png) [@PeterBB](https://forum.ada-lang.io/u/PeterBB)
#### Post date: [September 18, 2026, 2:15pm UTC](https://forum.ada-lang.io/t/y2038-compliance-broken-on-32bit/4731/10 "2026-09-18T14:15:10Z")

</div>

And, if possible , “Y2038 compliance broken on 32bit”,

would be a better title.
