ART: Refactor elf_writer_quick for elf section order

This writes ELF sections in approximate order (debug sections are
currently out-of-order) to avoid incompletely written files
appearing OK to ART loading code.

Bug: 17622827

(cherry picked from commit 3c5ec99e156632a734c2359642ae928102850597)

Change-Id: I812fd42fcf2823dbfaf5891bf101d3b59406f263
1 file changed