Skip to content

Commit

Permalink
Darwin, Arm64 : Darwin should use an OS call to clear caches.
Browse files Browse the repository at this point in the history
The sys_icache_invalidate() function is the right one to use.

The fixes issue #17
  • Loading branch information
iains committed Nov 28, 2020
1 parent c6f95bc commit 00cf379
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
5 changes: 5 additions & 0 deletions gcc/config/aarch64/darwin.h
Original file line number Diff line number Diff line change
Expand Up @@ -217,3 +217,8 @@ along with GCC; see the file COPYING3. If not see

#undef ASM_OUTPUT_DEF_FROM_DECLS

#undef CLEAR_INSN_CACHE
#define CLEAR_INSN_CACHE(beg, end) \
extern void sys_icache_invalidate(void *start, size_t len); \
sys_icache_invalidate ((beg), (size_t)((end)-(beg)))

1 change: 0 additions & 1 deletion libgcc/config.host
Original file line number Diff line number Diff line change
Expand Up @@ -374,7 +374,6 @@ aarch64*-*-elf | aarch64*-*-rtems*)
;;
aarch64*-*darwin* | arm64*-*darwin* )
extra_parts="$extra_parts crtfastmath.o"
tmake_file="${tmake_file} ${cpu_type}/t-aarch64"
tmake_file="${tmake_file} ${cpu_type}/t-lse "
tmake_file="${tmake_file} t-crtfm"
# No soft float for now because our long double is DF not TF.
Expand Down

0 comments on commit 00cf379

Please sign in to comment.