| 2517 | } |
| 2518 | |
| 2519 | void |
| 2520 | FabArrayBase::clearThisBD (bool no_assertion) const |
| 2521 | { |
| 2522 | BL_ASSERT(boxarray.empty() || no_assertion || getBDKey() == m_bdkey); |
| 2523 | |
| 2524 | auto cnt_it = m_BD_count.find(m_bdkey); |
| 2525 | if (cnt_it != m_BD_count.end()) |
| 2526 | { |
| 2527 | --(cnt_it->second); |
| 2528 | if (cnt_it->second == 0) |
| 2529 | { |
| 2530 | m_BD_count.erase(cnt_it); |
| 2531 | |
| 2532 | // Since this is the last one built with these BoxArray |
| 2533 | // and DistributionMapping, erase it from caches. |
| 2534 | flushTileArray(IntVect::TheZeroVector(), no_assertion); |
| 2535 | flushFPinfo(no_assertion); |
| 2536 | flushCFinfo(no_assertion); |
| 2537 | flushFB(no_assertion); |
| 2538 | flushCPC(no_assertion); |
| 2539 | flushRB90(no_assertion); |
| 2540 | flushRB180(no_assertion); |
| 2541 | flushPolarB(no_assertion); |
| 2542 | #ifdef AMREX_USE_GPU |
| 2543 | flushParForInfo(no_assertion); |
| 2544 | #endif |
| 2545 | } |
| 2546 | } |
| 2547 | } |
| 2548 | |
| 2549 | void |
| 2550 | FabArrayBase::addThisBD () |