-
Notifications
You must be signed in to change notification settings - Fork 5.8k
Reuduce memory copy when communication between trainer and pserver. #9271
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
29 commits
Select commit
Hold shift + click to select a range
1377f06
init
gongweibao 0824a8a
Merge branch 'develop' of https://github.com/PaddlePaddle/Paddle into…
gongweibao a0ecc4e
modify py
gongweibao 0aba233
fix debugger
gongweibao 2de648d
add test_debugger.py
gongweibao 022479d
test
gongweibao 32fe144
fix learningratebugs
gongweibao f45b065
modify grpc
gongweibao 9b3197b
merge
gongweibao d159525
compile ok
gongweibao 55ccdb2
add client
gongweibao 12c8c06
add testtime
gongweibao ff01579
add some
gongweibao 69b6ee5
add test_serde
gongweibao 0e404ac
add selected rows
gongweibao 476b56c
test gpu and cpu ok
gongweibao 91e154b
add selectrows
gongweibao 6907810
clean up
gongweibao d3cd31b
add serializetraits
gongweibao 16c6e7e
compile ok
gongweibao c32f228
fix bugs
gongweibao 9d028f9
merge
gongweibao 9b7a35c
cleanup some
gongweibao ac081a2
add print
gongweibao 735a5c0
clean up
gongweibao e25a270
cleanup
gongweibao 0d36059
fix by comments
gongweibao 011c909
rename tensorparser
gongweibao 27c1ed7
cleanup codes
gongweibao File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,8 @@ | ||
if(WITH_DISTRIBUTE) | ||
grpc_library(sendrecvop_grpc SRCS bytebuffer_stream.cc sendrecvop_utils.cc grpc_client.cc grpc_server.cc PROTO send_recv.proto DEPS lod_tensor selected_rows) | ||
grpc_library(sendrecvop_grpc SRCS bytebuffer_stream.cc sendrecvop_utils.cc grpc_client.cc | ||
grpc_server.cc variable_response.cc PROTO send_recv.proto DEPS lod_tensor selected_rows) | ||
set(DISTRIBUTE_COMPILE_FLAGS "-Wno-non-virtual-dtor -Wno-error=non-virtual-dtor -Wno-error=delete-non-virtual-dtor") | ||
set_source_files_properties(test_serde.cc PROPERTIES COMPILE_FLAGS ${DISTRIBUTE_COMPILE_FLAGS}) | ||
cc_test(serde_test SRCS test_serde.cc DEPS grpc++_unsecure grpc_unsecure gpr cares zlib protobuf sendrecvop_grpc) | ||
cc_test(serde_test SRCS test_serde.cc variable_response.cc DEPS grpc++_unsecure grpc_unsecure gpr | ||
cares zlib protobuf sendrecvop_grpc) | ||
endif() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why need so many wrappers, just create the
::grpc::GrpcBufferReader
asZeroCopyInputStream
could be simpler.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Abstract type should not be a parameter.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So make it don't have any abstract type. The interface is simple enough to understand without this abstract.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
没看懂。。。。
Parse
函数需要支持ByteBuffer
和grpc_byte_buffer
两种类型的参数,他们都可以转成ZeroCopyInputStream
, 而ZeroCopyInputStream
是不能当做参数类型的。