Re: [PATCH v3] [PR/target 100316] Allow constant address for __builtin___clear_cache.

2021-10-10 Thread Kito Cheng via Gcc-patches
Committed to trunk :) On Mon, Oct 11, 2021 at 11:23 AM Kito Cheng wrote: > > Hi Richard: > > Test with x86 and rl78, both are rejected by the front-end if modes > are different from Pmode/ptr_mode, > so I'm gonna commit this change :) > > Testcase for x86 / x86_64: > ``` > void test(void) > { >

Re: [PATCH v3] [PR/target 100316] Allow constant address for __builtin___clear_cache.

2021-10-10 Thread Kito Cheng
Hi Richard: Test with x86 and rl78, both are rejected by the front-end if modes are different from Pmode/ptr_mode, so I'm gonna commit this change :) Testcase for x86 / x86_64: ``` void test(void) { int __seg_fs *f = (int __seg_fs *)16; int __seg_fs *g = (int __seg_fs *)32; __builtin___clear_c

Re: [PATCH v3] [PR/target 100316] Allow constant address for __builtin___clear_cache.

2021-10-07 Thread Richard Biener via Gcc-patches
On Fri, Oct 8, 2021 at 4:40 AM Kito Cheng wrote: > > __builtin___clear_cache was able to accept constant address for the > argument, but it seems no longer accept recently, and it even not > accept constant address which is hold in variable when optimization is > enable: > > ``` > void foo3(){ >

[PATCH v3] [PR/target 100316] Allow constant address for __builtin___clear_cache.

2021-10-07 Thread Kito Cheng
__builtin___clear_cache was able to accept constant address for the argument, but it seems no longer accept recently, and it even not accept constant address which is hold in variable when optimization is enable: ``` void foo3(){ void *yy = (void*)0x1000; __builtin___clear_cache(yy, yy); } ```