Skip to content

GitLab

  • Projects
  • Groups
  • Snippets
  • Help
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
  • Sign in / Register
L llvm-project
  • Project overview
    • Project overview
    • Details
    • Activity
    • Releases
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 33
    • Issues 33
    • List
    • Boards
    • Labels
    • Service Desk
    • Milestones
    • Iterations
  • Merge requests 15
    • Merge requests 15
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Operations
    • Operations
    • Metrics
    • Incidents
    • Environments
  • Analytics
    • Analytics
    • CI/CD
    • Code Review
    • Repository
    • Value Stream
  • Snippets
    • Snippets
  • Members
    • Members
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • Morello
  • llvm-project
  • Issues
  • #51

Closed
Open
Created Jun 01, 2022 by Wes Filardo@WesFilardo

ld.lld: error: corrupted .eh_frame: unknown .eh_frame augmentation string: zRC

Building https://github.com/microsoft/snmalloc 9464556129ad38ed6cb19c472981576a93f529d4 (the current head of main, which is not expected to work on CHERI, but should build) with llvm-morello a7d0053c (the current dev) fails with

$ ninja -v -j1 libsnmallocshim.so
[0/2] /usr/bin/cmake -P /home/nwf/cheri/build/snmalloc-morello-purecap-build/CMakeFiles/VerifyGlobs.cmake
[1/2] /home/nwf/cheri/output/morello-sdk/bin/clang++ --target=aarch64-unknown-freebsd13 --sysroot=/home/nwf/cheri/output/rootfs-morello-purecap -DMALLOC_USABLE_SIZE_QUALIFIER=const -DSNMALLOC_BACKTRACE_HEADER=\"execinfo.h\" -DSNMALLOC_CHECK_LOADS=false -DSNMALLOC_EXPORT="__attribute__((visibility(\"default\")))" -DSNMALLOC_NO_REALLOCARR -DSNMALLOC_NO_REALLOCARRAY -DSNMALLOC_PAGEID=false -DSNMALLOC_PLATFORM_HAS_GETENTROPY -DSNMALLOC_USE_THREAD_CLEANUP -Dsnmallocshim_EXPORTS -I/home/nwf/cheri/snmalloc/src -target aarch64-unknown-freebsd13 --sysroot=/home/nwf/cheri/output/rootfs-morello-purecap -B/home/nwf/cheri/output/morello-sdk/bin -mcpu=rainier -march=morello+c64 -mabi=purecap -Xclang -morello-vararg=new -ggdb -gz -DNDEBUG -Wno-error=unused-command-line-argument -Werror=implicit-function-declaration -Werror=format -Werror=incompatible-pointer-types -Werror=cheri-capability-misuse -Werror=cheri-bitwise-operations -Werror=cheri-prototypes -Werror=pass-failed -Werror=undefined-internal -g -fPIC -fvisibility=hidden -fno-exceptions -fno-rtti -Wall -Wextra -Werror -Wundef -Wsign-conversion -Wconversion -fomit-frame-pointer -ffunction-sections -ftls-model=initial-exec -mcx16 -std=gnu++20 -MD -MT CMakeFiles/snmallocshim.dir/src/snmalloc/override/new.cc.o -MF CMakeFiles/snmallocshim.dir/src/snmalloc/override/new.cc.o.d -o CMakeFiles/snmallocshim.dir/src/snmalloc/override/new.cc.o -c /home/nwf/cheri/snmalloc/src/snmalloc/override/new.cc
clang-13: warning: argument unused during compilation: '-mcx16' [-Wunused-command-line-argument]
[2/2] : && /home/nwf/cheri/output/morello-sdk/bin/clang++ --target=aarch64-unknown-freebsd13 --sysroot=/home/nwf/cheri/output/rootfs-morello-purecap -fPIC -target aarch64-unknown-freebsd13 --sysroot=/home/nwf/cheri/output/rootfs-morello-purecap -B/home/nwf/cheri/output/morello-sdk/bin -mcpu=rainier -march=morello+c64 -mabi=purecap -Xclang -morello-vararg=new -ggdb -gz -DNDEBUG -Wno-error=unused-command-line-argument -Werror=implicit-function-declaration -Werror=format -Werror=incompatible-pointer-types -Werror=cheri-capability-misuse -Werror=cheri-bitwise-operations -Werror=cheri-prototypes -Werror=pass-failed -Werror=undefined-internal -g  -target aarch64-unknown-freebsd13 --sysroot=/home/nwf/cheri/output/rootfs-morello-purecap -B/home/nwf/cheri/output/morello-sdk/bin -mcpu=rainier -march=morello+c64 -mabi=purecap -Xclang -morello-vararg=new -fuse-ld=lld --ld-path=/home/nwf/cheri/output/morello-sdk/bin/ld.lld -Wl,--gdb-index -Wl,--compress-debug-sections=zlib   -Wl,--no-undefined -nostdlib++ -Wl,--icf=all -fuse-ld=lld -rdynamic -shared -Wl,-soname,libsnmallocshim.so -o libsnmallocshim.so CMakeFiles/snmallocshim.dir/src/snmalloc/override/new.cc.o  -Wl,-rpath,"\$ORIGIN/../lib"  -pthread  /home/nwf/cheri/output/rootfs-morello-purecap/usr/lib/libexecinfo.so && :
FAILED: libsnmallocshim.so
: && /home/nwf/cheri/output/morello-sdk/bin/clang++ --target=aarch64-unknown-freebsd13 --sysroot=/home/nwf/cheri/output/rootfs-morello-purecap -fPIC -target aarch64-unknown-freebsd13 --sysroot=/home/nwf/cheri/output/rootfs-morello-purecap -B/home/nwf/cheri/output/morello-sdk/bin -mcpu=rainier -march=morello+c64 -mabi=purecap -Xclang -morello-vararg=new -ggdb -gz -DNDEBUG -Wno-error=unused-command-line-argument -Werror=implicit-function-declaration -Werror=format -Werror=incompatible-pointer-types -Werror=cheri-capability-misuse -Werror=cheri-bitwise-operations -Werror=cheri-prototypes -Werror=pass-failed -Werror=undefined-internal -g  -target aarch64-unknown-freebsd13 --sysroot=/home/nwf/cheri/output/rootfs-morello-purecap -B/home/nwf/cheri/output/morello-sdk/bin -mcpu=rainier -march=morello+c64 -mabi=purecap -Xclang -morello-vararg=new -fuse-ld=lld --ld-path=/home/nwf/cheri/output/morello-sdk/bin/ld.lld -Wl,--gdb-index -Wl,--compress-debug-sections=zlib   -Wl,--no-undefined -nostdlib++ -Wl,--icf=all -fuse-ld=lld -rdynamic -shared -Wl,-soname,libsnmallocshim.so -o libsnmallocshim.so CMakeFiles/snmallocshim.dir/src/snmalloc/override/new.cc.o  -Wl,-rpath,"\$ORIGIN/../lib"  -pthread  /home/nwf/cheri/output/rootfs-morello-purecap/usr/lib/libexecinfo.so && :
ld.lld: error: corrupted .eh_frame: unknown .eh_frame augmentation string: zRC
>>> defined in CMakeFiles/snmallocshim.dir/src/snmalloc/override/new.cc.o:(.eh_frame+0x9)
clang-13: error: linker command failed with exit code 1 (use -v to see invocation)
ninja: build stopped: subcommand failed.

The static objects, including the tests, on the other hand, appear to build and run fine, as does a for-aarch64/hybrid build. Looking around the tree, this looks like it might be some overzealous preparation for CFI. Have I accidentally turned something on I didn't mean to?

To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Assignee
Assign to
None
Milestone
None
Assign milestone
Time tracking