[clang][cli] Fix generation of '-fvisibility' with regards to '-mignore-xcoff-visibility'
This patch fixes failure of the `CodeGen/aix-ignore-xcoff-visibility.cpp` test with command line round-trip. The absence of '-fvisibility' implies '-mignore-xcoff-visibility'. The problem is that when '-fvisibility default' is passed to -cc1, it isn't being generated. (This adheres to the principle that generation doesn't produce arguments with default values.) However, that caused '-mignore-xcoff-visibility' to be implied in the generated command line (without '-fvisibility'), while it wasn't implied in the original command line (with '-fvisibility'). This patch fixes that by always generating '-fvisibility' and explains the situation in comment. (The '-mginore-xcoff-visibility' option was added in D87451). Reviewed By: Bigcheese Differential Revision: https://reviews.llvm.org/D97552
Loading
Please sign in to comment