Skip to content

Commit d3f5047

Browse files
authored
Merge pull request #13747 from panyx0718/doc
clarify the fraction_of_gpu_memory flag
2 parents 320c0d5 + ab798a2 commit d3f5047

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

paddle/fluid/framework/rw_lock.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,7 @@ struct RWLock {
4646
private:
4747
pthread_rwlock_t lock_;
4848
};
49+
// TODO(paddle-dev): Support RWLock for WIN32 for correctness.
4950
#else
5051
// https://stackoverflow.com/questions/7125250/making-pthread-rwlock-wrlock-recursive
5152
// In windows, rw_lock seems like a hack. Use empty object and do nothing.

paddle/fluid/platform/gpu_info.cc

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,11 @@ limitations under the License. */
2020
#include "paddle/fluid/platform/enforce.h"
2121

2222
DEFINE_double(fraction_of_gpu_memory_to_use, 0.92,
23-
"Default use 92% of GPU memory for PaddlePaddle,"
24-
"reserve the rest for page tables, etc");
23+
"Allocate a trunk of gpu memory that is this fraction of the "
24+
"total gpu memory size. Future memory usage will be allocated "
25+
"from the trunk. If the trunk doesn't have enough gpu memory, "
26+
"additional trunks of the same size will be requested from gpu "
27+
"until the gpu has no memory left for another trunk.");
2528

2629
namespace paddle {
2730
namespace platform {

0 commit comments

Comments
 (0)