stfc / RegentParticleDSL

A particle-method DSL based on Regent programming language
MIT License
1 stars 0 forks source link

New feature: Pairwise interactions have access to config fspace #84

Closed LonelyCat124 closed 3 years ago

LonelyCat124 commented 3 years ago

This is required for DL_MESO style interactions, along with many others.

LonelyCat124 commented 3 years ago

Ok, so the plan is to modify in this way:

Pairwise tasks are read-only for the config (until I need more...). This means the invoke framework can ignore the accesses for their decisions for now.

For per-particle tasks - I will enable reduction and reads. The invoke framework will check if any reduction fields are used on the config, and disable merging if so.

LonelyCat124 commented 3 years ago

Ok, so pairwise tasks already allow reads(config) so nothing needs to change for those at the moment.

The only change needed for pairwise kernels is the need to pass the config into the kernel

LonelyCat124 commented 3 years ago

Re: per-particle tasks and invoke framework.

The invoke framework will actually check for privilege collisions between the config fields already, so I think this doesn't need to be touched since kernels of different types are never merged.

LonelyCat124 commented 3 years ago

An implementation now is commited in the DL_MESO_IO branch. I've tested it in a simple way, however there could be issues about this in the future.

LonelyCat124 commented 3 years ago

Pairwise need to allow reduction to the config, so need to switch to use three_region_privilege

LonelyCat124 commented 3 years ago

I have an implementation of this (To be tested) for 3D periodic symmetric pairwise.

LonelyCat124 commented 3 years ago

This is implemented in the dl_meso branch now.