libfoedus-core
FOEDUS Core Library
log_gleaner_resource.hpp
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2014-2015, Hewlett-Packard Development Company, LP.
3  * This program is free software; you can redistribute it and/or modify it
4  * under the terms of the GNU General Public License as published by the Free
5  * Software Foundation; either version 2 of the License, or (at your option)
6  * any later version.
7  *
8  * This program is distributed in the hope that it will be useful, but WITHOUT
9  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
10  * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
11  * more details. You should have received a copy of the GNU General Public
12  * License along with this program; if not, write to the Free Software
13  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
14  *
15  * HP designates this particular file as subject to the "Classpath" exception
16  * as provided by HP in the LICENSE.txt file that accompanied this code.
17  */
18 #ifndef FOEDUS_SNAPSHOT_LOG_GLEANER_RESOURCE_HPP_
19 #define FOEDUS_SNAPSHOT_LOG_GLEANER_RESOURCE_HPP_
20 
21 #include <stdint.h>
22 
23 #include <vector>
24 
26 
27 namespace foedus {
28 namespace snapshot {
35  enum Constants {
39  };
40  void allocate(uint16_t node_count);
41  void deallocate();
42 
51  struct PerNodeResource {
52  explicit PerNodeResource(uint16_t numa_node);
59 
60  const uint16_t numa_node_;
61  };
62 
63  // these are for the snapshot writer in gleaner's construct_root()
69 
70  std::vector< PerNodeResource > per_node_resources_;
71 };
72 
73 } // namespace snapshot
74 } // namespace foedus
75 #endif // FOEDUS_SNAPSHOT_LOG_GLEANER_RESOURCE_HPP_
memory::AlignedMemory work_memory_
Working memory to be used in gleaner's construct_root().
Root package of FOEDUS (Fast Optimistic Engine for Data Unification Services).
Definition: assert_nd.hpp:44
memory::AlignedMemory write_buffer_
used for writing out pages that have no children
std::vector< PerNodeResource > per_node_resources_
Local resource for the log gleaner, which runs only in the master node.
memory::AlignedMemory read_buffer_
used for reading intermediate results frome each reducer.
These buffers are used to read intermediate results from each reducer to compose the root page or oth...
Represents one memory block aligned to actual OS/hardware pages.
memory::AlignedMemory write_intermediate_buffer_
used for writing out pages that have children