mirror of
				https://github.com/paboyle/Grid.git
				synced 2025-11-01 04:24:32 +00:00 
			
		
		
		
	Peek poke laattice
This commit is contained in:
		| @@ -182,6 +182,14 @@ inline void peekLocalSite(sobj &s,const LatticeView<vobj> &l,Coordinate &site) | |||||||
|        |        | ||||||
|   return; |   return; | ||||||
| }; | }; | ||||||
|  | template<class vobj,class sobj> | ||||||
|  | inline void peekLocalSite(sobj &s,const Lattice<vobj> &l,Coordinate &site) | ||||||
|  | { | ||||||
|  |   autoView(lv,l,CpuRead); | ||||||
|  |   peekLocalSite(s,lv,site); | ||||||
|  |   return; | ||||||
|  | }; | ||||||
|  |  | ||||||
| // Must be CPU write view | // Must be CPU write view | ||||||
| template<class vobj,class sobj> | template<class vobj,class sobj> | ||||||
| inline void pokeLocalSite(const sobj &s,LatticeView<vobj> &l,Coordinate &site) | inline void pokeLocalSite(const sobj &s,LatticeView<vobj> &l,Coordinate &site) | ||||||
| @@ -210,6 +218,14 @@ inline void pokeLocalSite(const sobj &s,LatticeView<vobj> &l,Coordinate &site) | |||||||
|   return; |   return; | ||||||
| }; | }; | ||||||
|  |  | ||||||
|  | template<class vobj,class sobj> | ||||||
|  | inline void pokeLocalSite(const sobj &s, Lattice<vobj> &l,Coordinate &site) | ||||||
|  | { | ||||||
|  |   autoView(lv,l,CpuWrite); | ||||||
|  |   pokeLocalSite(s,lv,site); | ||||||
|  |   return; | ||||||
|  | }; | ||||||
|  |  | ||||||
| NAMESPACE_END(Grid); | NAMESPACE_END(Grid); | ||||||
| #endif | #endif | ||||||
|  |  | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user