summaryrefslogtreecommitdiffstats
path: root/llvm/lib
diff options
context:
space:
mode:
authorRui Ueyama <ruiu@google.com>2016-02-12 21:47:28 +0000
committerRui Ueyama <ruiu@google.com>2016-02-12 21:47:28 +0000
commit1ebc8ed78ac5df1ad5ba68eb8d8974c1cea1bffa (patch)
tree76d7ab09c995345f315b6b62ce3a2a43c789d31b /llvm/lib
parent595c13771d4bfdeea5f2e95a0bc82c5049f65f11 (diff)
downloadbcm5719-llvm-1ebc8ed78ac5df1ad5ba68eb8d8974c1cea1bffa.tar.gz
bcm5719-llvm-1ebc8ed78ac5df1ad5ba68eb8d8974c1cea1bffa.zip
ELF: Add wildcard pattern matching to SECTIONS linker script command.
Each rule in SECTIONS commands is something like ".foo *(.baz.*)", which instructs the linker to collect all sections whose name matches ".baz.*" from all files and put them into .foo section. Previously, we didn't recognize the wildcard character. This patch adds that feature. Performance impact is a bit concerning because a linker script can contain hundreds of SECTIONS rules, and doing pattern matching against each rule would be too expensive. We could merge all patterns into single DFA so that it takes O(n) to the input size. However, it is probably too much at this moment -- we don't know whether the performance of pattern matching matters or not. So I chose to implement the simplest algorithm in this patch. I hope this simple pattern matcher is sufficient. llvm-svn: 260745
Diffstat (limited to 'llvm/lib')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud