[all-commits] [llvm/llvm-project] 8c9863: [libc] Basic implementation of crt0 (#146863)

William Huynh via All-commits all-commits at lists.llvm.org
Thu Jul 31 04:17:39 PDT 2025


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 8c9863eb1e54847ca1d8a4abe8c0e842357d021d
      https://github.com/llvm/llvm-project/commit/8c9863eb1e54847ca1d8a4abe8c0e842357d021d
  Author: William Huynh <William.Huynh at arm.com>
  Date:   2025-07-31 (Thu, 31 Jul 2025)

  Changed paths:
    M libc/startup/baremetal/CMakeLists.txt
    A libc/startup/baremetal/arm/CMakeLists.txt
    A libc/startup/baremetal/arm/start.cpp
    M libc/startup/baremetal/fini.cpp
    A libc/startup/baremetal/fini.h
    M libc/startup/baremetal/init.cpp
    A libc/startup/baremetal/init.h

  Log Message:
  -----------
  [libc] Basic implementation of crt0 (#146863)

In order to run hermetic tests downstream (#145349), we need startup
code. This is based on the crt0 that is present in Arm Toolchain:
https://github.com/arm/arm-toolchain/tree/5446a3cbf4ef73196ccce490fc9fbf87bee093aa/arm-software/embedded/llvmlibc-support/crt0.
Note that some tests do fail due to lack of hardware setup, which will
be implemented at a later time.

Most of the CMake/structure is a copy from the existing code in both
`libc/startup/linux` and `libc/startup/gpu`. It is required to build an
object file to be linked with.

Also add header files for init/fini such that crt0 can use the provided
symbols.

---------

Co-authored-by: Michael Jones <michaelrj at google.com>



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list