[MDEV-27910] Internal compiler error on CentOS 7 ARMv8 GCC 4.8.5 Created: 2022-02-21  Updated: 2022-02-21  Resolved: 2022-02-21

Status: Closed
Project: MariaDB Server
Component/s: Storage Engine - InnoDB
Affects Version/s: N/A
Fix Version/s: 10.8.3

Type: Bug Priority: Blocker
Reporter: Marko Mäkelä Assignee: Marko Mäkelä
Resolution: Fixed Votes: 0
Labels: compilation

Issue Links:
Relates
relates to MDEV-27774 Reduce scalability bottlenecks in mtr... Closed

 Description   

The ancient GCC 4.8.5 cannot create ARMv8 code again, starting with MDEV-27774:

10.8 a635c40648519fd6c3729c9657872a16a0a20821

/home/buildbot/aarch64-centos-7-bintar-initd/build/storage/innobase/buf/buf0flu.cc: In function 'void buf_flush_page_cleaner()':
/home/buildbot/aarch64-centos-7-bintar-initd/build/storage/innobase/buf/buf0flu.cc:2400:1: error: could not split insn
 }
 ^
/home/buildbot/aarch64-centos-7-bintar-initd/build/storage/innobase/buf/buf0flu.cc:2400:1: internal compiler error: in final_scan_insn, at final.c:2897
Please submit a full bug report,
with preprocessed source if appropriate.
See <http://bugzilla.redhat.com/bugzilla> for instructions.
Preprocessed source stored into /tmp/ccNWcq6g.out file, please attach this to your bugreport.

If I remember correctly, Red Hat would tell that GCC 4.8.5 is not supported anymore. So, we will probably have to add some work-around like in MDEV-26467 in order to disable some optimizations when targeting ARMv8 with GCC 4.8.5.



 Comments   
Comment by Marko Mäkelä [ 2022-02-21 ]

It was not sufficient to use

# pragma GCC optimize ("no-expensive-optimizations")

but the compilation did succeed with the following:

# pragma GCC optimize ("O0")

All subsequent code in the file will be compiled in this mode on GCC 4.8.5 for ARMv8, because that old GCC does not support #pragma GCC diagnostic push.

Generated at Thu Feb 08 09:56:32 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.