This change adds support for function linkage and visibility and related
attributes. Most of the test changes are generalizations to allow
'dso_local' to be accepted where we aren't specifically testing for it.
Some tests based on CIR inputs have been updated to add 'private' to
function declarations where required by newly supported interfaces.
The dso-local.c test has been updated to add specific tests for
dso_local being set correctly, and a new test, func-linkage.cpp tests
other linkage settings.
This change sets `comdat` correctly in CIR, but it is not yet applied to
functions when lowering to LLVM IR. That will be handled in a later
change.
This adds alignment support for GlobalOp, LoadOp, and StoreOp.
Tests which failed because cir.store/cir.load now print alignment were
updated with wildcard matches, except where the alignment was relevant
to the test. Tests which check for cir.store/cir.load in cases that
don't have explicit alignment were not updated.
New tests for alignment are alignment.c, align-load.c, and
align-store.c.
We have been using the default names for global symbols to this point.
This change introduces proper name mangling for functions.
This requires introducing a CXXABI class in the CIRGenModule. Because
only target independent name mangling is handled in this patch, the
CXXABI class does not require a target-specific implementation. The
general mechanism for selecting an implementation is introduced here,
but the actual target-specific subclasses are deferred until needed.