在 2022/8/18 下午8:52, Xi Ruoyao 写道:
On Thu, 2022-08-18 at 19:49 +0800, Lulu Cheng wrote:
I think we can ignore the effect of -fplt if code model is extreme,
instead of forcing everyone to explicitly add -fno-plt.  The "large"
code model of x86_64 also does not limit the address range and it always
avoids PLT (even if someone adds "-fplt" explicitly).
     Do you mean that if cmodel=extreme,
       then add -fno-plt by default?
Yes, we should use -fno-plt as the default for cmodel=extreme.

x86_64 silently ignores -fplt for cmodel=large (their "large" is like
our "extreme"), but perhaps it's better for us to just report an error
if someone uses "-mcmodel=extreme -fplt" explicitly (if possible, I'm
not sure if we can determine whether -fplt is explicitly given in the
backend code).


I thought if using -mcmodel=extreme and -fplt at the same time we could add a warning here and inform the user that we changed to noplt.

Reply via email to