[llvm-bugs] [Bug 44198] Report invalid -z flags as errors

via llvm-bugs llvm-bugs at lists.llvm.org
Mon Dec 2 12:15:49 PST 2019


Fangrui Song <i at maskray.me> changed:

           What    |Removed                     |Added
                 CC|                            |i at maskray.me
         Resolution|---                         |INVALID
             Status|NEW                         |RESOLVED

--- Comment #1 from Fangrui Song <i at maskray.me> ---
I believe lld already errors on unknown -z options. See

static void checkZOptions(opt::InputArgList &args) {
  for (auto *arg : args.filtered(OPT_z))
    if (!isKnownZFlag(arg->getValue()))
      error("unknown -z value: " + StringRef(arg->getValue()));

% clang -fuse-ld=lld a.o -Wl,-z,stack_size=0x1000
ld.lld: error: unknown -z value: stack_size=0x1000
clang-10: error: linker command failed with exit code 1 (use -v to see

% ld.lld a.o -z stack_size=0x1000
ld.lld: error: unknown -z value: stack_size=0x1000

Can you check if there is some other issue with the build configuration?

You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20191202/8c709911/attachment.html>

More information about the llvm-bugs mailing list