#2967 closed enhancement (fixed)

ARM: Change ABI to not use short enums

Reported by: Sebastian Huber Owned by: Sebastian Huber
Priority: normal Milestone: 5.1
Component: tool/gcc Version:
Severity: normal Keywords:
Cc: Blocked By:


Whether enums are short or not is left open in the ARM EABI. On Linux and FreeBSD no short enums are used. Otherwise short enums are enabled by default.

Short enums may cause hard to find issues with 3rd party software, since the are quite unusual in general, e.g.


The data and structure layout may suddenly change in case enumeration values are added/removed. The benefit of short enums is probably not worth the trouble, since the packed compiler attribute can be used to individually make an enum short.

The reason for not choosing no short enums during the ARM EABI introduction was an issue with Newlib. This is addressed with the following patch:


Change History (6)

comment:1 Changed on Apr 3, 2017 at 6:07:37 AM by Sebastian Huber

Owner: changed from joel.sherrill@… to Sebastian Huber
Status: newaccepted

comment:3 Changed on Apr 7, 2017 at 7:19:04 AM by Sebastian Huber

GCC website update done (GCC 6.4 changes show up once released):


comment:4 Changed on Jun 8, 2017 at 7:30:12 AM by Sebastian Huber

Resolution: fixed
Status: acceptedclosed

Fixed due to change to GCC 7.1.

comment:5 Changed on Oct 10, 2017 at 5:58:26 AM by Sebastian Huber

Component: GCCtool/gcc

comment:6 Changed on Nov 9, 2017 at 6:27:14 AM by Sebastian Huber


Milestone renamed

Note: See TracTickets for help on using tickets.