Skip to content
Snippets Groups Projects
This project is mirrored from https://github.com/seL4/seL4.git. Pull mirroring failed .
Repository mirroring has been paused due to too many failed attempts. It can be resumed by a project maintainer or owner.
Last successful update .
  1. Nov 16, 2023
  2. Nov 15, 2023
  3. Nov 10, 2023
  4. Nov 08, 2023
  5. Nov 07, 2023
  6. Nov 02, 2023
  7. Oct 31, 2023
    • Hesham Almatary's avatar
      Add "ax" flags to .section directives in assembly · 5b4fb3e3
      Hesham Almatary authored
      This commit fixes a linking error when using LLVM's lld.
      
      llvm-as doesn't assume or assign section flags for input section if
      not specified. This will make the section non-allocatable and put
      into a none segment and trigger relocation linking errors against
      symbols in non-allocatble sections.
      
      For example, when building with LLVM/lld for AArch64, the following
      error occurs:
      (traps.S.obj:(function arm_vector_table: .vectors+0x0): has non-ABS
      relocation R_AARCH64_JUMP26 against symbol 'invalid_vector_entry')
      This does not happen with ld.bfd (GNU's linker) as it seems to allow
      relocations against symbols in non-allocatable sections.
      
      The GNU's assembler documentation states that:
      "If no flags are specified, the default flags depend upon the
      section name. If the section name is not recognized, the default
      will be for the section to have none of the above flags: it will
      not be allocated in memory, nor writable, nor executable.
      The section will contain data. [1]"
      
      This commit explicitly sets .section flags in assembly to avoid
      this error and for better intentionality (and good practice)
      without relying on toolchains handling flags and linkage differently.
      
      [1] https://sourceware.org/binutils/docs/as/Section.html
      
      
      
      Sponsored by: DARPA.
      
      Signed-off-by: default avatarHesham Almatary <hesham.almatary@cl.cam.ac.uk>
      5b4fb3e3
  8. Oct 27, 2023
  9. Oct 26, 2023
  10. Oct 25, 2023
  11. Oct 18, 2023
  12. Oct 05, 2023
  13. Aug 27, 2023
  14. Aug 23, 2023
  15. Aug 22, 2023
  16. Aug 14, 2023
  17. Aug 13, 2023
  18. Aug 12, 2023
    • Hesham Almatary's avatar
      riscv: Use jumps instead of branches jumping to C · fc0d257b
      Hesham Almatary authored
      
      Using branch instructions only allows -+4 KiB offseting range
      from the current PC. If the C code is placed (depending on
      linkers and address layout) far more than -+4 KiB, linking
      will fail (e.g., R_RISCV_BRANCH out of range: 4735 is not in
      [-2048, 2047]; references c_handle_fastpath_call.
      
      This commit accounts for this case and uses jumps when jumping
      to C code that should give enough offset range (-+ 1 MiB) and
      make the assembly code more portable.
      
      Signed-off-by: default avatarHesham Almatary <hesham.almatary@cl.cam.ac.uk>
      fc0d257b
  19. Aug 10, 2023
Loading