lei added inline comments.
================ Comment at: clang/lib/Basic/Targets/PPC.cpp:566-569 + if (llvm::find(FeaturesVec, "+pcrel") != FeaturesVec.end()) { + Diags.Report(diag::err_opt_not_valid_without_opt) << "-mpcrel" + << "-mprefixed"; + } ---------------- I think this need more thought: ``` $ clang -mcpu=pwr9 -mprefixed -mpcrel test.c -o test error: option '-mpcrel' cannot be specified without '-mprefixed' error: option '-mprefixed' cannot be specified without '-mcpu=pwr10' $ clang -mcpu=pwr9 -mpcrel test.c -o test error: option '-mpcrel' cannot be specified without '-mprefixed' ``` For this, the first err makes not sense since both `-mprefixed` and `-mpcrel` is specified: ``` $ clang -mcpu=pwr9 -mprefixed -mpcrel test.c -o test error: option '-mpcrel' cannot be specified without '-mprefixed' error: option '-mprefixed' cannot be specified without '-mcpu=pwr10' ``` Shouldn't it just give: ``` $ clang -mcpu=pwr9 -mprefixed -mpcrel test.c -o test error: option '-mpcrel' cannot be specified without '-mcpu=pwr10 -mprefixed' ``` For this: ``` $ clang -mcpu=pwr9 -mpcrel test.c -o test error: option '-mpcrel' cannot be specified without '-mprefixed' ``` I think it's better if it says: ``` $ clang -mcpu=pwr9 -mpcrel test.c -o test error: option '-mpcrel' cannot be specified without '-mcpu=pwr10 -mprefixed' ``` Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D109652/new/ https://reviews.llvm.org/D109652 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits