[all-commits] [llvm/llvm-project] 0b66b3: [clang][AIX] Fix Overly Strict LTO Option Checking...
Qiongsi Wu via All-commits
all-commits at lists.llvm.org
Tue Jul 11 10:24:57 PDT 2023
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 0b66b3417c026e145708d0e20bfd05a72e79f12a
https://github.com/llvm/llvm-project/commit/0b66b3417c026e145708d0e20bfd05a72e79f12a
Author: Qiongsi Wu <qwu at ibm.com>
Date: 2023-07-11 (Tue, 11 Jul 2023)
Changed paths:
M clang/lib/Driver/ToolChains/CommonArgs.cpp
M clang/test/Driver/ppc-roptr.c
Log Message:
-----------
[clang][AIX] Fix Overly Strict LTO Option Checking against `data-sections` when `mxcoff-roptr` is in Effect
The LTO `-mxcoff-roptr` [[ https://github.com/llvm/llvm-project/blob/c6b2d25927817bdeca99653ee3e66720f33ce3ae/clang/lib/Driver/ToolChains/CommonArgs.cpp#L750 | check ]] against data sections is overly strict and it ignores the fact that [[ https://github.com/llvm/llvm-project/blob/c6b2d25927817bdeca99653ee3e66720f33ce3ae/llvm/lib/LTO/LTOCodeGenerator.cpp#L427 | data sections is on by default on AIX ]], causing valid LTO compilation to fail when `-fdata-sections` is not explicitly specified.
This patch revises the check so that an error is reported only if data sections is explicitly turned off for LTO.
Reviewed By: hubert.reinterpretcast
Differential Revision: https://reviews.llvm.org/D152021
More information about the All-commits
mailing list