~ubuntu-branches/debian/sid/lammps/sid

« back to all changes in this revision

Viewing changes to src/OPT/pair_morse_opt.cpp

  • Committer: Package Import Robot
  • Author(s): Anton Gladky
  • Date: 2015-04-29 23:44:49 UTC
  • mfrom: (5.1.3 experimental)
  • Revision ID: package-import@ubuntu.com-20150429234449-mbhy9utku6hp6oq8
Tags: 0~20150313.gitfa668e1-1
Upload into unstable.

Show diffs side-by-side

added added

removed removed

Lines of Context:
68
68
  double factor_lj;
69
69
  double evdwl = 0.0;
70
70
 
71
 
  double** __restrict__ x = atom->x;
72
 
  double** __restrict__ f = atom->f;
73
 
  int* __restrict__ type = atom->type;
 
71
  double** _noalias x = atom->x;
 
72
  double** _noalias f = atom->f;
 
73
  int* _noalias type = atom->type;
74
74
  int nlocal = atom->nlocal;
75
 
  double* __restrict__ special_lj = force->special_lj;
 
75
  double* _noalias special_lj = force->special_lj;
76
76
 
77
77
  inum = list->inum;
78
 
  int* __restrict__ ilist = list->ilist;
79
 
  int** __restrict__ firstneigh = list->firstneigh;
80
 
  int* __restrict__ numneigh = list->numneigh;
 
78
  int* _noalias ilist = list->ilist;
 
79
  int** _noalias firstneigh = list->firstneigh;
 
80
  int* _noalias numneigh = list->numneigh;
81
81
 
82
 
  vec3_t* __restrict__ xx = (vec3_t*)x[0];
83
 
  vec3_t* __restrict__ ff = (vec3_t*)f[0];
 
82
  vec3_t* _noalias xx = (vec3_t*)x[0];
 
83
  vec3_t* _noalias ff = (vec3_t*)f[0];
84
84
 
85
85
  int ntypes = atom->ntypes;
86
86
  int ntypes2 = ntypes*ntypes;
87
87
 
88
 
  fast_alpha_t* __restrict__ fast_alpha =
 
88
  fast_alpha_t* _noalias fast_alpha =
89
89
    (fast_alpha_t*) malloc(ntypes2*sizeof(fast_alpha_t));
90
90
  for (i = 0; i < ntypes; i++) for (j = 0; j < ntypes; j++) {
91
91
    fast_alpha_t& a = fast_alpha[i*ntypes+j];
96
96
    a.d0 = d0[i+1][j+1];
97
97
    a.offset = offset[i+1][j+1];
98
98
  }
99
 
  fast_alpha_t* __restrict__ tabsix = fast_alpha;
 
99
  fast_alpha_t* _noalias tabsix = fast_alpha;
100
100
 
101
101
  // loop over neighbors of my atoms
102
102
 
106
106
    double ytmp = xx[i].y;
107
107
    double ztmp = xx[i].z;
108
108
    itype = type[i] - 1;
109
 
    int* __restrict__ jlist = firstneigh[i];
 
109
    int* _noalias jlist = firstneigh[i];
110
110
    jnum = numneigh[i];
111
111
 
112
112
    double tmpfx = 0.0;
113
113
    double tmpfy = 0.0;
114
114
    double tmpfz = 0.0;
115
115
 
116
 
    fast_alpha_t* __restrict__ tabsixi = (fast_alpha_t*)&tabsix[itype*ntypes];
 
116
    fast_alpha_t* _noalias tabsixi = (fast_alpha_t*)&tabsix[itype*ntypes];
117
117
 
118
118
    for (jj = 0; jj < jnum; jj++) {
119
119
      j = jlist[jj];