Skip to content

Commit

Permalink
bug fix for tip data type on beagle3-gpu
Browse files Browse the repository at this point in the history
  • Loading branch information
ayresdl committed Sep 16, 2018
1 parent 9141e60 commit e859dd3
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 7 deletions.
1 change: 0 additions & 1 deletion src/bayes.h
Original file line number Diff line number Diff line change
Expand Up @@ -1304,7 +1304,6 @@ typedef struct modelinfo
int* tiProbIndices; /* array of trans prob indices for Beagle */
MrBFlt* logLikelihoods; /* array of log likelihoods from Beagle */
int beagleInstance; /* beagle instance for division */
long beagleInstanceFlags; /* beagle instance flags for division */
MrBFlt* inWeights; /* array of weights for Beagle root likelihood */
int* bufferIndices; /* array of partial indices for root likelihood */
int* eigenIndices; /* array of eigen indices for root likelihood */
Expand Down
8 changes: 3 additions & 5 deletions src/mbbeagle.c
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ int InitBeagleInstance (ModelInfo *m, int division)
for (i=0; i<numLocalTaxa; i++)
{
#if defined(BEAGLE_MULTIPART_ENABLED) && !defined(BEAGLE_CTIPS_ENABLED)
if (m->isPartAmbig[i] == YES || (m->beagleInstanceFlags & BEAGLE_FLAG_PROCESSOR_GPU))
if (m->isPartAmbig[i] == YES || (beagleFlags & BEAGLE_FLAG_PROCESSOR_GPU))
#else
if (m->isPartAmbig[i] == YES)
#endif
Expand All @@ -128,7 +128,7 @@ int InitBeagleInstance (ModelInfo *m, int division)
for (i=0; i<numLocalTaxa; i++)
{
#if defined(BEAGLE_MULTIPART_ENABLED) && !defined(BEAGLE_CTIPS_ENABLED)
if (m->isPartAmbig[i] == NO && !(m->beagleInstanceFlags & BEAGLE_FLAG_PROCESSOR_GPU))
if (m->isPartAmbig[i] == NO && !(beagleFlags & BEAGLE_FLAG_PROCESSOR_GPU))
#else
if (m->isPartAmbig[i] == NO)
#endif
Expand Down Expand Up @@ -338,8 +338,6 @@ MrBayesPrint ("%s MODEL STATES: %d", spacer, numModelStates);
beagleInstanceCount++;
}

m->beagleInstanceFlags = details.flags;

return beagleInstance;
}

Expand Down Expand Up @@ -1625,7 +1623,7 @@ int InitBeagleMultiPartitionInstance ()
for (i=0; i<numLocalTaxa; i++)
{
#if defined(BEAGLE_MULTIPART_ENABLED) && !defined(BEAGLE_CTIPS_ENABLED)
if (!(m->beagleInstanceFlags & BEAGLE_FLAG_PROCESSOR_GPU))
if (!(beagleFlags & BEAGLE_FLAG_PROCESSOR_GPU))
#else
if (1)
#endif
Expand Down
1 change: 0 additions & 1 deletion src/model.c
Original file line number Diff line number Diff line change
Expand Up @@ -17509,7 +17509,6 @@ int SetModelInfo (void)

# if defined (BEAGLE_ENABLED)
m->beagleInstance = -1; /* beagle instance */
m->beagleInstanceFlags = 0; /* beagle instance flags for division */
m->logLikelihoods = NULL; /* array of log likelihoods from Beagle */
m->inRates = NULL; /* array of category rates for Beagle */
m->branchLengths = NULL; /* array of branch lengths for Beagle */
Expand Down

0 comments on commit e859dd3

Please sign in to comment.