summaryrefslogtreecommitdiffstats
path: root/llvm/test/CodeGen/ARM/bits.ll
diff options
context:
space:
mode:
authorSimon Atanasyan <simon@atanasyan.com>2014-05-30 05:29:46 +0000
committerSimon Atanasyan <simon@atanasyan.com>2014-05-30 05:29:46 +0000
commit2aae2b460965675656aabb1a19d1effc6a2e2c33 (patch)
treec861696ce0893eab6b94b559982fba6c866cdf2f /llvm/test/CodeGen/ARM/bits.ll
parent47d9ed4e2005795cb1565a5ec1952cabf777ad62 (diff)
downloadbcm5719-llvm-2aae2b460965675656aabb1a19d1effc6a2e2c33.tar.gz
bcm5719-llvm-2aae2b460965675656aabb1a19d1effc6a2e2c33.zip
[ELF] Fix incorrect sorting of .init_array / .fini_array sections.
The main problem is in the predicate passed to the `std::stable_sort()`. This predicate always returns false if **both** section's names do not start with `.init_array` or `.fini_array` prefixes. In short, it does not define a strict weak orderng. Suppose we have the following sections: .A .init_array.1 .init_array.2 The predicate states that: not .init_array.1 < .A not .A < .init_array.2 but .init_array.1 < .init_array.2 !!! The second problem is that `.init_array` section without number should go last in the list. Not it has the lowest priority '0' and goes first. The patch fixes both of the problems. llvm-svn: 209875
Diffstat (limited to 'llvm/test/CodeGen/ARM/bits.ll')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud