[PATCH] D120026: [ARM] Fix ARM backend to correctly use atomic expansion routines.

Eli Friedman via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Apr 4 14:40:28 PDT 2022


efriedma added a comment.

It probably makes sense to add `#error` to atomics.c, I guess, so that particular mistake gets caught at compile-time, not runtime.

Beyond that, though, I'm not sure what else I can do here.  I guess I could set `setMaxAtomicSizeInBitsSupported(32)` for Cortex-M0, even though the target doesn't really have such atomics, and document "users must provide __sync_*_{1,2,4}".  That seems a bit weird, though; like I mentioned before, we have no way to actually provide them.  (I guess we could provide them off-by-default, or something, but again, I don't want to mess with the interrupt mask behind the user's back.)


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D120026/new/

https://reviews.llvm.org/D120026



More information about the llvm-commits mailing list