[lld] [lld][macho] Support order cstrings with -order_file_cstring (PR #140307)
Snehasish Kumar via llvm-commits
llvm-commits at lists.llvm.org
Tue May 20 09:15:26 PDT 2025
https://github.com/snehasish commented:
Consider this alternative approach -- can we extend `--symbol_ordering_file` format to include cstrings? E.g. instead of the symbol name on each line we would have something like `<cstr>:hash`.
The concern I have with the current approach is the inability to specify a relative ordering of strings with respect to other static data objects. This is limting for fine grained tuning. Additionally build systems will need to be updated to handle the new flag and additional ordering file artefact. Post-link optimizations like Propeller and Intel's thin layout optimizer use the symbol ordering file too. I think it would be easier for these tools to adopt the static data layout enhancements if we reuse `--symbol_ordering_file` in my opinion.
Wdyt?
https://github.com/llvm/llvm-project/pull/140307
More information about the llvm-commits
mailing list