Forráskód Böngészése

aya: handle reordered functions

LLVM will split .text into .text.hot .text.unlikely etc and move the
content around in order to improve locality. We need to parse all the
text sections or relocations can potentially fail.
Alessandro Decina 3 éve
szülő
commit
81a0b61
1 módosított fájl, 1 hozzáadás és 1 törlés
  1. 1 1
      aya/src/obj/mod.rs

+ 1 - 1
aya/src/obj/mod.rs

@@ -277,7 +277,7 @@ impl Object {
                 self.maps
                     .insert(name.to_string(), parse_map(&section, name)?);
             }
-            &[".text"] => self.parse_text_section(section)?,
+            &[name] if name.starts_with(".text") => self.parse_text_section(section)?,
             &[".BTF"] => self.parse_btf(&section)?,
             &[".BTF.ext"] => self.parse_btf_ext(&section)?,
             &["maps", name] => {